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

Forums / Designing with Sitefinity / Create a popup menu in Sitefinity

Create a popup menu in Sitefinity

6 posts, 0 answered
  1. Troy Lawrence
    Troy Lawrence avatar
    56 posts
    Registered:
    07 Jan 2010
    16 Feb 2010
    Link to this post
    On the Telerik home page there is a button on the top right that says "Why?" referring to "why register".   When the user clicks it a nice menu pops up explaining why you should register.  It also has a nice little "x" button to close it.  I want to recreate this effect for my site but I don't know how.   Does anyone know how to do this in Sitefinity?
    I've attached a screenshot for clarity.
  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    25 Nov 2016
    17 Feb 2010
    Link to this post
    Hello Troy Lawrence,

    You have to use js and JQuery - .toggle()

    1. Create a div with a tag where you call the js function

    <a href="#" onclick="toggleWhyRegister(); return false; " class="tWhyRegister">Why?</a>
    <
    div id="whyRegister" class="tWhyRegisterExplanation" style="display: none; ">
    <a href="javascript:toggleWhyRegister();" class="closeWhyRegisterExplanation">Close</a>
    <strong>You need to be logged in to:</strong> <ul>
       <li>post in forums</li>
       <li>ask for support</li>
       <li>earn Telerik Points</li>
       <li>manage your account</li>
      <li>download your purchases</li>
     </ul>
    </div>

    2. Onclick you can call toggleWhyRegister

    function onclick(event) {
     toggleWhyRegister();
     return false;
     }

    3. toggleWhyRegister, get the div and style it.

    function toggleWhyRegister() {
    var whyReg = document.getElementById("whyRegister");
    whyReg.style.display = (document.getElementById("whyRegister").style.display == "block")? "none":"block";
    }


    All the best,
    Ivan Dimitrov
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
  3. Venkat
    Venkat avatar
    105 posts
    Registered:
    20 Nov 2008
    28 Sep 2010
    Link to this post
    Hi Ivan,

    In our application we have a requirement that ,when we clink on a link in the top menu, it shoud open a modal popup widow. Is it possible using sitefinity Rad menu control.

    Thanks
    Venkat.
  4. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    25 Nov 2016
    28 Sep 2010
    Link to this post
    Hello Venkat,

    You can use a dead link for the menu item from which you will open a windows and then call radopen function of RadWindow control. Another option is using RadToolTip control or jQuery Modal Window.

    All the best,
    Ivan Dimitrov
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  5. Venkat
    Venkat avatar
    105 posts
    Registered:
    20 Nov 2008
    01 Oct 2010
    Link to this post
    Hi Ivan,

    Thank you for your reply.

    What is a dead link? We can add pages of type Normal,Group and External.

    So How can I add an external page which shows up as a modal popup when we click on the menu.

    Not in a new window.

    Thanks
    Venkat
  6. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    25 Nov 2016
    01 Oct 2010
    Link to this post
    Hello Venkat,

    The NavigateUrl of the link should ends with "#" or you just have to remove the value set for NavigateUrl, because when you click on the link you will be redirected instead of getting a pop up.

    Regards,
    Ivan Dimitrov
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Register for webinar
6 posts, 0 answered