(Module) menu's

This forum is only for questions or discussions about working with the mojoPortal source code in Visual Studio, obtaining the source code from the repository, developing custom features, etc. If your question is not along these lines this is not the right forum. Please try to post your question in the appropriate forum.

Please do not post questions about design, CSS, or skinning here. Use the Help With Skins Forum for those questions.

This forum is for discussing mojoPortal development

This forum is only for questions or discussions about working with the mojoPortal source code in Visual Studio, obtaining the source code from the repository, developing custom features, etc. If your question is not along these lines this is not the right forum. Please try to post your question in the appropriate forum.

You can monitor commits to the repository from this page. We also recommend developers to subscribe to email notifications in the developer forum as occasionally important things are announced.

Before posting questions here you might want to review the developer documentation.

Do not post questions about design, CSS, or skinning here. Use the Help With Skins Forum for those questions.
This thread is closed to new posts. You must sign in to post in the forums.
6/10/2008 6:29:47 PM
Xje
Gravatar
Total Posts 1

(Module) menu's

I'm developing a module in mojoportal, but I need a quick start on some basic things like creating some sort of submenu. On mojoportal.com, after clicking on documentation/community, a second / new horizontal menu appears just below the header-image. How can I create this for my own module? I've been busy trying get the pagemodulecontrol to work, but it doesn't show anything at all after databinding. Is this the right control to use?

My second question is that i'm interested in how you created the links at the left side of the screen at documentation/developer docs. Is there an easy way or a standaard control for this which I can use? (in this last situation I don't want to add pages but I want it to be in my own module).

And finally, is there a possibility to create extra links in the main menu, and again not by creating new pages. So just a link to a page (which refers to a page in my module).

Thanks in advance..

 


 

6/11/2008 6:49:51 AM
Gravatar
Total Posts 18439

Re: (Module) menu's

Hi,

The SiteMenu and PageMenu have only to do with pages and nothing to do with modules. If you need a menu in your module you need to implement that your self.

The Site Map shows the entire hierarcy of content system pages and the Site Menu and page menu are using the same data as the site map but binding to specific nodes. So in this site the topmost menu is a SiteMenu and it is configured to show top level nodes only. Then there is a PageMenu styled the same as the SiteMenu (horizontal) which shows the next level, ie child pages below the top level menu. But it again is limited to show only 1 level and it has a starting node offset of one which makes it start at the first level of child pages. Then there is a 3rd pagemenu which has starting node offset = 2 which shows children below the second level menu (this is the one on the left with vertical links). This 3rd menu is configured as treeview so ti can show all further levels. The skin on this site was based on styleshout-brightsideoflife but is not the same as the one incldued with mojoportal releases, that one only has 2 levels of menus. The andreasvilund-02 skin has 3 levels and andreasviklund-02-alt1 has 4 levels of menu. But all of this is just different ways of showing the same site map.

So all the items in all the menus are pages not modules. The content system are virtual pages, there is really only one physcial page which handles requests for all content system pages and that is Default.aspx, so all content pages are really using Default.aspx?pageid=x, but we use Url re-writing to make friendlier urls. For each request the UrlRewriter http module gets the request first and looks it up in the db to see ifit is a friendly url, if it is then it rewrites to the real url, typically Default.aspx?pageid=x

So for example on this site blog.aspx is a friendly url that maps to Default.aspx?pageid=2.
This page has a blog module on it. Since the blog is a complex feature, it also has other physical pages outside the main menu and it links to those pages in a way to keep the context of the current content page intact. It does this by passing the pageid and module id in the query strring to its supporting pages. So for example the blog has links for categories and the links have /BlogCategoryView.aspx?cat=x&pageid=y&mid=z so it always passes the pageid and module id to keep the current page context. So a menu is nothing but links. Inside your module you need to implement your own menu or navigation by creating your own links an you should make sure if you link to a physical page that is part of your feature that you always pass these params pageid and mid plus any other params you need. This makes it seemless getting back to the original content system page.

Another thing to note is that recently we added friendly urls in the blog. So the title of a blog post is a link that really goes to /BlogView.aspx?pageid=x&mid=y&ItemID=z but we create a friendly url for each post and use the url rewriter to rewrite to the real url

Hope it helps,

Joe

You must sign in to post in the forums. This thread is closed to new posts.