Jump to content



Dreamweaver kai APACHE?


kagelar34

Recommended Posts

Παιδιά αν θυμάμαι καλά για να τρ΄ξεις μια βάση php mysql πρέπει να έχεις τον APAche στο background βάσζεις τα αρχεία της βάσης στο htdocs φάκελο του apache και τρέχεις τις φόρμες με τον ie

έχω to dreamweaver mx 2004 είναι απαραίτητο να έχω και τον apache για να φτιάξω την βάση ?Γίνεται να φτιάξω έναν server με το dreamweaver?Αν γίνεται ξέρετε πως ?

Link to comment
Share on other sites

Το Dreamweaver είναι απλά πρόγραμμα σχεδίασης ιστοσελίδων, δεν προσφέρει τίποτα παραπάνω. Χρειάζεσαι ή τον Apache ή τον IIS στημένο. Για την βάση χρειάζεσαι ή mysql ή κάτι αντίστοιχο.

Link to comment
Share on other sites

Τι εννοείς τα αρχεία της βάσης; Αυτά θα τα βρεις στο φάκελο της MySql αν χρησιμοποιείς αυτήν, αλλά χρειάζεσαι κάποιο front-end πρόγραμμα για την καλύτερη διαχείριση της.

Τα αρχεία του site μπαίνoυν στο φάκελο htdocs του Apache.

Aκολουθεί ένας μικρός οδηγός γραμμένος στο Vbulletin.org. All credits go to TECK.

PC PREPARATION

Create a folder called Network in your local disk C: with the following 2 sub-folders:

