New To XAMPP

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

New To XAMPP

Postby Erogenous » 09. January 2014 17:54

Hi All,

Please be patient with me as I am new to XAMPP and have no idea what I am doing. :shock: :?

I have been in web design for quite some time and I am just expanding my knowledge of PHP. Now, I am redesigning an old website using PHP and my files are on my desktop and when I look at them in the browser parts of the website are missing like the section <?php require("footer2.php"); ?>

I know how it looks using html and I'm sure that once it's uploaded to the server it will all be visible. How do I check it with XAMPP? When I try to open the php doc in a browser I just get the html/php code.

Many thanks in advance.

:cry: :? :roll:
Erogenous
 
Posts: 5
Joined: 09. January 2014 17:25
Operating System: Windows 7

Re: New To XAMPP

Postby Altrea » 09. January 2014 18:19

Hi,

How exactly do you "open" the php file in your browser?

Best wishes,
Altrea
We don't provide any support via personal channels like PM, email, Skype, TeamViewer!

It's like porn for programmers 8)
User avatar
Altrea
AF Moderator
 
Posts: 11933
Joined: 17. August 2009 13:05
XAMPP version: several
Operating System: Windows 11 Pro x64

Re: New To XAMPP

Postby Erogenous » 10. January 2014 10:18

Hi,

I right click and choose Open In Chrome then I just see the code but no text or graphics as you would do with an HTML file. Just wondering how this XAMPP works. No idea. I have followed some instructions but nothing. This AXMPP is supposed to display your php files as if you had uploaded them to a server, easy they said!!

Thanks
Erogenous
 
Posts: 5
Joined: 09. January 2014 17:25
Operating System: Windows 7

Re: New To XAMPP

Postby Nobbie » 10. January 2014 10:42

We cannot explain this in a few words, you should go for tutorials and/or documentation, how a webserver is working, what "CGI" means, what PHP means and how it fits together. Xampp is a collection of software tools that enables your PC to run like a webserver.
Nobbie
 
Posts: 13176
Joined: 09. March 2008 13:04

Re: New To XAMPP

Postby Altrea » 10. January 2014 13:21

Erogenous wrote:I right click and choose Open In Chrome

You cannot open a file directly in your browser, it needs to be processed before that.
Your Browser doesn't have any idea that these type of files need to be send through an php interpreter first and your browser don't have to know that.
Your Browser have to request files, the same way as they are saved on any webhost server.

There is a special domain for sending http requests directly to your very own computer => localhost
so http://localhost/ would be a request of the root index page (which is an xampp page) of the local webserver.
We don't provide any support via personal channels like PM, email, Skype, TeamViewer!

It's like porn for programmers 8)
User avatar
Altrea
AF Moderator
 
Posts: 11933
Joined: 17. August 2009 13:05
XAMPP version: several
Operating System: Windows 11 Pro x64

Re: New To XAMPP

Postby Erogenous » 10. January 2014 14:15

Hi,

I am a little confused of where I have to have my website files and how to access them via XAMPP.
On my HD C:/ there is a folder xampp with a sub folder htdocs and other sub folders. Where do I copy my files to and how do I access the php files to replicate how it would look on a server?
A link to a tutorial would be great if anyone has/knows of one. I don't mind taking the time to read and learn. I've jumped in at the deep end and I am struggling to swim. Usually I figure these things out but not this time.

Thanks again in advance for your time, efforts and patience.

:)
Erogenous
 
Posts: 5
Joined: 09. January 2014 17:25
Operating System: Windows 7

Re: New To XAMPP

Postby Altrea » 10. January 2014 14:43

Erogenous wrote:Where do I copy my files to and how do I access the php files to replicate how it would look on a server?

Create a new project folder inside \xampp\htdocs\, eg \xampp\htdocs\projectxy\
A file \xampp\htdocs\projectxy\file.php can then be requested by URL http://localhost/projectxy/file.php

Erogenous wrote:A link to a tutorial would be great if anyone has/knows of one.

The problem is, that one tutorial is not enough.
To know where you have to place the files and how to access them, you need knowledge about how the Apache webserver is configured, how http works and how serverside programming language like php are working.
You cannot start everywhere at the same time.
We don't provide any support via personal channels like PM, email, Skype, TeamViewer!

It's like porn for programmers 8)
User avatar
Altrea
AF Moderator
 
Posts: 11933
Joined: 17. August 2009 13:05
XAMPP version: several
Operating System: Windows 11 Pro x64

Re: New To XAMPP

Postby Erogenous » 10. January 2014 15:03

Tried a few things but nothing working. Thanks for trying to help. The local host just returned results of Oops! Google Chrome could not connect to localhost.
Back to the drawing board :?
Erogenous
 
Posts: 5
Joined: 09. January 2014 17:25
Operating System: Windows 7

Re: New To XAMPP

Postby Altrea » 10. January 2014 15:08

Is XAMPP Apache started successful?
We don't provide any support via personal channels like PM, email, Skype, TeamViewer!

It's like porn for programmers 8)
User avatar
Altrea
AF Moderator
 
Posts: 11933
Joined: 17. August 2009 13:05
XAMPP version: several
Operating System: Windows 11 Pro x64

Re: New To XAMPP

Postby Erogenous » 10. January 2014 15:11

Ha Ha!!! Stupid me had not opened the XAMPP control panel. Now that it is open the test pages work! Sometime I can't see the wood for the trees. Duh!!

Thanks for your time, patience and help.

:) :) :)
Erogenous
 
Posts: 5
Joined: 09. January 2014 17:25
Operating System: Windows 7

Re: New To XAMPP

Postby Altrea » 10. January 2014 15:47

You are welcome.
Have fun with XAMPP and all that fancy stuff 8)
We don't provide any support via personal channels like PM, email, Skype, TeamViewer!

It's like porn for programmers 8)
User avatar
Altrea
AF Moderator
 
Posts: 11933
Joined: 17. August 2009 13:05
XAMPP version: several
Operating System: Windows 11 Pro x64


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 174 guests