MENU service case
 Website construction website design Beijing website construction high-end website production company Shangpin China
We create by embracing change
360 ° brand value__
simplified Chinese character
Simplified Chinese English

Shangpin China Joins Hands with Beisheng Internet to Create a New Chapter in Website Construction

Type: Shangpin Dynamic Learn more

How to set Discuz! X2.5 Forum Win host and Linux host pseudo static

Source: Shangpin China | Type: website encyclopedia | Time: April 24, 2012
Beijing website construction Company Shangpin China: Recently, a friend asked me how to set pseudo static (ihucc.com). He is a forum built with the program of dzx2.5. As he is a novice in starting to build a website, he does not understand it very well. Recently, the version of dx2.5 was released. Now, let me share the setting methods of pseudo static rules for the win host and the linux host of the dx2.5 forum!

Windows host setting method:

Step 1: Create a file named httpd.ini. You can first create a new text on the computer, then copy the following code to this article, and then save it.

[ISAPI_Rewrite]

# 3600 = 1 hour

CacheClockRate 3600

RepeatLimit 32

# Protect httpd.ini and httpd.parse.errors files

# from accessing through HTTP

RewriteRule ^(.*)/topic-(.+).html(?(.*))*$ $1/portal.php? mod=topic&topic=$2&$4

RewriteRule ^(.*)/article-([0-9]+)-([0-9]+).html(?(.*))*$ $1/portal.php? mod=view&aid=$2&page=$3&$5

RewriteRule ^(.*)/forum-(w+)-([0-9]+).html(?(.*))*$ $1/forum.php? mod=forumdisplay&fid=$2&page=$3&$5

RewriteRule ^(.*)/thread-([0-9]+)-([0-9]+)-([0-9]+).html(?(.*))*$ $1/forum.php? mod=viewthread&tid=$2&extra=page%3D$4&page=$3&$6

RewriteRule ^(.*)/group-([0-9]+)-([0-9]+).html(?(.*))*$ $1/forum.php? mod=group&fid=$2&page=$3&$5

RewriteRule ^(.*)/space-(username|uid)-(.+).html(?(.*))*$ $1/home.php? mod=space&$2=$3&$5

RewriteRule ^(.*)/blog-([0-9]+)-([0-9]+).html(?(.*))*$ $1/home.php? mod=space&uid=$2&do=blog&id=$3&$5

RewriteRule ^(.*)/(fid|tid)-([0-9]+).html(?(.*))*$ $1/index.php? action=$2&value=$3&$5

After saving these codes into the text, rename the text to httpd.ini, and then upload it to the root directory of the website!

Step 2: Next, let's go to the background of the forum, global - SEO settings - URL pseudo static, and then check all the boxes inside.

Click Submit after checking all, OK, the pseudo static setting is successful, and then update the cache of the next forum to see the effect!

Linux host setting method:

If your space is a Linux host, you need to write the following URL static rules into the. htaccess file in the root directory of your website. The rules are as follows:

RewriteEngine On

RewriteBase /

#Rewrite system rules do not modify

RewriteCond %{QUERY_STRING} ^(.*)$

RewriteRule ^topic-(.+).html$ portal.php? mod=topic&topic=$1&%1

RewriteCond %{QUERY_STRING} ^(.*)$

RewriteRule ^article-([0-9]+)-([0-9]+).html$ portal.php? mod=view&aid=$1&page=$2&%1

RewriteCond %{QUERY_STRING} ^(.*)$

RewriteRule ^forum-(w+)-([0-9]+).html$ forum.php? mod=forumdisplay&fid=$1&page=$2&%1

RewriteCond %{QUERY_STRING} ^(.*)$

RewriteRule ^thread-([0-9]+)-([0-9]+)-([0-9]+).html$ forum.php? mod=viewthread&tid=$1&extra=page%3D$3&page=$2&%1

RewriteCond %{QUERY_STRING} ^(.*)$

RewriteRule ^group-([0-9]+)-([0-9]+).html$ forum.php? mod=group&fid=$1&page=$2&%1

RewriteCond %{QUERY_STRING} ^(.*)$

RewriteRule ^space-(username|uid)-(.+).html$ home.php? mod=space&$1=$2&%1

RewriteCond %{QUERY_STRING} ^(.*)$

RewriteRule ^([a-z]+)-(.+).html$ $1.php? rewrite=$2&%1

To set pseudo static, you need your virtual host to support pseudo static. If your virtual host does not support pseudo static, it is useless to set it!

You can first create a new text, and then copy these codes into the text, and save the text name as. htaccess, and then upload it to the root directory of the website. After uploading, you can also go to the background of the forum as above, global - SEO settings - URL pseudo static, and then check all the boxes inside, and update the cache to see the pseudo static effect!

This article was published on Seo website optimization Company Shangpin China //ihucc.com/
Source Statement: This article is original or edited by Shangpin China's editors. If it needs to be reproduced, please indicate that it is from Shangpin China. The above contents (including pictures and words) are from the Internet. If there is any infringement, please contact us in time (010-60259772).
TAG label:

What if your website can increase the number of conversions and improve customer satisfaction?

Make an appointment with a professional consultant to communicate!

* Shangpin professional consultant will contact you as soon as possible

Disclaimer

Thank you very much for visiting our website. Please read all the terms of this statement carefully before you use this website.

1. Part of the content of this site comes from the network, and the copyright of some articles and pictures involved belongs to the original author. The reprint of this site is for everyone to learn and exchange, and should not be used for any commercial activities.

2. This website does not assume any form of loss or injury caused by users to themselves and others due to the use of these resources.

3. For issues not covered in this statement, please refer to relevant national laws and regulations. In case of conflict between this statement and national laws and regulations, the national laws and regulations shall prevail.

4. If it infringes your legitimate rights and interests, please contact us in time, and we will delete the relevant content at the first time!

Contact: 010-60259772
E-mail: [email protected]

Communicate with professional consultants now!

  • National Service Hotline

    400-700-4979

  • Beijing Service Hotline

    010-60259772

Please be assured to fill in the information protection
Online consultation

Disclaimer

Thank you very much for visiting our website. Please read all the terms of this statement carefully before you use this website.

1. Part of the content of this site comes from the network, and the copyright of some articles and pictures involved belongs to the original author. The reprint of this site is for everyone to learn and exchange, and should not be used for any commercial activities.

2. This website does not assume any form of loss or injury caused by users to themselves and others due to the use of these resources.

3. For issues not covered in this statement, please refer to relevant national laws and regulations. In case of conflict between this statement and national laws and regulations, the national laws and regulations shall prevail.

4. If it infringes your legitimate rights and interests, please contact us in time, and we will delete the relevant content at the first time!

Contact: 010-60259772
E-mail: [email protected]