中文无码一区二区不卡av_色欲aⅴ 无码_亚洲AV无码乱码国产精品_人妻中出无码一区二区三区

Board logo

標題: [教程] 關于nginx+apache環境偽靜態規則是否有效的測試方法 [打印本頁]

作者: itxx    時間: 2013-12-23 22:27     標題: 關于nginx+apache環境偽靜態規則是否有效的測試方法

看到有幾個同學在使用nginx+apache引擎的時候需要的偽靜態無法使用的問題,請同學們按照如下方式進行測試,并把測試結果回復到本帖,以供我們為你診斷:1.登錄wdcp控制面板新建一個測試站點;
2.在測試站點根目錄寫入如下index.php測試代碼頁面:
<code>
<?php
header("Content-type: text/html; charset=utf-8");
echo 'action:'.$_GET['action'].'<br>id:'.$_GET['id'];
?>

</code>
3.在測試站點根目錄寫入如下.htacccess文件:
<code>
RewriteEngine on
RewriteRule ([a-zA-Z]{1,})-([0-9]{1,}).html$ index.php?action=$1&id=$2

</code>

4.訪問如下url,查看頁面輸出結果:
test.example.com/test-2013.html

如果頁面能夠輸出如:
action:test
id:2013
則說明環境支持偽靜態。
作者: crll    時間: 2013-12-25 18:40

這是我專門下載wdos 1.0 安裝的虛擬機測試的。
如下:
QQ截圖20131225183052.png

QQ截圖20131225183030.png


QQ截圖20131225183059.png


QQ截圖20131225183107.png


QQ截圖20131225183131.png


QQ截圖20131225183140.png

圖片附件: QQ截圖20131225183030.png (2013-12-25 18:38, 3.77 KB) / 下載次數 11527
//bsussrc.cn/bbs/attachment.php?aid=4027&k=915df270047247bea72a57954699f8b5&t=1716008411&sid=AxPOT7



圖片附件: QQ截圖20131225183052.png (2013-12-25 18:38, 5.35 KB) / 下載次數 11602
//bsussrc.cn/bbs/attachment.php?aid=4028&k=b0f8806b03e1b5aec3cfa446a581d842&t=1716008411&sid=AxPOT7



圖片附件: QQ截圖20131225183059.png (2013-12-25 18:38, 3.26 KB) / 下載次數 11755
//bsussrc.cn/bbs/attachment.php?aid=4029&k=0c0d44febe7dc4ccbc1b22f9f6941b90&t=1716008411&sid=AxPOT7



圖片附件: QQ截圖20131225183131.png (2013-12-25 18:38, 11.24 KB) / 下載次數 11566
//bsussrc.cn/bbs/attachment.php?aid=4030&k=d56ddd5768f112e2dafd1bf96e8c74e6&t=1716008411&sid=AxPOT7



圖片附件: QQ截圖20131225183107.png (2013-12-25 18:38, 3.34 KB) / 下載次數 11485
//bsussrc.cn/bbs/attachment.php?aid=4031&k=58f9594aa626c01cd438972f5624f6cb&t=1716008411&sid=AxPOT7



圖片附件: QQ截圖20131225183140.png (2013-12-25 18:38, 8.2 KB) / 下載次數 11515
//bsussrc.cn/bbs/attachment.php?aid=4032&k=03ccd08e3d276a957b77740e31dfa697&t=1716008411&sid=AxPOT7


作者: crll    時間: 2013-12-25 18:44

從以上圖片來看發現阿帕奇沒有起作用。
下面的圖片正面阿帕奇是運行的。

20131225183555.png

20131225183632.png


20131225183654.png

圖片附件: 20131225183555.png (2013-12-25 18:43, 8.83 KB) / 下載次數 11452
//bsussrc.cn/bbs/attachment.php?aid=4033&k=5d4f980696602770440a24187b99c32d&t=1716008411&sid=AxPOT7



圖片附件: 20131225183632.png (2013-12-25 18:43, 10.85 KB) / 下載次數 11403
//bsussrc.cn/bbs/attachment.php?aid=4034&k=2107efc4f060bbadf793f290ef931515&t=1716008411&sid=AxPOT7



圖片附件: 20131225183654.png (2013-12-25 18:43, 3.26 KB) / 下載次數 11318
//bsussrc.cn/bbs/attachment.php?aid=4035&k=0f2cb5fd72bd5d79a72b23b10595bd75&t=1716008411&sid=AxPOT7


作者: itxx    時間: 2013-12-25 22:41

回復 3# crll

