Jump to content

[SOLVED] Access denied for user 'SYSTEM'@'localhost' (using password: NO)


11sven

Recommended Posts

i recently upgraded to wamp5 four of my databases work but the first one doesn't it gives me this error

 

Access denied for user 'SYSTEM'@'localhost' (using password: NO)

 

i've tried everything including trying to export the database into a new one with another name. another person said i had a password problem. so i tried old passwords. i am at a loss. :facewall:

Link to comment
Share on other sites

Post your code from the start of the file up though and including the line where that error is being generated. Post any files being included in that portion of the code as well. Show the opening php tags that are in the file(s). xxxxxx out any sensitive information but don't change any of the syntax in the file(s).

Link to comment
Share on other sites

this is my main index page the error shows up at line 24

 

<?php
include("poet_layout.php");
$page_title = "Drunken Irish Poet, Home Page";

?>
<div id="content">
<p>You don't have to be drunk or Irish to be a poet, but it helps. This site contains poetry that reflects my life experience. You can <a href="index2.php">submit your poems</a> and be included in the poetry database. You can submit poems on any subject, in any style.
</p>

<p>
Check out the new features on this site. Now you can <a href="join2.php">register</a> and submit your poem directly to the site. You can also post comments to others poems. Registration is free and easy(about 30 seconds) and your email will never be used for evil purposes. <span style="color:#ccff33;"><b>NEW</b>  Search this site, just enter term into search box. </span> You can browse poems without signing up but if you want to post a poem or comment you must be logged in.
</p>


<p>
All poems posted on this site are the property of the posting author and may not be reproduced without the express permission of the author.
</p>

<h1>Poet of the Month-<?php echo date('F'); ?></h1>
<?php
$sql = mysql_query("SELECT *,
date_format(poem_date, '%M %D, %Y') as poem_date
FROM poem
WHERE poem_id = 1"); !!!ERROR SHOWS UP HERE!!!

$row= mysql_fetch_array($sql);
stripslashes(extract($row));

$cat_name = mysql_result(mysql_query("SELECT cat_name
FROM poem_categories
WHERE cat_id = '$cat_id'"),0);

$cat_name = nl2br(stripslashes(htmlentities($cat_name)));
$username= nl2br(stripslashes(htmlentities($username)));
$poem_title= nl2br(stripslashes(htmlentities($poem_title)));
$poem_body = nl2br(stripslashes(htmlentities($poem_body)));
?>

this is poet_layout
<?php
include("conn/session.php");
include("conn/dbcon.php");
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<title><?php if(isset($page_title)){echo $page_title;}?></title>
<link href="css/poetblue.css" rel="stylesheet" type="text/css"/>
<meta name="keywords" content="poet, poem, poems, poetry, submit poems, irish poet, drunken irish poet"/>

<meta name="description" content="gallery of original poetry. writers are invited to submit poems and be poet of the month"/>

</head>
<body>

<img src="image/logocap.gif" alt="logo" width="70" height="70" id="left"/>
<div class= "logo"><img src="image/poetlogo3.gif" width="600" height="70" alt="Drunken Irish Poet"/></div>

<div id="links">
<p>
<a href="index.php">Home</a>
<a href="project/poet1.html">Gallery 1</a>
<a href="project/poet2.html">Gallery 2</a>
<a href="submit.php">Submit Poem</a>
<a href="index2.php">View Poems</a>
<a href="project/links.html">Links</a>
</p>
<p class="searchbox">
<?php
include("boxes/member_box.php");
include("html/search_form.php");
?>
</p>
</div>

this is my connection page

<?
//$sql=mysql_connect('MySQLHost', '***', '***);

$sql=mysql_connect('localhost', 'drunkard', '******');
mysql_select_db('d60010322', $sql) or die(mysql_error());

?>

Link to comment
Share on other sites

<?
//$sql=mysql_connect('MySQLHost', '****', '***d');

$sql=mysql_connect('localhost', 'drunkard', '******');
mysql_select_db('d60010322', $sql) or die(mysql_error());

?>

 

Don't use short open tags <? and <?=. They are not portable between server configurations and sooner or later you will end up on a server where they are not turned on and you won't have the ability to turn them on.

 

Link to comment
Share on other sites

i changed the opening php tag and this is what i got.

 

Warning: mysql_connect() [function.mysql-connect]: OK packet 6 bytes shorter than expected in C:\wamp\www\drunken\conn\dbcon.php on line 4

 

Warning: mysql_connect() [function.mysql-connect]: mysqlnd cannot connect to MySQL 4.1+ using old authentication in C:\wamp\www\drunken\conn\dbcon.php on line 4

 

Warning: mysql_select_db() expects parameter 2 to be resource, boolean given in C:\wamp\www\drunken\conn\dbcon.php on line 5

mysqlnd cannot connect to MySQL 4.1+ using old authentication

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.