How to store a URL parameter (PHP & Smarty)

Bluesboy
Bluesboy's picture

Joined: 2007-11-11
Posts: 30
Posted: Sat, 2007-12-15 22:13

I've a Joomla site, within an iFrame I show Gallery.
How to store a URL parameter for later use?

In order to remove the navigation bar and footer I have add a parameter joomla_iframe to the my URL: http://www.MySite.nl/gallery2/main.php?g2_language=nl&joomla_iframe=ON

I've changed theme.tpl:

{if ($smarty.get.joomla_iframe == "ON")}
{* No Navigation Bar *}
{else}
... Navigation bar ...
{/if}

This works fine until I click an album or picture and a new pages is shown. The navigationbar is shown again because the new URL does not have joomla_iframe=ON. Therefore I would like to store this value for usage on 'new' pages. How can I do that?

I've changed main.php:

/* Write out our session data */
$session =& $gallery->getSession();

global $joomla;
$joomla = $_GET['joomla_iframe'] ;
$session->put('joomla_iframe', $joomla);
$ret = $session->save();
}

But I have not yet succeeded ...
I still can't change theme.tpl into:

{if ($smarty.session.joomla_iframe== "ON")}
{* No Navigation Bar *}
{else}
... Navigation bar ...
{/if}

Nor into:

{if ($joomla== "ON")}
{* No Navigation Bar *}
{else}
... Navigation bar ...
{/if}