這說明你的偽靜態規則確實無效,請使用最新版本的lanmp一鍵安裝包重新安裝環境試試,
作者: crll    時間: 2013-12-26 09:29

  1. [root@AY1312181404071177cdZ ~]# wget //dl.bsussrc.cn:5180/lanmp_laster.tar.gz
  2. --2013-12-26 09:14:33--  //dl.bsussrc.cn:5180/lanmp_laster.tar.gz
  3. Resolving dl.bsussrc.cn... 222.186.43.27
  4. Connecting to dl.bsussrc.cn|222.186.43.27|:5180... connected.
  5. HTTP request sent, awaiting response... 200 OK
  6. Length: 81325773 (78M) [application/x-gzip]
  7. Saving to: `lanmp_laster.tar.gz'

  8. 100%[======================================>] 81,325,773  1.66M/s   in 49s

  9. 2013-12-26 09:15:23 (1.58 MB/s) - `lanmp_laster.tar.gz' saved [81325773/81325773]

  10. [root@AY1312181404071177cdZ ~]# tar xf lanmp_laster.tar.gz
  11. [root@AY1312181404071177cdZ ~]# ls lanmp
  12. debian_patches_disable_SSLv2_for_openssl_1_0_0.patch
  13. eaccelerator-0.9.5.3.tar.bz2
  14. httpd-2.0.64.tar.gz
  15. httpd-2.2.24.tar.gz
  16. libiconv-1.14.tar.gz
  17. mod_rpaf-0.6.tar.gz
  18. mysql-5.1.69.tar.gz
  19. nginx-1.2.9.tar.gz
  20. pcre-8.10.tar.gz
  21. PDO_MYSQL-1.0.2.tgz
  22. php-5.2.17-fpm-0.5.14.diff.gz
  23. php-5.2.17.tar.gz
  24. php-5.3.27.tar.gz
  25. phpmyadmin.tar.gz
  26. pure-ftpd-1.0.36.tar.gz
  27. rpmforge-release-0.5.2-2.el5.rf.i386.rpm
  28. rpmforge-release-0.5.2-2.el5.rf.x86_64.rpm
  29. RPM-GPG-KEY.dag.txt
  30. wdcp_v2.5.tar.gz
  31. zend_32.tar.gz
  32. zend_64.tar.gz
  33. [root@AY1312181404071177cdZ ~]# curl //raw.github.com/wdlinux/lanmp/master/utils/bootstrap|sh
  34.   % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
  35.                                  Dload  Upload   Total   Spent    Left  Speed
  36. 100   728  100   728    0     0    618      0  0:00:01  0:00:01 --:--:--  710k
  37. Loaded plugins: fastestmirror
  38. Determining fastest mirrors
  39. * addons: mirrors.163.com
  40. * base: mirrors.163.com
  41. * extras: mirrors.163.com
  42. * updates: mirrors.163.com
  43. addons                                                   | 1.9 kB     00:00
  44. addons/primary_db                                        | 1.1 kB     00:00
  45. base                                                     | 1.1 kB     00:00
  46. base/primary                                             | 995 kB     00:01
  47. base                                                                  2789/2789
  48. extras                                                   | 2.1 kB     00:00
  49. extras/primary_db                                        | 164 kB     00:00
  50. updates                                                  | 1.9 kB     00:00
  51. updates/primary_db                                       | 184 kB     00:00
  52. Excluding Packages in global exclude list
  53. Finished
  54. Setting up Install Process
  55. No package git available.
  56. Nothing to do
  57. sh: line 22: git: command not found
  58. /bin/cp: cannot stat `./*': No such file or directory
  59. File `httpd-2.2.24.tar.gz' already there; not retrieving.

  60. File `nginx-1.2.9.tar.gz' already there; not retrieving.

  61. File `mysql-5.1.69.tar.gz' already there; not retrieving.

  62. File `php-5.3.27.tar.gz' already there; not retrieving.

  63. File `pure-ftpd-1.0.36.tar.gz' already there; not retrieving.

  64. if all packages downloaded,you can begin install now:
  65. type:    ./install.sh    to begin install.
  66. [root@AY1312181404071177cdZ ~]#
  67. [root@AY1312181404071177cdZ ~]#
  68. [root@AY1312181404071177cdZ ~]# ./install.sh
  69. Loaded plugins: fastestmirror
  70. Loading mirror speeds from cached hostfile
  71. * addons: mirrors.163.com
  72. * base: mirrors.163.com
  73. * extras: mirrors.163.com
  74. * updates: mirrors.163.com
  75. Excluding Packages in global exclude list
  76. Finished
  77. Setting up Install Process
  78. Resolving Dependencies
  79. There are unfinished transactions remaining. You might consider running yum-complete-transaction first to finish them.
  80. The program yum-complete-transaction is found in the yum-utils package.
  81. --> Running transaction check
  82. ---> Package screen.i386 0:4.0.3-4.el5 set to be updated
  83. --> Processing Dependency: libutempter.so.0 for package: screen
  84. --> Running transaction check
  85. ---> Package libutempter.i386 0:1.1.4-4.el5 set to be updated
  86. --> Finished Dependency Resolution

  87. Dependencies Resolved

  88. ================================================================================
  89. Package              Arch          Version                 Repository     Size
  90. ================================================================================
  91. Installing:
  92. screen               i386          4.0.3-4.el5             base          559 k
  93. Installing for dependencies:
  94. libutempter          i386          1.1.4-4.el5             base           22 k

  95. Transaction Summary
  96. ================================================================================
  97. Install      2 Package(s)
  98. Update       0 Package(s)
  99. Remove       0 Package(s)

  100. Total download size: 580 k
  101. Downloading Packages:
  102. (1/2): libutempter-1.1.4-4.el5.i386.rpm                  |  22 kB     00:00
  103. (2/2): screen-4.0.3-4.el5.i386.rpm                       | 559 kB     00:01
  104. --------------------------------------------------------------------------------
  105. Total                                           259 kB/s | 580 kB     00:02
  106. Running rpm_check_debug
  107. Running Transaction Test
  108. Finished Transaction Test
  109. Transaction Test Succeeded
  110. Running Transaction
  111.   Installing     : libutempter                                              1/2
  112.   Installing     : screen                                                   2/2

  113. Installed:
  114.   screen.i386 0:4.0.3-4.el5

  115. Dependency Installed:
  116.   libutempter.i386 0:1.1.4-4.el5

  117. Complete!
