phpBB SEO
Boards
Directory  
SEO  
Downloads
  phpBB SEO : Search Engine Optimization, Directory, Forums  
Index
Forums
Annuaire
Référencement
Télécharger
 
  Search Rechercher
    Register
Username :  Password :  Log me on automatically each visit  
S'enregistrer  
 
   
extra mod_rewrite with advanced seo and zero dupe
Goto page 1, 2  Next
 
Post new topic   Reply to topic    phpBB SEO » SEO Forum  » phpBB mod Rewrite  » Advanced mod Rewrite
::  
Author Message
lavinya
PR1
PR1


Joined: 24 Jul 2006
Posts: 159
Location: Turkey

extra mod_rewrite with advanced seo and zero dupePosted: Wed Feb 07, 2007 6:36 pm    Post subject: extra mod_rewrite with advanced seo and zero dupe

hello.
I using
phpBB SEO Advanced mod Rewrite 0.2.2
phpBB SEO Zero duplicate - phpBB SEO Advanced mod Rewrite version 0.2.2


How to rewrite urls?
(display link and redirect old url)


Code:
profile.php?mode=register&agreed=true >>  yeni-kayit.html
profile.php?mode=register&agreed=true&coppa=true >> kayit-coppa.html
profile.php?&mode=register >> kayit.html
profile.php?mode=sendpassword >> kayipsifre.html


thanks.
Back to top
Visit poster's website
AmirAbbas
phpBB SEO Team
phpBB SEO Team


Joined: 11 May 2006
Posts: 529
Location: IRAN

extra mod_rewrite with advanced seo and zero dupePosted: Thu Feb 08, 2007 5:08 am    Post subject: Re: extra mod_rewrite with advanced seo and zero dupe

hi lavinya

i think rewriting that URLs are not valuable
you must ban all of that URLs with robots.txt file because that links are not contain any valuable informations for indexing.

Code:
User-agent: *
Disallow: /profile.php?


for example the profile.php URLs are banned here

http://www.phpbb-seo.com/boards/robots.txt

you can rewrite them but rewriting that links only waste the server resources
Rolling Eyes

_________________
چهار گوش - طراحی وب - مجله طراحی وب
Back to top
Visit poster's website
lavinya
PR1
PR1


Joined: 24 Jul 2006
Posts: 159
Location: Turkey

extra mod_rewrite with advanced seo and zero dupePosted: Thu Feb 08, 2007 9:53 am    Post subject: Re: extra mod_rewrite with advanced seo and zero dupe

thanks amir abbas ok.


Last edited by lavinya on Thu Feb 08, 2007 11:33 am; edited 1 time in total
Back to top
Visit poster's website
dcz
Administrateur - Site Admin
Administrateur - Site Admin


Joined: 28 Apr 2006
Posts: 14279

extra mod_rewrite with advanced seo and zero dupePosted: Thu Feb 08, 2007 10:30 am    Post subject: Re: extra mod_rewrite with advanced seo and zero dupe

If you really want though, it's very possible.

Amir is right these are not SEO valuable, but, if you where previously using them ...

So please tell me what would you like to do.

++

_________________
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
Visit poster's website
MorYeL
phpBB SEO Team
phpBB SEO Team


Joined: 11 Aug 2006
Posts: 99

extra mod_rewrite with advanced seo and zero dupePosted: Thu Feb 08, 2007 11:48 am    Post subject: Re: extra mod_rewrite with advanced seo and zero dupe

Hi to all... Dcz, lavinya said that ;

I am using able2know now. url seems
Code:
profile.php?mode=register&agreed=true
but I want it be to
Code:
yeni-kayit.html


And the others are should be:

Code:
profile.php?mode=register&agreed=true&coppa=true
to
Code:
kayit-coppa.html

Code:
profile.php?&mode=register
to
Code:
kayit.html
Code:
profile.php?mode=sendpassword
to
Code:
kayipsifre.html


How can we do this...

He said Wink
Back to top
Visit poster's website
dcz
Administrateur - Site Admin
Administrateur - Site Admin