|--[C:

|----[Network

|------[MySQL

|------

[Php

PHP Binary INSTALLATION
01. Extract the contents of PHP .zip file to C:\Network\Php folder.

02. Copy the 'C:\Network\Php\php.ini-dist' file to your %SYSTEMROOT% directory (C:\WINDOWS for winXP; C:\WINNT for win2K).
In %SYSTEMROOT% folder, rename php.ini-dist to 'php.ini' and open it.

03. In php.ini, you will need to set the 'doc_root' to point to your web server(apache) document_root, like below:
; The root of the PHP pages, used only if nonempty.
; if PHP was not compiled with FORCE_REDIRECT, you SHOULD set doc_root
; if you are running php as a CGI under any web server (other than IIS)
; see documentation for security issues. The alternate is to use the
; cgi.force_redirect configuration below
doc_root = "c:\network\apache2\htdocs"

04. Still in php.ini, change the 'extension_dir' setting to point to your php-install-dir, like below:
; Directory in which the loadable extensions (modules) reside.
extension_dir = "c:\network\php"

05. Still in php.ini, change the 'mail function' setting to point to your ISP, like below:
[mail function]
; For Win32 only.
SMTP = smtp.myisp.com
; For Win32 only.
sendmail_from = johndoe@myisp.com

06. Save and close the php.ini file.

07. In C:\Network\Php folder, find php4ts.dll file. Move it to the %SYSTEMROOT%\system32 folder.

NOTE: Make sure you MOVE that file, DO NOT copy it only.

Apache Server INSTALLATION
01. Run the .msi file. Enter the value localhost for 'Network Domain' and 'Server Name'.

IMPORTANT: Make sure you select a custom setup and install Apache to C:\Network, not to 'C:\Program Files\Apache Group'. It will create automatically the 'Apache2' folder for you. There is no need to install the documentation, it is available online.

02. Go to your Apache conf file (C:\Network\Apache2\conf\httpd.conf) and find:
#LoadModule ssl_module modules/mod_ssl.so

BELOW this, add:
LoadModule php4_module c:/network/php/sapi/php4apache2.dll

03. Still in httpd.conf, find:
AddType application/x-tar .tgz

BELOW this, add:
AddType application/x-httpd-php .php

04. Still in httpd.conf, set the files that Apache will serve if a directory is requested. Find:
DirectoryIndex index.html index.html.var

REPLACE it with:
DirectoryIndex index.php index.html index.php.var index.html.var

05. Save and close the httpd.conf file.

06. Restart Apache Server.

MySQL Binary INSTALLATION
01. Extract the .zip binary to a temp folder. Run the Setup.exe file.

NOTE: Make sure you browse to C:\Network\MySQL folder, when you select the install location.

02. Go to C:\Network\MySQL\bin and run the 'winmysqladmin.exe' file. The WinMySQLadmin 1.3 database manager will start.
First, it will ask you to enter a new username and password. Enter the following information:
Username: root
Password: password

Click on OK.

03. Go to Go to C:\Network\MySQL\bin\data folder and create a new folder called vbulletin. That is your database.

04. Open a CMD window and change it's location to your current MySQL /bin folder.

05. Set your Users:
\bin> mysql --user=root mysql
mysql> GRANT ALL PRIVILEGES ON *.* TO monty@localhost
-> IDENTIFIED BY 'some_pass' WITH GRANT OPTION;
mysql> GRANT ALL PRIVILEGES ON *.* TO monty@'%'
-> IDENTIFIED BY 'some_pass' WITH GRANT OPTION;
mysql> GRANT RELOAD,PROCESS ON *.* TO admin@localhost;
mysql> GRANT USAGE ON *.* TO dummy@localhost;

NOTE: There is no need to do all GRANT 3 statements, the first one is more then enough. The other two were presented to you so you learn mode about the GRANT/REVOKE commands.

These GRANT statements set up three new users:
monty
A full superuser who can connect to the server from anywhere, but who must use a password 'some_pass' to do so.
Note that we must issue GRANT statements for both monty@localhost and monty@'%'.
If we don't add the entry with localhost, the anonymous user entry for localhost that is created by mysql_install_db will take precedence when we connect from the local host, because it has a more specific Host field value and thus comes earlier in the user table sort order.

admin
A user who can connect from localhost without a password and who is granted the RELOAD and PROCESS administrative privileges. This allows the user to execute the mysqladmin reload, mysqladmin refresh, and mysqladmin flush-* commands, as well as mysqladmin processlist . No database-related privileges are granted.
(They can be granted later by issuing additional GRANT statements.)

dummy
A user who can connect without a password, but only from the local host.
The global privileges are all set to 'N'—the USAGE privilege type allows you to create a user with no privileges. It is assumed that you will grant database-specific privileges later.

FINAL STEPS
Go to Start > Programs > Startup
Delete the 'Monitor Apache Servers' and 'MySQL Admin' tools. They waist your resources for nothing and are not needed. I personally moved the MySQL Admin tool to another folder, in case I want to create later another database.


Και για να δοκιμάσεις απλά αν δουλεύει η php σου και ο apache απλά φτιάξε ένα αρχείο info.php που να περιέχει μέσα
<?php phpinfo(); ?>

βάλτο στο htdocs και βρες το από τον browser σου.

Link to comment
Share on other sites

Βάλε η τον IIS που βρίσκεται στα cd των wndows η τον Apache. To DREAMWEAVER ΕΊΝΑΙ ΠΡΌΓΡΑΜΜΑ ΚΑΤΑΣΚΕΥΉς ΙΣΤΟΣΕΛΙΔΩΝ ΚΑΙ ΤΙΠΟΤΑ ΠΕΡΙΣΣΟΤΕΡΟ. ΕΠΙΣΗΣ ΜΠΟΡΕΙΣ ΝΑ ΓΡΑΨΕΙΣ ΕΥΚΟΛΑ ΚΩΔΙΚΑ JAVASCRIPT KAI PHP

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Δημιουργία...

Important Information

Ο ιστότοπος theLab.gr χρησιμοποιεί cookies για να διασφαλίσει την καλύτερη εμπειρία σας κατά την περιήγηση. Μπορείτε να προσαρμόσετε τις ρυθμίσεις των cookies σας , διαφορετικά θα υποθέσουμε ότι είστε εντάξει για να συνεχίσετε.