Go Back   PCMech Forums > Help & Discussion > Web Design / Development

Need Some Help? Type Your Keywords Here:

Reply
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
Old 08-12-2004, 02:02 PM   #1
Member (10 bit)
 
Designer's Avatar
 
Join Date: Mar 2004
Location: Essex, UK
Posts: 982
Send a message via AIM to Designer Send a message via MSN to Designer
Question Is there a way to test a PHP web page

Hi there,

Is is possible to test a PHP website on my local machine or from another machine on my home network without uploading it to a server. I'm learning about PHP and i'm having a go at making a site but I want to test it out before I commit to paying for web space. The same question for ASP as i've started playing around with that too.

Don't know if it's relevant but i'm using dreamweaver to build the pages

Also, i'm gonna be using PHPBB software from www.PHPBB.com and was wondering can I also test this on a local machine?

Thanks for any help you can provide
__________________
Intel Core i7 920 2.66GHz | Asus P6T SE| 6GB Corsair ram | XFX Radeon HD 4780 | 2 x 250 Gb Maxtor SATA II (in RAID 0), 1 x 250GB SATA II | Creative XFI soundcard | Coolermaster 650W PSU | ThermalTake Tsunami case

My new website -Carp Fishing Forums

Last edited by Designer; 08-12-2004 at 02:04 PM.
Designer is offline   Reply With Quote
Old 08-12-2004, 02:04 PM   #2
Professional gadfly
 
doctorgonzo's Avatar
 
Join Date: Jan 2002
Location: Minneapolis, MN
Posts: 6,364
Send a message via MSN to doctorgonzo
Do you have web server software installed on your local machine?
doctorgonzo is offline   Reply With Quote
Old 08-12-2004, 02:07 PM   #3
Member (10 bit)
 
Designer's Avatar
 
Join Date: Mar 2004
Location: Essex, UK
Posts: 982
Send a message via AIM to Designer Send a message via MSN to Designer
No, because I wasn't sure exactly what to do, can it be downloaded? and how would I need to set up?

I just really want to see if I got it right because I currently can't preview pages
Designer is offline   Reply With Quote
Old 08-12-2004, 02:08 PM   #4
PCMech: Saving Lives
 
Join Date: Apr 2004
Location: England, the United Kingdom
Posts: 1,839
If you are running XP Pro, you can get IIS (Internet Information Server) off the CD, and this can be set up to run over a network, then all you have to do is save your pages into the folder, if you are running XP Home (like me), I don't know what can be done locally, and am interested if there is something that will do it.

I think you can do the same with Apache, but I don't know about PHP.

Edit: If this is not possible, I might be able to upload some of your ASP pages onto my server, so you can preview them (please be nice with my bandwidth, if you do, PM if you are interested.)
__________________
WhatsThisBoxFor? is offline   Reply With Quote
Old 08-12-2004, 02:11 PM   #5
Member (10 bit)
 
Designer's Avatar
 
Join Date: Mar 2004
Location: Essex, UK
Posts: 982
Send a message via AIM to Designer Send a message via MSN to Designer
Would that be on the OEM XP pro CD?

All i've got for the laptop i'm using is recovery CD's but i've installed the OEM on the machine in my sig. Would I find that on add/remove windows comonents?
Designer is offline   Reply With Quote
Old 08-12-2004, 02:15 PM   #6
PCMech: Saving Lives
 
Join Date: Apr 2004
Location: England, the United Kingdom
Posts: 1,839
Look on the CD, I think (but am not sure at all) that you can get IIS to do PHP as well. You could find PWS of 98 on the install cd, so I am assuming thats where it is.
WhatsThisBoxFor? is offline   Reply With Quote
Old 08-12-2004, 08:57 PM   #7
Member (9 bit)
 
Join Date: Oct 2003
Location: Minnesota, USA
Posts: 382
Send a message via AIM to MrAustin
Either that or download PHPTriad from Sourceforge.com, which includes apache server, mysql and PHP 4.1 (link).

Then install, go to start -> phptriad -> apache -> start

To access documents locally, navigate to default C:\apache\htdocs\

That is where you store the .php files. To access them through the browser, just point to http://localhost/filename.php.

Hope that helps. IIS works as well, though PHP seems to function better through apache in my experience.
MrAustin is offline   Reply With Quote
Old 08-14-2004, 07:33 PM   #8
Member (10 bit)
 
Designer's Avatar
 
Join Date: Mar 2004
Location: Essex, UK
Posts: 982
Send a message via AIM to Designer Send a message via MSN to Designer
Thanks for the link MrAustin, just downloaded PHPTriad and the update, will install it tomorrow and post back shortly. Thanks everyone for your help so far, much appreciated.
Designer is offline   Reply With Quote
Old 08-15-2004, 08:10 AM   #9
Member (10 bit)
 
