Gå til innhold

Alternativ til PHPTriad for Windows?


Anbefalte innlegg

Videoannonse
Annonse

Jeg ser ikke helt behovet for å bruke disse foxserv/phptriad pakkene. En stor ulempe er at de er skjeldent oppdatert, og det er ikke så enkelt som det høres ut som. Dvs, det er ikke så mye enklere enn det høres ut som.

 

Det tar bare 10 minutter ekstra å installere alt manuelt, og da får du de siste versjonene.

 

Under er en enkel guide. Mer at linkene/versjonnumre kan være litt utdaterte.

 

Manually installing Apache/PHP/mySQL

~~~~~~~~~~~~~~~~~~~~~~~~~

 

This is actually very easy, and it will be a lot easier to maintain/upgrade than a preconfigged package...

 

1. Download the following four files ...

Apache2 -> http://www.apache.org/dist/httpd/binaries/...-x86-no_ssl.msi

PHP -> http://www.php.net/get/php-4.3.2-Win32.zip...p/from/a/mirror

mySQL -> http://www.mysql.com/downloads/download.ph...ror.anlx.net%2F

phpMyAdmin -> http://prdownloads.sourceforge.net/phpmyad...e_mirror=switch

 

2. Install Apache2 to c:/Apache

 

3. Unzip mysql zip and install into c:/Apache/mysql

 

4. Unzip php and copy all files into c:/Apache/php

 

5. Copy the following files into windows/system32 ...

all files from php/sapi

all files from php/dlls

php/php4ts.dll

 

6. Copy php/php.ini-dist into windows directory and rename it to php.ini

 

7. Open php.ini in text editor and make the following changes ...

change extension_dir to "c:Apachephpextensions"

change display_startup_errors to On

change upload_tmp_dir to "c:apachephptmp" (dont forget to create this folder)

uncomment extension = php_gd2.dll

 

8. Save php.ini and close it

 

9. Open C:ApacheApache2confhttpd.conf in a text editor and make the following changes ...

Under the LoadModule entries, add ...

LoadModule php4_module "c:/Apache/php/sapi/php4apache2.dll"

AddType application/x-httpd-php .php

Change DirectoryIndex index.html index.html.var to DirectoryIndex index.html index.html.var index.php

 

10. Save httpd.conf and close it

 

11. Open the c:Apachemysqlbin folder and run winmysqladmin.exe, enter a username and password when prompted - WRITE THEM DOWN SOMEWHERE SAFE!

 

12. Start your Apache server.

 

Securing your htdocs folder

~~~~~~~~~~~~~~~~~~

 

If you want to keep your local server locked to outside users you can easily add a .htaccess that requires you to enter a username/password to gain access ...

 

1. Select Run from your start menu and type C:ApacheApache2binhtpasswd.exe -c .users yourname

 

2. Enter your password when prompted

 

3. This will create a file called .users inside your apache2/bin folder

 

4. Open your text editor and enter this text ...

AuthName "Restricted"

AuthType Basic

AuthUserFile "C:/Apache/Apache2/bin/.users"

<LIMIT GET POST>

require valid-user

</LIMIT>

 

5. Save the file as .htaccess in yout Apaches2/htdocs folder

 

6. Open Apache2/conf/httpd.conf in your text editor

 

7. Change the line AllowOverride None to AllowOverride AuthConfig

 

8. Save and exit

 

9. Restart Apache, when you go to your local server (http://localhost) you will have to enter the username and password you entered to gain access.

 

Installing phpMyAdmin

~~~~~~~~~~~~~~

 

1. Unzip the phpMyAdmin zip you downloaded earlier and copy it into your Apache2/htdocs folder

 

2. Open config.inc.php in a text editor

 

3. Enter the full path to your phpMyAdmin folder in the $cfg['PmaAbsoluteUri'] variable, ie, $cfg['PmaAbsoluteUri'] = 'http://localhost/phpMyAdmin-2.5.1';

 

4. Enter your mySQL username that you entered earlier in the $cfg['Servers'][$i]['user'] variable

 

5. Enter your mySQL password that you entered earlier in the $cfg['Servers'][$i]['password'] variable

 

6. Save the file and exit - phpMyAdmin is now ready to use and can be found athttp://localhost/<your_phpMyAdmin_folder>

Lenke til kommentar
GeeZuZz, jeg gikk igjennom alle punktente for å installere bare apache og php... men steike salte det vil jo ikke funke.

Når jeg åpner siden http://localhost/ vil den ikke finne serveren...  

 

Tror du at noen av de nye oppdateringen har en litt endringer i seg når det kommer til installasjon?

 

Prøv med IP'n til serveren isteden.

Lenke til kommentar

Opprett en konto eller logg inn for å kommentere

Du må være et medlem for å kunne skrive en kommentar

Opprett konto

Det er enkelt å melde seg inn for å starte en ny konto!

Start en konto

Logg inn

Har du allerede en konto? Logg inn her.

Logg inn nå
×
×
  • Opprett ny...