I'm testing xampp setup, and when I enter localhost, the homepage doesn't display. The main port is 80, and SSL port is 443. I've tried removing the index and dashboard files, but that didn't work. PHP scripts are not running correctly.
You need to start the Apache.....
XAMPP has all logs in-built. Go to Apache > Logs > Apache (error.log) and do a quick search. In most of the cases you likely want to change the port Apache listens to.
Go to Apache > Config > Apache (httpd.conf) and find Listen 80. Replace it with any non-blocked port, i.e. Listen 8087. Save the file and start Apache again.
Related
I hosted a website using php-fpm and nginx on Termux and everytime I type the url localhost/sth and it redirects to localhost:8443/sth ,I don't want to see the port 8443, how to solve it?
Type url localhost/something and it redirects to localhost:8443/something
You should investigate your nginx.conf file, it probably has some misconfiguration:
Open the nginx configuration file located at /etc/nginx/nginx.conf
Locate the server block that contains the localhost:8443 server name, and change it to localhost
In the same server block, locate the listen directive and change the port number from 8443 to 80 (the default port for HTTP)
Save the changes and restart the nginx service using the command "service nginx restart"
Open your browser and try accessing the website using the localhost/sth URL. It should no longer redirect to localhost:8443/sth.
I created a virtual host on MAMP PRO 5 like this "mywebsite.test" but it does not open the local site unless I add :8888 so it has to be like this "mywebsite.test:8888" then I changed the Apache port to 80 and whenever I try to get them to local site using "mywebsite.test" is show me the default page of apache "it works!" instead.
I did uncomment this line
# Virtual hosts
#Include /private/etc/apache2/extra/httpd-vhosts.conf
in
/private/etc/apache2/httpd.conf
but still not working
any solution?
I just found the solution this could be helpful to anyone facing this same problem.
After contacting the support they told me to check indexes under Apache tab and it works
make sure the Apache port is at 80 and not 8888
I am trying to setup LEMP (Linux, Nginx, MySQL, PHP) stack on my PC to use with Wordpress.
I follow the instructions on this website. I see that the folder of wordpress in www folder was successfully extracted.
I can also verify that Nginx is running. However, I don't know how to get the wordpress index.php page on the browser.
On windows, I simply go to the browser and type localhost/webprojectfoldername or 127.0.0.1/webprojectfoldername
However, when I try to access the index.php of wordpress via localhost, I get the Apache page.
I would like to use Nginx as server but not Apache. I guess at this point, I don't know what servername or ipaddress to put on the browser to get to Nginx's page or Wordpress's index.php
I don't know how to identify the servername that was setup. On Windows, I simply use localhost or 127.0.0.1.
Any thoughts on how I identify it on Ubuntu?
I'd appreciate any help.
Thank you.
*** EDIT (Added Screenshot of Nginx configuration) ****
Either:
nginx is listening on a different port
By default, HTTP works over port 80, but when you connect to that port you are reaching Apache.
You need to find the port nginx is listening on (from the article you link to: listen 80 default_server; shows 80 but lets say it was 81) and connect to that instead: http://localhost:81/`
nginx and apache are trying to listen on the same port and apache won
You need to turn off Apache (and possibly restart nginx).
When XAMPP starts, I am getting the error below. I have already tried all sorts of port settings (listen:xx, servername:xxx settings in httpd.conf, httpd-ssl.conf) provided in this SO question.
Error: Apache shutdown unexpectedly.This may be due to a blocked port, missing dependencies,
improper privileges, a crash, or a shutdown by
another method. Press the Logs button to view
error logs and check the Windows Event Viewer for
more clues
If you need more help, copy and post
this entire log window on the forums
All of the threads with similar questions were revolving around one answer -
"system port". I have already tried this and it didn't solve my issue.
Open XAMPP Control Panel and select Config under Apache. Select your httpd.conf and locate the following line.
# Listen: Allows you to bind Apache to specific IP addresses and/or
# ports, instead of the default. See also the <VirtualHost>
# directive.
#
# Change this to Listen on specific IP addresses as shown below to
# prevent Apache from glomming onto all bound IP addresses.
#
#Listen 12.34.56.78:80
Listen **xx**
Where you see xx change this to something like 8080 if it currently states 81. Port 81 is commonly used by a few applications, so I tend to always change to 8080 by default, but your network may be different. You may obviously use netstat to see what ports may be available to you.
Restart XAMPP entirely as Apache is very fussy, then try starting Apache again.
Should changing ports not help, you can also try uninstalling and reinstalling the Apache service from the control panel through the following steps;
Start Xampp Control Panel
Uninstall Apache by clicking on Apache Module
Uninstall Mysql by clicking on Mysql Module
Again install both module by clicking on Xampp Control Panel.
Should both fail, there is an interesting guide here as well in case of duplicate services.
I used to work on localhost before and never had such issue, the issue was with Apache that was not starting so I went to my http.conf file and changed the port 80 to 8080 and from then I have to put the url present in the image. I just want to use the "localhost/projectname" which is not running at the moment.