| |
|
| :: |
| Author |
Message |
ibnuasad
Joined: 28 Jul 2006 Posts: 4 Location: Malaysia...Truly Asia!
|
Posted: Fri Jul 28, 2006 1:39 pm Post subject: Re: Locking the www in urls |
|
|
What is the difference between the First method and Second Method?
I am currently using the First Method. Which method should I use? |
_________________ Global Internet Forum (Optimized by phpbbSEO) |
|
| Back to top |
|
 |
|
 |
dcz Administrateur - Site Admin

Joined: 28 Apr 2006 Posts: 13994
|
Posted: Fri Jul 28, 2006 3:52 pm Post subject: Re: Locking the www in urls |
|
|
Well, the first one is just making sure it is not example.com to be used, where the second one make sure it is www.example.com to be used which leads to the same result.
It only changes something when playing with sub-domains linked to the same web space as the main one.
First method is then faster, as you won't need to test every single sub-domain as if using the other one.
The more important here is it works : -http://networldtalk.net
++ |
_________________ Useful links :
SEO Forum || SEO Directory || SEO phpBB || SEO phpBB3 || Search
____________________
Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Référencement phpBB3 || Recherche |
|
| Back to top |
|
 |
AmirAbbas phpBB SEO Team


Joined: 11 May 2006 Posts: 529 Location: IRAN
|
|
| Back to top |
|
 |
dcz Administrateur - Site Admin

Joined: 28 Apr 2006 Posts: 13994
|
Posted: Sun Jul 30, 2006 12:41 pm Post subject: Re: Locking the www in urls |
|
|
Then don't add it, you can try make sure it's not tested, but I doubt your server settings will allow the www version to hit your sub-domain webspace, so I don't think this will change anything.
Actually, it's the first time I see such page, usually, when the www prefix is not available, it leads to a 404, not to a login page not being really related it seems.
Anyway the worst is avoided as those two are not duplicates
++ |
_________________ Useful links :
SEO Forum || SEO Directory || SEO phpBB || SEO phpBB3 || Search
____________________
Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Référencement phpBB3 || Recherche |
|
| Back to top |
|
 |
lavinya PR1


Joined: 24 Jul 2006 Posts: 159 Location: Turkey
|
Posted: Thu Sep 07, 2006 2:57 pm Post subject: please help me |
|
|
Hello all.
dcz; I have 3 domain .
example
main domain www.phpbb-seo.com
above all domain however redirect to www.phpbb-seo.com ?
and all current links and domains are indexed my search engines, I want to make Redirect 301 from old links to new links ?
eg.
,
---
please help me
if you reply I will be happy. thanks.  |
|
|
| Back to top |
|
 |
dcz Administrateur - Site Admin

