1.2 PHP5的Zip包下載(別下安裝版本,用模塊模式比CGI模式效率好),如:php-5.2.4-Win32.zip
複製E:/php下需要的dll到系統盤的system32下(這個根據不同系統而定,有的是system文件夾等等),這裏我只複製了php5ts.dll和libmysql.dll
修改httpd.conf
網上普遍用這個方法:在模塊段(#LoadModulessl_module modules/mod_ssl.so後)添加下面兩句:
- ###------------------------------------------###
- LoadModule php5_module "E:/php/php5apache2_2.dll" #指定模塊
- AddType application/x-httpd-php .php #這個只是指定MIME
- ###------------------------------------------###
注意:要將代碼後面的中文去掉
將DirectoryIndex設置爲:
DirectoryIndex index.php index.htm index.html
這樣重啓Apache,寫個文件(hello_world.php)
echo("hello,world");
?>
一切就緒,點擊Install開始安裝。
c.開始安裝過程,會出現安裝進度條,安裝結束後,程序會提示是否要在mysql.com上註冊,我們選擇跳過,即SkipSign-Up然後點“Next”(大膽地跳過,不要緊的)
d.安裝結束,選擇現在開始配置mysql服務器。點擊Finish繼續。
g.下面是選擇數據庫用途,第一種是多功能用途,將把數據庫優化成很好的innodb存儲類型和高效率的myisam存儲類型,第二種是隻用於事務處理類型,最好的優化innodb,但同時也支持myisam,最後一種是非事務處理類型,適合於簡單的應用,只有不支持事務的myisam類型是被支持的。一般選擇第一種多功能的。點Next繼續,
n.到現在位置,mysql已經得到了足夠的配置條件,如果沒有問題即可點擊Execute,讓mysql進行配置,如果有不妥的地方,點擊Back,重新修改配置條件,
o.這樣mysql就全部安裝好了,可能出現的問題:
如果在第m步,你出現的界面有三個輸入密碼的地方,則有可能您是在原來基礎上安裝的。你在第一個文本框輸入原來root的密碼,後面兩個文本框輸入root的新密碼,點擊Next基礎,
給您推薦幾種解決辦法:
1、 點Retry,重試;
2、 再運行一次設置,看到有關“移除原設置”的選項,選擇移除,然後在重新設置。
3、 重裝。
重裝注意事項:最好刪除原來的所有文件,必要的話,可以清一下註冊表,如果你機器上沒有其它mysql相關的程序。而且一定記得不要保留原有的my.ini文件。還有就是刪除原來安裝路徑下的文件,並刪除數據目錄下面的ibdata1文件.
;extension=php_dbase.dll
將前面的';'都去掉
;session.save_path = "/tmp"
將';'去掉設置你保存session的目錄,如
session.save_path= "e:/php/session_temp"
post_max_size = 20M
upload_max_filesize = 20M
<?php
$link=mysql_connect('localhost','root','123456');
if(!$link)echo "fail";
else echo"success";
mysql_close();
?>
具體參數修改【config.inc.php】:
$cfg['blowfish_secret'] = '123456';
$cfg['Servers'][$i]['controluser'] ='root';
$cfg['Servers'][$i]['controlpass'] = '123456';
需要的話重啓下MySQL,用瀏覽器打開“http://localhost:8086/phpmyadmin”,出現登錄界面就OK了。
參考網站:1.http://bbs.mysql.cn/thread-261-1-1.html
2.小空間 大智慧
http://hi.baidu.com/webarea/blog/item/4db9e1103af09403213f2e18.html
3.夜雨闌珊
http://hi.baidu.com/372179111/blog/item/17c338d5e0f38ac751da4bb3.html
在此表示感謝!!!
7.配置SmartFoxServer
7.1 System requirements
SmartFoxServer is a multi-platform applicationwritten in Java 1.4 that can be run on many different operatingsystems.
The minimum requirements to run the serverare:
- A 300Mhz cpu or better
- At least64Mb of RAM
- 50Mb ofhardisk space
- Anoperating system capable of running a Java Virtual Machine (JVM)like Windows (98/NT/2000/XP), Linux, MacOS X, other Unix basedOS(es)
- The Sun"Java Runtime Edition (JRE) version 1.4.2 or higher.
(The PRO edition requires Java 1.5 - Linux versions already comewith an embedded JRE)
Reccomended basic hardwarerequirements:
- 800Mhz or higher CPU
- 256MbRAM
Reccomended hardware requirements for hightraffic applications and games:
- Dual 2.0Ghz CPU or higher
- 1GbRam
- Serverversion of the Sun JVM
7.2 Installing the Java Runtime
In order to install or upgrade your Java Runtime, pleasefollow thislink.
7.3 Installing on Windows (NT/2K/XP/2003)
Double click on the installer and follow the simple instructionson screen.
When theprocess is finished you will find a newSmartFoxServer folder under the Start >Programs menu where you can launch the server and accessthe other application folders.
InstallingSmartFoxServer as a Windows Service:
From the Windows Start Menu open the SmartFoxServer folderand click on the Install Service icon to installSmartFoxServer as a windows service. Once this is done you willfind it listed in the windows services under the managementconsole.
You can nowstart/stop/restart the server following these steps:
1.Right-click My Computer, and chooseManage.
2. Expandthe Services & Applications tab, and selectServices.
3. SelectSmartFoxServer and use the control buttons or right click on it toaccess the context menu.
In order touninstall the server as a service just click the UninstallService icon from the Start > Programs >SmartFoxServer menu.
7.4 Flash API installation
To complete the setup you will need to install theSmartFoxServer API extension forAdobe Flash.
The extension will add new objects that you can use in Actionscriptto interact with the server.
To install the API just open the Flash API/folder in your SFS main directory and choose the appropriateversion.
» Flash MX 2004 - Flash8
Simply double click the Actionscript2.0/SmartFoxClient_AS2.mxp file to launch the ExtensionManager and install the component.
Alternatively you can point the Flash classpath of your currentproject to the sources/AS2/ folder.
» Flex Builder 2 /Flash 9 alpha
Add the provided SmartFoxClient_AS3.swc libraryfile to your current project build path.
In Flex Builder right click the project icon, chooseproperties >> FlexBuild Path >> LibraryFile >> AddSWC...
If you want to use the JSON based protocol, add also the Adobecorelib.swc library file.
7.5 API documentation
For more info about the Flash Client API, please refer tosection 4.1, and section 4.2 of this documentation.
In case youneed to upgrade your Adobe Extension Manager please download the latest version.
補充:
問題1,PHP Parse Error: syntax error, unexpected $end 解決方法:
12In PHP 5, the following error may appears as an error entry in Apache error log or simply displays on PHP web page, even if calling to php scripts with php_info() works perfectly and successfully returns information on PHP configurations:
Parse Error: syntax error, unexpected $end in ….. scripts.php on line …
The error may caused by a missing curly bracket in PHP script coding. Beside, it may also caused by error in PHP coding in class definition, as in PHP, a class definition cannot be broke up and distributed into multiple files, or into multiple PHP blocks, unless the break is within a method declaration.
But more commonly, the error is often caused by the use of Short Open tags in PHP,
To use short open tags, it must be enabled in PHP.INI. Search for short_open_tag in PHP.INI, and change the value to On. The line should look line:
short_open_tag = On
注意:php.ini中像short_open_tag標籤不止一個,所以修改時一定要確保有一個修改爲On,而其他的都被註釋掉了.
補充2:phpmyadmin安裝在htdocs目錄下。輸入http://localhost/phpmyadmin顯示頁面如下: Index of /phpMyAdmin等
原因:原因是你的目錄是可以瀏覽的,其次是沒有指定index.php爲默認首頁
將http.conf設置爲:
DirectoryIndex index.php index.htm index.html
補充3:php配置的問題Fatal error: Call to undefined function mysql_connect()
extension=php_mysql.dll的;去掉了
把php5ts.dll,libmysql.dll 拷到 system32系統目錄裏了。
extension_dir = "D:/php/ext 也改了
但就是連不上。
解決方法:將extension_dir = "D:/php/ext ";改爲
extension_dir = "D:/php/ext ";
重啓Apache和MySQL就好了,很怪,在其他機子上都沒有這個問題的。