PHP - Help :( Can't Connect Wrong Variable
it says
Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'username'@'localhost' (using password: YES) in C:\wamp\www\Forum\config.php on line 9 Call Stack # Time Memory Function Location 1 0.0009 396096 {main}( ) ..\index.php:0 2 0.0014 399640 include( 'C:\wamp\www\Forum\config.php' ) ..\index.php:3 3 0.0014 399840 mysql_connect ( ) ..\config.php:9 cannot connect <?php mysql_connect('localhost', 'username', 'password') or die("cannot connect"); mysql_select_db('db'); //Username of the Administrator $admin='admin'; //Forum Home Page $url_home = 'index.php'; //Design Name $design = 'default'; include('init.php'); ?> Similar TutorialsLike the topic says. This is it: $margin-leftdelivery = "margin-left: -130px;"; Error log states: Quote syntax error, unexpected '=' How so? I am querying... $sql = "SELECT `messages_inbox`.`message_id`, `users`.`firstname`, `users`.`lastname`, `users`.`username` AS `from`, '${user_info['username']}' AS `to`, `subject`, LENGTH(`files`) AS `len`, 'inbox' AS `box`, DATE_FORMAT(`messages_inbox`.`time` ,'%T %D-%M-%Y') AS `time` "; $sql .= "FROM `messages_inbox` INNER JOIN `users` ON `messages_inbox`.`from_id` = `users`.`id` WHERE `to_id` = ${user_info['uid']} AND `messages_inbox`.`deleted` = 0 ORDER BY `messages_inbox`.`message_id` DESC"; and I am trying to output $displayName = ucwords("${message['firstname']} ${message['lastname']}"); by using $messages = pm_fetch_all($_GET['box']); I know my fetch works but for some reason firstname and lastname are only returning the logged in users first name and last name, not the person who sent the message. define("DB_HOST", "localhost"); Hi, I have a script which uses a connect file but I am struggling to get files in other folders to read and for the "$loggedIn = checkLogin();" code to work. If I connect to the database within the same script it works straight away. If I change my password then I have to change every file but otherwise I cannot include the connect file as I have to link to it locally. So if the connect file is in: www.domain.co.uk/php/login/connect.php then www.domain.co.uk/php/login/index.php -- this works www.domain.co.uk/php/logout.php -- this doesn't regardless of how I link to the connect file. hey I need this to connect to my database on my sybase sql server, but no matter what i try, it won't populate the plunum field. Any help would be appreciated. Here is my HTML code: Code: [Select] <html> <head> <title>helloscan</title> <meta http-equiv="refresh" content="18"> <meta http-equiv="scanner" content="javascript:doScan('%s');"/> <meta http-equiv="scanner" content="start"/> <META HTTP-Equiv="scanner" Content="enabled" /> <META HTTP-Equiv="scanner" Content="AutoEnter:Enabled"/> <meta http-equiv="keycapture" content="accelerate:all" /> <meta http-equiv="keycapture" content="keyvalue:0x0D; dispatch=true; keyevent:url('javascript:mykeypressed();')" /> <meta http-equiv="quitbutton" content="visibility: visible;"/> <script language="javascript" type="text/javascript"> function doScan(data){ var divEl = ("%s"); } function enablescanner(enable){ Generic.InvokeMetaFunction('scanner', 'start'); Generic.InvokeMetaFunction('scanner', 'enabled'); Generic.InvokeMetaFunction('scanner', 'autoenter:enabled'); } </script> <script> function get_plunum(){ xmlhttp=ajaxfunction(); if (xmlhttp==null) { alert ("no ajax support"); return; } var ae_xrefnum = document.getelementbyid('ae_xrefnum').value; var ae_plunum = document.getelementbyid('ae_plunum').value; var querystring = "?ae_xrefnum=" + xrefnum + "&ae_plunum="+ plunum"; xmlhttp.onreadystatechange = function (){ if (xmlhttp.readystate == 4 || xmlhttp.readystate=="comlete"){ document.myform.ae_plunum.value = xmlHttp.responseText; } } xmlhttp.open("GET", "helloscan2.php"+querystring, true); xmlhttp.send(null); } function ajaxfunction(){ var xmlhttp=null; try {// code for IE7+, Firefox, Chrome, Opera, Safari xmlhttp=new XMLHttpRequest(); } catch (err) {// code for IE6, IE5 xmlhttp=new ActiveXObject("Microsoft.XMLHTTP"); } return xmlhttp; } </script> </head> <body onload="enablescanner(true)"> <h3 align="center"><center><img src="ac moore" /></center>Please scan a barcode...</h3> <form name="myform"> ItemBarcode: <input type="text" id="ae_xrefnum" name="ae_xrefnum" itembarcode="divE1" oninput="get_plunum()" /> plunum: <input type="text" id="ae_plunum" name"ae_plunum" oninput="get_price()"/> </form> <script language=javascript> { document.myform.ae_xrefnum.focus(); } </script> </body> </html> And Here is my PHP code: Code: [Select] <?php //================================================================ // Configure connection parameters $db_host = "97.0.40.244, 1498"; $db_server_name = "ACMSQL036A"; $db_name = "backoff.db"; $db_file = 'd:\trvbkup\DB'; $db_conn_name = "php_script"; $db_user = "dba"; $db_pass = "sql"; //================================================================ $connect_string = "Driver={Adaptive Server Anywhere 8.0};". "CommLinks=tcpip(Host=$db_host);". "ServerName=$db_server_name;". "DatabaseName=$db_name;". "DatabaseFile=$db_file;". "ConnectionName=$db_conn_name;". "uid=$db_user;pwd=$db_pass"; // Connect to DB $conn = odbc_connect($connect_string,'',''); // Query $qry = "SELECT xrefnum, plunum FROM DBA.PLU_Cross_Ref where xrefnum = '$xrefnum'"; // Get Result $result = odbc_exec($conn,$qry); // Get Data From Result while ($row[] = odbc_fetch_array($result)); // Free Result odbc_free_result($result); // Close Connection odbc_close($conn); // Show data print_r($row[plunum]); //================================================================ ?> hi all First of all My client have dot net server on windows OS. They want to display some pages which are created by php. Is there any possibility to display like this. And How can i connect sql server using php on remote to retrieve data. Can any one tell me how can i do this. Thanks in advance hello, if i have an entry in a table called company on database cc, would the following be the propper code? im getting a blank page. Code: [Select] <?php $dbhost = 'localhost'; $dbuser = 'root'; $dbpass = 'mike'; $conn = mysql_connect($dbhost, $dbuser, $dbpass) or die ('Error connecting to mysql'); $dbname = 'cc'; mysql_select_db($dbname); $query = "SELECT * FROM company"; $result = mysql_query($query); while($row = mysql_fetch_array($result, MYSQL_ASSOC)) { echo "Name :{$row['compant']} <br>" . "Subject : {$row['address']} <br>" . } ?> HI, I'm running the next script from my local host and the production server, and Im getting different outputs. Anyone knows why am I getting that error from my localhost? <?php $host = 'ssl://mail.companyname.org'; $port = 993; $error = 0; $errorString = ""; var_dump(fsockopen($host, $port, $error, $errorString, 30)); var_dump($errorString); var_dump($error);
> PHP Warning: fsockopen(): SSL operation failed with code 1. OpenSSL Production server output: resource(4) of type (stream)
Edited November 26, 2020 by tirengarfio I have a simple form and I run my script without any errors. I click my btn and I would like to see my echo errors but no errors show up when I have no value in textboxes. I have tried if(isset($_Post["submit"])) and if($_SERVER["REQUEST_METHOD"] == "post") What I think is nether of there ifs are becoming valid on my btn click. <?php $nameerror = $twoerror = $errormsg = ""; // PHP Procedural MYSQLi // connect to mysql database with phpmyadmin $servername = "localhost"; $username = "root"; $password = "password"; $dbname = "test"; $connection = new mysqli($servername, $username, $password, $dbname); //if(isset($_Post["submit"])) if($_SERVER["REQUEST_METHOD"] == "post") { if(empty(trim($_Post["name"]))) { $nameerror = "Name is required"; } else { $namesafe = mysqli_real_escape_string($connection, $_Post["name"]); } if(empty(trim($_Post["two"]))) { $twoerror = "Two is required"; } else { $twosafe = mysqli_real_escape_string($connection, $_Post["two"]); } if($namesafe != "" && $twosafe != "") { $sqlInsert = "INSERT INTO tester(name, two) " . "VALUES('". $namesafe ."','". $twosafe ."')"; if(mysqli_query($connection, $sqlInsert)) { echo "Successfully entered."; } else { echo "NOT successful error: " . $sqlInsert . "<br>" . mysqli_error($connection); } } } mysqli_close($connection); ?> <?php if(!$connection) { die("Connection Failed! " . mysqli_connect_error()); } echo "Connected Successfully@!"; ?> <section class="text-align" id="section-content"> <div id="alertMessages" class="container rounded"></div> <div id="contentdiv" class="container rounded"> <form id="formtest" class="rounded" method="post" > <!-- action="" --> <h3>PHP Create</h3> <?php if(isset($errormsg)) { // echo "<div><span>"; echo $errormsg; // echo "</span></div>"; } ?> <div> <div class="form-group"> <input type="text" class="form-control" id="txtName" name="name" /> <label for="txtName">Name </label> <?php if(isset($nameerror)) { echo '<span class="error">' . $nameerror . '</span>'; } ?> <!-- ? php//if(isset($_Post["name"])) echo htmlspecialchars($_Post["name"]); ? >" /> ---> <!-- <span class="error"><?php //echo $nameerror; ?></span> --> </div> <div> <input type="text" class="form-control" id="txttwo" name="two" /> <label for="txttwo">Text Two </label> <?php if(isset($twoerror)) { echo '<span class="error">' . $twoerror . '</span>'; } ?> </div> </div> <button type="submit" class="btn btn-lg btn-primary btn-block" name="submit">Click</button> </form> </div> </section>
I'm trying to add Facebook connect to my new app, but I'm not sure where to really start. I looked through a lot of the facebook documentation, but I haven't been able to find any really good implementation suggestions. I just want basic functionality. Ok this code doesn't look wrong but i cant figure out whats going on? Code: (connect.php) [Select] <?php //connect.php $server = 'localhost'; $username = 'admin'; $password = 'pass'; $database = 'gms'; if(!mysql_connect($server, $username, $password)) { exit('Error: could not establish database connection'); } if(!mysql_select_db($database) { exit('Error: could not select the database'); } ?> ERROR Code: [Select] Parse error: syntax error, unexpected '{' in /home/adee67/public_html/forum/connect.php on line 13 Hello there, I'm using a Mac (10.5. and installed MAMP for PHP and MYSQL I trying to build a blog. I just setup a database in phpmyadmin. I created a php and start coding, everything works just fine, but when I tried to connect to the mysql it gives me a blank page I inserted this code Code: [Select] <?php session_start(); $connect = mysql_connect('localhost','root', 'root'); or die(mysql_error()); $db = mysql_select_db('blog',$connect); $session_name = $_SESSION['uid']; ?> but then the whole page turns to be blank page , but when I excluded this, it works just fine. I don't get it cause my database/phpmyadmin connected just fine. Any help is much appreciated. Been trying to figure this out for hours. Hi People. Thanks to everyone that helped me yesterday with my file that finally connected to the database. However, I have added a new field to my DB and now get further problems. Here is the error message I am getting after I added the "ppr" stuff to both files. Please could someone look at my code and tell me where I'm going wrong. Code: [Select] <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <title>Untitled Document</title> </head> <body> <?php include "config01.php"?> <form name = 'form1' method = 'post' action='config01.php'> <table width="700" border="1" cellspacing="5" cellpadding="5"> <caption> Submit Your Airfield Details </caption> <tr> <td width="100"> </td> <td width="200">Your Name</td> <td width="200"><input type='text' name='username' maxlength='30'></td> <td width="100"> </td> </tr> <tr> <td> </td> <td>Height Above MSL</td> <td><input type='text' name='height_above'maxlength= '30'></td> <td> </td> </tr> <tr> <td> </td> <td>Mb Difference</td> <td><input type='text' name='mb_diff'maxlength='40'></td> <td> </td> </tr> <tr> <td> </td> <td>Alternative Airfield</td> <td><input type='text' name='alternative' maxlength='30'></td> <td> </td> </tr> <tr> <td> </td> <td>PPR</td> <td><input type='radio' name='ppr' value="Y"/> Yes <input type='radio' name='ppr' value="N" /> No</td> <td> </td> </tr> <tr> <td><input type='submit' name='submit' value='post' /></td> <td> </td> <td> </td> <td> </td> </tr> </table> </form> </body> </html> Then the code from config01.php Code: [Select] <?php $host = 'localhost'; $usr = "VinnyG"; $password = 'thepassword'; $db_name = 'sitename'; $username = $_POST["username"]; $height_above = $_POST["height_above"]; $mb_diff = $_POST["mb_diff"]; $alternative = $_POST["alternative"]; $ppr = $_POST["ppr"]; //connect to database mysql_connect ("$host","$usr","$password") or die ('Error During Connect:<br>'.mysql_error()); mysql_select_db ("$db_name") or die ('Error Selecting DB:<br>'.mysql_error()); /* $sql01 = "INSERT INTO users SET username = '$username',height_above = '$height_above', mb_diff = $mb_diff, alternative = $alternative"; $result=mysql_query($sql01); */ //mysql_query("INSERT INTO users VALUES ('$username','$height_above','$mb_diff','$alternative')"); //mysql_query("INSERT INTO users (username, height_above, mb_diff, alternative) VALUES ('$username', '$height_above', '$mb_diff', '$alternative'"); //$insert_query = "INSERT INTO users (username, height_above, mb_diff, alternative) VALUES ('$username', '$height_above', '$mb_diff', '$alternative')"; //$insert_action = mysql_query($insert_query) or die ('Error Dring Insert :<br>'.mysql_error().'<br><br>Error occured running the following code :<br>'.$insert_query); //mysql_query("INSERT INTO users VALUES ('$username','$height_above','$mb_diff','$alternative')"); CHANGES FOLLOW THIS LINE . . $query = "INSERT INTO users (username, height_above, mb_diff, alternative, ppr) VALUES ('$username', '$height_above', '$mb_diff', '$alternative', '$ppr'"; if( !$result = mysql_query($query) ) { echo "<br>Query: $query<br>Produced error: " . mysql_error() .'<br>'; } else { echo "Query ran and inserted " . mysql_affected_rows() . "row(s)."; } ?> I only added the one thing and I've gone and broken it already. It was working last night too.. :-( for some reason my database will not connect, here's the code: Code: [Select] <?php require("mstr_ref2.php"); function parseToXML($htmlStr) { $xmlStr=str_replace('<','<',$htmlStr); $xmlStr=str_replace('>','>',$xmlStr); $xmlStr=str_replace('"','"',$xmlStr); $xmlStr=str_replace("'",'&#39;',$xmlStr); $xmlStr=str_replace("&",'&',$xmlStr); return $xmlStr; } // Opens a connection to a MySQL server $connection=mysql_connect (localhost, $username, $password); if (!$connection) { die('Not connected : ' . mysql_error()); } // Set the active MySQL database $db_selected = mysql_select_db($database, $connection); if (!$db_selected) { die ('Can\'t use db : ' . mysql_error()); } // Select all the rows in the markers table $query = "SELECT * FROM markers WHERE 1"; $result = mysql_query($query); if (!$result) { die('Invalid query: ' . mysql_error()); } header("Content-type: text/xml"); // Start XML file, echo parent node echo '<markers>'; // Iterate through the rows, printing XML nodes for each while ($row = @mysql_fetch_assoc($result)){ // ADD TO XML DOCUMENT NODE echo '<marker '; echo 'name="' . parseToXML($row['name']) . '" '; echo 'address="' . parseToXML($row['address']) . '" '; echo 'lat="' . $row['lat'] . '" '; echo 'lng="' . $row['lng'] . '" '; echo 'type="' . $row['type'] . '" '; echo '/>'; } // End XML file echo '</markers>'; ?> I think there is something wrong with this line of code. Where it says 'locat host' im not too sure about that because im not connecting to a local host, so what can i put in there instead?i think that is the problem. Code: [Select] $connection=mysql_connect (localhost, $username, $password); This is the error I get: Code: [Select] Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'a2221438'@'localhost' (using password: NO) in /home/a2221438/public_html/map.php on line 44 I'm trying to connect to two databases and I'm having problems with the following code. I googled to come up with this but can't figure out the errors I'm getting. Code: [Select] $connection="localhost"; $username="user"; $password="password"; $database1="dbone"; $database2="dbtwo"; $db1 = mysql_connect($connection,$username,$password) or die(mysql_error()); $sel1 = mysql_select_db($database1, $db1); $query1 = "SELECT * FROM TBLUSERS"; $result1 = mysql_query($query1, $db1); while($nt1 = mysql_fetch_array($result1, $db1)) { } $db2 = mysql_connect($connection,$username,$password) or die(mysql_error()); $sel2 = mysql_select_db($database2, $db2); $query2 = "SELECT * FROM TBLPD20101101"; $result2 = mysql_query($query2, $db2) or die(mysql_error()); while($nt2 = mysql_fetch_array($result2, $db2)) { } The error I get is Quote Warning: mysql_fetch_array() expects parameter 2 to be long, resource given in C:\xampp\htdocs\HighVisibility\DashBoard2.php on line 13 Warning: mysql_fetch_array() expects parameter 2 to be long, resource given in C:\xampp\htdocs\HighVisibility\DashBoard2.php on line 22 Hey, I've had this problem for a couple days now, and haven't been able to work it out. I'm trying to connect to the Gamesurge IRC using PHP - though the code I am using times out and can't connect. I thought it was my code, however I have searched the web for working codes and they all *seem* to do the same basic thing as mine. So if anyone has any ideas as to why I am getting a timeout, I would appreciate it. The code I'm using. <?php error_reporting(E_ERROR); $cfg = array( "server" => "irc.gamesurge.net", "channel" => "#wiremod", "port" => 6667, "name" => "thetree PHP" ); echo "Connecting to " . $cfg["server"] . " on port " . $cfg["port"] . "<br/>"; $socket = fsockopen($cfg["server"], $cfg["port"], $errno, $errstr, 5); if (!$socket) { echo("Error[$errno]: $errstr...<br/>"); } else { echo "Socket connection successful..<br/>"; } fclose($socket); ?> Hosted file: http://joethetree.lil.org.uk/socket.php Thanks thetree Hello all, This is my first post in here, so go easy. I recently transferred my account from my local ISP to GoDaddy. And now my search criteria is not working. I am getting the follow error message on the page of my search box, instead of the graphics itself: Could not connect to MySQL:Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) I thought maybe this would be a simple error when I found out that GoDaddy does not use the "localhost" connect string. So I switched it to the local IP for GoDaddy still to no avail. I am lost after that. My PHP skills are limited. I was taught by a very advanced user who uses shortcuts and different strings self made for his ease. So looking online for solutions for the script was very hard(to me at least), because the lines of code do not match common scripts online. Is this a simple solution? Does the: global $dbc; @dbConnect(); function work with GoDaddy? Because I have seen maybe different ways to connect to a DB with PHP. Here's the script I am using to connect and extract results from the DB. Any and all help will be greatly appreciated. Thanks in advance. Using MySQL Version 4: <? @require("searchheader.php"); ?> <table cellpadding=10 cellspacing=0 border=0> <tr> <td align=left valign=top> <? displayMenu(); ?> </td> <td align=right valign=bottom> <? if($_GET["f_catid"]){ $num_cats = 5; for($i=1;$i<=$num_cats;$i++){ $where .= " or c".$i." = ".$_GET["f_catid"]; } $where = substr($where,4,strlen($where)); $sql = "select * from product where ".$where." order by product_name ASC LIMIT 0,20"; dbConnect(); $result = mysql_query($sql,$dbc); ?> <div class="search_results_menu"> <form action="[url=http://www.nexpart.com/extpart.php?part=]http://www.nexpart.com/extpart.php?part=[/url]<?=$r["part_number"]?>&linecode=<?=$row[" manufacturer"] ?>" method="GET"><input type="text" name="quantity" size="2" value="0" style="text-align: center;"><input type="button" name="submit_top" value="Check Out"> </form> <table class="search_results_found" bgcolor="#efefef" cellpadding=3 cellspacing=0 border=1 bordercolor="#000000" style="border:1px solid #000000;"> <tr bgcolor="#efefef"> <td class="search_results_title"><b>Manufacturer</b></td> <td class="search_results_title"><b>Part Number</b></td> <td class="search_results_title"><b>Part Name</b></td> <td class="search_results_title"><b>Price</b></td> <td class="search_results_title"><b>Image</b></td> <td class="search_results_title"><b>Add to Cart</b></td> </tr> <? if(mysql_num_rows($result) > 0){ while($row = mysql_fetch_assoc($result)){ ?> <tr bgcolor="#efefef"> <td><?=$row["manufacturer"]?></td> <td><a href="[url=http://www.nexpart.com/extpart.php?part=]http://www.nexpart.com/extpart.php?part=[/url]<?=$row["part_number"]?>&linecode=<?=$row["manufacturer"]?>"><?=$row["part_number"]?></a></td> <td><?=$row["product_name"]?></td> <td>$<?=$row["price"]?></td> <td><a href="[url=http://www.wlpsr.com/images/]http://www.wlpsr.com/images/[/url]"<?=$row["part_number"]?>".jpg " onClick="window.open('/images/<?=$row["part_number"]?>.jpg', '<?=$row["part_number"]?>', 'toolbar=yes, directories=no, location=no, status=yes, menubar=no, resizable=yes, scrollbars=yes, height=300, width=400'); return false">View</a></td> <td><form action="[url=http://www.nexpart.com/extpart.php?part=]http://www.nexpart.com/extpart.php?part=[/url]<?=$r["part_number"]?>&linecode=<?=$row["manufacturer"] ?>" method="GET"><input type="text" name="quantity" size="2" value="0" style="text-align:center;"> </form> </td> </tr> <? } } else{ ?> <tr> <td colspan=100 align="center"><b>No products in this category.</b></td> </tr> </table> <form action="[url=http://www.nexpart.com/extpart.php?part=]http://www.nexpart.com/extpart.php?part=[/url]<?=$r["part_number"]?>&linecode=<?=$row[" manufacturer"] ?>" method="GET"><input type="text" name="quantity" size="2" value="0" style="text-align: center;"><input type="button" name="submit_top" value="Check Out"> </form> </td> </tr> <? } ?> </td> </tr> </table> </div> <? } ?> <div class="form"> <form name="search" action="<? echo $_SERVER['PHP_SELF']; ?>" method="GET"> <input type="text" name="f_keywords" size="17" value="" maxlength="100"> <input type="image" src="gobutton.gif"> </form> </select> <br><br><br> <? $trimmed = trim(strip_tags($_GET["f_keywords"])); //Set the database access information as constants. if(strlen($trimmed) > 0){ define ('DB_USER', 'USERNAME'); define ('DB_PASSWORD', 'THEPASSWORD'); define ('DB_HOST', 'LOCALIP'); define ('DB_NAME', 'DBNAME'); define ('DB_TABLE', 'TABLE'); //Make the connection to the DB global $dbc; @dbConnect(); $query = "SELECT * FROM product WHERE manufacturer LIKE '%$trimmed%' OR part_number LIKE '%$trimmed%' OR price LIKE '%$trimmed%' OR product_name LIKE '%$trimmed%' order by manufacturer"; $result = mysql_query($query); $count = mysql_numrows($result); if ($trimmed == "") { echo "Please enter a search criteria..."; exit; } // check for a search parameter if (!isset($result)) { echo "<p>Please enter a search parameter!</p>"; exit; } $numresults=mysql_query($query); $numrows=mysql_num_rows($numresults); if ($numrows == 0) { echo "<h4>Results</h4>"; echo "<p>We are sorry <b>$trimmed</b> has returned zero results.</p></font>"; } // next determine if s has been passed to script, if not use 0 if (empty($s)) { $s=0; } // get results $result = mysql_query($query,$dbc); if($numrows < 1){ $return= "results";} else{ $return = "result"; } if($numrows > 1){ $return = "results";} else{ $return = "result"; } // display what the person searched for echo "Your search for ", " <b>$trimmed</b> ", " found <br><b>$numrows $return.</b>"; // begin to show results set $count = 1 + $s ; } if(strlen($trimmed) > 0){ ?> </div> <div class="search_results"> <table cellpadding=0 cellspacing=0 border=0> <tr> <td align="right"> <form action="[url=http://www.nexpart.com/extpart.php?part=]http://www.nexpart.com/extpart.php?part=[/url]<?=$r["part_number"]?>&linecode=<?=$row[" manufacturer"] ?>" method="GET"><input type="text" name="quantity" size="2" value="0" style="text-align: center;"><input type="button" name="submit_top" value="Check Out"> </td> </tr> <tr> <td> <table class="search_results_found" bgcolor="#efefef" cellpadding=3 cellspacing=0 border=1 bordercolor="#000000" style="border:1px solid #000000;"> <tr> <td width="100" class="search_results_title" align="center"> Manufacturer </td><td width="70" class="search_results_title" align="center"> Part Num. </td><td width="115" class=" search_results_title" align="center"> Description </td><td width="60" class="search_results_title" align="center">Price</td><td width="45" class=" search_results_title" align="center"> Image </td><td width="105" align="center"><b>Add to Cart</b> </td> </tr> </td> </tr> <? while ($r= mysql_fetch_array($result)) { $manufacturer = $r["manufacturer"]; $part_number = $r["part_number"]; $product_name = $r["product_name"]; $price = $r["price"]; $count++; echo "<tr><td>$manufacturer</td><td>"; echo "<a href=\"[url=http://www.nexpart.com/extpart.php?part=]http://www.nexpart.com/extpart.php?part=[/url]".$r["part_number"]."&linecode=".$r["manufacturer"]."\">".$r["part_number"]."</a></td><td>"; echo "$product_name</td><td>"; echo "$ $price</td><td>"; echo "<a href=\"[url=http://www.wlpsr.com/images/]http://www.wlpsr.com/images/[/url]".$r["part_number"].".jpg \" onClick=\"window.open('/images/".$r["part_number"].".jpg', '".$r["part_number"]."', 'toolbar=yes, directories=no, location=no, status=yes, menubar=no, resizable=yes, scrollbars=yes, height=300, width=400'); return false \">View</a></td><td>"; echo "<form action=\"[url=http://www.nexpart.com/extpart.php?part=]http://www.nexpart.com/extpart.php?part=[/url]".$r["part_number"]."&linecode=".$r["manufacturer"]."\" method=\"GET\"><input type=\"text\" name=\"quantity\" size=\"2\" value=\"0\" style=\"text-align:center;\"></td></tr>"; } ?> </table> <tr> <td align="right"> <form action="[url=http://www.nexpart.com/extpart.php?part=]http://www.nexpart.com/extpart.php?part=[/url]<?=$r["part_number"]?>&linecode=<?=$row[" manufacturer"] ?>" method="GET"><input type="text" name="quantity" size="2" value="0" style="text-align: center;"><input type="button" name="submit_bottom" value="Check Out"> </td> </tr> <? } ?> </table> <br><br> </div> <? @require("footer3.php"); ?> Mod edit: [code] . . . [/code] tags added. Hello all, and apologies for taking your time up, but I am completely stuck!! Have been trying to create a PHP search code (6 weeks now) to return results from a mysql database (I am completely new to this, but okay with HTML). Most of the many attempts I have tried over the weeks have been learned/copied from the web, which resulted initially in connection errors (I hadn't set privileges up), and now I am in a place that that the Favicon spins and returns to original state - but does return:
else{ I am aware that the code may not be perfect, so I have tried downloading sample 'database and php files', and using them but they also dont work (but they do for others trying the sample). I have tried Stack Overflow forums, but they all seem very rude and patronising sadly, and still I havent managed to resolve it...so here I am! Here is a link to the page mentioned (search bar top right in question): https://flighteducation.co.uk/Careers Connect.php
And the php code: <?php session_start(); $output=NULL; if(isset($_POST['submit'])){ //Connect to the database $mysqli = new mysqli("localhost", "jj3wg2td_steven", "MYPASSWORD", "jj3wg2td_careerslist"); $search = $mysqli->real_escape_string($_POST['search']); //Query the database $result = $mysqli->query("SELECT * FROM careers WHERE Job Title LIKE '%$search%'"); if($result->num_rows > 0) { while($rows=$result->fetch_assoc()) { $jobTitle=$rows['Job Title']; $jobDesription=$rows['Job Description']; $salaryLow=$rows['Salary Low']; $salaryHigh=$rows['Salary High']; $output .="Job Title:$jobTitle<br /> Job Description:$jobDesription<br /> Salary Low:$salaryLow<br /> Salary High:$salaryHigh<br /> <br />"; } } else{ $output="No results"; } } ?> I have an output php further down the page, after my search setup OUTPUT:
<!--PHP OUTPUT-->
Search Button Code:
<!--SEARCH BOX-->
I cannot thank you enough for any support you can add as this is literally driving me mad, and wasting endless days (trying)
Kindest regards
Steven
Here's the whole PHP code, just in case I have something in there that clashes with it and a screen shot of the phpMYAdmin header database : <?php session_start(); $output=NULL; if(isset($_POST['submit'])){ //Connect to the database $mysqli = new mysqli("localhost", "jj3wg2td_steven", "MYPASSWORD", "jj3wg2td_careerslist"); $search = $mysqli->real_escape_string($_POST['search']); //Query the database $result = $mysqli->query("SELECT * FROM 'careers' WHERE Job Title LIKE '%$search%'"); if($result->num_rows > 0) { while($rows=$result->fetch_assoc()) { $jobTitle=$rows['Job Title']; $jobDesription=$rows['Job Description']; $salaryLow=$rows['Salary Low']; $salaryHigh=$rows['Salary High']; $output .="Job Title:$jobTitle<br /> Job Description:$jobDesription<br /> Salary Low:$salaryLow<br /> Salary High:$salaryHigh<br /> <br />"; } } else{ $output="No results"; } } ?> <!doctype html> <html> <head> <!-- Global site tag (gtag.js) - Google Analytics --> <script async src="https://www.googletagmanager.com/gtag/js?id=UA-170467250-1"></script> <script> window.dataLayer = window.dataLayer || []; function gtag(){dataLayer.push(arguments);} gtag('js', new Date()); gtag('config', 'UA-170467250-1'); </script> <!--FAVICON--> <link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png"> <link rel="icon" type="image/png" sizes="32x32" href="/favicon-32x32.png"> <link rel="icon" type="image/png" sizes="16x16" href="/favicon-16x16.png"> <link rel="manifest" href="/site.webmanifest"> <link rel="mask-icon" href="/safari-pinned-tab.svg" color="#5bbad5"> <!--FAVICON--> <meta name="msapplication-TileColor" content="#da532c"> <meta name="theme-color" content="#ffffff"> <meta name="msapplication-TileColor" content="#ffffff"> <meta name="msapplication-TileImage" content="/ms-icon-144x144.png"> <meta name="theme-color" content="#ffffff"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css"> <meta charset="utf-8"> <title>- CAREERS -</title> <link href="Responsive.css" rel="stylesheet" type="text/css"> <style type="text/css"> a:link { color: rgba(255,255,255,1); } a:visited { color: rgba(255,255,255,1); } a:hover { color: rgba(243,219,7,1); } a:active { color: rgba(255,255,255,1); } /* scrollbar*/ body::-webkit-scrollbar { width: 6px; } body::-webkit-scrollbar-track { background: Black; } body::-webkit-scrollbar-thumb { background-color: rgba(243,219,7,1); border-radius: 20px; } /* scrollbar*/ </style> <script type="text/javascript"> function MM_swapImgRestore() { //v3.0 var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a)&&x.oSrc;i++) x.src=x.oSrc; } function MM_preloadImages() { //v3.0 var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array(); var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++) if (a.indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a;}} } function MM_findObj(n, d) { //v4.01 var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) { d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);} if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[n]; for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers.document); if(!x && d.getElementById) x=d.getElementById(n); return x; } function MM_swapImage() { //v3.0 var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3) if ((x=MM_findObj(a))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];} } </script> </head> <body onLoad="MM_preloadImages('Top-LogoR.png')"> <!--TOP LOGO --> <div class="home-logo"> <a href="index.html" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('Image31','','Top-LogoR.png',1)"><img id="Image31" src="Top-Logo.png" alt="HOME"></a> </div> <div class="wrapper"> <!--Navigation --> <nav class="topnavbar-container"> <ul> <li><a href="#">COLLEGE /</a> <ul> <li><a href="#">SEARCH FOR A COLLEGE</a></li> <li><a href="#">GO TO COLLEGE</a></li> </ul> </li> <li><a href="#">UNIVERSITY /</a> <ul> <li><a href="#">SEARCH FOR A UNI</a></li> <li><a href="#">GO TO UNI</a></li> <li><a href="League Table.html">LEAGUE TABLES</a></li> <li><a href="Uni Life.html">LIFE IN UNI</a></li> </ul> </li> <li><a href="#">CAREERS</a> <ul> <li><a href="Careers Results.html">SEARCH CAREERS</a></li> <li><a href="index.html#CAREERS">BROWSE CAREERS</a></li> <li><a href="Set your Target.html">PLAN YOUR PATHWAY</a></li> <li><a href="Trending 2020.html">TRENDING IN 2020</a></li> </ul> </li> </ul> </nav> <!--SEARCH BOX--> <div class="search-box"> <form method="POST" id="search"> <input class="search-txt" type="TEXT" name="search" placeholder="SEARCH CAREERS"> <button class="search-btn" name="submit" type="submit"> <i class="fa fa-search" aria-hidden="true"></i> </button> </form> </div> <!--Top Container --> <section class="careers-results"> <header class="showcase-career"> <label for="Careers">Choose a Career:</label> <img src="img/Careers-Logo.png" alt="LOGO"> <br> <select class="careers-dropdown" name="Careers" id="Careers"> <option value=" 3D printing technician "> 3D printing technician </option> <option value=" Accommodation warden "> Accommodation warden </option> <option value=" Accounting technician "> Accounting technician </option> <option value=" Acoustics consultant "> Acoustics consultant </option> <option value=" Actor "> Actor </option> <option value=" Actuary "> Actuary </option> <option value=" Acupuncturist "> Acupuncturist </option> <option value=" Admin assistant "> Admin assistant </option> <option value=" Advertising account executive "> Advertising account executive </option> <option value=" Advertising account planner "> Advertising account planner </option> <option value=" Advertising art director "> Advertising art director </option> <option value=" Advertising copywriter "> Advertising copywriter </option> <option value=" Advertising media buyer "> Advertising media buyer </option> <option value=" Advertising media planner "> Advertising media planner </option> <option value=" Aerospace engineer "> Aerospace engineer </option> <option value=" Aerospace engineering technician "> Aerospace engineering technician </option> <option value=" Agricultural contractor "> Agricultural contractor </option> <option value=" Agricultural engineer "> Agricultural engineer </option> <option value=" Agricultural engineering technician "> Agricultural engineering technician </option> <option value=" Agricultural inspector "> Agricultural inspector </option> <option value=" Agronomist "> Agronomist </option> <option value=" Aid worker "> Aid worker </option> <option value=" Air accident investigator "> Air accident investigator </option> <option value=" Air traffic controller "> Air traffic controller </option> <option value=" Airline customer service agent "> Airline customer service agent </option> <option value=" Airline pilot "> Airline pilot </option> <option value=" Airport baggage handler "> Airport baggage handler </option> <option value=" Airport information assistant "> Airport information assistant </option> <option value=" Alexander Technique teacher "> Alexander Technique teacher </option> <option value=" Ambulance care assistant "> Ambulance care assistant </option> <option value=" Anaesthetist "> Anaesthetist </option> <option value=" Analytical textile technologist "> Analytical textile technologist </option> <option value=" Anatomical pathology technician "> Anatomical pathology technician </option> <option value=" Animal care worker "> Animal care worker </option> <option value=" Animal technician "> Animal technician </option> <option value=" Animator "> Animator </option> <option value=" Antique dealer "> Antique dealer </option> <option value=" App developer "> App developer </option> <option value=" Arboricultural officer "> Arboricultural officer </option> <option value=" Archaeologist "> Archaeologist </option> <option value=" Architect "> Architect </option> <option value=" Architectural technician "> Architectural technician </option> <option value=" Architectural technologist "> Architectural technologist </option> <option value=" Archivist "> Archivist </option> <option value=" Army officer "> Army officer </option> <option value=" Aromatherapist "> Aromatherapist </option> <option value=" Art editor "> Art editor </option> <option value=" Art gallery curator "> Art gallery curator </option> <option value=" Art therapist "> Art therapist </option> <option value=" Art valuer "> Art valuer </option> <option value=" Arts administrator "> Arts administrator </option> <option value=" Assistance dog trainer "> Assistance dog trainer </option> <option value=" Assistant immigration officer "> Assistant immigration officer </option> <option value=" Astronaut "> Astronaut </option> <option value=" Astronomer "> Astronomer </option> <option value=" Athlete "> Athlete </option> <option value=" Audiologist "> Audiologist </option> <option value=" Audio-visual technician "> Audio-visual technician </option> <option value=" Auditor "> Auditor </option> <option value=" Auto electrician "> Auto electrician </option> <option value=" Automotive engineer "> Automotive engineer </option> <option value=" Bailiff "> Bailiff </option> <option value=" Baker "> Baker </option> <option value=" Bank manager "> Bank manager </option> <option value=" Banking customer service adviser "> Banking customer service adviser </option> <option value=" Bar person "> Bar person </option> <option value=" Barber "> Barber </option> <option value=" Barista "> Barista </option> <option value=" Barrister "> Barrister </option> <option value=" Barristers' clerk "> Barristers' clerk </option> <option value=" Beauty consultant "> Beauty consultant </option> <option value=" Beauty therapist "> Beauty therapist </option> <option value=" Beekeeper "> Beekeeper </option> <option value=" Betting shop cashier "> Betting shop cashier </option> <option value=" Bid writer "> Bid writer </option> <option value=" Bilingual secretary "> Bilingual secretary </option> <option value=" Bin worker "> Bin worker </option> <option value=" Bingo caller "> Bingo caller </option> <option value=" Biochemist "> Biochemist </option> <option value=" Biologist "> Biologist </option> <option value=" Biomedical scientist "> Biomedical scientist </option> <option value=" Biotechnologist "> Biotechnologist </option> <option value=" Blacksmith "> Blacksmith </option> <option value=" Boat builder "> Boat builder </option> <option value=" Body piercer "> Body piercer </option> <option value=" Bodyguard "> Bodyguard </option> <option value=" Bomb disposal technician "> Bomb disposal technician </option> <option value=" Bookbinder "> Bookbinder </option> <option value=" Bookkeeper "> Bookkeeper </option> <option value=" Bookmaker "> Bookmaker </option> <option value=" Bookseller "> Bookseller </option> <option value=" Border Force officer "> Border Force officer </option> <option value=" Botanist "> Botanist </option> <option value=" Bottler "> Bottler </option> <option value=" Boxer "> Boxer </option> <option value=" Brewery worker "> Brewery worker </option> <option value=" Bricklayer "> Bricklayer </option> <option value=" British Sign Language interpreter "> British Sign Language interpreter </option> <option value=" British Sign Language teacher "> British Sign Language teacher </option> <option value=" Broadcast Engineer "> Broadcast Engineer </option> <option value=" Broadcast journalist "> Broadcast journalist </option> <option value=" Builders' merchant "> Builders' merchant </option> <option value=" Building control officer "> Building control officer </option> <option value=" Building services engineer "> Building services engineer </option> <option value=" Building site inspector "> Building site inspector </option> <option value=" Building surveyor "> Building surveyor </option> <option value=" Building technician "> Building technician </option> <option value=" Bus or coach driver "> Bus or coach driver </option> <option value=" Business adviser "> Business adviser </option> <option value=" Business analyst "> Business analyst </option> <option value=" Business development manager "> Business development manager </option> <option value=" Business project manager "> Business project manager </option> <option value=" Butcher "> Butcher </option> <option value=" Butler "> Butler </option> <option value=" Cabin crew "> Cabin crew </option> <option value=" CAD technician "> CAD technician </option> <option value=" Cake decorator "> Cake decorator </option> <option value=" Call centre operator "> Call centre operator </option> <option value=" Car manufacturing worker "> Car manufacturing worker </option> <option value=" Car rental agent "> Car rental agent </option> <option value=" Car valet "> Car valet </option> <option value=" Care escort "> Care escort </option> <option value=" Care home advocate "> Care home advocate </option> <option value=" Care home manager "> Care home manager </option> <option value=" Care worker "> Care worker </option> <option value=" Careers adviser "> Careers adviser </option> <option value=" Caretaker "> Caretaker </option> <option value=" Carpenter "> Carpenter </option> <option value=" Carpet fitter and floor layer "> Carpet fitter and floor layer </option> <option value=" Cartographer "> Cartographer </option> <option value=" Catering manager "> Catering manager </option> <option value=" Cavity insulation installer "> Cavity insulation installer </option> <option value=" Ceiling fixer "> Ceiling fixer </option> <option value=" Celebrant "> Celebrant </option> <option value=" Cellar technician "> Cellar technician </option> <option value=" Cemetery worker "> Cemetery worker </option> <option value=" Ceramics designer-maker "> Ceramics designer-maker </option> <option value=" Charity director "> Charity director </option> <option value=" Charity fundraiser "> Charity fundraiser </option> <option value=" Chauffeur "> Chauffeur </option> <option value=" Checkout operator "> Checkout operator </option> <option value=" Chef "> Chef </option> <option value=" Chemical engineer "> Chemical engineer </option> <option value=" Chemical engineering technician "> Chemical engineering technician </option> <option value=" Chemical plant process operator "> Chemical plant process operator </option> <option value=" Chemist "> Chemist </option> <option value=" Chief executive "> Chief executive </option> <option value=" Chief inspector "> Chief inspector </option> <option value=" Child protection officer "> Child protection officer </option> <option value=" Childminder "> Childminder </option> <option value=" Children's nurse "> Children's nurse </option> <option value=" Chimney sweep "> Chimney sweep </option> <option value=" Chiropractor "> Chiropractor </option> <option value=" Choreographer "> Choreographer </option> <option value=" Cinema or theatre attendant "> Cinema or theatre attendant </option> <option value=" Cinema projectionist "> Cinema projectionist </option> <option value=" Circus performer "> Circus performer </option> <option value=" Civil enforcement officer "> Civil enforcement officer </option> <option value=" Civil engineer "> Civil engineer </option> <option value=" Civil engineering technician "> Civil engineering technician </option> <option value=" Civil Service administrative officer "> Civil Service administrative officer </option> <option value=" Civil Service executive officer "> Civil Service executive officer </option> <option value=" Civil Service manager "> Civil Service manager </option> <option value=" Classical musician "> Classical musician </option> <option value=" Cleaner "> Cleaner </option> <option value=" Climate scientist "> Climate scientist </option> <option value=" Clinical engineer "> Clinical engineer </option> <option value=" Clinical psychologist "> Clinical psychologist </option> <option value=" Clinical scientist "> Clinical scientist </option> <option value=" CNC machinist "> CNC machinist </option> <option value=" Coastguard "> Coastguard </option> <option value=" Cognitive behavioural therapist "> Cognitive behavioural therapist </option> <option value=" Colon hydrotherapist "> Colon hydrotherapist </option> <option value=" Colour therapist "> Colour therapist </option> <option value=" Commercial energy assessor "> Commercial energy assessor </option> <option value=" Commissioning editor "> Commissioning editor </option> <option value=" Communication support worker "> Communication support worker </option> <option value=" Community arts worker "> Community arts worker </option> <option value=" Community development worker "> Community development worker </option> <option value=" Community education co-ordinator "> Community education co-ordinator </option> <option value=" Community matron "> Community matron </option> <option value=" Community transport driver "> Community transport driver </option> <option value=" Company secretary "> Company secretary </option> <option value=" Computer games developer "> Computer games developer </option> <option value=" Computer games tester "> Computer games tester </option> <option value=" Conference and exhibition manager "> Conference and exhibition manager </option> <option value=" Conservator "> Conservator </option> <option value=" Construction contracts manager "> Construction contracts manager </option> <option value=" Construction labourer "> Construction labourer </option> <option value=" Construction manager "> Construction manager </option> <option value=" Construction plant hire adviser "> Construction plant hire adviser </option> <option value=" Construction plant mechanic "> Construction plant mechanic </option> <option value=" Construction plant operator "> Construction plant operator </option> <option value=" Construction site supervisor "> Construction site supervisor </option> <option value=" Consumer scientist "> Consumer scientist </option> <option value=" Copy editor "> Copy editor </option> <option value=" Coroner "> Coroner </option> <option value=" Cosmetic surgeon "> Cosmetic surgeon </option> <option value=" Costume designer "> Costume designer </option> <option value=" Counsellor "> Counsellor </option> <option value=" Counter service assistant "> Counter service assistant </option> <option value=" Countryside officer "> Countryside officer </option> <option value=" Countryside ranger "> Countryside ranger </option> <option value=" Courier "> Courier </option> <option value=" Court administrative assistant "> Court administrative assistant </option> <option value=" Court legal adviser "> Court legal adviser </option> <option value=" Court usher "> Court usher </option> <option value=" Crane driver "> Crane driver </option> <option value=" Credit controller "> Credit controller </option> <option value=" Credit manager "> Credit manager </option> <option value=" Crematorium technician "> Crematorium technician </option> <option value=" Cricketer "> Cricketer </option> <option value=" Criminal intelligence analyst "> Criminal intelligence analyst </option> <option value=" Criminologist "> Criminologist </option> <option value=" Critical care technologist "> Critical care technologist </option> <option value=" Croupier "> Croupier </option> <option value=" Crown prosecutor "> Crown prosecutor </option> <option value=" Cruise ship steward "> Cruise ship steward </option> <option value=" Customer service assistant "> Customer service assistant </option> <option value=" Customer services manager "> Customer services manager </option> <option value=" Cyber intelligence officer "> Cyber intelligence officer </option> <option value=" Cycle mechanic "> Cycle mechanic </option> <option value=" Cycling coach "> Cycling coach </option> <option value=" Dance movement psychotherapist "> Dance movement psychotherapist </option> <option value=" Dance teacher "> Dance teacher </option> <option value=" Dancer "> Dancer </option> <option value=" Data analyst-statistician "> Data analyst-statistician </option> <option value=" Data entry clerk "> Data entry clerk </option> <option value=" Database administrator "> Database administrator </option> <option value=" Delivery van driver "> Delivery van driver </option> <option value=" Demolition operative "> Demolition operative </option> <option value=" Dental hygienist "> Dental hygienist </option> <option value=" Dental nurse "> Dental nurse </option> <option value=" Dental technician "> Dental technician </option> <option value=" Dental therapist "> Dental therapist </option> <option value=" Dentist "> Dentist </option> <option value=" Design and development engineer "> Design and development engineer </option> <option value=" Dietitian "> Dietitian </option> <option value=" Digital delivery manager "> Digital delivery manager </option> <option value=" Digital marketer "> Digital marketer </option> <option value=" Digital product owner "> Digital product owner </option> <option value=" Diplomatic Service officer "> Diplomatic Service officer </option> <option value=" Director of photography "> Director of photography </option> <option value=" Dispensing optician "> Dispensing optician </option> <option value=" District nurse "> District nurse </option> <option value=" Diver "> Diver </option> <option value=" DJ "> DJ </option> <option value=" Dog groomer "> Dog groomer </option> <option value=" Dog handler "> Dog handler </option> <option value=" Domestic appliance service engineer "> Domestic appliance service engineer </option> <option value=" Domestic energy assessor "> Domestic energy assessor </option> <option value=" Door supervisor "> Door supervisor </option> <option value=" Dramatherapist "> Dramatherapist </option> <option value=" Dressmaker "> Dressmaker </option> <option value=" Driving instructor "> Driving instructor </option> <option value=" Drone pilot "> Drone pilot </option> <option value=" Drug and alcohol worker "> Drug and alcohol worker </option> <option value=" Dry cleaner "> Dry cleaner </option> <option value=" Dry liner "> Dry liner </option> <option value=" Early years teacher "> Early years teacher </option> <option value=" Ecologist "> Ecologist </option> <option value=" E-commerce manager "> E-commerce manager </option> <option value=" Economic development officer "> Economic development officer </option> <option value=" Economist "> Economist </option> <option value=" Editorial assistant "> Editorial assistant </option> <option value=" Education technician "> Education technician </option> <option value=" Education welfare officer "> Education welfare officer </option> <option value=" E-learning developer "> E-learning developer </option> <option value=" Electrical engineer "> Electrical engineer </option> <option value=" Electrical engineering technician "> Electrical engineering technician </option> <option value=" Electrician "> Electrician </option> <option value=" Electricity distribution worker "> Electricity distribution worker </option> <option value=" Electricity generation worker "> Electricity generation worker </option> <option value=" Electronics engineer "> Electronics engineer </option> <option value=" Electronics engineering technician "> Electronics engineering technician </option> <option value=" Embalmer "> Embalmer </option> <option value=" Emergency care assistant "> Emergency care assistant </option> <option value=" Emergency medical dispatcher "> Emergency medical dispatcher </option> <option value=" Energy engineer "> Energy engineer </option> <option value=" Engineering construction craftworker "> Engineering construction craftworker </option> <option value=" Engineering construction technician "> Engineering construction technician </option> <option value=" Engineering craft machinist "> Engineering craft machinist </option> <option value=" Engineering maintenance technician "> Engineering maintenance technician </option> <option value=" Engineering operative "> Engineering operative </option> <option value=" English as a foreign language (EFL) teacher "> English as a foreign language (EFL) teacher </option> <option value=" Entertainer "> Entertainer </option> <option value=" Entertainment agent "> Entertainment agent </option> <option value=" Environmental consultant "> Environmental consultant </option> <option value=" Environmental health officer "> Environmental health officer </option> <option value=" Equalities officer "> Equalities officer </option> <option value=" Ergonomist "> Ergonomist </option> <option value=" Estate agent "> Estate agent </option> <option value=" Estates officer "> Estates officer </option> <option value=" Estimator "> Estimator </option> <option value=" European Union official "> European Union official </option> <option value=" Events manager "> Events manager </option> <option value=" Exhibition designer "> Exhibition designer </option> <option value=" Facilities manager "> Facilities manager </option> <option value=" Fairground worker "> Fairground worker </option> <option value=" Family mediator "> Family mediator </option> <option value=" Family support worker "> Family support worker </option> <option value=" Farm secretary "> Farm secretary </option> <option value=" Farm worker "> Farm worker </option> <option value=" Farmer "> Farmer </option> <option value=" Farrier "> Farrier </option> <option value=" Fashion design assistant "> Fashion design assistant </option> <option value=" Fashion designer "> Fashion designer </option> <option value=" Fashion model "> Fashion model </option> <option value=" Fence installer "> Fence installer </option> <option value=" Film critic "> Film critic </option> <option value=" Finance officer "> Finance officer </option> <option value=" Financial adviser "> Financial adviser </option> <option value=" Financial services customer adviser "> Financial services customer adviser </option> <option value=" Fine artist "> Fine artist </option> <option value=" Fingerprint officer "> Fingerprint officer </option> <option value=" Firefighter "> Firefighter </option> <option value=" Fish farmer "> Fish farmer </option> <option value=" Fish frier "> Fish frier </option> <option value=" Fishing boat deckhand "> Fishing boat deckhand </option> <option value=" Fishing vessel skipper "> Fishing vessel skipper </option> <option value=" Fishmonger "> Fishmonger </option> <option value=" Fitness instructor "> Fitness instructor </option> <option value=" Florist "> Florist </option> <option value=" Food factory worker "> Food factory worker </option> <option value=" Food manufacturing inspector "> Food manufacturing inspector </option> <option value=" Food packaging operative "> Food packaging operative </option> <option value=" Food scientist "> Food scientist </option> <option value=" Football coach "> Football coach </option> <option value=" Football referee "> Football referee </option> <option value=" Footballer "> Footballer </option> <option value=" Footwear designer "> Footwear designer </option> <option value=" Footwear manufacturing operative "> Footwear manufacturing operative </option> <option value=" Forensic computer analyst "> Forensic computer analyst </option> <option value=" Forensic psychologist "> Forensic psychologist </option> <option value=" Forensic scientist "> Forensic scientist </option> <option value=" Forest officer "> Forest officer </option> <option value=" Forestry worker "> Forestry worker </option> <option value=" Forklift driver "> Forklift driver </option> <option value=" Forklift truck engineer "> Forklift truck engineer </option> <option value=" Foster carer "> Foster carer </option> <option value=" Foundry mould maker "> Foundry mould maker </option> <option value=" Foundry process operator "> Foundry process operator </option> <option value=" Franchise owner "> Franchise owner </option> <option value=" French polisher "> French polisher </option> <option value=" Funeral director "> Funeral director </option> <option value=" Furniture designer "> Furniture designer </option> <option value=" Furniture maker "> Furniture maker </option> <option value=" Furniture restorer "> Furniture restorer </option> <option value=" Further education lecturer "> Further education lecturer </option> <option value=" Gamekeeper "> Gamekeeper </option> <option value=" Garage manager "> Garage manager </option> <option value=" Garden nursery assistant "> Garden nursery assistant </option> <option value=" Gardener "> Gardener </option> <option value=" Garment technologist "> Garment technologist </option> <option value=" Gas mains layer "> Gas mains layer </option> <option value=" Gas service technician "> Gas service technician </option> <option value=" General practice surveyor "> General practice surveyor </option> <option value=" Geneticist "> Geneticist </option> <option value=" Geoscientist "> Geoscientist </option> <option value=" Geospatial technician "> Geospatial technician </option> <option value=" Geotechnician "> Geotechnician </option> <option value=" Glassmaker "> Glassmaker </option> <option value=" Glazier "> Glazier </option> <option value=" GP "> GP </option> <option value=" GP practice manager "> GP practice manager </option> <option value=" Graphic designer "> Graphic designer </option> <option value=" Groundsperson "> Groundsperson </option> <option value=" Hairdresser "> Hairdresser </option> <option value=" Hairdressing salon manager "> Hairdressing salon manager </option> <option value=" Handyperson "> Handyperson </option> <option value=" Head chef "> Head chef </option> <option value=" Head of IT (IT director) "> Head of IT (IT director) </option> <option value=" Headteacher "> Headteacher </option> <option value=" Health and safety adviser "> Health and safety adviser </option> <option value=" Health play specialist "> Health play specialist </option> <option value=" Health promotion specialist "> Health promotion specialist </option> <option value=" Health records clerk "> Health records clerk </option> <option value=" Health service manager "> Health service manager </option> <option value=" Health trainer "> Health trainer </option> <option value=" Health visitor "> Health visitor </option> <option value=" Healthcare assistant "> Healthcare assistant </option> <option value=" Healthcare science assistant "> Healthcare science assistant </option> <option value=" Heating and ventilation engineer "> Heating and ventilation engineer </option> <option value=" Helicopter engineer "> Helicopter engineer </option> <option value=" Helicopter pilot "> Helicopter pilot </option> <option value=" Heritage officer "> Heritage officer </option> <option value=" Higher education lecturer "> Higher education lecturer </option> <option value=" Highways cleaner "> Highways cleaner </option> <option value=" Homeopath "> Homeopath </option> <option value=" Horse groom "> Horse groom </option> <option value=" Horse riding instructor "> Horse riding instructor </option> <option value=" Horticultural manager "> Horticultural manager </option> <option value=" Horticultural therapist "> Horticultural therapist </option> <option value=" Horticultural worker "> Horticultural worker </option> <option value=" Hospital doctor "> Hospital doctor </option> <option value=" Hospital porter "> Hospital porter </option> <option value=" Hotel manager "> Hotel manager </option> <option value=" Hotel porter "> Hotel porter </option> <option value=" Hotel receptionist "> Hotel receptionist </option> <option value=" Hotel room attendant "> Hotel room attendant </option> <option value=" Housekeeper "> Housekeeper </option> <option value=" Housing officer "> Housing officer </option> <option value=" Housing policy officer "> Housing policy officer </option> <option value=" Human resources assistant "> Human resources assistant </option> <option value=" Human resources manager "> Human resources manager </option> <option value=" Human resources officer "> Human resources officer </option> <option value=" Hydrologist "> Hydrologist </option> <option value=" Hypnotherapist "> Hypnotherapist </option> <option value=" Illustrator "> Illustrator </option> <option value=" Image consultant "> Image consultant </option> <option value=" Immigration adviser (non-government) "> Immigration adviser (non-government) </option> <option value=" Immigration officer "> Immigration officer </option> <option value=" Import-export clerk "> Import-export clerk </option> <option value=" Indexer "> Indexer </option> <option value=" Industrial cleaner "> Industrial cleaner </option> <option value=" Information scientist "> Information scientist </option> <option value=" Insurance account manager "> Insurance account manager </option> <option value=" Insurance broker "> Insurance broker </option> <option value=" Insurance claims handler "> Insurance claims handler </option> <option value=" Insurance loss adjuster "> Insurance loss adjuster </option> <option value=" Insurance risk surveyor "> Insurance risk surveyor </option> <option value=" Insurance technician "> Insurance technician </option> <option value=" Insurance underwriter "> Insurance underwriter </option> <option value=" Interior designer "> Interior designer </option> <option value=" Interpreter "> Interpreter </option> <option value=" Investment analyst "> Investment analyst </option> <option value=" IT project manager "> IT project manager </option> <option value=" IT security co-ordinator "> IT security co-ordinator </option> <option value=" IT service engineer "> IT service engineer </option> <option value=" IT support technician "> IT support technician </option> <option value=" IT trainer "> IT trainer </option> <option value=" Jewellery designer-maker "> Jewellery designer-maker </option> <option value=" Jockey "> Jockey </option> <option value=" Judge "> Judge </option> <option value=" Kennel worker "> Kennel worker </option> <option value=" Kitchen and bathroom fitter "> Kitchen and bathroom fitter </option> <option value=" Kitchen assistant "> Kitchen assistant </option> <option value=" Kitchen porter "> Kitchen porter </option> <option value=" Knitter "> Knitter </option> <option value=" Laboratory technician "> Laboratory technician </option> <option value=" Land and property valuer and auctioneer "> Land and property valuer and auctioneer </option> <option value=" Land surveyor "> Land surveyor </option> <option value=" Landscape architect "> Landscape architect </option> <option value=" Landscaper "> Landscaper </option> <option value=" Large goods vehicle driver "> Large goods vehicle driver </option> <option value=" Laundry worker "> Laundry worker </option> <option value=" Learning disability nurse "> Learning disability nurse </option> <option value=" Learning mentor "> Learning mentor </option> <option value=" Leather craftworker "> Leather craftworker </option> <option value=" Leather technologist "> Leather technologist </option> <option value=" Legal executive "> Legal executive </option> <option value=" Legal secretary "> Legal secretary </option> <option value=" Leisure centre assistant "> Leisure centre assistant </option> <option value=" Leisure centre manager "> Leisure centre manager </option> <option value=" Letting agent "> Letting agent </option> <option value=" Librarian "> Librarian </option> <option value=" Library assistant "> Library assistant </option> <option value=" Licensed conveyancer "> Licensed conveyancer </option> <option value=" Life coach "> Life coach </option> <option value=" Lifeguard "> Lifeguard </option> <option value=" Lift engineer "> Lift engineer </option> <option value=" Lighting technician "> Lighting technician </option> <option value=" Live sound engineer "> Live sound engineer </option> <option value=" Local government administrative assistant "> Local government administrative assistant </option> <option value=" Local government officer "> Local government officer </option> <option value=" Local government revenues officer "> Local government revenues officer </option> <option value=" Lock keeper "> Lock keeper </option> <option value=" Locksmith "> Locksmith </option> <option value=" Magazine journalist "> Magazine journalist </option> <option value=" Magistrate "> Magistrate </option> <option value=" Maintenance fitter "> Maintenance fitter </option> <option value=" Make-up artist "> Make-up artist </option> <option value=" Management accountant "> Management accountant </option> <option value=" Management consultant "> Management consultant </option> <option value=" Manufacturing supervisor "> Manufacturing supervisor </option> <option value=" Manufacturing systems engineer "> Manufacturing systems engineer </option> <option value=" Marine engineer "> Marine engineer </option> <option value=" Marine engineering technician "> Marine engineering technician </option> <option value=" Market research data analyst "> Market research data analyst </option> <option value=" Market research executive "> Market research executive </option> <option value=" Market researcher "> Market researcher </option> <option value=" Market trader "> Market trader </option> <option value=" Marketing director "> Marketing director </option> <option value=" Marketing executive "> Marketing executive </option> <option value=" Marketing manager "> Marketing manager </option> <option value=" Martial arts instructor "> Martial arts instructor </option> <option value=" Massage therapist "> Massage therapist </option> <option value=" Materials engineer "> Materials engineer </option> <option value=" Materials technician "> Materials technician </option> <option value=" Maternity support worker "> Maternity support worker </option> <option value=" Meat hygiene inspector "> Meat hygiene inspector </option> <option value=" Meat process worker "> Meat process worker </option> <option value=" Mechanical engineer "> Mechanical engineer </option> <option value=" Mechanical engineering technician "> Mechanical engineering technician </option> <option value=" Media researcher "> Media researcher </option> <option value=" Medical herbalist "> Medical herbalist </option> <option value=" Medical illustrator "> Medical illustrator </option> <option value=" Medical physicist "> Medical physicist </option> <option value=" Medical sales representative "> Medical sales representative </option> <option value=" Medical secretary "> Medical secretary </option> <option value=" Mental health nurse "> Mental health nurse </option> <option value=" Merchant Navy deck officer "> Merchant Navy deck officer </option> <option value=" Merchant Navy engineering officer "> Merchant Navy engineering officer </option> <option value=" Merchant Navy rating "> Merchant Navy rating </option> <option value=" Meteorologist "> Meteorologist </option> <option value=" Metrologist "> Metrologist </option> <option value=" Microbiologist "> Microbiologist </option> <option value=" Microbrewer "> Microbrewer </option> <option value=" Midwife "> Midwife </option> <option value=" Model maker "> Model maker </option> <option value=" Money adviser "> Money adviser </option> <option value=" Montessori teacher "> Montessori teacher </option> <option value=" Mortgage adviser "> Mortgage adviser </option> <option value=" Motor mechanic "> Motor mechanic </option> <option value=" Motor vehicle breakdown engineer "> Motor vehicle breakdown engineer </option> <option value=" Motor vehicle fitter "> Motor vehicle fitter </option> <option value=" Motor vehicle parts person "> Motor vehicle parts person </option> <option value=" Motorcycle mechanic "> Motorcycle mechanic </option> <option value=" Motorsport engineer "> Motorsport engineer </option> <option value=" MP "> MP </option> <option value=" Museum assistant "> Museum assistant </option> <option value=" Museum curator "> Museum curator </option> <option value=" Music promotions manager "> Music promotions manager </option> <option value=" Music teacher "> Music teacher </option> <option value=" Music therapist "> Music therapist </option> <option value=" Musical instrument maker and repairer "> Musical instrument maker and repairer </option> <option value=" Nail technician "> Nail technician </option> <option value=" Nanny "> Nanny </option> <option value=" Nanotechnologist "> Nanotechnologist </option> <option value=" Naturopath "> Naturopath </option> <option value=" Naval architect "> Naval architect </option> <option value=" Neighbourhood warden "> Neighbourhood warden </option> <option value=" Network engineer "> Network engineer </option> <option value=" Network manager "> Network manager </option> <option value=" Newspaper journalist "> Newspaper journalist </option> <option value=" Newspaper or magazine editor "> Newspaper or magazine editor </option> <option value=" Non-destructive testing technician "> Non-destructive testing technician </option> <option value=" Nuclear engineer "> Nuclear engineer </option> <option value=" Nuclear technician "> Nuclear technician </option> <option value=" Nurse "> Nurse </option> <option value=" Nursery manager "> Nursery manager </option> <option value=" Nursery worker "> Nursery worker </option> <option value=" Nursing associate "> Nursing associate </option> <option value=" Nutritional therapist "> Nutritional therapist </option> <option value=" Nutritionist "> Nutritionist </option> <option value=" Occupational health nurse "> Occupational health nurse </option> <option value=" Occupational therapist "> Occupational therapist </option> <option value=" Occupational therapy support worker "> Occupational therapy support worker </option> <option value=" Oceanographer "> Oceanographer </option> <option value=" Office manager "> Office manager </option> <option value=" Offshore drilling worker "> Offshore drilling worker </option> <option value=" Ofsted inspector "> Ofsted inspector </option> <option value=" Oil and gas operations manager "> Oil and gas operations manager </option> <option value=" Online tutor "> Online tutor </option> <option value=" Operating department practitioner "> Operating department practitioner </option> <option value=" Operational researcher "> Operational researcher </option> <option value=" Optometrist "> Optometrist </option> <option value=" Order picker "> Order picker </option> <option value=" Ornithologist "> Ornithologist </option> <option value=" Orthoptist "> Orthoptist </option> <option value=" Osteopath "> Osteopath </option> <option value=" Outdoor activities instructor "> Outdoor activities instructor </option> <option value=" Packaging technologist "> Packaging technologist </option> <option value=" Packer "> Packer </option> <option value=" Paediatrician "> Paediatrician </option> <option value=" Paint sprayer "> Paint sprayer </option> <option value=" Painter and decorator "> Painter and decorator </option> <option value=" Palaeontologist "> Palaeontologist </option> <option value=" Palliative care assistant "> Palliative care assistant </option> <option value=" Paper maker "> Paper maker </option> <option value=" Paralegal "> Paralegal </option> <option value=" Paramedic "> Paramedic </option> <option value=" Patent attorney "> Patent attorney </option> <option value=" Pathologist "> Pathologist </option> <option value=" Patient advice and liaison service officer "> Patient advice and liaison service officer </option> <option value=" Patient transport service controller "> Patient transport service controller </option> <option value=" Pattern cutter "> Pattern cutter </option> <option value=" Payroll administrator "> Payroll administrator </option> <option value=" Payroll manager "> Payroll manager </option> <option value=" PE teacher "> PE teacher </option> <option value=" Pensions administrator "> Pensions administrator </option> <option value=" Pensions adviser "> Pensions adviser </option> <option value=" Personal assistant "> Personal assistant </option> <option value=" Personal shopper "> Personal shopper </option> <option value=" Personal trainer "> Personal trainer </option> <option value=" Pest control technician "> Pest control technician </option> <option value=" Pet behaviour counsellor "> Pet behaviour counsellor </option> <option value=" Pet shop assistant "> Pet shop assistant </option> <option value=" Petrol station sales assistant "> Petrol station sales assistant </option> <option value=" Pharmacist "> Pharmacist </option> <option value=" Pharmacologist "> Pharmacologist </option> <option value=" Pharmacy assistant "> Pharmacy assistant </option> <option value=" Pharmacy technician "> Pharmacy technician </option> <option value=" Phlebotomist "> Phlebotomist </option> <option value=" Photographer "> Photographer </option> <option value=" Photographic stylist "> Photographic stylist </option> <option value=" Photographic technician "> Photographic technician </option> <option value=" Physician associate "> Physician associate </option> <option value=" Physicist "> Physicist </option> <option value=" Physiotherapist "> Physiotherapist </option> <option value=" Physiotherapy assistant "> Physiotherapy assistant </option> <option value=" Picture framer "> Picture framer </option> <option value=" Pilates teacher "> Pilates teacher </option> <option value=" Pipe fitter "> Pipe fitter </option> <option value=" Planning and development surveyor "> Planning and development surveyor </option> <option value=" Plasterer "> Plasterer </option> <option value=" Play therapist "> Play therapist </option> <option value=" Playworker "> Playworker </option> <option value=" Plumber "> Plumber </option> <option value=" Podiatrist "> Podiatrist </option> <option value=" Podiatry assistant "> Podiatry assistant </option> <option value=" Police community support officer "> Police community support officer </option> <option value=" Police officer "> Police officer </option> <option value=" Pop musician "> Pop musician </option> <option value=" Port operative "> Port operative </option> <option value=" Portage home visitor "> Portage home visitor </option> <option value=" Post Office customer service assistant "> Post Office customer service assistant </option> <option value=" Postman or postwoman "> Postman or postwoman </option> <option value=" Practice nurse "> Practice nurse </option> <option value=" Pre-press operator "> Pre-press operator </option> <option value=" Primary care graduate mental health worker "> Primary care graduate mental health worker </option> <option value=" Primary school teacher "> Primary school teacher </option> <option value=" Prison governor "> Prison governor </option> <option value=" Prison instructor "> Prison instructor </option> <option value=" Prison officer "> Prison officer </option> <option value=" Private investigator "> Private investigator </option> <option value=" Private practice accountant "> Private practice accountant </option> <option value=" Probation officer "> Probation officer </option> <option value=" Probation services officer "> Probation services officer </option> <option value=" Product designer "> Product designer </option> <option value=" Production manager (manufacturing) "> Production manager (manufacturing) </option> <option value=" Production worker (manufacturing) "> Production worker (manufacturing) </option> <option value=" Proofreader "> Proofreader </option> <option value=" Prop maker "> Prop maker </option> <option value=" Prosthetist-orthotist "> Prosthetist-orthotist </option> <option value=" Psychiatrist "> Psychiatrist </option> <option value=" Psychologist "> Psychologist </option> <option value=" Psychotherapist "> Psychotherapist </option> <option value=" Public finance accountant "> Public finance accountant </option> <option value=" Public relations director "> Public relations director </option> <option value=" Public relations officer "> Public relations officer </option> <option value=" Publican "> Publican </option> <option value=" Purchasing manager "> Purchasing manager </option> <option value=" QCF assessor "> QCF assessor </option> <option value=" Quality assurance manager "> Quality assurance manager </option> <option value=" Quality control assistant "> Quality control assistant </option> <option value=" Quantity surveyor "> Quantity surveyor </option> <option value=" Quarry engineer "> Quarry engineer </option> <option value=" Quarry worker "> Quarry worker </option> <option value=" Racehorse trainer "> Racehorse trainer </option> <option value=" Radio broadcast assistant "> Radio broadcast assistant </option> <option value=" Radiographer "> Radiographer </option> <option value=" Radiography assistant "> Radiography assistant </option> <option value=" RAF airman or airwoman "> RAF airman or airwoman </option> <option value=" RAF non-commissioned aircrew "> RAF non-commissioned aircrew </option> <option value=" RAF officer "> RAF officer </option> <option value=" Rail engineering technician "> Rail engineering technician </option> <option value=" Rail track maintenance worker "> Rail track maintenance worker </option> <option value=" Railway signaller "> Railway signaller </option> <option value=" Receptionist "> Receptionist </option> <option value=" Recruitment consultant "> Recruitment consultant </option> <option value=" Recycled metals worker "> Recycled metals worker </option> <option value=" Recycling officer "> Recycling officer </option> <option value=" Recycling operative "> Recycling operative </option> <option value=" Reflexologist "> Reflexologist </option> <option value=" Refrigeration and air-conditioning installer "> Refrigeration and air-conditioning installer </option> <option value=" Registrar of births, deaths, marriages and civil partnerships "> Registrar of births, deaths, marriages and civil partnerships </option> <option value=" Reiki healer "> Reiki healer </option> <option value=" Religious leader "> Religious leader </option> <option value=" Removals worker "> Removals worker </option> <option value=" Reprographic assistant "> Reprographic assistant </option> <option value=" Research and development manager "> Research and development manager </option> <option value=" Research scientist "> Research scientist </option> <option value=" Residential support worker "> Residential support worker </option> <option value=" Resort representative "> Resort representative </option> <option value=" Restaurant manager "> Restaurant manager </option> <option value=" Retail buyer "> Retail buyer </option> <option value=" Retail jeweller "> Retail jeweller </option> <option value=" Retail manager "> Retail manager </option> <option value=" Retail merchandiser "> Retail merchandiser </option> <option value=" Riding holiday centre manager "> Riding holiday centre manager </option> <option value=" Riding holiday leader "> Riding holiday leader </option> <option value=" Road traffic accident investigator "> Road traffic accident investigator </option> <option value=" Road transport manager "> Road transport manager </option> <option value=" Road worker "> Road worker </option> <option value=" Roadie "> Roadie </option> <option value=" Robotics engineer "> Robotics engineer </option> <option value=" Roofer "> Roofer </option> <option value=" Roustabout "> Roustabout </option> <option value=" Royal Marines commando "> Royal Marine Hi, I cant connect to my Mysql database. I get this problem: Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'esolarch_databas'@'localhost' (using password: YES) in /home7/esolarch/public_html/new/storescripts/connect_to_mysql.php on line 21 could not connect to mysql Code: [Select] <?php /* 1: "die()" will exit the script and show an error statement if something goes wrong with the "connect" or "select" functions. 2: A "mysql_connect()" error usually means your username/password are wrong 3: A "mysql_select_db()" error usually means the database does not exist. */ // Place db host name. Sometimes "localhost" but // sometimes looks like this: >> ???mysql??.someserver.net $db_host = "localhost"; // Place the username for the MySQL database here $db_username = "esolarch_database"; // Place the password for the MySQL database here $db_pass = "Password"; // Place the name for the MySQL database here $db_name = "esolarch_admin2"; // Run the actual connection here mysql_connect("$db_host","$db_username","$db_pass") or die ("could not connect to mysql"); mysql_select_db("$db_name") or die ("no database"); ?> |