顶点网 » 脚本代码 » DataLife Engine v.12.0 - UTF8英文破解版
九月 16 2017年

DataLife Engine v.12.0 - UTF8英文破解版

reishi  2017-09-16, 08:00   脚本代码  19372 
你必须注册后才能查看此内容。请 注册登录


以下内容转自

http://www.zeroto.net/website/nginx-url-rewrite-rule-for-datalife-engine.html

由群友飞扬(一堆K)提供
DataLife Engine 的 Nginx 网址重写规则,代码如下:


# Redirects
rewrite ^/page/(.*)$ /index.php?cstart=$1 last;

# Post
rewrite ^/([0-9]+)/([0-9]+)/([0-9]+)/page,([0-9]+),([0-9]+),(.*).html(/?)+$ /index.php?subaction=showfull&year=$1&month=$2&day=$3&news_page=$4&cstart=$5&news_name=$6 last;
rewrite ^/([0-9]+)/([0-9]+)/([0-9]+)/page,([0-9]+),(.*).html(/?)+$ /index.php?subaction=showfull&year=$1&month=$2&day=$3&news_page=$4&news_name=$5 last;
rewrite ^/([0-9]+)/([0-9]+)/([0-9]+)/print:page,([0-9]+),(.*).html(/?)+$ /engine/print.php?subaction=showfull&year=$1&month=$2&day=$3&news_page=$4&news_name=$5 last;
rewrite ^/([0-9]+)/([0-9]+)/([0-9]+)/(.*).html(/?)+$ /index.php?subaction=showfull&year=$1&month=$2&day=$3&news_name=$4 last;

rewrite ^/([^.]+)/page,([0-9]+),([0-9]+),([0-9]+)-(.*).html(/?)+$ /index.php?newsid=$4&news_page=$2&cstart=$3&seourl=$5&seocat=$1 last;
rewrite ^/([^.]+)/page,([0-9]+),([0-9]+)-(.*).html(/?)+$ /index.php?newsid=$3&news_page=$2&seourl=$4&seocat=$1 last;
rewrite ^/([^.]+)/print:page,([0-9]+),([0-9]+)-(.*).html(/?)+$ /engine/print.php?news_page=$2&newsid=$3&seourl=$4&seocat=$1 last;
rewrite ^/([^.]+)/([0-9]+)-(.*).html(/?)+$ /index.php?newsid=$2&seourl=$3&seocat=$1 last;

rewrite ^/page,([0-9]+),([0-9]+),([0-9]+)-(.*).html(/?)+$ /index.php?newsid=$3&news_page=$1&cstart=$2&seourl=$4 last;
rewrite ^/page,([0-9]+),([0-9]+)-(.*).html(/?)+$ /index.php?newsid=$2&news_page=$1&seourl=$3 last;
rewrite ^/print:page,([0-9]+),([0-9]+)-(.*).html(/?)+$ /engine/print.php?news_page=$1&newsid=$2&seourl=$3 last;
rewrite ^/([0-9]+)-(.*).html(/?)+$ /index.php?newsid=$1&seourl=$2 last;

# For day
rewrite ^/([0-9]+)/([0-9]+)/([0-9]+)(/?)+$ /index.php?year=$1&month=$2&day=$3 last;
rewrite ^/([0-9]+)/([0-9]+)/([0-9]+)/page/([0-9]+)(/?)+$ /index.php?year=$1&month=$2&day=$3&cstart=$4 last;
# For all months
rewrite ^/([0-9]+)/([0-9]+)(/?)+$ /index.php?year=$1&month=$2 last;
rewrite ^/([0-9]+)/([0-9]+)/page/([0-9]+)(/?)+$ /index.php?year=$1&month=$2&cstart=$3 last;
# Output for the entire year
rewrite ^/([0-9]+)(/?)+$ /index.php?year=$1 last;
rewrite ^/([0-9]+)/page/([0-9]+)(/?)+$ /index.php?year=$1&cstart=$2 last;
# Output for tags
rewrite ^/tags/([^/]*)(/?)+$ /index.php?do=tags&tag=$1 last;
rewrite ^/tags/([^/]*)/page/([0-9]+)(/?)+$ /index.php?do=tags&tag=$1&cstart=$2 last;
# Output for users
rewrite ^/user/([^/]*)/rss.xml$ /engine/rss.php?subaction=allnews&user=$1 last;
rewrite ^/user/([^/]*)(/?)+$ /index.php?subaction=userinfo&user=$1 last;
rewrite ^/user/([^/]*)/page/([0-9]+)(/?)+$ /index.php?subaction=userinfo&user=$1&cstart=$2 last;
rewrite ^/user/([^/]*)/news(/?)+$ /index.php?subaction=allnews&user=$1 last;
rewrite ^/user/([^/]*)/news/page/([0-9]+)(/?)+$ /index.php?subaction=allnews&user=$1&cstart=$2 last;
rewrite ^/user/([^/]*)/news/rss.xml(/?)+$ /engine/rss.php?subaction=allnews&user=$1 last;
# Output for last news
rewrite ^/lastnews/(/?)+$ /index.php?do=lastnews last;
rewrite ^/lastnews/page/([0-9]+)(/?)+$ /index.php?do=lastnews&cstart=$1 last;
# Output for catalog
rewrite ^/catalog/([^/]*)/rss.xml$ /engine/rss.php?catalog=$1 last;
rewrite ^/catalog/([^/]*)(/?)+$ /index.php?catalog=$1 last;
rewrite ^/catalog/([^/]*)/page/([0-9]+)(/?)+$ /index.php?catalog=$1&cstart=$2 last;
# Output for new posts
rewrite ^/newposts(/?)+$ /index.php?subaction=newposts last;
rewrite ^/newposts/page/([0-9]+)(/?)+$ /index.php?subaction=newposts&cstart=$1 last;
# Output for favorites news
rewrite ^/favorites(/?)+$ /index.php?do=favorites last;
rewrite ^/favorites/page/([0-9]+)(/?)+$ /index.php?do=favorites&cstart=$1 last;