Designer's Avatar
 
Join Date: Mar 2004
Location: Essex, UK
Posts: 982
Send a message via AIM to Designer Send a message via MSN to Designer
Got PHPTriad working and I can now vew PHP pages on my PC OK (for which i'm very greatful - thankyou) Now i'm having trouble getting PHPbb to work on my local machine.

I've made a folder called 'forum' in the htdocs folder and copied the entire contents of the PHPbb folder there (think that's what i'm supposed to do), now when I try to open install.php in IE6 it decides to open in Dreamweaver instead. It's really getting frustrating now as I really want to see how this bb will work for me as it will be the basis of my site.

I've attached the PHPbb installation instructions (sorry about the formatting it was an HTML that I had to convert to txt to get it to upload properly), now I'm pretty sure it should be possible to run it on my local machine but im not 100% sure so any further help is much appreciated.
Attached Files
File Type: txt phpBB 2_0_10 Install.txt (28.4 KB, 145 views)
Designer is offline   Reply With Quote
Old 08-15-2004, 03:23 PM   #10
Member (9 bit)
 
Join Date: Oct 2003
Location: Minnesota, USA
Posts: 382
Send a message via AIM to MrAustin
I'll try to install it right now and get back to you with my results.
MrAustin is offline   Reply With Quote
Old 08-15-2004, 03:43 PM   #11
Member (9 bit)
 
Join Date: Oct 2003
Location: Minnesota, USA
Posts: 382
Send a message via AIM to MrAustin
OKay, just got it setup, here is a semi-detailed instruction on how it works here.

1. Go to Start Menu -> Programs -> PHPTriad -> MySQL - MySQL-D.exe
Run this program, it will pop open the DOS window, do its thing, then go away. Boom, your MySQL server is now running.

2. Go to Start Menu -> Run... and type in CMD.EXE -- hit enter.

3. Navigate to C:\apache\mysql\bin and then type mysql.exe to enter the msyql> prompt.

4. In this step, ###### represents your username and $$$$$$$ represents your password. Do the following at the MySQL prompt, remembering that you MUST end it with a semicolon and use only single quotations:

HTML Code:
GRANT ALL ON *.* TO '######'@'localhost' IDENTIFIED BY '$$$$$$$';
Hit enter and now you have a new user on your mysql database that has access to ALL databases.

5. Here is where you will setup the forum database on your site. Open up your web browser and point to http://localhost/phpmyadmin <-- this is the database frontend management system that PHPTriad installs, and most hosts use.

6. Near the middle, where it says Create Table, enter forum and hit enter. You now have a database table for the forum and can proceed with installation.

7. Navigate to http://localhost/forum/install/install.php to get to the installer.

8. Then all you have to do is enter the relevant information to setup phpBB. When it asks for table, just enter forum. Username and password are the database ones you setup in step 4.

I hope I didn't forget anything.

Good luck.
MrAustin is offline   Reply With Quote
Old 08-15-2004, 08:34 PM   #12
Member (10 bit)
 
Designer's Avatar
 
Join Date: Mar 2004
Location: Essex, UK
Posts: 982
Send a message via AIM to Designer Send a message via MSN to Designer
I had it working earlier, now after rebooting i can't seem to get it again

OK, I thought so I deleted the c:\apache folder and re-followed your instructions, now i've got as far as trying to open myphpadmin and im getting a "connection was refused" message, i'm currently using Mozilla Firefox, it gives the same message when trying to open any .php file in that folder

I know it's something i've done wrong but hav'nt a clue what, any ideas?

Last edited by Designer; 08-15-2004 at 08:37 PM.
Designer is offline   Reply With Quote
Old 08-15-2004, 08:38 PM   #13
Member (9 bit)
 
Join Date: Oct 2003
Location: Minnesota, USA
Posts: 382
Send a message via AIM to MrAustin
Browser shouldn't be the issue. Try restarting apache and mysql, then try again and report back

Edit: Can you open standard HTML pages such as http://localhost/index.html ?
MrAustin is offline   Reply With Quote
Old 08-15-2004, 09:04 PM   #14
Member (10 bit)
 
Designer's Avatar
 
Join Date: Mar 2004
Location: Essex, UK
Posts: 982
Send a message via AIM to Designer Send a message via MSN to Designer
From now on please call me Muppet. Forgot to start Apache and that's why it didn't work

Thanks MrAustin for you spot-on advice, I followed your instructions word-for-word and it's working perfectly, shut-down and re-started a few times (as that's what stuffed it up first time round) and it's all working sweet.


Thanks again for your help, it's greatly appreciated

