I am not a PHP coder, I just dabble a bit, so I was struggling to find a way to create custom blocks using HTML with menus and submenus. Someone asked me about how to do it, as they had seen this site
hereEventually I figured they probably used a variety of different blocks in exactly the same position.
I have a little menu on my top page called "General" (yet to add the little image to the left of the menu)
macambridgeIt turns out it is not to hard to do this with XOOPS unlimited blocks power.
This is a simple HTML method, not a php method
I am basing the code here on my little "General" menu
First you create a custom block for your "Top Page", your "Top Page" is whatever page is set to default i.e "News" or "None" if you don't wish to load a module at the start.
Go to System Admin/Blocks and insert HTML code similar to the following for your included links in a new custom block. You will find the "classes" your style sheet is using in System Admin "Templates", look for "System" and click on "List". Then look for system_block_mainmenu.html and click on "Edit"
This will reveal the classes your template is using. My X2t Template uses "menuMain" and "menuSub". These "Classes" are related to your theme's style sheet in your themes folder (style.css)
So for your first Top Page block insert the code similar to this layout, with your own paths and links.
Not all this needed, but it works for me.
Make this block only visible in the Top Page for now, you can choose other pages or modules later.
The "modules/mypage" link is a little module I made, it is very easy to do your own one page HTML modules--which create one HTML page wrapped within Xoops. You can also call these modules anything you wish. I will make one available for download with instructions on how to make any amount of clones by just altering a couple of lines.
The advantage of having these modules is that you can choose to make your block visible in that page only in blocks, because the module is listed. Of course you can create another block with the same name in a link to an already existing module if you wish.
They also produce a neat link in your browser i.e.
http://www.yoursiste.com/modules/mypagename/rather than:
http://www.yoursite.com/modules/wfsection/...php?articleid=3Not as sophisticated as wfsections which I like, but handy for one-of HTML pages.
Edit: I added a download in my site forum
Edit: remember no "Global" search ability included, trying to figure out that one
Now we creat the opened "submenu" block for the destination page.
To do this create another block with the same name and postition, to be made visible in the destination page i.e for the link "My Home Town"
Note: when creating blocks you can select which modules the block is visible in by holding down Ctrl on your keyboard for multiple selection. It is also better to click on "Edit" to the right of an existing block and make your selections in the resulting dialogue box.
Insert code similar to this with your own paths.
Notice I have an external link included. I can also have links to any other module, article or page.
Also notice the layout of this line, you may just need need this style for linking from the modules folder (two levels down in this example)
Next, I create individual submenu blocks with the same name and position for each page or module I wish the submenu block to appear in. I can have my non-submenu blocks appear in multiple pages by clicking on "Edit" to the right of the block on blocks admin.
(Submenus and extra links can also be added to the standard mainmenu, see the link "mypage" in my mainmenu, I will add a bit about that later)
Remember to call the blocks by the same name, and place in the same position--they have different id no's assigned to them by Xoops, and grant appropriate permission in "Groups"
It is really a trick of the eye..you have just made a variety of different blocks, and some have more links than others?