Joined: 28 Apr 2006
Posts: 14279

extra mod_rewrite with advanced seo and zero dupePosted: Thu Feb 08, 2007 11:54 am    Post subject: Re: extra mod_rewrite with advanced seo and zero dupe

This I know Wink

Quote:
So please tell me what would you like to do.


Wink

_________________
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
Visit poster's website
lavinya
PR1
PR1


Joined: 24 Jul 2006
Posts: 159
Location: Turkey

extra mod_rewrite with advanced seo and zero dupePosted: Thu Feb 08, 2007 11:57 am    Post subject: Re: extra mod_rewrite with advanced seo and zero dupe

dcz example forum:
www.lavinya.net/phpBB2/

but register url(üye ol): http://www.lavinya.net/phpBB2/kayit.html
and other above link.

i this week migrate to
phpBB SEO Advanced mod Rewrite 0.2.2
phpBB SEO Zero duplicate - phpBB SEO Advanced mod Rewrite version 0.2.2
Back to top
Visit poster's website
MorYeL
phpBB SEO Team
phpBB SEO Team


Joined: 11 Aug 2006
Posts: 99

extra mod_rewrite with advanced seo and zero dupePosted: Thu Feb 08, 2007 12:03 pm    Post subject: Re: extra mod_rewrite with advanced seo and zero dupe

MorYeL wrote:
Hi to all... Dcz, lavinya said that ;

I am using able2know now. url seems
Code:
profile.php?mode=register&agreed=true
but I want it be to
Code:
yeni-kayit.html


And the others are should be:

Code:
profile.php?mode=register&agreed=true&coppa=true
to
Code:
kayit-coppa.html

Code:
profile.php?&mode=register
to
Code:
kayit.html
Code:
profile.php?mode=sendpassword
to
Code:
kayipsifre.html


How can we do this...

He said Wink


We want to migrate this to phpBB SEO Advanced mod Rewrite 0.2.2
phpBB SEO Zero duplicate - phpBB SEO Advanced mod Rewrite version 0.2.2
Back to top
Visit poster's website
dcz
Administrateur - Site Admin
Administrateur - Site Admin


Joined: 28 Apr 2006
Posts: 14279

extra mod_rewrite with advanced seo and zero dupePosted: Thu Feb 08, 2007 12:40 pm    Post subject: Re: extra mod_rewrite with advanced seo and zero dupe

All right Wink

Open :

Code:
phpbb_seo/phpbb_seo_class.php


Find :

Code:
   function profile() {
      if ( !empty($this->get_vars[POST_USERS_URL]) && $this->get_vars['mode'] === 'viewprofile') {
         $this->url =  $this->seo_static['user'] . $this->get_vars[POST_USERS_URL] . $this->seo_ext['user'];
         unset($this->get_vars[POST_USERS_URL]);
         unset($this->get_vars['mode']);
      }
      return;
   }


Replace with :

Code:
   function profile() {
      if ( !empty($this->get_vars[POST_USERS_URL]) && $this->get_vars['mode'] === 'viewprofile') {
         $this->url =  $this->seo_static['user'] . $this->get_vars[POST_USERS_URL] . $this->seo_ext['user'];
         unset($this->get_vars[POST_USERS_URL]);
         unset($this->get_vars['mode']);
         return;
      } elseif ($this->get_vars['mode'] === 'register' ) {
         if ($this->get_vars['agreed'] === 'true' && $this->get_vars['coppa'] === 'true' ) {
            $this->url =  'kayit-coppa.html';
            unset($this->get_vars['agreed']);
            unset($this->get_vars['coppa']);
         } else {
            $this->url =  'kayit.html';
         }
         unset($this->get_vars['mode']);
         return;
      } elseif ($this->get_vars['mode'] === 'sendpassword' ) {
         $this->url =  'kayipsifre.html';
         unset($this->get_vars['mode']);
      }
      return;
   }


Should do it Wink

++

_________________
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
Visit poster's website
lavinya
PR1
PR1


