![]() |
other skin dir depending on user
Is it possible to change the skindir location on the fly depending on the type of user.
Like: if user = eq "something" In smarty.php this is in. $smarty->template_dir = $xcart_dir."/skin1"; $smarty->compile_dir = $var_dirs["templates_c"]; $smarty->config_dir = $xcart_dir."/skin1"; $smarty->cache_dir = $var_dirs["cache"]; $smarty->secure_dir = $xcart_dir."/skin1"; $smarty->debug_tpl = "file:debug_templates.tpl"; $smarty->assign("ImagesDir",$xcart_web_dir."/skin1/images"); $smarty->assign("SkinDir",$xcart_web_dir."/skin1"); Thnx |
Re: other skin dir depending on user
What are you trying to achieve, just showing a different skin for each usertype?
|
Re: other skin dir depending on user
Yes thats what i want.
Better if it would work with different membership levels..... thnx |
Re: other skin dir depending on user
Then just use an {if} statement in customer/home.tpl on the line that controls which skin is displayed. No need to change the whole skin directory:
{if $usertype eq "C"} <LINK rel="stylesheet" href="{$SkinDir}/skin1.css"> {else} <LINK rel="stylesheet" href="{$SkinDir}/skin2.css"> {/if} Check the sticky thread on {if} statements for membership level statements. |
All times are GMT -8. The time now is 08:40 PM. |
Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.