
Version 3 adds support for is_tablet(), is_desktop(), and is_browser() as well as numerous bug fixes and code improvements. As of version 3.1.2 automatic updates of browscap.ini are disabeld until we can deal with memory usage issues.
PHP Browser Detection is a WordPress plugin used to detect a user’s browser. It can be used to send conditional CSS files for Internet Explorer, display different content or custom messages anywhere on the page, or to swap out Flash for an image for iPhones.
Template Tags:
Test for specific browsers:
$version is optional. Include a major version number, a single integer – 3,4,5, etc… Or leave it empty to test for any version.
<?php if(is_firefox($version)) { /* your code here */ }; ?> <?php if(is_safari($version)) { /* your code here */ }; ?> <?php if(is_chrome($version)) { /* your code here */ }; ?> <?php if(is_opera($version)) { /* your code here */ }; ?> <?php if(is_ie($version)) { /* your code here */ }; ?> <?php if(is_browser($name, $version)) { /* your code here */ }; ?> Check for mobile, tablet, iPhone, iPad, iPod, etc…
<?php if(is_desktop()) { /* your code here */ }; ?> <?php if(is_tablet()) { /* your code here */ }; ?> <?php if(is_iphone($version)) { /* your code here */ }; ?> <?php if(is_ipad($version)) { /* your code here */ }; ?> <?php if(is_ipod($version)) { /* your code here */ }; ?> <?php if(is_mobile()) { /* your code here */ }; ?> Check for greater than / less than a specific version…
Less than or equal to Firefox 19:
< ?php if(is_firefox() && get_browser_version()
Less than or equal to IE 10:
< ?php if(is_ie() && get_browser_version()
Greater than or equal to Safari 4:
= 4) { /* your code here */ }; ?>
these are just a few examples, but this syntax will work for any browser or version.
Check specific versions…
Is the browser IE6?
Is the browser IE10?
Or you can get all the info and do what you want with it:
Get just the name…
<?php $browser_name = get_browser_name(); ?>
Get the full version number – 3.2, 5.0, etc…
<?php $browser_version = get_browser_version(); ?>
Or get it all in array…
<?php $browser_info = php_browser_info(); ?>
Shortcodes:
Test for specific browsers:
[is_browser name="chrome" version="45"] <p>You are using Chrome 45 or above.</p> [/is_browser]
Output all browser info:
[browser_info]
Starting from $0 per month.
Rating
Reviewers
16 reviews
Tags
Developed By
Mindshare Labs, Inc.
Quick & Easy
Common Ninja has a large selection of powerful Wordpress plugins that are easy to use, fully customizable, mobile-friendly and rich with features — so be sure to check them out!
Testimonial plugins for Wordpress
Contact Form plugins for Wordpress
Maps plugins for Wordpress
Translation plugins for Wordpress
Chat plugins for Wordpress
Slider plugins for Wordpress
Reviews plugins for Wordpress
Contact plugins for Wordpress
Galleries plugins for Wordpress
SEO plugins for Wordpress
Forms plugins for Wordpress
Comments plugins for Wordpress
Backup plugins for Wordpress
Privacy plugins for Wordpress
Optimize plugins for Wordpress
Tabs plugins for Wordpress
Social Sharing plugins for Wordpress
Events Calendar plugins for Wordpress
Comments plugins for Wordpress
Social Feeds plugins for Wordpress
Social Sharing plugins for Wordpress
Portfolio plugins for Wordpress
Video Player plugins for Wordpress
popup plugins for Wordpress
SiteMap plugins for Wordpress
Payment plugins for Wordpress
Coming Soon plugins for Wordpress
Inventory plugins for Wordpress
Testimonials plugins for Wordpress
Portfolio plugins for Wordpress
Membership plugins for Wordpress
Forms plugins for Wordpress
Analytics plugins for Wordpress
Events Calendar plugins for Wordpress
Sliders plugins for Wordpress
Analytics plugins for Wordpress
Reviews plugins for Wordpress
Security plugins for Wordpress
Ads plugins for Wordpress
Music Player plugins for Wordpress
Countdown plugins for Wordpress
Email Marketing plugins for Wordpress
Membership plugins for Wordpress
Ecommerce plugins for Wordpress
Customer Support plugins for Wordpress
Video Player plugins for Wordpress
Tabs plugins for Wordpress
Social Feeds plugins for Wordpress
Common Ninja Apps
Browse our extensive collection of compatible plugins, and easily embed them on any website, blog, online store, e-commerce platform, or site builder.
Add an Instagram slider to your site to display social posts dynamically and keep your visual content engaging and current.
Collect user insights with a feedback popup that reveals issues early, improves user experience, and captures valuable leads through a clear feedback form.
Use feature voting so users submit ideas, vote on requests, and help you prioritize product updates by real customer demand.
Add a no-code audio player to your site and boost engagement with music, podcasts, and voice content effortlessly.
Track time since important events with a count up clock that displays elapsed days and hours and keeps visitors engaged.
Show LinkedIn posts with a slider that auto updates, presents content in a smooth layout, and keeps visitors engaged.
Show Medium articles in a Medium feed that keeps content fresh, improves readability, and helps visitors discover more posts.
Create course listings with a course catalog widget that displays programs clearly, supports easy organization, and helps visitors explore courses effectively.
Create interactive diagrams with a diagrams widget that lets you build and customize flow charts, improve clarity, and help visitors understand complex ideas easily.
Back to top button that improves navigation, speeds up browsing, and helps visitors move smoothly through long pages for a better user experience.

Create consent forms that collect signatures, save submissions, send notifications, and help you manage approvals efficiently.
Create interactive video polls that use engaging clips to boost participation, gather insights, and help visitors vote in a more dynamic way.
More plugins
The Common Ninja Search Engine platform helps website builders find the best site widgets, apps, plugins, tools, add-ons, and extensions! Compatible with all major website building platforms - big or small - and updated regularly, our Search Engine tool provides you with the business tools your site needs!
