More in this section

Forums / Developing with Sitefinity / How to identify page and template design modes

How to identify page and template design modes

2 posts, 0 answered
  1. Arto
    Arto avatar
    6 posts
    10 Mar 2014
    21 May 2014
    Link to this post


    I have this small problem: I want a section of html  (with some placeholders for widgets)  to

    - be visible in frontend + preview,

    - not show in page edit mode

    -display itself a bit differently in page template edit mode so widgets can be inserted there to placeholders

    (This is a small floating left side menu containing search and  social sharing widgets that can clicked open by user and it's included and only edited in template)

    Using IsDesignMode and IsPreviewMode and a custom control to display required css + javascript, I managed to get the functionality visible in frontend and editable on design modes, no problem there.

    But what is the best way to identify if we are in page or page template design mode so I can show the html differently in each case? 

  2. Steve
    Steve avatar
    3037 posts
    03 Dec 2008
    21 May 2014 in reply to Arto
    Link to this post

    Its easy :)

2 posts, 0 answered