qq_35011659 2018-08-06 03:26 采纳率: 0%
浏览 623
已结题

SEOApache配置修改 http rewrite

根据url规则 写cookie值
第一种: 域名后的第一个值放入cookie 第一个竖线和第二个竖线之间
https://xxx.com/wholesale/wedding+dresses.html
cookies 值: seo|wholesale||organic|搜索引擎|搜索关键词|
https://xxx.com/manufacturers/wedding-dresses-suppliers.html
cookies 值:seo|manufacturers||organic|搜索引擎|搜索关键词|
第二种:m. 后的值放入 cookie 第一个竖线和第二个竖线之间
https://m.ca.xx.com/skater-skirt-woman-canada.html
cookies 值:seo|ca||organic|搜索引擎|搜索关键词|
https://m.au.xx.com/knit-skater-skirt-australia.html
cookies 值:seo|au||organic|搜索引擎|搜索关键词|

RewriteCond %{HTTP_REFERER} ^https?://(\S+\.)?(google|yahoo|bing|aol|ask|search-results|yandex)\.(.+)(\?q=|&q=|\?p=|&p=|\?text=|&text=)([^&]*)gate([^&]*)(.*)$ [NC]
RewriteRule ^(.*)$ $1 [CO=ref_f:seo|%{ENV:pkey}||brand|%2|%5gate%6|:dhgate.com:43200,S=6]
RewriteCond %{HTTP_REFERER} ^https?://(\S+\.)?(google|yahoo|bing|aol|ask|search-results|yandex)\.(.+)(\?q=|&q=|\?p=|&p=|\?text=|&text=)([^&]*)(.*)$ [NC]
RewriteRule ^(.*)$ $1 [CO=ref_f:seo|%{ENV:pkey}||organic|%2|%5|:dhgate.com:43200,S=5]
RewriteCond %{HTTP_REFERER} ^http://(\S+\.)?(google)\.(.*)/search$ [NC]
RewriteRule ^(.*)$ $1 [CO=ref_f:seo|%{ENV:pkey}||organic|%2|search|:dhgate.com:43200,S=4]
RewriteCond %{HTTP_REFERER} ^https?://(\S+\.)?(google|yahoo|bing|aol|ask|search-results|yandex)\.(.*)$ [NC]
#RewriteRule ^(.*)$ $1 [CO=ref_f:seo|%{ENV:pkey}||organic|%2|http|:dhgate.com:43200,S=3]
RewriteRule ^(.*)$ $1 [CO=ref_f:seo|%{ENV:pkey}|%{REQUEST_URI}|organic|%2|http|:dhgate.com:43200,S=3]
RewriteCond %{HTTP_REFERER} ^https?://(\S+\.)?(youtube)\.(.*)/watch\?v=([^&]*)(.*)$ [NC]
RewriteRule ^(.*)$ $1 [CO=ref_f:%2|organic|%4||||:dhgate.com:43200,S=2]
RewriteCond %{HTTP_REFERER} ^https?://(\S+\.)?(youtube|twitter|facebook|pinterest|instagram|bit|reddit)\.(.*)/?(.*)$ [NC]
RewriteRule ^(.*)$ $1 [CO=ref_f:%2|organic|||||:dhgate.com:43200,S=1]

RewriteCond %{REQUEST_URI} /wholesale-refine/(.*)$ [NC]
RewriteCond %{HTTP_REFERER} ^https?://(\S+\.)?(google|yahoo|bing)\.(.*)$ [NC]
RewriteRule ^(.*)$ $1 [CO=ref_f:seo|cate-attr||organic|%2|http|:dhgate.com:43200,S=7]

RewriteCond %{HTTP_REFERER} ^https?://(\S+\.)?(google|yahoo|bing|aol|ask|search-results|yandex)\.(.+)(\?q=|&q=|\?p=|&p=|\?text=|&text=)([^&]*)(.*)$ [NC]
RewriteRule ^(.*)$ $1 [CO=ref_f:seo|||organic|%2|%5|:dhgate.com:43200,S=6]

RewriteCond %{HTTP_REFERER}-split-%{REQUEST_URI} ^https?://(\S+\.)?(google|yahoo|bing|aol|ask|search-results|yandex)\.(.*)-split-/(wholesale|manufacturers|discount|online-shopping|free-shipping|hot-product|uk|price|reviews)/(.*)\.html$ [NC]
RewriteRule ^(.*)$ $1 [CO=ref_f:seo|%4||organic|%2|http|:dhgate.com:43200,S=5]

RewriteCond %{HTTP_REFERER}-split-%{HTTP_HOST} ^https?://(\S+\.)?(google|yahoo|bing|aol|ask|search-results|yandex)\.(.*)-split-(au|ca|nz|uk)\.dhgate\.com$ [NC]
RewriteRule ^(.*)$ $1 [CO=ref_f:seo|%4||organic|%2|http|:dhgate.com:43200,S=4]
  • 写回答

1条回答 默认 最新

  • dabocaiqq 2018-08-06 14:34
    关注
    评论

报告相同问题?

悬赏问题

  • ¥35 平滑拟合曲线该如何生成
  • ¥100 c语言,请帮蒟蒻写一个题的范例作参考
  • ¥15 名为“Product”的列已属于此 DataTable
  • ¥15 安卓adb backup备份应用数据失败
  • ¥15 eclipse运行项目时遇到的问题
  • ¥15 关于#c##的问题:最近需要用CAT工具Trados进行一些开发
  • ¥15 南大pa1 小游戏没有界面,并且报了如下错误,尝试过换显卡驱动,但是好像不行
  • ¥15 没有证书,nginx怎么反向代理到只能接受https的公网网站
  • ¥50 成都蓉城足球俱乐部小程序抢票
  • ¥15 yolov7训练自己的数据集