復制代碼

作者: itxx    時間: 2013-12-26 20:12

回復 5# crll


   你的yum倉庫里沒有git,看看yum倉庫是不是有問題呢。
作者: SaorUicnext    時間: 2014-2-5 01:47

應該是".htaccess"!!!不是".htacccess"。。因為這個折騰了半天都不行。。暈倒
作者: mjl840125    時間: 2014-3-15 17:53

本帖最后由 mjl840125 于 2014-3-15 18:03 編輯

1.jpg
2.jpg
3.jpg
4.jpg

圖片附件: 1.jpg (2014-3-15 18:02, 17.61 KB) / 下載次數 11373
//bsussrc.cn/bbs/attachment.php?aid=4298&k=9cc790f9ce2febcef3408772ef9dc75b&t=1716008411&sid=AxPOT7



圖片附件: 2.jpg (2014-3-15 18:02, 17.43 KB) / 下載次數 11502
//bsussrc.cn/bbs/attachment.php?aid=4299&k=c6229777c8aed3a94650b70e331e5f40&t=1716008411&sid=AxPOT7



圖片附件: 3.jpg (2014-3-15 18:02, 19.61 KB) / 下載次數 11367
//bsussrc.cn/bbs/attachment.php?aid=4300&k=4e392764c8d2d23daf4b047c2c71d9c1&t=1716008411&sid=AxPOT7



圖片附件: 4.jpg (2014-3-15 18:02, 44.26 KB) / 下載次數 11477
//bsussrc.cn/bbs/attachment.php?aid=4301&k=0fba08afa76085beb19fbd9184064516&t=1716008411&sid=AxPOT7


作者: wuyouseo    時間: 2014-3-27 18:55

看不懂啊。你們都是大神
作者: 360784502    時間: 2014-3-29 22:51

那樣子啊,厲害
作者: yuqi1015918    時間: 2014-4-6 08:47

學習一下!!
作者: 96542199    時間: 2014-4-23 17:41

支持的!WORDPRESS 直接就支持了。
作者: mingsz8    時間: 2014-5-6 10:39

我弄WP規則弄了好久才弄好
作者: linuxwolf    時間: 2014-6-27 11:09

測試  盜鏈   //www.hbike.cn
作者: linuxwolf    時間: 2014-6-27 11:09

一會成功    一會不成功    相當的郁悶
作者: limingchuan    時間: 2014-6-30 23:49

呵呵呵!
作者: webyxm    時間: 2014-7-11 14:00

WP規則弄了好久才弄好
作者: linuxwolf    時間: 2014-10-17 17:44

//bsussrc.cn/bbs/viewthread.php?tid=37688&extra=
作者: linuxwolf    時間: 2014-10-17 17:44

wdcp重啟nginx服務后,.htaccess立馬失效  
//bsussrc.cn/bbs/viewthread.php?tid=37688&extra=
作者: my1281617143    時間: 2015-5-20 22:39

用了2種模式,一定要用2種偽靜態規則嗎?
作者: metersbonwe    時間: 2017-3-28 20:32

WP規則弄了好久才弄好!~
作者: laomeng    時間: 2017-4-29 13:10

回復 7# SaorUicnext
:handshake:handshake:handshake:handshake
頂上去,讓更多的人看到
作者: zzidc    時間: 2017-10-12 11:27

測試一下 測試一下 測試一下 測試一下




歡迎光臨 WDlinux官方論壇 (//bsussrc.cn/bbs/) Powered by Discuz! 7.2