Scripting Gurus! Help please!

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Tala
    Fucked if I know
    • Dec 2002
    • 23368

    #1

    Scripting Gurus! Help please!

    I need a code of some sort that reads the user's browser and redirects the user to an area of the site made specifically for that type of browser.

    Example: User A is using a desktop with Nutscrape and User B is using a Palm Pilot with a wireless browser. I need to redirect User B to a wireless area of my site.

    Help!

    ICQ: 11120676 | Google: mindcrime | Skype: suitemindcrime|E-Mail: mindcrime AT gmail.com|PR girl with great writing skills for hire!!!! Contact me to work for YOU!|TECHIEMEDIA? 24/7 support from some of the best techs in the biz. Tell Jim that I sent you.
  • Tala
    Fucked if I know
    • Dec 2002
    • 23368

    #2
    BuMp

    ICQ: 11120676 | Google: mindcrime | Skype: suitemindcrime|E-Mail: mindcrime AT gmail.com|PR girl with great writing skills for hire!!!! Contact me to work for YOU!|TECHIEMEDIA? 24/7 support from some of the best techs in the biz. Tell Jim that I sent you.

    Comment

    • fuzebox
      making it rain
      • Oct 2003
      • 22352

      #3
      I can do this in PHP fairly easily.

      (see sig)

      Comment

      • swedguy
        Confirmed User
        • Jan 2002
        • 7981

        #4
        http://www.google.com/search?sourcei...direct+browser

        Comment

        • swedguy
          Confirmed User
          • Jan 2002
          • 7981

          #5
          http://www.google.com/search?num=30&...TTP_USER_AGENT

          Comment

          • fuzebox
            making it rain
            • Oct 2003
            • 22352

            #6
            Own3d by emb.ed protection again!

            Doing this with java.script is a hack anyway.

            Comment

            • icedemon
              Confirmed User
              • Jun 2003
              • 1022

              #7
              If the server is using Apache, you can just use Mod_Rewrite in a .htaccess file.

              For example:
              Code:
              RewriteEngine on
              
              RewriteCond %{HTTP_USER_AGENT}  ^Mozilla/3.*
              RewriteRule ^foo\.html$         foo.NS.html          [L]
              
              RewriteCond %{HTTP_USER_AGENT}  ^Lynx/.*         [OR]
              RewriteCond %{HTTP_USER_AGENT}  ^Mozilla/[12].*
              RewriteRule ^foo\.html$         foo.20.html          [L]
              
              RewriteRule ^foo\.html$         foo.32.html          [L]
              Clips4Sale.com

              Comment

              • berg.the.red
                Confirmed User
                • Feb 2003
                • 596

                #8
                maybe PHP Sniff
                Need a Dedicated Box with BALLS ?
                How about a Dedicated Server starting at just $49 per month.

                Comment

                • jwerd
                  Confirmed User
                  • Jun 2003
                  • 1953

                  #9
                  For this particular answer, I am going to have to say http://www.php.net/manual/en/tutorial.useful.php

                  If you read that, you will get a grasp on what it is you are trying to do. Then after you find out what the browsers names are you'd do some code like
                  PHP Code:
                  if($_SERVER["HTTP_USER_AGENT"] hahahaha "IE") {
                    // use some java code, redirect to designated page //
                  } else {
                    // go somewhere else... 
                  
                  Hope that helps!
                  Yii Framework Guru - Seasoned PHP vet - Partner @ XXXCoupon.com

                  Comment

                  • Volantt
                    Confirmed User
                    • Nov 2003
                    • 745

                    #10
                    Originally posted by icedemon
                    If the server is using Apache, you can just use Mod_Rewrite in a .htaccess file.

                    For example:
                    Code:
                    RewriteEngine on
                    
                    RewriteCond %{HTTP_USER_AGENT}  ^Mozilla/3.*
                    RewriteRule ^foo\.html$         foo.NS.html          [L]
                    
                    RewriteCond %{HTTP_USER_AGENT}  ^Lynx/.*         [OR]
                    RewriteCond %{HTTP_USER_AGENT}  ^Mozilla/[12].*
                    RewriteRule ^foo\.html$         foo.20.html          [L]
                    
                    RewriteRule ^foo\.html$         foo.32.html          [L]
                    Use the Apache Rewrite method, it is the most effective and less of a hassle. Write it and forget about it.

                    V
                    "Only the dead have seen the end of war." - Plato
                    "In the abscence of orders, go find something and kill it." - Erwin Rommel
                    "A man's worth is no greater then the worth of his ambitions." - Marcus Aurelius

                    Comment

                    • Tala
                      Fucked if I know
                      • Dec 2002
                      • 23368

                      #11
                      Thanks everyone!

                      ICQ: 11120676 | Google: mindcrime | Skype: suitemindcrime|E-Mail: mindcrime AT gmail.com|PR girl with great writing skills for hire!!!! Contact me to work for YOU!|TECHIEMEDIA? 24/7 support from some of the best techs in the biz. Tell Jim that I sent you.

                      Comment

                      Working...