Title: Browser dependant content
Last modified: August 18, 2016

---

# Browser dependant content

 *  Resolved [anabelle](https://wordpress.org/support/users/anabelle/)
 * (@anabelle)
 * [19 years, 6 months ago](https://wordpress.org/support/topic/browser-dependant-content/)
 * Is there a way of showing some content only for “non firefox” visitors?
 * i want to display a “This site works better with firefox, get it here” but i 
   think is ridiculous to show such text to firefox users.
 * Is there something i can do to do this?

Viewing 9 replies - 1 through 9 (of 9 total)

 *  [whooami](https://wordpress.org/support/users/whooami/)
 * (@whooami)
 * [19 years, 6 months ago](https://wordpress.org/support/topic/browser-dependant-content/#post-457481)
 * `<!--[if IE]>
    blah blah blah <![endif]-->
 * Please dont forget to mark this resolved.
 * and yes, I do realize you asked about non-firefox users, not ie users. theres
   no equivalent way to do something that _excludes_ firefox users that i am aware
   of, UNLESS you want to use javascript.
 * I would target ie users anyway, since chances are if someone isnt using firefox
   but also isnt using ie, theyre prolly well aware of the existance of ff and chose
   not to use it.
 *  Thread Starter [anabelle](https://wordpress.org/support/users/anabelle/)
 * (@anabelle)
 * [19 years, 6 months ago](https://wordpress.org/support/topic/browser-dependant-content/#post-457483)
 * ok, that’s IF ie, but im looking for “IF firefox: nothing, else: content”
 *  [whooami](https://wordpress.org/support/users/whooami/)
 * (@whooami)
 * [19 years, 6 months ago](https://wordpress.org/support/topic/browser-dependant-content/#post-457485)
 * and you didnt read what i wrote apparantly.
 * there is NO conditional comment for excluding FF users. conditonal comments are
   an IE thing.
 * if you want to do a simple browser detection thing, google browser detection 
   javascript.
 * Hoping you realize that a fair number of users disable javascript.
 * ..
 *  Thread Starter [anabelle](https://wordpress.org/support/users/anabelle/)
 * (@anabelle)
 * [19 years, 6 months ago](https://wordpress.org/support/topic/browser-dependant-content/#post-457486)
 * youre right about targeting IE users, and Javascript, I will do it that way, 
   and sorry i didn’t read but I swear i haven’t seen it… ¿ did you edit your post
   after? i think you did!
 *  Thread Starter [anabelle](https://wordpress.org/support/users/anabelle/)
 * (@anabelle)
 * [19 years, 6 months ago](https://wordpress.org/support/topic/browser-dependant-content/#post-457487)
 * Another question… just guessing does this work with safari?
 * <!–[if safari]>
    blah blah blah <![endif]–>
 * wich browsers are detected and by wich tag? im seeing a lot of posibilities here..
   thanks!
 *  [Pizdin Dim](https://wordpress.org/support/users/pizdin_dim/)
 * (@pizdin_dim)
 * [19 years, 6 months ago](https://wordpress.org/support/topic/browser-dependant-content/#post-457492)
 * You could do it with some simple PHP browser detection instead:
    ` <?php $ua 
   = strtolower($_SERVER['HTTP_USER_AGENT']); if (strpos($ua, 'mozilla') === false
   || strpos($ua, 'firefox') === false) { echo 'This site works better with <a href
   ="http://www.mozilla.com/firefox/">Firefox</a>.'; } ?>  Put that in the appropriate
   place in whatever theme you’re using.
 *  Thread Starter [anabelle](https://wordpress.org/support/users/anabelle/)
 * (@anabelle)
 * [19 years, 6 months ago](https://wordpress.org/support/topic/browser-dependant-content/#post-457494)
 * thank you VERY VERY much, but im still interested in the working browser tags
   for te if condition in wordpress.
 *  [DianeV](https://wordpress.org/support/users/dianev/)
 * (@dianev)
 * [19 years, 6 months ago](https://wordpress.org/support/topic/browser-dependant-content/#post-457497)
 * I’d have a couple of questions.
 * First, does the site *really* work better with Firefox than with other browsers?
   If so, I’d tend to the code, because sites can (and, in my opinion, should) be
   made workable in all browsers. Cross-browser compatibility is vital.
 * Secondly, well, I use Opera, which is at least as advanced as Firefox; telling
   me to upgrade to Firefox would be along the lines of Macromedia bouncing me out
   of its shopping cart mid-purchase to upgrade to IE or ::cough:: the AOL browser,
   which has happened.
 *  [whooami](https://wordpress.org/support/users/whooami/)
 * (@whooami)
 * [19 years, 6 months ago](https://wordpress.org/support/topic/browser-dependant-content/#post-457509)
 * pizdin_dim’s suggestion is great, and will work just fine.
 * _<!–[if safari]>
    blah blah blah <![endif]–>
 * Again, youre not reading — thats called a conditional comment, and conditional
   comments are for ie ONLY. you cannot plugin firefox, safari, camino, flock, etc..
 * it wont work.
 * [@dianev](https://wordpress.org/support/users/dianev/) : thats exactly why I 
   suggested targeting ie users only in my first post — ppl like you have already
   made the switch to “another” browser. 🙂

Viewing 9 replies - 1 through 9 (of 9 total)

The topic ‘Browser dependant content’ is closed to new replies.

## Tags

 * [content](https://wordpress.org/support/topic-tag/content/)
 * [dependant](https://wordpress.org/support/topic-tag/dependant/)
 * [hacks](https://wordpress.org/support/topic-tag/hacks/)
 * [specific](https://wordpress.org/support/topic-tag/specific/)
 * [tags](https://wordpress.org/support/topic-tag/tags/)

 * In: [Everything else WordPress](https://wordpress.org/support/forum/miscellaneous/)
 * 9 replies
 * 4 participants
 * Last reply from: [whooami](https://wordpress.org/support/users/whooami/)
 * Last activity: [19 years, 6 months ago](https://wordpress.org/support/topic/browser-dependant-content/#post-457509)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
