WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is there a Wordpress plugin out there, that redirects only Blackberry visitors to a very simple basic something of the site?

Currently I have a responsive website, a long vertical one with smoothscroll.js (Similar to the Nike one). It responds in iOS, Android, and iPad - and while it displays alright in BB (curve 2009), its very hard to read text. I have to support curve 2009 + BB.

Any suggestions?

share|improve this question

closed as off-topic by Pieter Goosen, Mark Kaplun, birgire, gmazzap, cybmeta Dec 9 '14 at 11:29

This question appears to be off-topic. The users who voted to close gave these specific reasons:

If this question can be reworded to fit the rules in the help center, please edit the question.

up vote 1 down vote accepted

There isn't one that I know off, however if you wanted to write a script to solve your problem then:

In Javascript:

<script type="text/javascript">   
   var userBrowser = navigator.userAgent;
   var url = "http://forblackberryusers.yoursite.com/";
   if (userBrowser.indexOf("BlackBerry") >= 0)
      if (userBrowser.indexOf("WebKit") >= 0)
         window.location = url;

or alternatively you could be smart and try and create a plugin. In php, I'd imagine it would have something along the lines of:

   $userBrowser = strtolower($_SERVER['HTTP_USER_AGENT']);
   $blackberry = strrpos($userBrowser, "blackberry");
   $webkit = strrpos($userBrowser, "webkit");
   $url = "http://forblackberryusers.yoursite.com/";

   if (!($pos_blackberry === false))
      if (!($pos_webkit === false))
         header("Location: " . $url);

Hope that helps

share|improve this answer
This seems like a good suggestion, I'll give it a go - thanks! – Arnold Feb 15 '12 at 14:14

Not the answer you're looking for? Browse other questions tagged or ask your own question.