Skip to:
Content
Pages
Categories
Search
Top
Bottom

BuddyPress Mobile for 1.5 needs testing

Viewing 23 replies - 1 through 23 (of 23 total)
  • Avatar of juanmaguerrero
    juanmaguerrero
    Participant

    @juanmaguerrero

    Y will be testing it today’s night, after that i’ll tell you how it went! :)

    Avatar of Stigmartyr
    Stigmartyr
    Member

    @stigmartyr

    @juanmaguerrer – How did it go?

    modemlooper – this dev version is still a theme right? Not the app you were alluding to recently?

    Avatar of hackerstore
    hackerstore
    Member

    @hackerstore

    not working…. Check here http://www.migwarez.tk

    Avatar of @modemlooper
    @modemlooper
    Moderator

    @modemlooper

    ‘not working’ helps no one. If you’d like to add anything so I can figure out what your issue is. You must be running the 1.5 trunk of BuddyPress.

    Avatar of @modemlooper
    @modemlooper
    Moderator

    @modemlooper

    @Stigmartyr it’s mostly the same as before

    Avatar of Stigmartyr
    Stigmartyr
    Member

    @stigmartyr

    Thanks @modemlooper -

    Not sure what hackerstore means but I just tested with BP 1.2.9 / WP 3.2.1 and got this error on activating the plugin:

    `Deprecated: Function eregi() is deprecated in /var/www/vhosts/httpdocs/wp-content/plugins/buddypress-mobile/buddypress-mobile.php on line 73`

    I went looking for the function to replace eregi a few days ago but that didn’t work for me but then again Im no coder :P Im just dangerous with snippets.

    I wasn’t expecting it to work as the plugin clearly shows it’s compatibility but perhaps this helps.

    Avatar of @modemlooper
    @modemlooper
    Moderator

    @modemlooper

    Yes, this version is ONLY for BP 1.5

    Avatar of hackerstore
    hackerstore
    Member

    @hackerstore

    when i activated the plugin and visited it with N70 nokia i found the pc theme its changed nothing… Is it for iphone and ipad only?

    Avatar of @modemlooper
    @modemlooper
    Moderator

    @modemlooper

    Probably won’t work with that phone model. BP mobile is mostly for touch screen devices.

    You can try and add the user agent in the file buddypress-mobile.php. You will see a list of supported devices.

    “NokiaN70″,

    Avatar of @modemlooper
    @modemlooper
    Moderator

    @modemlooper

    @Stigmartyr already fixed that old function error.

    Avatar of Stigmartyr
    Stigmartyr
    Member

    @stigmartyr

    @modemlooper – any chance you could share the code replacement? Or can I just use the beta version of buddypress-mobile.php with my 1.5.1 version?

    I was going to try to use the mobile theme for now with BP 1.2.9 and adopt the new when everyone else has gone down the path.

    Avatar of @modemlooper
    @modemlooper
    Moderator

    @modemlooper

    Next BP Mobile will only work with 1.5. Earlier versions won’t break if you are still running 1.2. The core theme files have changed too much to support both versions. So if you are still using 1.2 then do not upgrade.

    The git repo is updated to fix the eregi error. download link above.

    Avatar of hackerstore
    hackerstore
    Member

    @hackerstore

    please care about normal mobile users in next version not much ppl using iPhone or Ipad to browse the internet lol,
    btw thank u dude its amazing plugin :)

    Avatar of hackerstore
    hackerstore
    Member

    @hackerstore

    hey, how to edit the template i searchd at themes page but i didnt find it, thanks

    Avatar of @modemlooper
    @modemlooper
    Moderator

    @modemlooper

    /plugins/buddypress-mobile/buddypress-mobile.php

    There may be a dumb phone version

    Avatar of hackerstore
    hackerstore
    Member

    @hackerstore

    which part in buddypress-mobile.php :-S
    <?php
    /*
    Plugin Name: BuddyPress Mobile
    Plugin URI: http://go-themes.com
    Description: A plugin and theme for BuddyPress for optimized viewing on Apple’s iPhone and iPod touch. Also works with some Android and blackberry devices..
    Author: modemlooper
    Version: 1.5.1
    Author URI: http://twitter.com/modemlooper
    */

    /*
    * Make sure BuddyPress is loaded before we do anything.
    */
    if ( !function_exists( ‘bp_core_install’ ) ) {
    require_once( ABSPATH . ‘/wp-admin/includes/plugin.php’ );
    if ( is_plugin_active( ‘buddypress/bp-loader.php’ ) ) {
    require_once ( WP_PLUGIN_DIR . ‘/buddypress/bp-loader.php’ );
    } else {
    add_action( ‘admin_notices’, ‘buddypress_mobile_install_buddypress_notice’ );
    return;
    }
    }

    define ( ‘BUDDYPRESS_MOBILE_VERSION’, ’1.5.1′ );

    /*
    * admin links
    */
    require ( dirname( __FILE__ ) . ‘/admin.php’ );

    function buddypress_mobile_install_buddypress_notice() {
    echo ‘

    ‘;
    _e(‘BuddyPress Mobile requires the BuddyPress plugin to work. Please install BuddyPress first, or deactivate BuddyPress Mobile.’);
    echo ‘

    ‘;
    }

    require_once( ‘include/compat.php’ );

    class bpMobilePlugin{
    var $iphone;

    function bpMobilePlugin(){
    $this->iphone = false;
    add_action(‘plugins_loaded’,array(&$this,’detectiPhone’));
    add_filter(‘stylesheet’,array(&$this,’get_stylesheet’));
    add_filter(‘template’,array(&$this,’get_template’));
    add_filter( ‘theme_root’, array(&$this, ‘theme_root’) );
    add_filter( ‘theme_root_uri’, array(&$this, ‘theme_root_uri’) );
    add_filter( ‘template’, array(&$this, ‘get_template’) );
    }

    function detectiPhone($query){
    $container = $_SERVER;
    $useragents = array (
    “iPhone”,
    “iPod”,
    “iPad”,
    “Android”,
    “blackberry9500″,
    “blackberry9530″,
    “blackberry9520″,
    “blackberry9550″,
    “blackberry9800″,
    “webOS”,
    “OperaMini”,
    “Nokia”,
    “Opera Mini”
    );
    $this->iphone = false;
    foreach ( $useragents as $useragent ) {
    if (eregi($useragent,$container)){
    $this->iphone = true;
    }
    }

    }

    function get_stylesheet($stylesheet) {
    if($this->iphone){
    return ‘default’;
    }else{
    return $stylesheet;
    }
    }

    function get_template($template) {
    if($this->iphone){
    return ‘default’;
    }else{
    return $template;
    }
    }

    function get_template_directory( $value ) {
    $theme_root = compat_get_plugin_dir( ‘buddypress-mobile’ );
    if ($this->iphone) {
    return $theme_root . ‘/themes’;
    } else {
    return $value;
    }
    }

    function theme_root( $path ) {
    $theme_root = compat_get_plugin_dir( ‘buddypress-mobile’ );
    if ($this->iphone) {
    return $theme_root . ‘/themes’;
    } else {
    return $path;
    }
    }

    function theme_root_uri( $url ) {
    if ($this->iphone) {
    $dir = compat_get_plugin_url( ‘buddypress-mobile’ ) . “/themes”;
    return $dir;
    } else {
    return $url;
    }
    }

    }
    $bp_mobile = new bpMobilePlugin();

    function bp_mobile_scripts() {
    wp_enqueue_script( “buddypress-mobile”, path_join(WP_PLUGIN_URL, basename( dirname( __FILE__ ) ).”/themes/default/theme.js”), array( ‘jquery’ ) );
    if (get_option(‘add2homescreen’)==1) {
    wp_enqueue_script( “add2home-mobile”, path_join(WP_PLUGIN_URL, basename( dirname( __FILE__ ) ).”/themes/default/add2home.js”) );
    }
    }
    add_action(‘wp_print_scripts’, ‘bp_mobile_scripts’);

    ?>

    Avatar of @modemlooper
    @modemlooper
    Moderator

    @modemlooper

    It says Nokia but it definitely will not work in all Nokia phones. I only think the N80 has a real browser. Also have not tested in Opera. Theme may break

    Avatar of hackerstore
    hackerstore
    Member

    @hackerstore

    yea, btw i will edit it and maybe gonna relase it here :p:D

    Avatar of @modemlooper
    @modemlooper
    Moderator

    @modemlooper

    Actually, please don’t. You are trying to add non touch phones and it will not work. Others will think it will and I don’t want to deal with the complaints.

    Avatar of hackerstore
    hackerstore
    Member

    @hackerstore

    lol, ok bro :D

    Avatar of @modemlooper
    @modemlooper
    Moderator

    @modemlooper

    I’ll do a poll and see if people need a non touch mobile bp

    Avatar of @modemlooper
    @modemlooper
    Moderator

    @modemlooper

    If you are testing, I’ve uploaded a new build. Delete and re download latest.

    added new admin features.

    https://github.com/modemlooper/BuddyPress-Mobile

    Avatar of @modemlooper
    @modemlooper
    Moderator

    @modemlooper

    Please test and let me know how it goes.

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

You must be logged in to reply to this topic.