Solved

xampp php

Posted on 2012-04-11
9
1,362 Views
Last Modified: 2012-04-12
I have successfully installed the latest xampp on a windows server 2008.
The localhost port is :888
Mysql is running on 3306

When I type in the url: http://localhost:888/xampp I get the correct orange administration screen and I can administer all the servers and files.

PHP info tells me that the port is Localhost:888
Mysql is on 3306

The problem is as follows:
If I create a website in the following directory:
c:\xampp/htdocs\sitename\sitename2\site\index.php

And access using:
http://localhost:888/sitename/sitename2/index.php

The page times out and gives an error telling me that it is waiting for the localhost

the connections.php file is as follows (the xxx values are correct in my file):
<?php
# FileName="Connection_php_mysql.htm"
# Type="MYSQL"
# HTTP="true"
$hostname_Onecallorders = "localhost:888";
$database_Onecallorders = "1callorders";
$username_Onecallorders = "xxx";
$password_Onecallorders = "xxx";
$Onecallorders = mysql_pconnect($hostname_Onecallorders, $username_Onecallorders, $password_Onecallorders) or trigger_error(mysql_error(),E_USER_ERROR);
?>

am I missing a configuration somewhere ?
0
Comment
Question by:doctorbill
  • 6
  • 3
9 Comments
 
LVL 3

Assisted Solution

by:gnemi
gnemi earned 500 total points
ID: 37832125
MySQL hostname would just be localhost.
0
 

Author Comment

by:doctorbill
ID: 37832210
where would this be ?
0
 

Author Comment

by:doctorbill
ID: 37832212
would it be in the my.ini file ?
0
VMware Disaster Recovery and Data Protection

In this expert guide, you’ll learn about the components of a Modern Data Center. You will use cases for the value-added capabilities of Veeam®, including combining backup and replication for VMware disaster recovery and using replication for data center migration.

 

Author Comment

by:doctorbill
ID: 37832220
This is what I get if I let the php page try to load:

Warning: mysql_pconnect() [function.mysql-pconnect]: MySQL server has gone away in C:\xampp\htdocs\OneCallOrders\Connections\Onecallorders.php on line 9

Warning: mysql_pconnect() [function.mysql-pconnect]: Error while reading greeting packet. PID=6120 in C:\xampp\htdocs\OneCallOrders\Connections\Onecallorders.php on line 9

Warning: mysql_pconnect() [function.mysql-pconnect]: MySQL server has gone away in C:\xampp\htdocs\OneCallOrders\Connections\Onecallorders.php on line 9

Fatal error: Maximum execution time of 30 seconds exceeded in C:\xampp\htdocs\OneCallOrders\Connections\Onecallorders.php on line 9
0
 
LVL 3

Assisted Solution

by:gnemi
gnemi earned 500 total points
ID: 37832259
$hostname_Onecallorders = "localhost:888";

should just be
$hostname_Onecallorders = "localhost";

apache is listening on 888 not mysql
0
 

Author Comment

by:doctorbill
ID: 37832685
I now get the following:

Fatal error: Access denied for user 'root'@'localhost' (using password: YES) in C:\xampp\htdocs\OneCallOrders\Connections\Onecallorders.php on line

The pw for root is correct. How can I set up a different UN / PW or check the existing one ?
0
 

Author Comment

by:doctorbill
ID: 37832714
Sorry - I have found the problem. The root UN does not have a password at the initial instal of xampp. The site is now working

Having said that,  could you still tell me how to:
1 add a password for root
2 set up a new UN and PW in mysql

Thanks,
0
 
LVL 3

Accepted Solution

by:
gnemi earned 500 total points
ID: 37835179
you can change the MySQL root password at http://localhost/security/

and you can add a MySQL user through phpmyadmin located at http://localhost/phpmyadmin
0
 

Author Closing Comment

by:doctorbill
ID: 37836721
Very accurate and speedy responses
0

Featured Post

Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

If you are a web developer, you would be aware of the <iframe> tag in HTML. The <iframe> stands for inline frame and is used to embed another document within the current HTML document. The embedded document could be even another website.
These days socially coordinated efforts have turned into a critical requirement for enterprises.
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question