D
Designer is offline   Reply With Quote
Old 08-15-2004, 09:32 PM   #15
Member (9 bit)
 
Join Date: Oct 2003
Location: Minnesota, USA
Posts: 382
Send a message via AIM to MrAustin
Glad I could help, good luck when you launch the site, make sure to send me a link
MrAustin is offline   Reply With Quote
Old 08-15-2004, 10:46 PM   #16
Member (10 bit)
 
Designer's Avatar
 
Join Date: Mar 2004
Location: Essex, UK
Posts: 982
Send a message via AIM to Designer Send a message via MSN to Designer
Will do,

I just looked at how much space the forum alone (with around 14 boards on it) consumes about 42MB! (that's without my site), so now i'm gonna have to make about 100 test posts with a few attachements and stuff to work out how much space i'm gonna need and do a bit of maths.
Designer is offline   Reply With Quote
Old 08-16-2004, 07:27 AM   #17
Staff
Premium Member
 
mairving's Avatar
 
Join Date: Jul 1999
Location: Arlington, TN
Posts: 5,538
Quote:
Originally Posted by Designer
Will do,

I just looked at how much space the forum alone (with around 14 boards on it) consumes about 42MB! (that's without my site), so now i'm gonna have to make about 100 test posts with a few attachements and stuff to work out how much space i'm gonna need and do a bit of maths.
There is no way that it is 42Mb. The download for PHPBB is only 500-600Kb compressed. Uncompressed you may have 1.5-2MB but not much more. I think that you are counting some of the other stuff that you installed.
__________________

Want to Make $$$$ with your Computer? No Risk! Simply press shift-4 four times in a row
mairving is offline   Reply With Quote
Old 08-17-2004, 02:56 AM   #18
Member (10 bit)
 
Designer's Avatar
 
Join Date: Mar 2004
Location: Essex, UK
Posts: 982
Send a message via AIM to Designer Send a message via MSN to Designer
That's quite possible I suppose, I was going by the size of the \apache folder which has phpbb and phpmyadmin in it. I'm assumin that would all have to be uploaded, correct?
Designer is offline   Reply With Quote
Old 08-17-2004, 04:17 PM   #19
Member (10 bit)
 
Designer's Avatar
 
Join Date: Mar 2004
Location: Essex, UK
Posts: 982
Send a message via AIM to Designer Send a message via MSN to Designer
Is it possible to display some stats on the homepage of my site which is also going to be a PHP site? I wanted to display how many users are currently online, the total number of members, the number of threads and posts. I've found this list of variables used in PHPBB2 for various things

http://www.phpbb.com/styles/listvars.php

Don't know if this has any relevance but thought it might so I put a link in to it

Thanks
Designer is offline   Reply With Quote
Old 08-17-2004, 10:10 PM   #20
Member (9 bit)
 
Join Date: Oct 2003
Location: Minnesota, USA
Posts: 382
Send a message via AIM to MrAustin
Post #18: phpbb, yes. phpmyadmin, no. It all depends on what frontend your host when you get one uses. The most common is phpmyadmin (at least on PHP enabled servers, duh), in which case it is already on the server.

Post #19: Working on it. It would appear that while those variables are global, they are only so within the forum working directory. In other words, to display that info on your home page would require manual access to each of the relevant tables for which you would like to extract said data. :takes a breath: Phew.
MrAustin is offline   Reply With Quote
Old 08-18-2004, 04:45 AM   #21
Member (10 bit)
 
Designer's Avatar
 
Join Date: Mar 2004
Location: Essex, UK
Posts: 982
Send a message via AIM to Designer Send a message via MSN to Designer
Thanks MrAustin
Designer is offline   Reply With Quote
Old 09-19-2004, 06:16 AM   #22
Member (10 bit)
 
Designer's Avatar
 
Join Date: Mar 2004
Location: Essex, UK
Posts: 982
Send a message via AIM to Designer Send a message via MSN to Designer
I gave up on the website design and decided to go for mx-portal and phpbb2, despite many installation problems (phpbb was OK) but mx-portal had problems as my host did'nt give access to the session_save path so it would'nt instlla properly, so he had a go and corrected the problem, it's now all working and can be viewed at the address shown in my signature. I got an excellent deal on hosting from www.ezboxx.com they gave me 1GB space and 10GB/month bandwidth for £100/year, a friend of mine has had a site with them for quite a while and got in touch with the host for me.

Thanks for all your help MrAustin

Last edited by Designer; 09-19-2004 at 06:23 AM.
Designer is offline   Reply With Quote
Reply

Bookmarks

Still Need Help? Type Your Keywords Here:


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT -5. The time now is 06:51 AM.
Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2012, vBulletin Solutions, Inc.
SEO by vBSEO 3.6.0 PL2