+1-888-365-2779
Try Now
More in this section

Forums / 3.x Pre-release forums (retired) / Scrolling inside Page Edit

Scrolling inside Page Edit

8 posts, 0 answered
  1. kevin
    kevin avatar
    16 posts
    Registered:
    30 Jan 2007
    26 Apr 2007
    Link to this post
    Seems to be a simple thing, but apparently users can't scroll to edit content on a page. We've tried Firefox and IE.
  2. Sean
    Sean avatar
    271 posts
    Registered:
    31 May 2006
    27 Apr 2007
    Link to this post
    Hi Kevin,

    I have had this problem before. Have you wrapped your Master pages in the <div id="cmsWrapper"></div> as described in the user manual under the Masterpages and Templates section.

    Regards
    Sean
  3. Ben Alexandra
    Ben Alexandra avatar
    215 posts
    Registered:
    15 Sep 2012
    06 Jul 2007
    Link to this post
    Hi,

    I have this same issue.  I've now put such a div around my content, but it didn't help, at least not in IE7.  Here's my template...

    <body> 
    <sf1:CmsForm id="cmsForm" runat="server">  
      <asp:Label ID="lblStyleSheet" runat="server" Text="<link href='/common/IE7.css' type='text/css' rel='stylesheet' />" /> 
      <div id="cmsWrapper">  
        <div id="page_wrapper"> ... </div> 
      </div> 
    </sf1:CmsForm>   
    </body> 

    Any suggestions?

    Thanks

    Ben
  4. Sean
    Sean avatar
    271 posts
    Registered:
    31 May 2006
    07 Jul 2007
    Link to this post
    Hi Ben,

    You need to ensure that the cmsWrapper div wraps around everything in your template including the form template.

    So your code should be:

    1<body>  
    2  <div id="cmsWrapper">   
    3<sf1:CmsForm id="cmsForm" runat="server">   
    4  <asp:Label ID="lblStyleSheet" runat="server" Text="<link href='/common/IE7.css' type='text/css' rel='stylesheet' />" />  
    5    <div id="page_wrapper"> ... </div>  
    6</sf1:CmsForm>    
    7 </div>  
    8</body>  

    By the way to ensure XHTML compliance your style sheet should only be included in the <head></head> section of the page.

    If you only want the css to be included if the website is running IE7 you can use this code instead:

    <!--[if IE 7]><link rel="stylesheet" type="text/css" href="/common/IE7.css" /><![endif]-->

    Cheers
    Sean
  5. Sean
    Sean avatar
    271 posts
    Registered:
    31 May 2006
    07 Jul 2007
    Link to this post
    Oh and sorry it is mean to be <div class="cmsWrapper"> not <div id="cmsWrapper">

  6. Ben Alexandra
    Ben Alexandra avatar
    215 posts
    Registered:
    15 Sep 2012
    07 Jul 2007
    Link to this post
    Hi,

    So I sorted it out and it's working perfectly.

    When i put the tag:
    <div class="cmsWrapper"
    around the WHOLE form, it did NOT work right.  The whole thing scrolled, but so did the list of controls and it wasn't what I wanted.

    I then moved the same tag (above) INSIDE the form and now it's perfect!  Scroll just the page, not any of what Sitefinity puts around it for editing.

    Note it's class="cmsWrapper", NOT id=.

    Sean, as for the stylesheet, I have code that runs in the background that checks the browser and adds another stylesheet based on which browser they're using (IE6, IE7, FX, Safari, etc.).  The stylesheets generally just have small fixes to a couple of things and are usually only 4 or 5 lines total.  If it doesn't need a stylesheet, it hides that line.  I have IE7 as the default in case the code fails somehow.  Hope that makes sense.

    Ben
  7. Sean
    Sean avatar
    271 posts
    Registered:
    31 May 2006
    08 Jul 2007
    Link to this post
    Hi Ben,

    Sorry I was trying to work from memory as to where to exactly place the div tag....

    As for what I was saying with the IE7 fixes currently from what I can see you Label is actually rendering the stylesheet in the Body of the page, which breaks Standard Compliance....

     I understand what you are trying to do and while it may work, it isn't correct that is all I was just trying to point out.  You can choose not to use it that way if you wish, but if you validate your HTML you will find it tells you that putting your style sheets in the body isn't Standards compliant.  It will work for now but if you ever try and change your website to XHTML Strict it will stop working.

    http://www.w3schools.com/tags/tag_link.asp

    Regards
    Sean
  8. Ben Alexandra
    Ben Alexandra avatar
    215 posts
    Registered:
    15 Sep 2012
    08 Jul 2007
    Link to this post
    Hi Sean,

    Point taken.  I'll move it to the <head>.

    Thanks for your feedback and I'm glad I got this issue resolved, as it's a bit tricky for people to add controls and content without the scrolling.

    Ben
Register for webinar
8 posts, 0 answered