Adding CMSMS menus to SMF

Do something cool with CMS? Show us ...
This board is for 'Answers', and the discussion of answers... Not for questions.
Post Reply
krussell
Forum Members
Forum Members
Posts: 32
Joined: Wed May 16, 2007 2:00 pm

Adding CMSMS menus to SMF

Post by krussell »

I have a site which uses CMSMS and SMF at http://www.edinburghrc.co.uk
My SMF install is simply skinned to match my CMSMS template (essentially creating a new SMF theme where the index.template.php page is topped and tailed by the same html as my CMSMS template.
However, the SMF forum pages simply had a "Back to website" link to return to CMSMS, with no other menu options, and I always wanted to make things more seamless.

Having studied the forum, I came across various solutions to SMF integration, including this:
http://forum.cmsmadesimple.org/index.php/topic,1785.0.html
This seemed a bit convoluted, and involved hacking away some key structure of the SMF pages, as well as messing with the CMSMS navigation and redirects.
Taking a simpler approach, I concluded that I only really needed to include the CMSMS menus on my SMF page to "integrate". My templates are pretty stable, so it is not a huge overhead to have to update the html in both CMSMS and SMF if something (rarely) changes.

My solution was to create a new CMSMS template with a tag referencing my menu and nothing else:
{menu template='kcr_drop_menu.tpl' collapse='0'}
and use this template to create a new page with empty content {}. This page is not shown in the menu structure.
I then added the following line to my SMF template to call the new page and display the CMSMS menu on the forums page:
readfile("http://www.edinburghrc.co.uk/menu");

This is not an original idea. I simply pulled together information from a couple of forum posts, including this one:
http://forum.cmsmadesimple.org/index.php/topic,12634.0.html
I also nicked ideas from another post, which I cannot now locate, so apologies for not crediting the originator of the idea!

I think full SMF integration is a bit of an unattainable "holy grail" at present, and the best solution is to keep the two applications separate and resort to matching templates and common navigation.
Last edited by krussell on Fri Feb 06, 2009 11:38 pm, edited 1 time in total.
SimonSchaufi

Re: Adding CMSMS menus to SMF

Post by SimonSchaufi »

you can get only the menu without anyting else like this:

index.php?mact=MenuManager,cntnt01,default,0&cntnt01showtemplate=false
krussell
Forum Members
Forum Members
Posts: 32
Joined: Wed May 16, 2007 2:00 pm

Re: Adding CMSMS menus to SMF

Post by krussell »

I saw that solution in another forum post, and originally intended to use it, because it is neater. However, I wanted to use a specific template with the menu, and wasn't able to find documentation to explain the syntax of the parameters for the module action call.
Post Reply

Return to “Tips and Tricks”