koshy

Topic: Links do not work from main page

I have installed jobber base on Ubuntu with apache and mysql
unzipped the contects of public folder to /var/www/jobberbase
set up mysql, created database 'jobber' a user 'jobber@localhost' with all privileges for the database jobberbase.
set config.envs.php as follows
$__instances['local'] = array(

    // should be a unique part of the url (or the entire url if you wish)

    'prefix' => 'local',

    // mysql credentials

    'db_host' => 'localhost',

    'db_port' => 3306,

    'db_user' => 'jobber@localhost',

    'db_password' => 'jobber12',

    'db_name' => 'jobberbase',

    'db_prefix' => '',

    // your site's full url

    'app_url' => 'http://localhost/jobberbase/',

    // error reporting

    'ini_error_reporting' => E_ALL,

    'ini_display_errors' => 'On'
.....
None of the links work from the home page.
the contents of the public folder is unzipped under the folder /var/www/jobberbase
what am i doing wrong

putypuruty

Re: Links do not work from main page

Hi!

I'm pretty convinced that your problem is caused by an incorrectly configured Apache installation and not by jobberbase. You must have the mod_rewrite module enabled and correctly configured. Maybe this will help you http://www.jobberbase.com/forum/post11275.html#p11275

hobo

Re: Links do not work from main page

In config.envs.php try changing:
from: 'prefix' => 'local', to: 'prefix' => 'localhost',
...and from:     'db_user' => 'jobber@localhost', to:     'db_user' => 'jobber',
Also, change your password before posting your url on the forum smile
Good luck

koshy

Re: Links do not work from main page

hobo wrote:

In config.envs.php try changing:
from: 'prefix' => 'local', to: 'prefix' => 'localhost',
...and from:     'db_user' => 'jobber@localhost', to:     'db_user' => 'jobber',
Also, change your password before posting your url on the forum smile
Good luck

Ok. Tried that still does not work.
the url is http://localhost/jobberbase

But on the internet everything is working
The Url is http://www.mysite.com

Does it have to be http://jobber base for it to work on the local host?

putypuruty

Re: Links do not work from main page

As I wrote you above, I'm pretty sure that mod_rewrite is not correctly configured inside Apache. Jobberbase will not work with the default Apache configuration. You must enable mod_rewrite yourself and then correctly configure it.

In the end, your problem is not jobberbase related. You would have the same problem with any site that uses .htaccess files.

koshy

Re: Links do not work from main page

I have now mod_rewrite enabled.
here is my conf.env.php
// local (http://localhost/jobberbase/public)

$__instances['local'] = array(

    // should be a unique part of the url (or the entire url if you wish)

    'prefix' => 'jobberbase',

    // mysql credentials

    'db_host' => 'localhost',

    'db_port' => 3306,

    'db_user' => 'jobber',

    'db_password' => 'jobber12',

    'db_name' => 'jobberbase',

    'db_prefix' => '',

    // your site's full url

    'app_url' => 'http://localhost/jobberbase/',

    // error reporting

    'ini_error_reporting' => E_ALL,

    'ini_display_errors' => 'On',

    // environment setting 1 (use 'local' for localhost/testing OR 'online' for live, production environment)

    'location' => 'local',

    // environment setting 2 (use 'dev' together with 'local' in the previous setting OR 'prod' with 'online')

    'environment' => 'dev',

    //'apache_mod_rewrite', 'iis_url_rewrite' -microsoft URL Rewrite module, 'iis_isapi_rewrite'

    'rewrite_mode' => 'apache_mod_rewrite'

);

Now with http://localhost/jobberbase
I get only a blank page.

koshy

Re: Links do not work from main page

I also found the following in Config.php

try

    {

                //Not sure whether i really need to do this.
        $db = new Db(localhost, jobber, jobber12, jobberbase, 3306);

                //Not sure whether i really need to do this.
        $db->Execute('SET NAMES UTF8');

    }

    catch(ConnectException $exception)

    {

        if (ENVIRONMENT == 'dev')

        {

            echo "Database Connection Error:<br />";

            printr($exception->getMessage());   

        }

    }

   

   

    // Load the Site-Specific Settings
    echo "this Prints";

    $jobber_settings = new JobberSettings();

        echo "This Does not print"; // This line is not printing. So some error at the above line

    $settings = $jobber_settings->GetSettings();

hobo

Re: Links do not work from main page

Hi
If you have your files in http://localhost/jobberbase/public/ than that should be your 'app_url' and that is where you will be able to access your homepage,
Your 'prefix' should still be localhost, or just maybe localhost/jobberbase, but try localhost first.
It could also be the issue putypuruty suggested above.

koshy

Re: Links do not work from main page

I have my files under /var/www/jobberbase, The contents of public folder is moved under /var/www/jobberbawse
There is not folder named public

hobo

Re: Links do not work from main page

Than app_url you posted is fine but your  'prefix' => 'jobberbase', should say 'prefix' => 'localhost', for local testing.
Other stuff looks ok.
PS.Editing config.php is usually not needed (for jobberbase versions after 1.8).

Last edited by hobo (2011-01-23 06:33:57)