self links in global content blocks?

For questions and problems with the CMS core. This board is NOT for any 3rd party modules, addons, PHP scripts or anything NOT distributed with the CMS made simple package itself.
Post Reply
Chris..S
Forum Members
Forum Members
Posts: 23
Joined: Thu Apr 20, 2006 5:23 pm

self links in global content blocks?

Post by Chris..S »

I am getting a PHP fatal error when attempting to use a self link within a global content block.  Reading around these forums,  I get the impression that it should be possible.

This is the global content block

Code: Select all

<div id="footer">   
  <p class="links">{cms_selflink page='disclaimer-en' text='disclaimer'} | {cms_selflink page='sitemap-en' text='sitemap'} </p>
  <p class="smallprint">©2007 Bleh Limited.</p>
</div><!-- #footer -->
And this is the error

Code: Select all

Fatal error: Call to undefined function smarty_cms_function_cms_selflink() in /path/to/cmsms/lib/content.functions.php(669) : eval()'d code on line 27
Any advice to solve the error or somehow use cms links within global content blocks?
Chris..S
Forum Members
Forum Members
Posts: 23
Joined: Thu Apr 20, 2006 5:23 pm

Re: self links in global content blocks?

Post by Chris..S »

Its more complex than mentioned above.

I have a userdefined tag to determine a link to alternate language versions of the current page.  That user defined tag works out the id of the pages to be linked to, updates its parameter block and calls the self link function.  Its seems that under some circumstances the userdefined tag is eval'd before the in built tags are loaded.

It makes sense for me to treat a language link as an extension of self link, that way all the parameters that apply to self links also apply to language links and they are processed in the same way they would normally be.    And if self link is updated in a CMS MS update, the user defined tag gets updated too.

Does anyone have any ideas how I can get around the loading order problem?
Post Reply

Return to “CMSMS Core”