amansker Posted May 19, 2004 Posted May 19, 2004 I'm installing the vwar php script which uses a mySQL db. I created the db, uploaded files, set permissions and ran the install.php. The result is an error. I looked up the error in the vwar faq and the problem (evidently) is that I used the wrong localhost. Permissions are correct. What localhost should I use? I tried: localhost www.server47totalchoicehosting.com Error is: Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/man1958/public_html/vwar/includes/classes/class_db.php on line 190 Warning: Cannot modify header information - headers already sent by (output started at /home/man1958/public_html/vwar/includes/classes/class_db.php:190) in /home/man1958/public_html/vwar/install/install.php on line 332 Quote
DarqFlare Posted May 19, 2004 Posted May 19, 2004 Use localhost for the host/IP Are you sure you're using the right db name, user name, and password? Is it possible for you to give more information? Quote
amansker Posted May 19, 2004 Author Posted May 19, 2004 I will provide any info you request. Thanks for helping. I used the user/pw/dbname found in the cpanel under mysql just after I created the db (triple checked). After creating the db, I did not use the "add user" and "add host" at the bottom of the screen. I assume those are for additions. Using "localhost" as the "Database Server" results in the error message above. Using anything else results in "database not found." So maybe "localhost" is correct, but something else is wrong. Here is the install file: http://mandolinwind.com/vwar/install/install.php I will provide user/pw on PM if needed. The VWAR FAQ regarding the error message found above: http://web8.bmbnet.com/FAQ.html#2_3 Quote
DarqFlare Posted May 19, 2004 Posted May 19, 2004 Username should just be your CPanel login name. Password should be the same. DB name should just be cpanelusername_dbname Does that match up with the information you've put in? Quote
TCH-Rob Posted May 19, 2004 Posted May 19, 2004 Dont forget that after creating the DB and user to add the user to the db. Quote
borfast Posted May 19, 2004 Posted May 19, 2004 amansker, that error does not mean you're using the wrong database host, it means there was an error while processing the SQL query. Try adding or die("Error: ".mysql_error()) at the enq of the query line, like this: $result = mysql_query($query) or die("Error: ".mysql_error()); That should outupt the problem. Quote
DarqFlare Posted May 19, 2004 Posted May 19, 2004 Raul, I took a look at it... Seems like the script has a problem somewhere. Quote
amansker Posted May 19, 2004 Author Posted May 19, 2004 I PM'd and was told to submit a work ticket which I did - before reading the last two posts. Rob: Are you saying it is mandatory to manually create a user and then add it to the db? I see that function, but have been using the cpanel user/pw as suggested elsewhere. Raul: I'm not sure how to do what you are suggesting. I'm running an install file: http://mandolinwind.com/vwar/install/install.php and not certain where to add the code you suggest. I guess that goes in the install.php file? Will try now. I SUBMITTED A HELP TICKET SO YOU GUYS MIGHT WANT TO IGNORE THIS. Quote
DarqFlare Posted May 20, 2004 Posted May 20, 2004 Yeah amansker... After thinking about this, I think there's a coding problem in the script that you're using to install. But better to listen to what the techs say in the ticket, lol... Quote
TCH-Rob Posted May 20, 2004 Posted May 20, 2004 Rob: Are you saying it is mandatory to manually create a user and then add it to the db? I see that function, but have been using the cpanel user/pw as suggested elsewhere. These are my stept to creating my db info. Create database Create user Add user to database If I create database "stuff" I get a db name of cPanel-name_stuff I then create a user "admin" and the username to access the db is cPanel-name_admin Then I add the name to the database See image below. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.