PHP Developers Network

A community of PHP developers offering assistance, advice, discussion, and friendship.
 
Loading
It is currently Sun Apr 30, 2017 11:47 am

All times are UTC - 5 hours




Post new topic Reply to topic  [ 22 posts ]  Go to page Previous  1, 2
Author Message
 Post subject: Re: Uni Server set-up
PostPosted: Wed Sep 09, 2015 4:38 pm 
Offline
Forum Newbie

Joined: Sun Nov 22, 2009 8:15 pm
Posts: 21
When I click on the phpMyAdmin button in UniServer the NZMotorhomeForum database is not listed.


Top
 Profile  
 
 Post subject: Re: Uni Server set-up
PostPosted: Wed Sep 09, 2015 5:35 pm 
Offline
Spammer :|
User avatar

Joined: Wed Oct 15, 2008 2:35 am
Posts: 6398
Location: WA, USA
Okay... So it sounds like you don't have the database set up. You need that.

You basically need to install phpBB on your machine. Go through that whole process, which will involve setting up a database user and creating databases and tables and such, and when you're done you can try the forum again. Most of the information you'll need to know (eg. username, password, database name) should be configured with the site's phpBB - maybe in a config file?


Top
 Profile  
 
 Post subject: Re: Uni Server set-up
PostPosted: Wed Sep 09, 2015 8:22 pm 
Offline
Forum Newbie

Joined: Sun Nov 22, 2009 8:15 pm
Posts: 21
I think you are right again.

I used phpMyAdmin to set up the database and user
BUT
when I go to load the (large) database using bigdump.php I get a similar message saying :
Quote:
Database connection failed due to No connection could be made because the target machine actively refused it.


So I had another look at the database I'd set up. It looks as if the UniServer phpMyAdmin utility has set it up in a different folder to where it should be. It is not in localhost:81/NZMotorhomeForum/

See attached clip
Attachment:
Capture.PNG
Capture.PNG [ 37.14 KiB | Viewed 2618 times ]


I don't know how to get phpMyAdmin to create the database in the right folder.


Top
 Profile  
 
 Post subject: Re: Uni Server set-up
PostPosted: Wed Sep 09, 2015 10:09 pm 
Offline
Spammer :|
User avatar

Joined: Wed Oct 15, 2008 2:35 am
Posts: 6398
Location: WA, USA
Databases are not set up in folders.

Did you find the configuration for the forum? It's probably a file, like config.php or config.inc or something like that. I think. That's the information that tells phpBB where the database is and how to connect to it.
You need to find that file and edit it to connect to your local database because whatever settings it has now will not work. The hostname needs to change (probably to localhost) but the username and password will be fine. Note the username, password, and database name.
Now you need to create the new database. Follow the instructions to install phpBB's database. Do it on your computer. Use the username, password, and database name from before.


Top
 Profile  
 
 Post subject: Re: Uni Server set-up
PostPosted: Wed Sep 09, 2015 10:22 pm 
Offline
Forum Newbie

Joined: Sun Nov 22, 2009 8:15 pm
Posts: 21
Quote:
<?php
// phpBB 3.0.x auto-generated configuration file
// Do not change anything in this file!
$dbms = 'mysqli';
$dbhost = 'localhost';
$dbport = '';
$dbname = 'nzmotorh_forum';
$dbuser = 'nzmotorh_markh';
$dbpasswd = '*******'; [edited]

$table_prefix = 'phpbb_';
$acm_type = 'file';
$load_extensions = '';

@define('PHPBB_INSTALLED', true);
// @define('DEBUG', true);
// @define('DEBUG_EXTRA', true);
?>


This is the file (config.php) that is in the localhost:81/NZMotorhomeForum/ folder.
The dbname and dbuser entries are what I used when setting up the database.
I'm confused by the strange appearance of "us_opt1" in the address bar of the phpMyAdmin page that I included in my last post. That feels wrong.

I'll remove the database I have set up and try again. See if I can get to be recognised by either bigdump.php or my forum index.php


Top
 Profile  
 
 Post subject: Re: Uni Server set-up
PostPosted: Thu Sep 10, 2015 8:52 pm 
Offline
Forum Newbie

Joined: Sun Nov 22, 2009 8:15 pm
Posts: 21
I have used phpMyAdmin in the UniServer dashboard to create the
database nzmotorh_forum
a User nzmotorh_markh
I have given nzmotorh_markh All privileges on database nzmotorh_forum.

I have imported my data into this database.

I can browse this data using phpMyAdmin :)

The forum's config.php is as posted in a previous post and I have attached some screen shots from within phpMyAdmin that seem to show (to me) that the config.php settings are right.

BUT when I try to run the forum's index.php I still get the following message
Quote:

General Error
SQL ERROR [ mysqli ]

No connection could be made because the target machine actively refused it. [2002]

An sql error occurred while fetching this page. Please contact an administrator if this problem persists.


Attachments:
File comment: Shows that I can browse my phpBB3 database
nzmotorh_forum.PNG
nzmotorh_forum.PNG [ 33 KiB | Viewed 2599 times ]
File comment: Shows the Username same as in config.php
Users.png
Users.png [ 17.08 KiB | Viewed 2599 times ]
File comment: Shows the Database same as in config.php
Databases.PNG
Databases.PNG [ 18.67 KiB | Viewed 2599 times ]
Top
 Profile  
 
 Post subject: Re: Uni Server set-up
PostPosted: Wed Sep 16, 2015 1:13 am 
Offline
Spammer :|
User avatar

Joined: Wed Oct 15, 2008 2:35 am
Posts: 6398
Location: WA, USA
And I'm back.

Did you set up the database on the same machine where PHP is running?


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 22 posts ]  Go to page Previous  1, 2

All times are UTC - 5 hours


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB® Forum Software © phpBB Group