Forum Moderators: coopster

Message Too Old, No Replies

how to install mysql?

         

rekhad

1:58 am on Feb 20, 2006 (gmt 0)

10+ Year Member



I have downloaded Apache server and php.I want to know how to install mysql.I believe mysql gets downloaded with php,but I am not able to insatll it?
Please help...

I also want to konw how insert into table works in php with MS Access as database.I have a form which as a link to database through a second php scrpit.I tried to inert a row into my table,but am not successful.the code is

Form.php

<?php
echo "
<HTML><HEAD>
<TITLE>Processing Form</TITLE>
</HEAD>
<BODY BGCOLOR=\"#D5D5AB\">
</body></html>";
echo "
<FORM NAME = \"AccessInterface\" METHOD=post ACTION=\"Data2.php\">
Please enter the details you wish to be inserted
into the Access Database data2.<br>
First Name:<input name=\"FirstName\" TYPE=\"text\" SIZE=\"25\"><br>

<INPUT type=\"Submit\" name=\"Sumbit\">
</form>
";
?>

The form acts on Data2.php which is

<?php
echo"<HTML>
<HEAD>
<TITLE>Processing Form</TITLE>
</HEAD>
<BODY>
</body>
</html>";
$cnx = odbc_connect( 'Test' , '', '' );
echo"connected";

if (!$cnx) {
Error_handler( "Error in odbc_connectnn", $cnx );
}
$SQL_Exec_String = "Insert Into People1 Values ('$FirstName')" ;
$cur= odbc_exec( $cnx, $SQL_Exec_String );

echo "Thank you! Information entered.\n";

if (!$cur) {
Error_handler( "Error in odbc_exec( no cursor returned mm) " , $cnx );
odbc_close( $cnx);
}
?>

I get the Warning message that FirstName variable is undefined and error as people1.FirstName can not be a zero length string.
Please help...I am stuck

DrDoc

2:11 am on Feb 20, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Welcome to WebmasterWorld! [WebmasterWorld.com]

Which OS are you trying to install it on? And, if a linux/unix system, are you looking for RPM or step by step instructions?

Regardless, all the installation information can be found on [mysql.com...]

rekhad

2:36 am on Feb 20, 2006 (gmt 0)

10+ Year Member



I am new to server side scripting.So dont know what is RPM?
I have a WindowsXP machine and I have Apache server installed.

DrDoc

2:50 am on Feb 20, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Then ignore the RPM thing. It applies to linux installations :)

Just download the MySQL installation files (along with instructions) from the MySQL website.
[dev.mysql.com...]

rekhad

3:06 am on Feb 20, 2006 (gmt 0)

10+ Year Member



I have insatlled Mysql with instructions.Trying to run the following code again.

<html>

<body>

<?php

if ($submit) {

// process form

$db = mysql_connect("localhost", "root");

mysql_select_db("Test",$db);

$sql = "INSERT INTO People1 (FirstName) VALUES ('$FirstName')";

$result = mysql_query($sql);

echo "Thank you! Information entered.\n";

} else{

// display form

?>

<form method="post" action="<?php echo $_SERVER['PHP_SELF']?>">

First name:<input type="Text" name="FirstName">

<input type="Submit" name="submit" value="Enter information">

</form>
<?php

but getting the following error...please help

Forbidden
You don't have permission to access /<br /><b>Notice</b>: Undefined variable: PHP_SELF in <b>c:/program files/easyphp1-8/www/test.php</b> on line <b>37</b><br /> on this server.

--------------------------------------------------------------------------------

Apache/1.3.33 Server at 127.0.0.1 Port 80

rekhad

3:15 am on Feb 20, 2006 (gmt 0)

10+ Year Member



I think I need to do more to run the server.what I did was gave an id and passsword.
Do I need to run some script to get it going..

rekhad

4:02 am on Feb 20, 2006 (gmt 0)

10+ Year Member



i am still stuck How to know whether MYSql is running?

DrDoc

4:09 am on Feb 20, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



It will show up in your task manager's process list

Anyango

10:16 am on Feb 20, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



that 403 forbidden message on a new installation usually comes due to directory permissions problem. check if you have valid directory and file permissions set.

rekhad

12:18 pm on Feb 20, 2006 (gmt 0)

10+ Year Member



when I run easyphp for apache server,MySQL is stopped.It gives error message.
I get the error
MySQL port(3306) is used by mysql-nt.exe
Apache is running o.k.

I have MySQL loaded independently from [mysql.net...]
I dont know which MySQL is needed?
The directory is
C:\Program Files\EasyPHP1-8\MySQL
Size of MySQL is 85.4MB
I also have
C:\Program Files\EasyPHP1-8\www\MySQL
size of MySQL is 57.5MB

omoutop

1:34 pm on Feb 20, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



not a master in setting mysql server, but I usually follow the installation instructions that come along in mysql documentation and I have no problems (then again i dont use apache at all when i am at home :) mysql, php under winxp :) .... no comments here people, please)!

rekhad

7:20 pm on Feb 20, 2006 (gmt 0)

10+ Year Member



I have removed MySQL and easyphp-1.8 from my PC.
Can I load php apache and MySQL all from one package?

From http:/www.mysql.com what do I need-
source downloads or MySQL 4.1 downloads.

I am asking these simple questions again
1. How to configure /run MySQL?
2.Do I need to set up TCP/IP also? if yes how?
3.I get mysql when i download easyphp together with Apache.Is this mysql same as what we get from the website www.mysql.com

rekhad

10:29 pm on Feb 20, 2006 (gmt 0)

10+ Year Member



I installed MySQL from www.mysql.com
At the C prompt when I type
C:\Program Files\MySQL\MySQL Server 5.0\bin\mysqlshow
I get the error message
'C:\Progarm' is not a recognized as an external or internal command operable program or batch file.
what does it mean?
need help ..