New Posts
Welcome guest, is this your first visit?
  • Login:
CakePoker.com Affiliate Program
+ Reply to Thread
Results 1 to 6 of 6
  1. #1
    PENQUIN
    Go F@@K Yourself
     

    Add as a friend
    Join Date
    Nov 2008
    Location
    Canada
    Posts
    2,375
    Blog Entries
    1
    Feedback Score
    60 (100%)

    Default Need some help with redirect 301

    Hi there,

    I recently decided it was better for me to have urls that do not have /index.php/ in them.

    In google all my indexed pages have the index.php in them.

    Now i have altered my .htaccess code to change all new content added to have the proper links.

    Most of the site now is without the index.php code in it.

    But within content when i user clicks on a link that i had the index.php code in it, it goes to a 404 page error.

    Rather than me create custom redirects for 100s of pages, is there a way that i can add a code in .htaccess that will know that if it has that code index.php in it should just remove that part and use the url without it.

    Also in google the pages that were sucessfully changed on my site lost page rank with the new url, how can i fix this to keep my page ranks.

    Or do i need to custom change every single url with index.php and takes days to do it?

    Desperate for some help here.

    Steve
    Play Poker Online with some of best poker rooms in the business.
    __________________
    bwin - Rogue
    Learn why Bewinners is a predatory affiliate program.

  2. #2
    Member
    My Status
     

    Add as a friend
    Join Date
    Nov 2008
    Location
    USA
    Posts
    75
    Feedback Score
    1 (100%)

    Default

    I posted in the other thread too but try this rewrite:

    RewriteRule ^index.php/(.*) $1 [R=301,L]

  3. #3
    PENQUIN
    Go F@@K Yourself
     

    Add as a friend
    Join Date
    Nov 2008
    Location
    Canada
    Posts
    2,375
    Blog Entries
    1
    Feedback Score
    60 (100%)

    Default

    Quote Originally Posted by MewsicLovr View Post
    I posted in the other thread too but try this rewrite:

    RewriteRule ^index.php/(.*) $1 [R=301,L]

    Oh my God mate it worked. Oh man you saved me so much time. All my indexed links seem to work like a charm...

    That's was just such a valuable piece of work there thank you so so so much!!


    Do you think thats all i need? I just added it to the last line of my .htaccess after everything else..

    Most comments in that area have more than a one liner to redirect urls like a condition sentence..

    But this does work for all internal and links.. and also google indexed pages.

    Do you think its still wise to to alter the links on site to make them the new url structure, or is this not needed as long as i have the code in .htaccess?

    Man this is sweet.



    Steve
    Play Poker Online with some of best poker rooms in the business.
    __________________
    bwin - Rogue
    Learn why Bewinners is a predatory affiliate program.

  4. #4
    Member
    My Status
     

    Add as a friend
    Join Date
    Nov 2008
    Location
    USA
    Posts
    75
    Feedback Score
    1 (100%)

    Default

    It is supposed to only rewrite url's that have the index.php/<something>, I sent you a PM as well, the one I sent probably needs tweaking to:

    RewriteRule ^index.php/(.+) $1 [R=301,L]

    So that something must be after index.php...also this will need to be placed higher in your rules before it gets to other processing.

    Sometimes it is better to have individual rules, but if you can find a single statement that applies to all of them then it's much easier to use that. The trick is finding it. If it makes you feel better I have literally hundreds of custom rewrites in my own htaccess, Randy likes changing URL structures on me

  5. #5
    PENQUIN
    Go F@@K Yourself
     

    Add as a friend
    Join Date
    Nov 2008
    Location
    Canada
    Posts
    2,375
    Blog Entries
    1
    Feedback Score
    60 (100%)

    Default

    Quote Originally Posted by MewsicLovr View Post
    It is supposed to only rewrite url's that have the index.php/<something>, I sent you a PM as well, the one I sent probably needs tweaking to:

    RewriteRule ^index.php/(.+) $1 [R=301,L]

    So that something must be after index.php...also this will need to be placed higher in your rules before it gets to other processing.

    Sometimes it is better to have individual rules, but if you can find a single statement that applies to all of them then it's much easier to use that. The trick is finding it. If it makes you feel better I have literally hundreds of custom rewrites in my own htaccess, Randy likes changing URL structures on me
    Oh wow.. lol yeah i hear you. No i just wanted the single index.php gone.

    I think you have done the trick. I did it exactly as you said, and i have checked various links.. all work so far..

    i will keep testing it.. to make sure.. but so far so good...

    i guess its best to actually chage all urls anyway to correct ones i would imagine?

    so that if you take out the re write rule it will work flawlessly.. abd eventually google will drop old urls anyway..

    lets see how goes.. thank you so much for your help, your amazing dude!!

    I feel so happy you helped me out.. i owe you!!!

    Steve
    Play Poker Online with some of best poker rooms in the business.
    __________________
    bwin - Rogue
    Learn why Bewinners is a predatory affiliate program.

  6. #6
    PENQUIN
    Go F@@K Yourself
     

    Add as a friend
    Join Date
    Nov 2008
    Location
    Canada
    Posts
    2,375
    Blog Entries
    1
    Feedback Score
    60 (100%)

    Default

    By the way in case anyone has this issue as well. I also tried another code to get ride of the index.php.. Maybe it could help someone else.

    RedirectMatch 301 ^/index.php(/.*)$ http://www.example.com$1

    That also seems to work.

    Steve
    Play Poker Online with some of best poker rooms in the business.
    __________________
    bwin - Rogue
    Learn why Bewinners is a predatory affiliate program.


 

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

     

Similar Threads

  1. Redirect or Not?
    By kushmoney in forum Poker SEO Forum
    Replies: 1
    Last Post: 06-10-2010, 03:31 PM
  2. 301 Redirect Help
    By KevinMcC in forum Wordpress - Web Design - Coding - Technical
    Replies: 4
    Last Post: 07-10-2009, 08:39 AM
  3. 301 Redirect Help
    By Ridge in forum Poker SEO Forum
    Replies: 0
    Last Post: 04-06-2009, 05:20 PM
  4. A redirect
    By Newjabber in forum Poker SEO Forum
    Replies: 2
    Last Post: 12-17-2008, 09:16 AM
  5. 302 redirect code
    By Jeremy in forum Poker SEO Forum
    Replies: 11
    Last Post: 11-19-2008, 07:08 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
Powered by vBulletin® Version 4.1.5
Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.
SEO by vBSEO 3.6.0
Affiliate Program Consultant