Solved

Adobe Contribute - How to selectively lock only particular code in a page from editing or configure to behave?

Posted on 2013-01-04
4
597 Views
Last Modified: 2013-02-05
Hello Experts,

I created Classic ASP web pages using Dreamweaver but someone else is responsible for updating them using Contribute. I have a submenu in a div on each page that is not part of the template where the links in the aforementioned submenu can be updated.

The problem is whenever a link is minutely updated and the page saved, the div moves out of place- a line up or down. (No line spaces were added, just the name of the link changed and /or the URL.)
Is there a way to correct this? Or a configuration in Contribute made where the code behaves despite the update?

Thanks in advance.
0
Comment
Question by:colonelblue
  • 2
4 Comments
 
LVL 70

Expert Comment

by:Jason C. Levine
ID: 38746151
The problem is whenever a link is minutely updated and the page saved, the div moves out of place- a line up or down. (No line spaces were added, just the name of the link changed and /or the URL.)

Can you examine a before and after version to see if Contribute is adding an extra line break or p tag to the HTML?
0
 
LVL 52

Expert Comment

by:Scott Fell, EE MVE
ID: 38746153
I think you have to have contribute too and make yourself the owner of the page and then only allow edits to editable areas.  

One thing you can try is to make your submenu a server side include.  The the others can just edit that and leave your div alone.

Mainpage.asp

<div id="menu">
<!--#include virtual="/theSubMenu.asp"-->
</div>

theSubMenu.asp
<ul>
<li>menu</li>
<li>menu</li>
<li>menu</li>
</ul>
0
 

Author Comment

by:colonelblue
ID: 38746284
Hello and thank you.
Trouble is I made the submenus unique for each page since they can have  relative links to them .

Is there a setting in Contribute where I can toggle to not add any extra code?

I will not be able to do a before and after until Monday when I am back at the office.

I would so appreciate your further assistance.

Thank you in advance.
0
 
LVL 52

Accepted Solution

by:
Scott Fell,  EE MVE earned 500 total points
ID: 38749580
My experience is  if  you give somebody a chance to mess it up they will.  

One option is to convert your site to using dreamweaver templates  http://help.adobe.com/en_US/dreamweaver/cs/using/WScbb6b82af5544594822510a94ae8d65-7abea.html where you make certain areas off limits to editing (locked regions) and certain areas open for edits (editable regions).  If you have contribute too, you can make it so you are the contribute site admin which will block contribute users from messing with your stuff.  http://help.adobe.com/en_US/dreamweaver/cs/using/WScbb6b82af5544594822510a94ae8d65-7f37a.html.

If you don't have contribute, you can still make the templates but you just need to instruct your users not to mess with anything but editable regions.  Because they will be the contribute site admin, they can choose to stay within the lines or not.  

 If you have not used dreamweaver templates before I would suggest making a few practice pages first and notice how the links work on your hard drive vs live.  If you don't have the site set up correctly, sometimes you find the links seem fine off line but live they are broken. It is all based on how you have the "testing" server settings in dreamweaver.

As you can probably see, making a separate navigation for each page is time consuming.  Either way, you still have to touch each page.  I would consider using the suggestion of include files for your navigation.  It will make your life a lot easier.  If you place the include file in a new folder such as www.mysite.com/myincludes/nav1.asp but the actual files are on mysite.com/page1.asp and mysite.com/page2.asp your relative links will still work if all pages on the same level.  The reason is the include file in a separate folder is being loaded into the page1.asp.  If you view source on page1.asp you will never see any sign of where the include file is, you will just see rendered html.

If your site is built on multiple levels like mysite.com/group1/index.asp  mysite.com/group1/sub1/index.asp you can simply change your links from relative ../index.asp to absolute  /group1/index.asp  or you can use mod rewrite to change the lnks.

In any case, by using the include file, not only will you protect your code, you will make your life easier if you have to edit your navigation because it will be in just one place. Instead of updating each page, you update in one place.

You ca use multiple include files for your nav.  Maybe you have 20 page site with 5 different groups of navigation. Just make 5 different include files.  You can also use your asp/vb to dynamically generate the sub menues and just one include file like below.

<%

Select case page
   case "page1.asp"
   response.write "Link A.1 | Link A.2 | Link A.3"
 
  case "page2.asp"
     response.write "Link B.1 | Link B.2 | Link B.3"

  case "page3.asp"
     response.write "Link C.1 | Link C.2 | Link C.3"
end select

%>
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

I recently decide that I needed a way to make my pages scream on the net.   While searching around how I can accomplish this I stumbled across a great article that stated "minimize the server requests." I got to thinking, hey, I use more than one…
I still run into .cgi files every now and then. In some instances, I actually prefer the simplicity of a .cgi script to other options. Since I use DreamWeaver extensively, what I needed was a way to open .cgi scripts in Dreamweaver. And I wanted to …
The purpose of this video is to demonstrate how to automatically show related posts at the bottom of a blog post in WordPress. This will be demonstrated using a Windows 8 PC. Plugin “Yet Another Related Posts Plugin” will be used. Go to your…
The purpose of this video is to demonstrate how to exclude a particular blog category from the main blog page. This is can be used when a category already has its own tab, or you simply want certain types of posts not to show up on the main blog. …

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now