Joined: 28 Apr 2006 Posts: 13994
|
Posted: Thu Sep 07, 2006 3:52 pm Post subject: Re: Locking the www in urls |
|
|
So I assume you are happy now
Very simple indeed.
You just need to use the !^www\.example\.com method (not the ^example.com), some thing like :
| Code: | RewriteCond %{HTTP_HOST} !^www\.example\.com$ [NC]
RewriteRule ^(.*) http://www.example.com/$1 [QSA,L,R=301] |
With this any domain linked to the same folder as the one you want in the end, will be HTTP 301 redirected to the correct one.
The idea is any_sub.any_domain.any_ext/*.* will be redirected to www.example.com/*.*
And if you only have one .htaccess with rewriterules in it, this will work for all sub-folders at once.
You may have to play a bit around the suggested code as explained in the first post, but it will work.
++ |
_________________ Useful links :
SEO Forum || SEO Directory || SEO phpBB || SEO phpBB3 || Search
____________________
Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Référencement phpBB3 || Recherche |
|
| Back to top |
|
 |
lavinya PR1


Joined: 24 Jul 2006 Posts: 159 Location: Turkey
|
Posted: Thu Sep 07, 2006 4:33 pm Post subject: Re: Locking the www in urls |
|
|
very thanks dcz very happy
dcz: main directory it will work >> ok
eg: www.xxxx1.com redirect to www.xxxx.com
I have got subdomain .htaccess eg: /phpBB2/ and /gallery/
doesnt will work.
-----
I after this code added in /phpBB2/ .htaccess
| Code: | RewriteCond %{HTTP_HOST} !^www\.mydomain\.com$ [NC]
RewriteRule ^(.*) http://www.mydomain.com/$1 [QSA,L,R=301] |
doesnt work
click to http://www.maindomain2.com/phpBB2/about219.html
redirect to
http://www.maindomain.com/viewtopic.php?t=219 >> error 404 page
please help me thanks  |
|
|
| Back to top |
|
 |
dcz Administrateur - Site Admin

Joined: 28 Apr 2006 Posts: 13994
|
Posted: Thu Sep 07, 2006 5:08 pm Post subject: Re: Locking the www in urls |
|
|
This is becoming more complex if you do not implement all of your rewriterules in your root's .htaccess.
Don't worry, as you can see on this site, it's just very possible to filter www prefix and run sub domains in the same folder.
My problem here to help out is to know :
1) where are all the .htaccess with rewriterules in it
2) sub domain config : where are they installed.
3) possibly real examples, or at lest a link to the concerned web site.
Don't worry about posting duplicate domains links here as we'll http 301 all of them, this is for sure
++ |
_________________ Useful links :
SEO Forum || SEO Directory || SEO phpBB || SEO phpBB3 || Search
____________________
Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Référencement phpBB3 || Recherche |
|
| Back to top |
|
 |
lavinya PR1


Joined: 24 Jul 2006 Posts: 159 Location: Turkey
|
Posted: Thu Sep 07, 2006 5:39 pm Post subject: Re: Locking the www in urls |
|
|
Thanks dcz.
my main site adress :
www.lavinya.net
other my site adress:
www.lavinya.org
www.lavinya.de
lavinya.net
lavinya.org
lavinya.de
click to www.lavinya.org
redirect to >> www.lavinya.net (OK)
Here my root directory .htaccess www.lavinya.net /.htaccess
| Code: | AddType application/x-httpd-php .html .htm
RewriteEngine on
RewriteCond %{HTTP_HOST} !^www\.lavinya\.net$ [NC]
RewriteRule ^(.*) http://www.lavinya.net/$1 [QSA,L,R=301]
ErrorDocument 404 /404.html
ErrorDocument 403 /403.html
RewriteEngine on
RewriteCond %{HTTP_REFERER} ^$
RewriteCond %{HTTP_USER_AGENT} ^$
RewriteCond %{REQUEST_URI} ^/$
RewriteRule ^/.* http://%{REMOTE_ADDR}/ [L,E=nolog:1] |
click to http://www.lavinya.org/phpBB2/about219.html
redirect to >> http://www.lavinya.net/viewtopic.php?t=219 (404 page)
Here my www.lavinya.net/phpBB2 /.htaccess code
| Code: | RewriteEngine On
RewriteBase /phpBB2/
RewriteRule ^forums.* index.php [L,NC]
RewriteRule ^post-([0-9]*).html&highlight=([a-zA-Z0-9]*) viewtopic.php?p=$1&highlight=$2 [L,NC]
RewriteRule ^post-([0-9]*).* viewtopic.php?p=$1 [L,NC]
RewriteRule ^view-poll([0-9]*)-([0-9]*)-([a-zA-Z]*).* viewtopic.php?t=$1&postdays=$2&postorder=$3&vote=viewresult [L,NC]
RewriteRule ^about([0-9]*).html&highlight=([a-zA-Z0-9]*) viewtopic.php?t=$1&highlight=$2 [L,NC]
RewriteRule ^about([0-9]*).html&view=newest viewtopic.php?t=$1&view=newest [L,NC]
RewriteRule ^about([0-9]*)-([0-9]*)-([a-zA-Z]*)-([0-9]*).* viewtopic.php?t=$1&postdays=$2&postorder=$3&start=$4 [L,NC]
RewriteRule ^about([0-9]*)-([0-9]*).* viewtopic.php?t=$1&start=$2 [L,NC]
RewriteRule ^about([0-9]*).* viewtopic.php?t=$1 [L,NC]
RewriteRule ^about([0-9]*).html viewtopic.php?t=$1&start=$2&postdays=$3&postorder=$4&highlight=$5 [L,NC]
RewriteRule ^mark-forum([0-9]*).html* viewforum.php?f=$1&mark=topics [L,NC]
RewriteRule ^updates-topic([0-9]*).html* viewtopic.php?t=$1&watch=topic [L,NC]
RewriteRule ^stop-updates-topic([0-9]*).html* viewtopic.php?t=$1&unwatch=topic [L,NC]
RewriteRule ^forum-([0-9]*).html viewforum.php?f=$1 [L,NC]
RewriteRule ^forum-([0-9]*).* viewforum.php?f=$1 [L,NC]
RewriteRule ^topic-([0-9]*)-([0-9]*)-([0-9]*).* viewforum.php?f=$1&topicdays=$2&start=$3 [L,NC]
RewriteRule ^ptopic([0-9]*).* viewtopic.php?t=$1&view=previous [L,NC]
RewriteRule ^ntopic([0-9]*).* viewtopic.php?t=$1&view=next [L,NC]
RewriteRule ^ara-([0-9]*)-([0-9]*).html search.php?search_id=$1&start=$2 [L]
RewriteRule ^arama-yazar-([a-zA-Z0-9_-]*).html search.php?&search_author=$1 [L]
RewriteRule ^cevapsiz.html search.php?search_id=$1 [L]
RewriteRule ^yeni-kayit.html profile.php?mode=register&agreed=true [L]
RewriteRule ^kayit-coppa.html profile.php?mode=register&agreed=true&coppa=true [L]
RewriteRule ^kayit.html profile.php?&mode=register [L]
RewriteRule ^bilgiduzenle.html profile.php?mode=editprofile [L]
RewriteRule ^uye-([0-9]*).html profile.php?mode=viewprofile&u=$1 [L]
RewriteRule ^kayipsifre.html profile.php?mode=sendpassword [L]
RewriteRule ^kategori-([0-9]*).html index.php\?c=$1 [L]
RewriteRule ^uyelistesi-([a-zA-Z0-9]*)-([a-zA-Z]*)-([0-9]*).html memberlist.php\?mode=$1&order=$2&start=$3 [L]
RewriteRule ^uyelistesi.html memberlist.php [L]
RewriteRule ^sss-([a-zA-Z0-9]*).html faq.php\?mode=$1 [L]
RewriteRule ^sss.html faq.php [L]
RewriteRule ^sitemaps.xml$ sitemap.php [L]
RewriteRule ^sitemap-forum-([0-9]+).xml$ sitemap.php?fid=$1 [L]
RewriteRule ^sitemap-forum.xml$ sitemap.php?forum [L]
RewriteEngine On
RewriteCond %{HTTP_HOST} !^www\.lavinya\.net$ [NC]
RewriteRule ^(.*) http://www.lavinya.net$1 [QSA,L,R=301]
|
Now delete below code but no redirect adress
click to >> http://www.lavinya.org/phpBB2/about219.html
no redirect...
| Code: |
RewriteEngine On
RewriteCond %{HTTP_HOST} !^www\.lavinya\.net$ [NC]
RewriteRule ^(.*) http://www.lavinya.net/$1 [QSA,L,R=301]
|
|
|
|
| Back to top |
|
 |
dcz Administrateur - Site Admin

Joined: 28 Apr 2006 Posts: 13994
|
Posted: Thu Sep 07, 2006 6:01 pm Post subject: Re: Locking the www in urls |
|
|
Jeez, I had never paid too much attention to the able2know rewriterules, but it seems some are useless. It's a bit of topic but :
| Code: |
RewriteRule ^post-([0-9]*).html&highlight=([a-zA-Z0-9]*) viewtopic.php?p=$1&highlight=$2 [L,NC]
RewriteRule ^post-([0-9]*).* viewtopic.php?p=$1 [L,NC] |
Should just be :
| Code: | | RewriteRule ^post-([0-9]*).* viewtopic.php?p=$1 [QSA,L,NC] |
or even better :
| Code: |
RewriteRule ^post-([0-9]*)\.html viewtopic.php?p=$1 [QSA,L,NC] |
$highlight being here a $_GET var, it will be passed to the script with the QSA flag.
It's just more work for Apache for nothing.
So I think the only thing you need to do for the redirection to work across domains, is to delete your phpBB/ .htaccess and to add all the rewriterules that where in it in the root's one.
You'd need to add proper paths, so it would look like :
| Code: | AddType application/x-httpd-php .html .htm
ErrorDocument 404 /404.html
ErrorDocument 403 /403.html
RewriteEngine on
RewriteBase /
RewriteCond %{HTTP_REFERER} ^$
RewriteCond %{HTTP_USER_AGENT} ^$
RewriteCond %{REQUEST_URI} ^/$
RewriteRule ^/.* http://%{REMOTE_ADDR}/ [L,E=nolog:1]
RewriteCond %{HTTP_HOST} !^www\.lavinya\.net$ [NC]
RewriteRule ^(.*) http://www.lavinya.net/$1 [QSA,L,R=301]
RewriteRule ^phpBB2/forums.* phpBB2/index.php [L,NC]
RewriteRule ^phpBB2/post-([0-9]*).html&highlight=([a-zA-Z0-9]*) phpBB2/viewtopic.php?p=$1&highlight=$2 [L,NC]
RewriteRule ^phpBB2/post-([0-9]*).* phpBB2/viewtopic.php?p=$1 [L,NC]
RewriteRule ^phpBB2/view-poll([0-9]*)-([0-9]*)-([a-zA-Z]*).* phpBB2/viewtopic.php?t=$1&postdays=$2&postorder=$3&vote=viewresult [L,NC]
RewriteRule ^phpBB2/about([0-9]*).html&highlight=([a-zA-Z0-9]*) vviewtopic.php?t=$1&highlight=$2 [L,NC]
RewriteRule ^phpBB2/about([0-9]*).html&view=newest phpBB2/viewtopic.php?t=$1&view=newest [L,NC]
RewriteRule ^phpBB2/about([0-9]*)-([0-9]*)-([a-zA-Z]*)-([0-9]*).* phpBB2/viewtopic.php?t=$1&postdays=$2&postorder=$3&start=$4 [L,NC]
RewriteRule ^phpBB2/about([0-9]*)-([0-9]*).* phpBB2/viewtopic.php?t=$1&start=$2 [L,NC]
RewriteRule ^phpBB2/about([0-9]*).* phpBB2/viewtopic.php?t=$1 [L,NC]
RewriteRule ^phpBB2/about([0-9]*).html phpBB2/viewtopic.php?t=$1&start=$2&postdays=$3&postorder=$4&highlight=$5 [L,NC]
RewriteRule ^phpBB2/mark-forum([0-9]*).html* phpBB2/viewforum.php?f=$1&mark=topics [L,NC]
RewriteRule ^phpBB2/updates-topic([0-9]*).html* phpBB2/viewtopic.php?t=$1&watch=topic [L,NC]
RewriteRule ^phpBB2/phpBB2/stop-updates-topic([0-9]*).html* phpBB2/viewtopic.php?t=$1&unwatch=topic [L,NC]
RewriteRule ^phpBB2/forum-([0-9]*).html phpBB2/viewforum.php?f=$1 [L,NC]
RewriteRule ^phpBB2/forum-([0-9]*).* phpBB2/viewforum.php?f=$1 [L,NC]
RewriteRule ^phpBB2/topic-([0-9]*)-([0-9]*)-([0-9]*).* phpBB2/viewforum.php?f=$1&topicdays=$2&start=$3 [L,NC]
RewriteRule ^phpBB2/ptopic([0-9]*).* phpBB2/viewtopic.php?t=$1&view=previous [L,NC]
RewriteRule ^phpBB2/ntopic([0-9]*).* phpBB2/viewtopic.php?t=$1&view=next [L,NC]
RewriteRule ^phpBB2/ara-([0-9]*)-([0-9]*).html phpBB2/search.php?search_id=$1&start=$2 [L]
RewriteRule ^phpBB2/arama-yazar-([a-zA-Z0-9_-]*).html phpBB2/search.php?&search_author=$1 [L]
RewriteRule ^phpBB2/cevapsiz.html phpBB2/search.php?search_id=$1 [L]
RewriteRule ^phpBB2/yeni-kayit.html phpBB2/profile.php?mode=register&agreed=true [L]
RewriteRule ^phpBB2/kayit-coppa.html phpBB2/profile.php?mode=register&agreed=true&coppa=true [L]
RewriteRule ^phpBB2/kayit.html phpBB2/profile.php?&mode=register [L]
RewriteRule ^phpBB2/bilgiduzenle.html phpBB2/profile.php?mode=editprofile [L]
RewriteRule ^phpBB2/uye-([0-9]*).html phpBB2/profile.php?mode=viewprofile&u=$1 [L]
RewriteRule ^phpBB2/kayipsifre.html phpBB2/profile.php?mode=sendpassword [L]
RewriteRule ^phpBB2/kategori-([0-9]*).html phpBB2/index.php\?c=$1 [L]
RewriteRule ^phpBB2/uyelistesi-([a-zA-Z0-9]*)-([a-zA-Z]*)-([0-9]*).html phpBB2/memberlist.php\?mode=$1&order=$2&start=$3 [L]
RewriteRule ^phpBB2/uyelistesi.html vmemberlist.php [L]
RewriteRule ^phpBB2/sss-([a-zA-Z0-9]*).html phpBB2/faq.php\?mode=$1 [L]
RewriteRule ^phpBB2/sss.html phpBB2/faq.php [L]
RewriteRule ^phpBB2/sitemaps.xml$ phpBB2/sitemap.php [L]
RewriteRule ^phpBB2/sitemap-forum-([0-9]+).xml$ phpBB2/sitemap.php?fid=$1 [L]
RewriteRule ^phpBB2/sitemap-forum.xml$ phpBB2/sitemap.php?forum [L] |
This way you are sure the redirection will work for all sub folders, as long as they do not turn the rewrite engine on themselves.
It's no big deal to read a bigger .htaccess from root, the process is lite fast.
The other scenario, in which you'd repeat the redirection in every .htaccess should work, but you need to then replace :
| Code: | RewriteEngine On
RewriteBase /phpBB2/ |
with :
| Code: |
RewriteEngine On
RewriteBase /phpBB2/
RewriteCond %{HTTP_HOST} !^www\.lavinya\.net$ [NC]
RewriteRule ^(.*) http://www.lavinya.net$1 [QSA,L,R=301] |
in your original phpBB2/ .htaccess.
++ |
_________________ Useful links :
SEO Forum || SEO Directory || SEO phpBB || SEO phpBB3 || Search
____________________
Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Référencement phpBB3 || Recherche |
|
| Back to top |
|
 |
lavinya PR1


Joined: 24 Jul 2006 Posts: 159 Location: Turkey
|
Posted: Thu Sep 07, 2006 6:34 pm Post subject: Re: Locking the www in urls |
|
|
thanks dcz.
Added above code but
| Code: | | Internal Server Error |  |
|
|
| Back to top |
|
 |
dcz Administrateur - Site Admin

Joined: 28 Apr 2006 Posts: 13994
|
|
| Back to top |
|
 |
lavinya PR1


Joined: 24 Jul 2006 Posts: 159 Location: Turkey
|
Posted: Fri Sep 08, 2006 7:14 am Post subject: Re: Locking the www in urls |
|
|
big thanks dcz. my problem solved.
delete www.lavinya.net/phpBB2/ .htaccess
new create www.lavinya.net/ .htaccess
| Code: | AddType application/x-httpd-php .html .htm
ErrorDocument 404 /404.html
ErrorDocument 403 /403.html
RewriteEngine On
RewriteCond %{HTTP_HOST} !^www\.lavinya\.net$ [NC]
RewriteRule ^(.*) http://www.lavinya.net/$1 [QSA,L,R=301]
RewriteEngine On
RewriteRule ^phpBB2/forums.* phpBB2/index.php [L,NC]
RewriteRule ^phpBB2/post-([0-9]*).html&highlight=([a-zA-Z0-9]*) phpBB2/viewtopic.php?p=$1&highlight=$2 [L,NC]
RewriteRule ^phpBB2/post-([0-9]*).* phpBB2/viewtopic.php?p=$1 [L,NC]
RewriteRule ^phpBB2/view-poll([0-9]*)-([0-9]*)-([a-zA-Z]*).* phpBB2/viewtopic.php?t=$1&postdays=$2&postorder=$3&vote=viewresult [L,NC]
RewriteRule ^phpBB2/about([0-9]*).html&highlight=([a-zA-Z0-9]*) phpBB2/viewtopic.php?t=$1&highlight=$2 [L,NC]
RewriteRule ^phpBB2/about([0-9]*).html&view=newest phpBB2/viewtopic.php?t=$1&view=newest [L,NC]
RewriteRule ^phpBB2/about([0-9]*)-([0-9]*)-([a-zA-Z]*)-([0-9]*).* phpBB2/viewtopic.php?t=$1&postdays=$2&postorder=$3&start=$4 [L,NC]
RewriteRule ^phpBB2/about([0-9]*)-([0-9]*).* phpBB2/viewtopic.php?t=$1&start=$2 [L,NC]
RewriteRule ^phpBB2/about([0-9]*).* phpBB2/viewtopic.php?t=$1 [L,NC]
RewriteRule ^phpBB2/about([0-9]*).html phpBB2/viewtopic.php?t=$1&start=$2&postdays=$3&postorder=$4&highlight=$5 [L,NC]
RewriteRule ^phpBB2/mark-forum([0-9]*).html* phpBB2/viewforum.php?f=$1&mark=topics [L,NC]
RewriteRule ^phpBB2/updates-topic([0-9]*).html* phpBB2/viewtopic.php?t=$1&watch=topic [L,NC]
RewriteRule ^phpBB2/stop-updates-topic([0-9]*).html* phpBB2/viewtopic.php?t=$1&unwatch=topic [L,NC]
RewriteRule ^phpBB2/forum-([0-9]*).html phpBB2/viewforum.php?f=$1 [L,NC]
RewriteRule ^phpBB2/forum-([0-9]*).* phpBB2/viewforum.php?f=$1 [L,NC]
RewriteRule ^phpBB2/topic-([0-9]*)-([0-9]*)-([0-9]*).* phpBB2/viewforum.php?f=$1&topicdays=$2&start=$3 [L,NC]
RewriteRule ^phpBB2/ptopic([0-9]*).* phpBB2/viewtopic.php?t=$1&view=previous [L,NC]
RewriteRule ^phpBB2/ntopic([0-9]*).* phpBB2/viewtopic.php?t=$1&view=next [L,NC]
RewriteRule ^phpBB2/ara-([0-9]*)-([0-9]*).html phpBB2/search.php?search_id=$1&start=$2 [L]
RewriteRule ^phpBB2/arama-yazar-([a-zA-Z0-9_-]*).html phpBB2/search.php?&search_author=$1 [L]
RewriteRule ^phpBB2/cevapsiz.html phpBB2/search.php?search_id=$1 [L]
RewriteRule ^phpBB2/yeni-kayit.html phpBB2/profile.php?mode=register&agreed=true [L]
RewriteRule ^phpBB2/kayit-coppa.html phpBB2/profile.php?mode=register&agreed=true&coppa=true [L]
RewriteRule ^phpBB2/kayit.html phpBB2/profile.php?&mode=register [L]
RewriteRule ^phpBB2/bilgiduzenle.html phpBB2/profile.php?mode=editprofile [L]
RewriteRule ^phpBB2/uye-([0-9]*).html phpBB2/profile.php?mode=viewprofile&u=$1 [L]
RewriteRule ^phpBB2/kayipsifre.html phpBB2/profile.php?mode=sendpassword [L]
RewriteRule ^phpBB2/kategori-([0-9]*).html phpBB2/index.php\?c=$1 [L]
RewriteRule ^phpBB2/uyelistesi-([a-zA-Z0-9]*)-([a-zA-Z]*)-([0-9]*).html phpBB2/memberlist.php\?mode=$1&order=$2&start=$3 [L]
RewriteRule ^phpBB2/uyelistesi.html phpBB2/memberlist.php [L]
RewriteRule ^phpBB2/sss-([a-zA-Z0-9]*).html phpBB2/faq.php\?mode=$1 [L]
RewriteRule ^phpBB2/sss.html phpBB2/faq.php [L]
RewriteRule ^phpBB2/sitemaps.xml$ phpBB2/sitemap.php [L]
RewriteRule ^phpBB2/sitemap-forum-([0-9]+).xml$ phpBB2/sitemap.php?fid=$1 [L]
RewriteRule ^phpBB2/sitemap-forum.xml$ phpBB2/sitemap.php?forum [L] |
re thanks dcz. my footer add thanks to dcz in /phpBB2/
dcz
this code
| Code: | RewriteRule ^post-([0-9]*).html&highlight=([a-zA-Z0-9]*) viewtopic.php?p=$1&highlight=$2 [L,NC]
RewriteRule ^post-([0-9]*).* viewtopic.php?p=$1 [L,NC] |
replace with to
| Code: | | RewriteRule ^post-([0-9]*)\.html viewtopic.php?p=$1 [QSA,L,NC] |
correct ???
and QSA flag what mean ? |
|
|
| Back to top |
|
 |
AmirAbbas phpBB SEO Team


Joined: 11 May 2006 Posts: 529 Location: IRAN
|
|
| Back to top |
|
 |
dcz Administrateur - Site Admin

Joined: 28 Apr 2006 Posts: 13994
|
Posted: Fri Sep 08, 2006 7:30 am Post subject: Re: Locking the www in urls |
|
|
| lavinya wrote: |
re thanks dcz. my footer add thanks to dcz in /phpBB2/
dcz
this code
| Code: | RewriteRule ^post-([0-9]*).html&highlight=([a-zA-Z0-9]*) viewtopic.php?p=$1&highlight=$2 [L,NC]
RewriteRule ^post-([0-9]*).* viewtopic.php?p=$1 [L,NC] |
replace with to
| Code: | | RewriteRule ^post-([0-9]*)\.html viewtopic.php?p=$1 [QSA,L,NC] |
correct ???
and QSA flag what mean ? |
Cool
QSA stands for Query String Append, it's just an option to make sure additional $_GET vars that could be in the requested URI will be passed to the script.
So there is no need to add vars like $highlight in the left part of the rewriterules.
You can implement the change, don't forget the paths though
There would be some more small optimizations doable in your .htaccess, we can look at it in the Apache mod rewrite forum if you like.
++ |
_________________ Useful links :
SEO Forum || SEO Directory || SEO phpBB || SEO phpBB3 || Search
____________________
Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Référencement phpBB3 || Recherche |
|
| Back to top |
|
 |
|
|
| Navigation |
Similar Topics |
|
|
|
|
|
|
|