Link clicking inside a panel bar

5 posts, 0 answers
  1. Gabriel
    Gabriel avatar
    79 posts
    Member since:
    Nov 2011

    Posted 25 Dec 2011 Link to this post

    I have a panel bar with several items inside. Each <li> item has a regular HREF link, which, when clicked, redirects the page as it is supposed too.

    Problem is, when I try to override a link using jQuery or just bind a click event to any element within the panel bar, nothing works.

    I think I am missing something here. The list item is as follows:
    <li><a class="popup" href="gosomehwereelse">click me</a></li>

    The jQuery code I have is:
    $("a.popup").click(function (e) {
            e.preventDefault();
            // do something...
        });

    No matter what I try, it seems impossible to override link clicks when the link is inside a panel bar list...

  2. Petyo
    Admin
    Petyo avatar
    2439 posts

    Posted 26 Dec 2011 Link to this post

    Hi,

    You can bind to the kendo PanelBar select or expand event - see this example for more details. However, it really depends on what you are trying to accomplish by preventing the default event here. Can please provide some more details?

    Greetings,
    Petyo
    the Telerik team
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  3. Kendo UI is VS 2017 Ready
  4. Gabriel
    Gabriel avatar
    79 posts
    Member since:
    Nov 2011

    Posted 26 Dec 2011 Link to this post

    I have a PabelBar with every item in it containing a link.

    When a link is clicked, the browser follows it. What I'm trying to do is override links that contain the class 'popup'.

    Problem is, I can't override them.
  5. Petyo
    Admin
    Petyo avatar
    2439 posts

    Posted 27 Dec 2011 Link to this post

    Hello,

    I am not sure what the issue may be. Failed reproducing it in the attached example. Is it possible for you to modify it, so that we can exhibit the problem? 

    Regards,
    Petyo
    the Telerik team
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  6. Sumit
    Sumit avatar
    2 posts
    Member since:
    Apr 2012

    Posted 04 Apr 2012 Link to this post

    Hello,

    I am also facing the same problem with panel bar item.
    I am doing POC to move our one of the application to Mobile and this is the first time I am using KendoUI.
    I am new to HTML and Jquery.

    I have a panel bar which contains multiple items and when I click on any item it should perform some task.
    (please see the snapshot for more detail)

    Here I want when I click on one of the item lets say "Attendance" it must show the data in grid.
    And data must come from DB. (I need to develop a widget)
    Please help me how can proceed further.

    Thanks in advance,
    Sumit Purothi.
Back to Top
Kendo UI is VS 2017 Ready