I have installed XAMPP in a virtual machine with VirtualBox. I run both Apache and MySql and there aren't any errors.
I can access phpmyadmin from this virtual machine but if I try to run it on the real machine, I can't get it.
I tried to put http://IP of the virtual machine/phpmyadmin but it doesn't work.
If I put only http://IP of the virtual machine I can see a webpage in which it says "It works".
If I try to use http://localhost in the virtual machine I can see a page in which I see "XAMPP" and where I can choose the language in which I want to use it.
I want to use phpmyadmin from real machine.
The screen you get is the real (splash) screen choose your language from there you will be routed to make the basic setup options, then you will see the phpmyadmin link under the subheading "Tools", select it and see what the link is for you
Create a host only network in virtualbox. Configure the network in your guest machine. Then using IP of guest in the host only network
try http://IP/phpmyadmin . It will work if you have installed it correctly.
as you are working on Windows you might have to configure your host file and allocate a different ip for your vm then add a new alias(or change your alias) in your http-xampp.conf
Finally, I realized that I had installed Apache 2.4 in my real machine so the main page that I saw before and could see this: "It works" was from this Apache.
I solved it uninstalling Apache, and now it works perfectly.
Thanks all of you for your answers!
Related
After enabling the auto virtual host I wanted to try pretty url for my current project. Problem is it first showed index of/ of the project and after trying some solutions it now shows "This site cannot be reached!" error. The pretty url feature wotks withother projects.
What I tried:
.restarting laragon and pc
.enabeling nginx
.renaming the project
.clearing something in my apache server
Any suggestion?
Thank you in advance!
what i do is :
a. open laragon > menu > apache > sites-enabled > Delete all [auto]
b. if you are using ur own computer, please set Open as administrator to Laragon
c. make sure auto virtual host is checked on laragon
d. last, check your host file, don't forget to un-check 'Read-Only' options
For me, I need to remove the 'Read-Only' option of hosts file in C:\Windows\System32\drivers\etc. I'm using Windows, obviously.
when i write localhost or even 127.0.0.1 on my web navigator to go to my apache, i got this website, instead of the usual debian localhost page, why? then minutes ago i could go to the default debian apache page, like that:
![click here to see the image][1]
but now, when i write localhost or 127.0.0.1 i got this page, why?
![localhost/127.0.0.1 page i got, click here to see][2]
Best guess is Wifi Lock is listening on port 80. you should try changing the Apache port to 81 or something.
It kept showing this wifilock.com page for me also. I went to " /etc/apache2/sites-available/ " and just removed all files except for " 000-default.conf ". Now it works perfectly.
I'm running a Kali Linux VM, and just typing in it's IP address into the browser from a seperate Ubuntu VM, so it should be the exact same things for Debian.
I'm pretty new to Linux, after trying countless things I've come across online this notion of mine finally worked, but hopefully hasn't messed anything up XD
So I want to use Xampp to control my servers. I already installed Apache2 and now it orverrides localhost.
Whenever i put localhost/xampp/index.php it says OBJECT NOT FOUND.
How would I delete this Apache program, and strictly use Xampp on localhost?
I already tried to change the .conf file to Listen 8000 and when to http://localhost:8000/xampp/index.php
Steps:
Open "XAMPP controll panel and run Apache and MySQL"
create folder www inside xampp\htdocs, if you are on win propably C:\xampp\htdocs, so now you have C:\xampp\htdocs\www\
Create test.php inside C:\xampp\htdocs\www\, now you have C:\xampp\htdocs\www\test.php
Put inside test this: <?php echo 'php works fine.'; ?>
Run this script in browser on link "http://localhost/www/test.php" you will see "php works fine.".
DONE.
Have you started apache by opening up Xampp control panel? If you didn't then it won't work. So open up Xampp control panel from the start menu and click on start where it says apache and then run http://localhost to see whether it works.
Have a look at the :
\xampp\apache\logs\error.log
This might give you an idea, why the XAMPP splash screen cannot be found.
Also, make sure you do not have any IIS or similar programs running, as they might have a conflict with the XAMPP.
You can also check if the port is open or not using the instructions given here..
Cheers.
I might be wrong, but it seems to me that everything on localhost is coming from htdocs, but you don't call it from htdocs in the URL.
I have installed Apache2.2 on my computer, PHP 5, and MySQL. Everything was working fine until last night. Suddenly, I could no longer connect to the localhost. I think my computer was infected with a trojan, but that has since been removed and I am unable to reconnect to my localhost.
I have updated my hosts file Windows(C:)/Windows/System32/drivers/etc hosts in notepad: see attachment.
I have tested my connection in the CMD prompt see attachment.
You'll notice [::]1, but after updating my host file, it now displays as 127.0.0.1
Additionally, port 80 IS LISTENING
instead of my web browser loading the page as localhost/vote/home.php NOW it loads as file:///C:/Websites/Vote/home.php AND NOW my PHP no longer works i.e. not being pulled into my web page.
...can't establish a connection to the server at localhost.
Why is my local host not working? Thoughts? Thank you in advance.
Additionally, my web browser page does not time out when requesting localhost....
(I'm a new user so I am unable to post images)?
× 257296
if you put localhost/vote/home.php into your browser's address bar you should get an unabled to connect error,
not a redirect to a file. The only time the address bar will show file:///C:/Websites/Vote/home.php is if you open
that file directly in your browser.
Your details about why apache isnt working are not to clear, but you can try a couple of things.
First, how did you install apache, is it a service? you can check this by going to control panel > Administrative Tools > Services and
see if apache is in that list. If its, you have to start it, if its not then apache is not installed as a service and
you need to start it by running the executable. Go to the whichever directory your httpd executable is and run it.
Some things to try:
Make sure Apache is actually running, that it haven't failed during startup.
Check if it's listening to the expected port (80, or whatever you have configured it to)
> netstat -nb
Check your hosts file to make sure nothing fishy is going on there. localhost should point to 127.0.0.1, but maybe it's been set to point somewhere else by your virus thing.
If you can't figure it out, you can always try to remove/uninstall and try to set it up again. If this is a developer machine, I can recommend using the WAMP package installer instead of setting it all up yourself. It provides fairly easy switching between php/apache/mysql versions and easy switching on and off of most regular apache and php modules.
run command prompt as administrator and go to Apache bin folder (usually 'cd \apache\bin' ) and type httpd -k start. it worked for me with the same issue.
I had the exact issue. If you have a XAMPP control panel pull it up. There you will see XAMPP Control Panel Image the different modules that you have open... Apache will be one of them. In the 'Actions' column you will have 'Stop' adjacent to it. Hit the 'Stop' and wait about 1 minute for everything to calm down. The button will change to 'start' so hit it. This will reset Apache. It worked for me...Good Luck.
If you don't have the control panel on your desktop, go into your programs list and drop-down the XAMPP icon. The control panel is right there. Just click it and it will show
I am currently using Windows XP SP3 with Apache 2.2, PHP 5.3, MySQL 5.1 and XAMPP 1.7.3 installed.
However after installing everything including XAMPP, I could not see the "XAMPP Welcome Page" at all! I only see the Apache default Page "It Works!!" on http://localhost/ . I also tried http://127.0.0.1/ but it gives back the same Apache results. My Apache and MySQL service seems to be running fine on the XAMPP console.
I have also placed a php file under C:\program files\apache\htdocs\test.php and access the page via http://localhost/test.php which works fine! I really can't guess why isn't the XAMPP installed over the Apache.
Can anyone please give some advice on the problem? Thanks.
XAMPP is a standalone AMP solution, so you don't need to install Apache or anything else with it. And if you do, both servers will probably conflict.
You need to either uninstall XAMPP, or uninstall Apache, PHP, and MySQL.
Note that XAMPP needs to be started up through its control panel, accessible from whatever start menu folder it will have created.
EDIT: Also, XAMPP has its own htdocs folder, located in C:\xampp\htdocs
Alternatively you can switch the port of the Apache server that came with your XAMPP installation via httpd.conf. and as it is described here for example:
Just remember to address the corresponding pages via http://localhost:XXXX
XXXX being the new portnummer you picked (for example 8080).
check the port from xampp control panel >config > Apache httpd.conf
then