Skip to:
Content
Pages
Categories
Search
Top
Bottom

Mobile Redirect, Registration, Login

  • Avatar of bbingham7
    bbingham7
    Participant

    @bbingham7

    Hi all! I am currently developing a mobile site to go along with a customers recent Buddypress Build. I am using the following:

    • WP 3.4.1
    • BP 1.6.2
    • Multisite
    • Many custom plugins
    • Theme mostly Based on BP Columns
    • I am hosting on one of my rackspace vps’s with cpanel

    Currently I am developing the mobile site in a copy of the primary theme on a subdomain. I am doing this so I can separate the sites somewhat, minimize the functions and design of the mobile site and submit it as a mobile app to ios and android. Is there a better way to do this?
    My issue is mainly with the login/registration process. What is the best way to handle redirection as I can see the native buddypress login and reg page is used for all additional sites added on the network? is it possible to use separate login reg pages? Where does the registration/login redirection take place? Can I modify it to redirect mobile after login/reg process to the m.subdomain and just rewrite the login/reg url for mobile devices? Then make the registration/login page responsive? Any advise on how to handle this would be appreciated! Thanks in advance!

Viewing 4 replies - 1 through 4 (of 4 total)
  • Avatar of Jigesh
    Jigesh
    Participant

    @jigesh

    if you are using default buddypress theme than it is already having responsive layout , if you are newbie than you can learn how they are providing responsiveness for the mobile users , just see their Css structure, i haven’t seen but may be based on screen size OR the best way is track mobile device and provide a different css for mobile users , to simplify above let me do one thing

    Download : https://github.com/serbanghita/Mobile-Detect/releases/tag/2.6.6 -its a mobile detect script , don’t worry you just need Mobile_Detect.php file and place it in the server and add one line in starting <head> tab as

    <?php include_once(“./Folder_name/Mobile_Detect.php”);
    $detect = new Mobile_Detect;
    ?>

    now add an condition such as,

    <?php if ($detect->isMobile()) {
    ?><link href=”/Css/Mobile.css” rel=”stylesheet” type=”text/css” /><?php //this will be load when mobile device
    }
    else if ($detect->isTablet()) {
    ?><link href=”/Css/Tablet.css” rel=”stylesheet” type=”text/css” /><?php //this will be load when tablet device
    }
    else
    {
    ?><link href=”/wp-content/themes/Your_theme_name/_inc/css/default.css” rel=”stylesheet” type=”text/css” /><?php //this will be load when no mobile no tablet means desktop
    }

    ?>

    hope above thing will help someone.

    thanks.

    Avatar of Jigesh
    Jigesh
    Participant

    @jigesh

    Avatar of bbingham7
    bbingham7
    Participant

    @bbingham7

    Thanks! I am not trying to load just a CSS on mobile detection, however. I would like the mobile site to have completely different pages and functionality than the primary site. I would like, if possible, to use the existing login/registration then redirect mobile to the m.site.com. Is this possible?

    Avatar of @mercime
    @mercime
    Keymaster

    @mercime

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

You must be logged in to reply to this topic.