Announcement

Collapse
No announcement yet.

[RELEASE] Spider friendly URLs

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • [RELEASE] Spider friendly URLs

    For vB 2.0

    This little hackette is a quick fix to allow search engine bots to spider your threads.

    Although this will allow the bots to index every thread on your site, it will not make the threads 'search engine optimized'. They will see exactly what you see when you visit your site. It simply removes the CGI bits from the URL's which prevents most search engine bots from spidering more than one level deep.

    If you want a hack that allows to fully customize how the thread will look to the search engine bot, you should look at Overgrows more complete hack here.

    The advantage of this hack over Overgrows is that it does not require htaccess support which can have performance issues. This could also be seen as a disadvantage though as my hack requires that you have mod_rewrite enabled on your Apache Server, whereas Overgrows method should work with just about any web host out there.

    Take yer pick
    Last edited by fastforward; Sun 1st Jul '01, 10:43am.
    http://britishexpats.com/ - British expatriate community

  • #2
    got a demo/example url for us ?
    :: Always Back Up Forum Database + Attachments BEFORE upgrading !
    :: Nginx SPDY SSL - World Flags Demo [video results]
    :: vBulletin hacked forums: Clean Up Guide for VPS/Dedicated hosting users [ vbulletin.com blog summary ]

    Comment


    • #3
      Originally posted by eva2000
      got a demo/example url for us ?
      http://dbforums.com

      You can see the forum links on the front page are like :

      http://dbforums.com/f5/s



      and the threads are like:

      http://dbforums.com/t44153/s.html
      http://britishexpats.com/ - British expatriate community

      Comment


      • #4
        Hey very cool.. I haven't looked at the code yet, but nice job.

        One note though: The main point of my hack is getting Google to the archives, not really friendly URLs.. that was just a sidenote. The archiving is what I'm after.
        vB Retro -> See vBulletin 1.1.2 and travel back to the Year 2000!
        Overgrow the Government: The Edge Forums
        presented by Overgrow Marijuana Magazine


        *warning: adult content since vB1.1... now faster than ever!

        Comment


        • #5
          yeah cool but do normal showthreads and forumdisplay urls still work ?

          i.e would a url like http://animeboards.com/forumdisplay.php?s=&forumid=2 still work as well as

          http://animeboards.com/f2/s ?
          :: Always Back Up Forum Database + Attachments BEFORE upgrading !
          :: Nginx SPDY SSL - World Flags Demo [video results]
          :: vBulletin hacked forums: Clean Up Guide for VPS/Dedicated hosting users [ vbulletin.com blog summary ]

          Comment


          • #6
            Originally posted by eva2000
            yeah cool but do normal showthreads and forumdisplay urls still work ?

            i.e would a url like http://animeboards.com/forumdisplay.php?s=&forumid=2 still work as well as

            http://animeboards.com/f2/s ?
            hehe. Oh ye of little faith

            Yeah they do.

            The only urls that are trapped by the mod_rewrite directives are ones that match one of these three expressions:
            Code:
            ^/f([0-9]+)/s([^/]+?)$
            ^/t([0-9]+)/s([^/]+?)\.html$
            ^/s([^/])+?/$
            ie.
            /f234/s or /f234/s345345detr3
            /t2343/s.html or /t2343/s435345.html
            /s/ or /s435345345dfsdf/

            Actually I need to clarify in the docs that this assumes your forums are in the web root. Those directives should be prefixed with /forums/ or wherever if your vB is installed elsewhere.
            Last edited by fastforward; Fri 25th May '01, 5:29pm.
            http://britishexpats.com/ - British expatriate community

            Comment


            • #7
              cool.. yet another hack i'm gonna add hehe
              :: Always Back Up Forum Database + Attachments BEFORE upgrading !
              :: Nginx SPDY SSL - World Flags Demo [video results]
              :: vBulletin hacked forums: Clean Up Guide for VPS/Dedicated hosting users [ vbulletin.com blog summary ]

              Comment


              • #8
                oh wait any problems you can see running both overgrow's search engine spidering hack and yours together ? i also use htacess to use mod_rewrite to prevent hot linking of my forum images
                :: Always Back Up Forum Database + Attachments BEFORE upgrading !
                :: Nginx SPDY SSL - World Flags Demo [video results]
                :: vBulletin hacked forums: Clean Up Guide for VPS/Dedicated hosting users [ vbulletin.com blog summary ]

                Comment


                • #9
                  Originally posted by eva2000
                  oh wait any problems you can see running both overgrow's search engine spidering hack and yours together ? i also use htacess to use mod_rewrite to prevent hot linking of my forum images
                  No problems at all. I just installed Overgrows

                  http://dbforums.com/archive/

                  I did make one change to Overgrows though so that I wouldn't need to use .htaccess files. I deleted the .htaccess and added this to my httpd.conf:
                  Code:
                  RewriteRule ^/archive/.* /archive/index.php [L]
                  But either method will work.
                  http://britishexpats.com/ - British expatriate community

                  Comment


                  • #10
                    Originally posted by fastforward

                    No problems at all. I just installed Overgrows

                    http://dbforums.com/archive/

                    I did make one change to Overgrows though so that I wouldn't need to use .htaccess files. I deleted the .htaccess and added this to my httpd.conf:
                    Code:
                    RewriteRule ^/archive/.* /archive/index.php [L]
                    But either method will work.
                    okay great then
                    :: Always Back Up Forum Database + Attachments BEFORE upgrading !
                    :: Nginx SPDY SSL - World Flags Demo [video results]
                    :: vBulletin hacked forums: Clean Up Guide for VPS/Dedicated hosting users [ vbulletin.com blog summary ]

                    Comment


                    • #11
                      okay i already have mod_rewrite so what do i do for the first step something like this ?

                      <VirtualHost 157.238.46.185>
                      ServerAdmin [email protected]
                      DocumentRoot /home/usr1/public_html
                      BytesLog domlogs/animeboards.net-bytes_log
                      ServerName www.animeboards.net
                      ServerAlias animeboards.com *.animeboards.com
                      CustomLog domlogs/animeboards.net combined
                      ScriptAlias /cgi-bin/ /home/usr1/public_html/cgi-bin/
                      RewriteEngine on
                      RewriteRule ^/f([0-9]+)/s([^/]+?)$ /forumdisplay.php?forumid=$1&s=$2 [L]
                      RewriteRule ^/t([0-9]+)/s([^/]+?)\.html$ /showthread.php?threadid=$1&s=$2 [L]
                      RewriteRule ^/s([^/])+?/$ /index.php?s=$1 [L]
                      </VirtualHost>
                      :: Always Back Up Forum Database + Attachments BEFORE upgrading !
                      :: Nginx SPDY SSL - World Flags Demo [video results]
                      :: vBulletin hacked forums: Clean Up Guide for VPS/Dedicated hosting users [ vbulletin.com blog summary ]

                      Comment


                      • #12
                        That's correct as long as your foums are in the web root. If not, you need to change those to something like:
                        Code:
                        RewriteRule ^/forums/t([0-9]+)/s([^/]+?)\.html$ /showthread.php?threadid=$1&s=$2 [L]
                        http://britishexpats.com/ - British expatriate community

                        Comment


                        • #13
                          okay gonna implement this now hehe
                          :: Always Back Up Forum Database + Attachments BEFORE upgrading !
                          :: Nginx SPDY SSL - World Flags Demo [video results]
                          :: vBulletin hacked forums: Clean Up Guide for VPS/Dedicated hosting users [ vbulletin.com blog summary ]

                          Comment


                          • #14
                            okay installed one problem i sthe showthread links for

                            Go to first unread post go to

                            http://animeboards.com/# now
                            also

                            Admin options for

                            split

                            merge

                            move

                            stick/unstick threads all don't work

                            as well as view mod queue, view attachment queue etc

                            they are redirect to my front page since i have an htaccess for error redirects to my front page
                            Last edited by George L; Fri 25th May '01, 8:48pm.
                            :: Always Back Up Forum Database + Attachments BEFORE upgrading !
                            :: Nginx SPDY SSL - World Flags Demo [video results]
                            :: vBulletin hacked forums: Clean Up Guide for VPS/Dedicated hosting users [ vbulletin.com blog summary ]

                            Comment


                            • #15
                              Originally posted by eva2000
                              okay installed one problem i sthe showthread links for

                              Go to first unread post go to

                              http://animeboards.com/# now
                              Not sure what you mean here.
                              also

                              Admin options for

                              split

                              merge

                              move

                              stick/unstick threads all don't work

                              as well as view mod queue, view attachment queue etc

                              they are redirect to my front page since i have an htaccess for error redirects to my front page
                              I really can't see how the changes could in anyway affect these. You did only change the links in the forumhome and forumdisplay templates right?

                              The links you're talking about don't even point to pages that use these templates. they are still in their original form and point to postings.php.
                              http://britishexpats.com/ - British expatriate community

                              Comment

                              widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
                              Working...
                              X