close ad
WARNING: Do Not Install the DREAMWEAVER CC 2017 Update »
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Transferred host and can no longer log in

Thread began 11/01/2011 1:09 pm by drook431907 | Last modified 11/01/2011 2:36 pm by Jason Byrnes | 1552 views | 3 replies |

drook431907

Transferred host and can no longer log in

I am working on a site that someone else has done. It was just recently moved to godaddy and now when I attempt to login, I get the following:


Warning: mysql_select_db(): supplied argument is not a valid MySQL-Link resource in /home/content/97/8368397/html/includes/login/Helper_PHP.php on line 16

Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in /home/content/97/8368397/html/includes/login/Helper_PHP.php on line 22
Table 'astrec.your_tablename' doesn't exist


When I go to Helper_PHP.php, here are lines 11-24:


$WA_Auth_Separator = "|§|";

function WA_AuthenticateUser($WA_Auth_Parameter){

$UserAuthenticated = false;
mysql_select_db($WA_Auth_Parameter["database"], $WA_Auth_Parameter["connection"]); -------------(LINE 16)
$WA_Auth_loginSQL = "SELECT `".implode('`,`', $WA_Auth_Parameter["sessionColumns"])."` FROM `".$WA_Auth_Parameter["tableName"]."` WHERE ";

for($idx=0;$idx<count($WA_Auth_Parameter["columns"]);$idx++){
$WA_Auth_loginSQL = sprintf($WA_Auth_loginSQL.(($idx!=0)?" AND ":" ")."`%s`=%s ", $WA_Auth_Parameter["columns"][$idx], WA_GetSQLValueString($WA_Auth_Parameter["columnValues"][$idx], $WA_Auth_Parameter["columnTypes"][$idx]));
}
$WA_Auth_RS = mysql_query($WA_Auth_loginSQL, $WA_Auth_Parameter["connection"]) or die(mysql_error()); -------------(LINE 22)
$WA_Auth_Rows = mysql_num_rows($WA_Auth_RS);

I'm a newbie, any suggestions?? Thanks.

Sign in to reply to this post

Jason ByrnesWebAssist

you will need to edit the Connections/localhost.php file to pint to the database on the GoDaddy MySQL server.

Sign in to reply to this post

drook431907

Based on godaddy specs, my localhost.php is actually astrec.php and this is their suggested code that I have in that file.

<?php
//Connect To Database
$hostname='astrec.db.8368397.hostedresource.com';
$username='astrec';
$password='SpaceTech2011';
$dbname='astrec';
$usertable='your_tablename';
$yourfield = 'your_field';

mysql_connect($hostname,$username, $password) OR DIE ('Unable to connect to database! Please try again later.');
mysql_select_db($dbname);

$query = 'SELECT * FROM ' . $usertable;
$result = mysql_query($query);
if($result) {
while($row = mysql_fetch_array($result)){
$name = $row[$yourfield];
echo 'Name: ' . $name;
}
}
?>

Sign in to reply to this post

Jason ByrnesWebAssist

the user registration solution pack uses the Connections/localhost.php file to connect to the database.

you will need to update that connection file with the correct information to connect to the database on the go daddy server.

Sign in to reply to this post

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...