rewrite ^/rules.html$ /index.php?do=rules last;
rewrite ^/statistics.html$ /index.php?do=stats last;
rewrite ^/addnews.html$ /index.php?do=addnews last;
rewrite ^/rss.xml$ /engine/rss.php last;
rewrite ^/sitemap.xml$ /uploads/sitemap.xml last;

if (!-d $request_filename) {
    rewrite ^/([^.]+)/page/([0-9]+)(/?)+$ /index.php?do=cat&category=$1&cstart=$2 last;
    rewrite ^/([^.]+)/?$ /index.php?do=cat&category=$1 last;
}

if (!-f $request_filename) {
    rewrite ^/([^<]+)/rss.xml$ /engine/rss.php?do=cat&category=$1 last;
    rewrite ^/page,([0-9]+),([^/]+).html$ /index.php?do=static&page=$2&news_page=$1 last;
    rewrite ^/print:([^/]+).html$ /engine/print.php?do=static&page=$1 last;
}

if (!-f $request_filename) {
    rewrite ^/([^/]+).html$ /index.php?do=static&page=$1 last;
}


请将上述代码存成 .conf 文件 ( linux 系统该文件保存在 /usr/local/nginx/conf ),并在网站设置里面加载。


DataLife Engine v.12.0 - UTF8英文破解版

文章最后由 reishi 在 2017-09-17, 22:04 编辑
编辑原因: 新增nginx伪静态规则


评论(5)

  1. 头像

    reishi ( 管理员)

    2017-10-07 07:42 1622 条评论

    引用: fushiyi
    为什么中文用户注册就出现错误,中文的标签也不能访问,老大给个解决的办法

    应该是主机的问题,你可以进QQ群一起交流一下。

  1. 头像

    fushiyi ( 会员)

    2017-10-05 10:18 4 条评论

    为什么中文用户注册就出现错误,中文的标签也不能访问,老大给个解决的办法

  1. 头像

    kkkkkkkk ( 会员)

    2017-09-17 21:08 2 条评论

    引用: reishi
    引用: kkkkkkkk
    求nginx伪静态
    网上找的都只能用文章伪静态样式1
    用户设置和样式2,3都无法进入

    不知道你看没看过这个
    点击浏览

    Stoping nginx... nginx: [emerg] directive "rewrite" is not terminated by ";" in /usr/local/nginx/conf/dle.conf:4
    failed. Use force-quit
    Starting nginx... nginx (pid 28051 28050) already running.
    有问题.

    引用: kkkkkkkk
    引用: reishi
    引用: kkkkkkkk
    求nginx伪静态
    网上找的都只能用文章伪静态样式1
    用户设置和样式2,3都无法进入

    不知道你看没看过这个
    点击浏览

    Stoping nginx... nginx: [emerg] directive "rewrite" is not terminated by ";" in /usr/local/nginx/conf/dle.conf:4
    failed. Use force-quit
    Starting nginx... nginx (pid 28051 28050) already running.
    有问题.

    用了这个OK了:http://www.zeroto.net/website/nginx-url-rewrite-rule-for-datalife-engine.html
    你贴进文章里去吧,造福大众

  1. 头像

    reishi ( 管理员)

    2017-09-17 13:57 1622 条评论

    引用: kkkkkkkk
    求nginx伪静态
    网上找的都只能用文章伪静态样式1
    用户设置和样式2,3都无法进入

    不知道你看没看过这个
    点击浏览

  1. 头像

    kkkkkkkk ( 会员)

    2017-09-17 13:25 2 条评论

    求nginx伪静态
    网上找的都只能用文章伪静态样式1
    用户设置和样式2,3都无法进入

信息

想要留言? 请 登录 您的账号。还没有? 你可以 点击注册账号

投票调查

对新模板的看法