|
-
Jun 17th, 2006, 12:14 AM
#1
Thread Starter
Hyperactive Member
[RESOLVED] Trying to get my website working...
I'm using PHP to connect to MySQL database. When I go to www.alamotrades.com/post.html and try to post something it just spits back this below. I am not good with PHP or MySQL but use to have it running for an old site and trying to get it running again. I'm putting the right info in the PHP script so I don't get it...
If anyone wants to help I can let you get into my server to take a look. Thanks!
$hostname=mysqlhost
$username=
$password=
$dbid=
$link=mysql_connect($hostname, $username, $password);
mysql_select_db($dbid)
Warning: mysql_connect(): Access denied for user 'u70262984'@'anyhost' (using password: YES) in /mnt/w0200/d41/s14/b0284c62/www/submitit.php on line 3
Warning: mysql_select_db(): Access denied for user 'root'@'anyhost' (using password: NO) in /mnt/w0200/d41/s14/b0284c62/www/submitit.php on line 4
Warning: mysql_select_db(): A link to the server could not be established in /mnt/w0200/d41/s14/b0284c62/www/submitit.php on line 4
Warning: imagejpeg(): Unable to open '/export/home/vonoventwin/public_html/images/content/7172006ups.jpg' for writing in /mnt/w0200/d41/s14/b0284c62/www/php-lib/imageupload.php on line 64
Warning: mysql_query(): Access denied for user 'root'@'anyhost' (using password: NO) in /mnt/w0200/d41/s14/b0284c62/www/submitit.php on line 44
Warning: mysql_query(): A link to the server could not be established in /mnt/w0200/d41/s14/b0284c62/www/submitit.php on line 44
Warning: mysql_insert_id(): A link to the server could not be established in /mnt/w0200/d41/s14/b0284c62/www/submitit.php on line 50
Warning: Cannot modify header information - headers already sent by (output started at /mnt/w0200/d41/s14/b0284c62/www/submitit.php:3) in /mnt/w0200/d41/s14/b0284c62/www/submitit.php on line 85
-
Jun 17th, 2006, 03:29 AM
#2
Re: Trying to get my website working...
The host name is usually 'localhost' unless MySQL is on a different server to PHP.
Is this your own server?
-
Jun 17th, 2006, 08:34 AM
#3
<?="Moderator"?>
Re: Trying to get my website working...
Looks like you need to configure the permissions on both your MySQL database and your server.
Do you have access to change the permissions yourself?
-
Jun 17th, 2006, 10:18 AM
#4
Thread Starter
Hyperactive Member
Re: Trying to get my website working...
 Originally Posted by john tindell
Looks like you need to configure the permissions on both your MySQL database and your server.
Do you have access to change the permissions yourself?
I use NetFirms. So my MySQL database is through them and they told me the host name was mysqlhost. I can get into phpmyadmin to change anything about my MySQL database and then I do have complete permissions for the website also.
-
Jun 17th, 2006, 10:19 AM
#5
Re: Trying to get my website working...
Are you sure that is $hostname='mysqlhost' not $hostname=mysqlhost.
-
Jun 17th, 2006, 10:30 AM
#6
Thread Starter
Hyperactive Member
Re: Trying to get my website working...
This is what I have:
<?php
// establish db connection
$sql_link = mysql_connect("mysqlhost", "username", "password");
mysql_select_db("d60244618");
-
Jun 17th, 2006, 10:32 AM
#7
Thread Starter
Hyperactive Member
Re: Trying to get my website working...
Also what is this crap before everything? /mnt/w0200/d41/s14/b0284c62/www/
-
Jun 17th, 2006, 10:43 AM
#8
Thread Starter
Hyperactive Member
Re: Trying to get my website working...
Does anyone want to log into my website www.alamotrades.com and take a look around. I will give you all the information to help me. All the PHP is written I just can't get it to connect to MySQL database. PM if you would like to help me!
-
Jun 22nd, 2006, 01:45 PM
#9
New Member
Re: [RESOLVED] Trying to get my website working...
I have the answer for you if you still need it... I also use Netfirms and just figured it out.
You have to log into your Netfirms account, then get into the settings for your database user account (you should check to see if it's an 'admin' account, although I don't know if that's mandatory). From there select the option to 'Allow external connections'. You will then be shown the correct hostname and port to connect remotely. The correct hostname should be 'mysql.netfirms.com'. It tried that and it worked for me.
Chris
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|