Jump to content

Variable to know Broser type and version


Recommended Posts

I would like to make some changes in header.tpl depending on user's browser type and version.
Is there any smarty variable that could tell me this ?
I have seen that in php I can find the HTTP_USER agent - but how do I get this in a smarty template ?

Link to comment
Share on other sites

Many thanks !

I have found also interesting variables : http://www.sandfighter.net/prestashop/smarty-globals-in-prestashop-uncovered/
But I believe that I should get acquainted with smarty first.
Taking your starting point I have found :

{if "MSIE"|eregi:$smarty.server.HTTP_USER_AGENT or "Internet Explorer"|eregi:$smarty.server.HTTP_USER_AGENT} .... {/if}

Link to comment
Share on other sites

×
×
  • Create New...