Start a new discussion

To start a new discussion please visit the discussions section of the GitHub home page of the project.

Discussions on GitHub

You can also search our old self-hosted forums for any useful information below but please note that posting new content here is not possible any more.

Replace contents of div when submenu item clicked

Home Forums Older releases 0.9.x Replace contents of div when submenu item clicked

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #1420
    jlpaltenghe
    Participant

    I am new to web development. I have a page that uses the vertical menu with submenu items. Each submenu item represents a different report object. I want to display all reports within the same

    upon the user clicking the respective submenu item. How do I accomplish this?
    #1777
    admin
    Keymaster

    You will need to call a JS function that will update your DIV on item click. Here is some sample code (of course, it can be done in many other ways):

    HTML

    <li><a href="#" data-page="home">Home</a></li>

    JS

    $('#main-menu').bind('select.smapi', function(e, item) {
    	var page = $(item).data('page');
    	// code to fetch the new page and update the DIV content
    	// loadPage(page);
    	return false;
    });
Viewing 2 posts - 1 through 2 (of 2 total)
  • The forum ‘0.9.x’ is closed to new topics and replies.