By zeroagain on
I wish to display a block if user is using any version of Firefox web browser.
Please give the required php code. Also mention changes for any version of chrome web browser.
I wish to display a block if user is using any version of Firefox web browser.
Please give the required php code. Also mention changes for any version of chrome web browser.
Comments
hi i think this link can help
hi
i think this link can help you:
http://php.net/manual/fr/function.get-browser.php
A quick solution
Hi,
Please go to that specific block configure page and in "Page specific visibility settings" section of the block configure , select the 3rd option which says "Show if the following PHP code returns TRUE (PHP-mode, experts only)."
And
Paste this code (<?php ?> should be included too).
Thanks
Changing this
Changing this line:
To this:
Is a little less resource intensive. Regex is best saved for searching for patterns, rather than simple strings.
Edit: Actually looking at the whole thing, you could rewrite it like this:
Contact me to contract me for D7 -> D10/11 migrations.
Thanks
It works!