Joined: 24 Jul 2006
Posts: 159
Location: Turkey

extra mod_rewrite with advanced seo and zero dupePosted: Thu Feb 08, 2007 12:41 pm    Post subject: Re: extra mod_rewrite with advanced seo and zero dupe

Shocked Million thanks admin Smile

ok. works.


Last edited by lavinya on Thu Feb 08, 2007 3:56 pm; edited 1 time in total
Back to top
Visit poster's website
MorYeL
phpBB SEO Team
phpBB SEO Team


Joined: 11 Aug 2006
Posts: 99

extra mod_rewrite with advanced seo and zero dupePosted: Thu Feb 08, 2007 3:34 pm    Post subject: Re: extra mod_rewrite with advanced seo and zero dupe

We have migrated it to advanced seo and zero duplucate... When we login from able2know there is 404 error...!!! And the address is seeming like
Code:
http://www.lavinya.net/phpBB2/http://www.lavinya.net/phpBB2/?sid=516dd146a190e4d5d409c433f95bdda0
...

And admin page's url is :

Code:
http://www.lavinya.net/phpBB2/admin/http://www.lavinya.net/phpBB2/?admin=1&sid=47294baef2741e24c3df5119dde5e9cd
Back to top
Visit poster's website
MorYeL
phpBB SEO Team
phpBB SEO Team


Joined: 11 Aug 2006
Posts: 99

extra mod_rewrite with advanced seo and zero dupePosted: Thu Feb 08, 2007 4:26 pm    Post subject: Re: extra mod_rewrite with advanced seo and zero dupe

approve mod was like viewtopic.php?p=47956&app_p=48911#48911 but it is like şimdi post48911.html?app_p=48911#48911 and when click it, it doesn't working. http://www.phpbb.com/phpBB/viewtopic.php?p=2183442 I installed this mode... http://www.phpbb.com/phpBB/viewtopic.php?p=2183442

And I will install http://www.phpbb.com/phpBB/viewtopic.php?t=444640 this mod in the future...
Back to top
Visit poster's website
dcz
Administrateur - Site Admin
Administrateur - Site Admin


Joined: 28 Apr 2006
Posts: 14279

extra mod_rewrite with advanced seo and zero dupePosted: Thu Feb 08, 2007 4:30 pm    Post subject: Re: extra mod_rewrite with advanced seo and zero dupe

As the zero dupe is up and running : http://www.lavinya.net/phpBB2/very-big-dupe-f2.html

My bet is you put a R=301 flag in the able2know rewriterules and you should not.

Could you start another topic if you need more support on this, and post you .htaccess if needed ?

++

_________________
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
Visit poster's website
MorYeL
phpBB SEO Team
phpBB SEO Team


Joined: 11 Aug 2006
Posts: 99

extra mod_rewrite with advanced seo and zero dupePosted: Thu Feb 08, 2007 4:46 pm    Post subject: Re: extra mod_rewrite with advanced seo and zero dupe

The .htaccess is:

Code:
RewriteEngine On
RewriteBase /phpBB2/

