I got stuck with this problem
For a temporary solution, I changed the port to 5555 in apache httptd.conf
localhost
shows default index.html content
I integerated php with apache and then started apache by executing httpd.exe
localhost:5555/index.php
says url error How do i achieve this?
Related
Hello I have installed xampp/lampp on windows and am trying to open website in local host using:
http://localhost/htdocs/my-first-project/index.php
I have also tried
http://localhost/my-first-project/index.php
But it always shows following error:
Not Found The requested URL was not found on this server.
Apache/2.4.41 (Ubuntu) Server at localhost Port 80
But my local host page and phpmyAdmin is running without any problem
I also want to mention that I have set my Apache server port to 8080.
Thank you in advance
Have you already tried to place your index.php in the DocumentRoot Folder and access it from there?
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).
Am trying to use php I downloaded XAMPP control panel v3.2.2set the port to listen at 8080 and I set the localhost to 8080 too and apache starts and runs fine.
The problem is that for any php file that I try to open by writing at my browser:localhost/thefile'sname.php, even though I have saved it in C:\xampp\htdocs, I get the error:HTTP Error 404. The requested resource is not found. Any ideas as to what could be causing this error to occur and how to fix it?
If it can't find the document it's most definitely with your apache config and your document root or possibly a .htaccess file in the document root?
check or post your apache config and check for .htaccess file.
ah also localhost will only map to port 80, http://localhost:8080/yourfile.php
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.