bbPress

Simple, Fast, Elegant

bbPress support forums » Installation

localhost installs

(6 posts)
  • Started 1 year ago by davetropeano
  • Latest reply from Omarvelous
  • This topic is not resolved
  1. davetropeano
    Member

    I recently did my first bbpress install on localhost and it went miserably. I used the latest download from today.

    Checking on this forum I had the same path seperator issues and stylesheet issues others had, etc.

    My $bb->domain and $bb->path were fine. The fresh install just didn't work properly under xampp and then again a retry on easyPHP.

    This is the solution and findings I found:

    1. The first issue is because in config.php and bb-load.php dirname(__FILE__) is used to get the base path for BBPATH. This is not a good thing on localhost Windows based installs.

    2. There are a number of attempted workarounds to this that I've read about in this forum. All of them that I saw didn't work. Focusing on the issue with the stylesheet href not being correct I noticed that there was logic in the bb_get_active_theme_folder() function.

    By default, the installer does NOT create an option entry 'bb_active_theme' in the database table topicmeta. The code logic doesn't make the correct uri.

    To fix this, do an install and then add a database field bb_active_theme in the topicmeta table.

    For example, I set mine to:
    http://localhost/dev/bbpress/

    Playing regular expression games to change x:\ and \ in general is not worth it. This seemed to be simple and worked right out of the box.

    Posted 1 year ago #
  2. Thanks for the discussion! I will make sure I point mdawaffe to this thread!

    Cheers,

    Trent

    Posted 1 year ago #
  3. davetropeano's fix worked, although I had to dig a little to find out exactly what he was referring to.
    You dont want to create a field but rather a row in the "bb_topicmeta" table.
    I was able to check a working bbpress installation on Linux to verify the setting. I noticed that the bb_active_theme was set to use the full server path to the template folder. The below did the trick for me.

    meta_id = next available number
    topic_id = 0
    meta_key = bb_active_theme
    meta_value = /bbpress-path/bb-templates/theme-to-use/

    Save that, cross your fingers and refresh your forum.

    Posted 1 year ago #
  4. mirfan
    Member

    I changed
    define( 'BBPATH', dirname(__FILE__) . '/' );
    with this:
    define( 'BBPATH', str_replace('\\', '/', realpath(dirname(__FILE__))) . '/' );
    in bb-load.php, and now it works on localhost with windows xp sp2.

    Posted 1 year ago #
  5. Cheers mirfan - your fix worked a treat! (I've got an XP install using WAMP as a server - just for testing stuff atm).

    Posted 1 year ago #
  6. Omarvelous
    Member

    GREAT!! Thx!

    Posted 1 year ago #

RSS feed for this topic

Reply

You must log in to post.

Code is Poetry.