6 Replies Latest reply: Nov 14, 2012 6:03 AM by anuverskrenenaim RSS

    Is there any way to edit an uneditable region and still keep it uneditable?

    anuverskrenenaim

      I have a hobby site: http://www.grantbarker.com

       

      I've just got into Facebook and Google+ and I've added a couple of share this site buttons in my main menu. The main menu is linked to a template so that any changes propogate to the other pages. I'm not much of a coder. I'd like the Facebook and Google+ buttons on each page's menu to simply have that pages url to share (share this page, not site). This means that I need them to be different on each page, but I'd like the menu itself to propogate from my template.

      The menu is more important and I don't mind adjusting the Facebook and Google+ button code by hand.

       

      How would you do this? Is it possible to break into the uneditable region via the code screen to hack the page, so to speak?

       

      Thanks for any advice.

       

      (I'm not sure if it's possible to have the actual 2 buttons themselves independent from the menu's uneditable region.)

       

      Have a good day. I must get ready for work. Will check back this evening.

        • 1. Re: Is there any way to edit an uneditable region and still keep it uneditable?
          Nancy O. CommunityMVP
          1. Open the template.dwt file. It should be in your site's Templates folder. 
          2. Add what you need to the page. 
          3. Save Template. 
          4. When prompted to update child pages, hit YES.

          Content in uneditable regions will propogate to all child pages spawned from that template.dwt.

           

           

          Nancy O.

          • 2. Re: Is there any way to edit an uneditable region and still keep it uneditable?
            anuverskrenenaim Community Member

            Sorry, I didn't maybe word it correctly?

             

            I already use a template for the main menu (plus other regions) on all of my 60 pages.

             

            If I want to change just a couple of things on some of the menus on some of the pages, but keep most of the menu the same, is it possible to hack into the code on some of the pages, just to change a few small details?

             

            I realize that using the template will propogate to all of my child pages. I just want to be able to also add a few extra changes to some of those child pages when necessary.

             

            EG. Imagine I was a dentist. I want all of my 60 patients to have the same mouth and exactly the same set of teeth, but a few of them I would like to also have special fillings on their teeth.

             

            I wonder if it is possible to open a few of the child pages in code view and make a few small cosmetic changes to the code when necessary.

             

            When I update my main menu with the template it will update all of the child pages as expected. Then I'd like to hack a few of those pages to make tiny changes to those menus.

             

            Sorry, if I'm not explaining myself so well.

             

            Thanks for any advice.

            • 3. Re: Is there any way to edit an uneditable region and still keep it uneditable?
              MurraySummers CommunityMVP

              If I want to change just a couple of things on some of the menus on some of the pages, but keep most of the menu the same, is it possible to hack into the code on some of the pages, just to change a few small details?

               

              You could only do this by detaching those pages from the template - a very poor approach.  What you are describing is an indication that your template is not flexible enough to meet your site's needs.  You will need to redesign your template to allow such things to happen, or you will need to figure out how to add these cosmetic changes using only CSS.  If you could do the latter, then it's quite simple to place page-specific CSS on the desired child pages by adding an embedded stylesheet in the editable region called 'head' on each.

               

              So, specifically what kind of changes are you wanting to change on these pages?  Maybe it would be a good idea to give us a link to one of these pages so we can see what would be involved in making those changes - can you?

              • 4. Re: Is there any way to edit an uneditable region and still keep it uneditable?
                anuverskrenenaim Community Member

                Thanks. That makes sense and was probably what I expected. Basically I've added a Facebook button and a Google+ to my main menu here http://grantbarker.com/ (just a hobby). The menu is uneditable as it's controlled from the template, as one would expect. However, the url `href="http://www.facebook.com/share.php?u=www.grantbarker.com/&t=Samsung Galaxy Note 2 ROMs"..' on those 2 buttons needs to be changed for a few, if not all of my main pages on my site. Otherwise the buttons when clicked will only recommend the front page and not the actual page that the viewer is looking at and might want to share.

                 

                I'm not sure if it's possible to create a smaller editable region inside my main menu just for those 2 buttons. I'll have to experiement.

                 

                While you are there and very helpful (both of you), what does the &t= stand for in the above url? And what should we ideally write after it? Does it stand for title?

                 

                Thanks for your time and advice.

                • 5. Re: Is there any way to edit an uneditable region and still keep it uneditable?
                  MurraySummers CommunityMVP

                  I'm not sure if it's possible to create a smaller editable region inside my main menu just for those 2 buttons. I'll have to experiement.

                   

                  This would be a bad idea, because it would mean that those two buttons would then not propagate to any page meaning that these two buttons on all pages would then have to be manually maintained.

                   

                  Consider these alternative approaches:

                   

                  1.  Make your menu actually have duplicates of those two buttons with the originals and the duplicates somehow tagged so that you can discriminate between them with CSS.  Have the default CSS reveal the unmodified buttons and hide the modified ones (using display:block | none).  Use an embedded stylesheet on the desired pages to reverse that display.

                  2.  Create an editable region for the entire menu.  Then create two Library items: one for the unmodified menu and another for the modified menu.  Place the desired Library item into the editable region on each page.

                  3.  Create a server-side include for each of the two menus.  Include BOTH on each page.  Use embedded CSS to make the desired menu instance visible (as in #1, above).

                   

                  Would any of those work?

                  • 6. Re: Is there any way to edit an uneditable region and still keep it uneditable?
                    anuverskrenenaim Community Member

                    OK. Thanks very much MurraySummers. I'll try tro get my head around those suggestions and see which one I can apply. Thanks a lot for your time and effort.

                    Thank you too Nancy O for your information.