#########################################################
# PHPBB SEO REWRITE RULES            #
#########################################################
# AUTHOR : dcz http://www.phpbb-seo.com/
# STARTED : 01/2006
#####################################################
# FORUMS PAGES
########################
# FORUM INDEX (un-comment if used)
# RewriteRule ^index\.html$ index.php [QSA,L]
# FORUM PROTECTION RULE
#RewriteRule ^.+/([^/]+\.html)$ index.php [R=301,L]
# CATEGORIES
RewriteRule ^.*-c([0-9]+)\.html$ index.php?c=$1 [QSA,L]
# PAGINATED FORUM
RewriteRule ^.*-f([0-9]+)-([0-9]+)\.html$ viewforum.php?f=$1&start=$2 [QSA,L]
# FORUM
RewriteRule ^.*-f([0-9]+)\.html$ viewforum.php?f=$1 [QSA,L]
# PAGINATED TOPIC
RewriteRule ^.*-t([0-9]+)-([0-9]+)\.html$ viewtopic.php?t=$1&start=$2 [QSA,L]
# TOPIC
RewriteRule ^.*-t([0-9]+)\.html$ viewtopic.php?t=$1 [QSA,L]
# POST
RewriteRule ^post([0-9]+)\.html$ viewtopic.php?p=$1 [QSA,L]
#PROFILES
RewriteRule ^uye-([0-9]+)\.html$ profile.php?mode=viewprofile&u=$1 [QSA,L]
# END PHPBB PAGES
#####################################################
RewriteRule ^post-([0-9]*)\.html 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 [QSA,L]
RewriteRule ^arama-yazar-([a-zA-Z0-9_-]*).html search.php?&search_author=$1 [QSA,L]
RewriteRule ^cevapsiz.html search.php?search_id=$1 [QSA,L]
RewriteRule ^yeni-kayit.html profile.php?mode=register&agreed=true [QSA,L]
RewriteRule ^kayit-coppa.html profile.php?mode=register&agreed=true&coppa=true [QSA,L]
RewriteRule ^kayit.html profile.php?&mode=register [QSA,L]
RewriteRule ^bilgiduzenle.html profile.php?mode=editprofile [QSA,L]
RewriteRule ^kayipsifre.html profile.php?mode=sendpassword [QSA,L]
RewriteRule ^kategori-([0-9]*).html index.php\?c=$1 [QSA,L]
RewriteRule ^sss-([a-zA-Z0-9]*).html faq.php\?mode=$1 [QSA,L]
RewriteRule ^sss.html faq.php [QSA,L]
RewriteRule ^arama.htm search.php [QSA,L]

RewriteRule ^emaill-(.*).jpg email.php?adres=$1
RewriteRule ^emaill-(.*).gif email.php?adres=$1
Back to top
Visit poster's website
dcz
Administrateur - Site Admin
Administrateur - Site Admin


Joined: 28 Apr 2006
Posts: 14279

extra mod_rewrite with advanced seo and zero dupePosted: Thu Feb 08, 2007 5:00 pm    Post subject: Re: extra mod_rewrite with advanced seo and zero dupe

All right .htaccess is ok.

For the approve mod we'll really deal with it in the zero dupe forum this time Wink

So, it then looks like the forum url is added twice for these links, I got wrong because you talked about abl2know redirections, and as a matter of fact they work perfecty : http://www.lavinya.net/phpBB2/about293.html

So it can be just that you hard coded the full phpBB url in the template or in the php code.

The problem occurs in the redirect() function, in includes/function.php.

If the full url was added in the php code, as it seems, you could do the following; open :


Code:
includes/function.php


Find :

Code:
function redirect($url)
{
   global $db, $board_config;

After add :

Code:
   // www.phpBB-SEO.com SEO TOOLKIT BEGIN
   global $phpbb_seo;
   // www.phpBB-SEO.com SEO TOOLKIT END


Find :
Code:

   if (strstr(urldecode($url), "\n") || strstr(urldecode($url), "\r") || strstr(urldecode($url), ';url'))
   {
      message_die(GENERAL_ERROR, 'Tried to redirect to potentially insecure url.');
   }


After add :

Code:
// www.phpBB-SEO.com SEO TOOLKIT BEGIN
if ( strpos($url, $phpbb_seo->seo_path['phpbb_url']) === FALSE ) {


Find :

Code:
   $url = preg_replace('#^\/?(.*?)\/?$#', '/\1', trim($url));


After add :

Code:
} else {
   $server_protocol = $server_name = $server_port = $script_name = '';
}
// www.phpBB-SEO.com SEO TOOLKIT END


This will allow the redirect function to only add the full url when it was not already added.
Note that this is inteded to wrok with the 0.2.2 and above mod rewrites.

++

_________________
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
Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    phpBB SEO » SEO Forum  » phpBB mod Rewrite  » Advanced mod Rewrite
Page 1 of 2 Goto page 1, 2  Next

Navigation Similar Topics

Jump to: