如题所述
åªé以ä¸æ¥éª¤ï¼
1ãä¸è½½è¦å®è£ çPHPçæ¬ãæ¢ç¶æ¯ç¨WampServerï¼é£å½ç¶æ¯ä¸è½½Windowçæ¬çZIPå å¦ï¼http://windows.php.netã解åå°
Wampçå®è£ ç®å½\bin\php\php5.2.17ãè¿é以5.2.17为ä¾ã
2ãè¿å ¥ Wampçå®è£ ç®å½\bin\php\php5.2.17 ç®å½ï¼ä» php.ini-dist æè php.ini-recommended å¤å¶ä¸ä»½ï¼éå½å为php.iniï¼éåºä¿®æ¹php.inié ç½®ï¼å¦extension_dirï¼ï¼åä»php.iniå¤å¶ä¸åï¼éå½å为 phpForApache.iniã
3ãä»å·²æççæ¬ç®å½ä¸å¤å¶ä¸ä»½ wampserver.confãæ¯å¦æå®è£ WampServerçæ¶åå·²ç»æphp5.3.0ï¼å¨ Wampçå®è£ ç®å½\bin\php\php5.3.0 ç®å½ä¸å¤å¶ wampserver.conf
å° Wampçå®è£ ç®å½\bin\php\php5.2.17ã
4ãä¿®æ¹Wampé ç½®æ件ï¼è¿å ¥ Wampçå®è£ ç®å½ï¼ç¨IDEæè®°äºæ¬ï¼æ好使ç¨è¡å·å®ä½çè®°äºæ¬ï¼å¦EditPlusçï¼æå¼ wampmanager.iniï¼å®ä½å° 335 è¡ï¼é常å¨è¿ä¸è¡å°±æ¯[phpVersion]ï¼å¦æä¸æ¯ï¼åå¨éè¿æ¾æ¾ãå¤å¶ä¸é¢ä¸è¡ï¼
Type: item; Caption: "5.3.0"; Action: multi; Actions:switchPhp5.3.0
æå ¥å°è¿ä¸è¡åé¢ï¼å¹¶ä¿®æ¹ä¸º
Type: item; Caption: "5.2.17"; Action: multi; Actions:switchPhp5.2.17
åå¤å¶
[switchPhp5.3.0]
Action: service; Service: wampapache; ServiceAction: stop; Flags: ignoreerrors waituntilterminated
Action: run; FileName: "Wampçå®è£ ç®å½/bin/php/php5.3.0/php-win.exe";Parameters: "switchPhpVersion.php 5.3.0";WorkingDir: "Wampçå®è£ ç®å½/scripts"; Flags: waituntilterminated
Action: run; FileName: "Wampçå®è£ ç®å½/bin/php/php5.3.0/php-win.exe";Parameters: "-c . refresh.php";WorkingDir: "Wampçå®è£ ç®å½/scripts"; Flags: waituntilterminated
Action: run; FileName: "net"; Parameters: "start wampapache"; ShowCmd: hidden; Flags: waituntilterminated
Action: resetservices
Action: readconfig;
æå ¥è¿ä¸æ®µä¹åï¼å¹¶ä¿®æ¹ä¸º
[switchPhp5.2.17]
Action: service; Service: wampapache; ServiceAction: stop; Flags: ignoreerrors waituntilterminated
Action: run; FileName: "Wampçå®è£ ç®å½/bin/php/php5.3.0/php-win.exe";Parameters: "switchPhpVersion.php 5.2.17";WorkingDir: "Wampçå®è£ ç®å½/scripts"; Flags: waituntilterminated
Action: run; FileName: "Wampçå®è£ ç®å½/bin/php/php5.3.0/php-win.exe";Parameters: "-c . refresh.php";WorkingDir: "Wampçå®è£ ç®å½/scripts"; Flags: waituntilterminated
Action: run; FileName: "net"; Parameters: "start wampapache"; ShowCmd: hidden; Flags: waituntilterminated
Action: resetservices
Action: readconfig;
5ãéåºWampServerï¼åéå¯ãå®æã
éè¿è¿5æ¥ï¼å³å¯å®æPHPä»»æçæ¬çå®è£ ã
1ãä¸è½½è¦å®è£ çPHPçæ¬ãæ¢ç¶æ¯ç¨WampServerï¼é£å½ç¶æ¯ä¸è½½Windowçæ¬çZIPå å¦ï¼http://windows.php.netã解åå°
Wampçå®è£ ç®å½\bin\php\php5.2.17ãè¿é以5.2.17为ä¾ã
2ãè¿å ¥ Wampçå®è£ ç®å½\bin\php\php5.2.17 ç®å½ï¼ä» php.ini-dist æè php.ini-recommended å¤å¶ä¸ä»½ï¼éå½å为php.iniï¼éåºä¿®æ¹php.inié ç½®ï¼å¦extension_dirï¼ï¼åä»php.iniå¤å¶ä¸åï¼éå½å为 phpForApache.iniã
3ãä»å·²æççæ¬ç®å½ä¸å¤å¶ä¸ä»½ wampserver.confãæ¯å¦æå®è£ WampServerçæ¶åå·²ç»æphp5.3.0ï¼å¨ Wampçå®è£ ç®å½\bin\php\php5.3.0 ç®å½ä¸å¤å¶ wampserver.conf
å° Wampçå®è£ ç®å½\bin\php\php5.2.17ã
4ãä¿®æ¹Wampé ç½®æ件ï¼è¿å ¥ Wampçå®è£ ç®å½ï¼ç¨IDEæè®°äºæ¬ï¼æ好使ç¨è¡å·å®ä½çè®°äºæ¬ï¼å¦EditPlusçï¼æå¼ wampmanager.iniï¼å®ä½å° 335 è¡ï¼é常å¨è¿ä¸è¡å°±æ¯[phpVersion]ï¼å¦æä¸æ¯ï¼åå¨éè¿æ¾æ¾ãå¤å¶ä¸é¢ä¸è¡ï¼
Type: item; Caption: "5.3.0"; Action: multi; Actions:switchPhp5.3.0
æå ¥å°è¿ä¸è¡åé¢ï¼å¹¶ä¿®æ¹ä¸º
Type: item; Caption: "5.2.17"; Action: multi; Actions:switchPhp5.2.17
åå¤å¶
[switchPhp5.3.0]
Action: service; Service: wampapache; ServiceAction: stop; Flags: ignoreerrors waituntilterminated
Action: run; FileName: "Wampçå®è£ ç®å½/bin/php/php5.3.0/php-win.exe";Parameters: "switchPhpVersion.php 5.3.0";WorkingDir: "Wampçå®è£ ç®å½/scripts"; Flags: waituntilterminated
Action: run; FileName: "Wampçå®è£ ç®å½/bin/php/php5.3.0/php-win.exe";Parameters: "-c . refresh.php";WorkingDir: "Wampçå®è£ ç®å½/scripts"; Flags: waituntilterminated
Action: run; FileName: "net"; Parameters: "start wampapache"; ShowCmd: hidden; Flags: waituntilterminated
Action: resetservices
Action: readconfig;
æå ¥è¿ä¸æ®µä¹åï¼å¹¶ä¿®æ¹ä¸º
[switchPhp5.2.17]
Action: service; Service: wampapache; ServiceAction: stop; Flags: ignoreerrors waituntilterminated
Action: run; FileName: "Wampçå®è£ ç®å½/bin/php/php5.3.0/php-win.exe";Parameters: "switchPhpVersion.php 5.2.17";WorkingDir: "Wampçå®è£ ç®å½/scripts"; Flags: waituntilterminated
Action: run; FileName: "Wampçå®è£ ç®å½/bin/php/php5.3.0/php-win.exe";Parameters: "-c . refresh.php";WorkingDir: "Wampçå®è£ ç®å½/scripts"; Flags: waituntilterminated
Action: run; FileName: "net"; Parameters: "start wampapache"; ShowCmd: hidden; Flags: waituntilterminated
Action: resetservices
Action: readconfig;
5ãéåºWampServerï¼åéå¯ãå®æã
éè¿è¿5æ¥ï¼å³å¯å®æPHPä»»æçæ¬çå®è£ ã
温馨提示:答案为网友推荐,仅供参考
第1个回答 2014-11-03
这个真没听过可以装多个版本的
要是版本低了的话,可以升级啊
PHP5.X以上的话,兼容还是不错的本回答被提问者和网友采纳
要是版本低了的话,可以升级啊
PHP5.X以上的话,兼容还是不错的本回答被提问者和网友采纳