Newbee - Error on Mysql_connect

Problems with the Windows version of XAMPP, questions, comments, and anything related.

Newbee - Error on Mysql_connect

Postby Jaykappy » 05. July 2013 03:16

I have this website running on my computer at work....everything works fine...
I just installed XAMPP and activated the Apache and MySQL db
I set a password for MySQL and gave it a password...this is the same password that I am using to connect to mySQL
I imported the tables needed for the web site I am testing with.

The index page calls this init.php page

* I am getting these errors: WHY IS my machine actively refusing it? how do I fix this? Is this a setting in XAMPP?
* I am NOT getting to the echos I am testing for in the 2nd connection attempt

ERRORS:
Warning: mysql_connect(): No connection could be made because the target machine actively refused it. in C:\xampp\htdocs\VisualUpload\init.php on line 8

Warning: mysql_connect(): No connection could be made because the target machine actively refused it. in C:\xampp\htdocs\VisualUpload\init.php on line 13
Please try later.


CODE:

<?php

// Start headers and sessions
ob_start();
session_start();

// MySQL Connection
mysql_connect("127.0.0.1:3600", "Jason", "Passw0rd");
mysql_select_db("visualupload");


$mysqlConnection = mysql_connect("127.0.0.1:3600", "Jason", "Passw0rd");
if (!$mysqlConnection)
{
echo "Please try later.";
}
else
{
echo "connected";
}

// Include func files
include("func/album.func.php");
include("func/image.func.php");
include("func/user.func.php");
include("func/thumb.func.php");

?>
Jaykappy
 
Posts: 14
Joined: 28. May 2013 19:50
Operating System: Win 8

Re: Newbee - Error on Mysql_connect

Postby JJ_Tagy » 05. July 2013 03:31

Did you change your listen port from 3306 to 3600?
JJ_Tagy
 
Posts: 678
Joined: 30. January 2012 13:44
Operating System: Windows 10 Pro x64

Re: Newbee - Error on Mysql_connect

Postby Jaykappy » 05. July 2013 03:43

Bang...thats weird....dont know why that changed....maybe my mqsql port is 3600 on my computer at work...
either way its all fixed....THANKS.....cheers
Jaykappy
 
Posts: 14
Joined: 28. May 2013 19:50
Operating System: Win 8


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 29 guests