SitePoint Sponsor

User Tag List

Results 1 to 14 of 14
  1. #1
    SitePoint Wizard triexa's Avatar
    Join Date
    Dec 2002
    Location
    Canada
    Posts
    2,476
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    article.php/article_title ... cannot get it to work

    I was reading through this:

    http://www.sitepoint.com/article/sea...-friendly-urls

    and this doesn't work:
    http://triexa.com/browse.php/abc

    Yet this loads the file just fine:
    http://triexa.com/browse.php

    Any ideas why this isn't working? I can't get it working in my local dev environment either
    AskItOnline.com - Need answers? Ask it online.
    Create powerful online surveys with ease in minutes!
    Sign up for your FREE account today!
    Follow us on Twitter

  2. #2
    Follow Me On Twitter: @djg gold trophysilver trophybronze trophy Dan Grossman's Avatar
    Join Date
    Aug 2000
    Location
    Philadephia, PA
    Posts
    20,580
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Need more info. How is "No input file specified." the wrong output for browse.php? What's in browse.php?

  3. #3
    SitePoint Wizard triexa's Avatar
    Join Date
    Dec 2002
    Location
    Canada
    Posts
    2,476
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    browse.php JUST has:

    $path = $_SERVER['PATH_INFO'];
    echo "Path: ---$path===";


    "no input file specified" seems to be the default 404:
    http://triexa.com/no_such_file.php
    AskItOnline.com - Need answers? Ask it online.
    Create powerful online surveys with ease in minutes!
    Sign up for your FREE account today!
    Follow us on Twitter

  4. #4
    SitePoint Wizard silver trophy
    Join Date
    Mar 2006
    Posts
    6,132
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

  5. #5
    SitePoint Wizard triexa's Avatar
    Join Date
    Dec 2002
    Location
    Canada
    Posts
    2,476
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I tried adding that, unsuccessfully.. but I am more than sure I likely "did it wrong"... could you please outline exaclty what I need to add, and where?
    AskItOnline.com - Need answers? Ask it online.
    Create powerful online surveys with ease in minutes!
    Sign up for your FREE account today!
    Follow us on Twitter

  6. #6
    SitePoint Wizard silver trophy
    Join Date
    Mar 2006
    Posts
    6,132
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    ive never used the setting, i just knew what it was called.

    it looks like you should be able to set it in .htaccess as well as httpd.conf

    maybe just

    Code:
    AcceptPathInfo On

  7. #7
    SitePoint Wizard triexa's Avatar
    Join Date
    Dec 2002
    Location
    Canada
    Posts
    2,476
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    well I added:
    <Files "browse.php">
    Options +Includes
    SetOutputFilter INCLUDES
    AcceptPathInfo On
    </Files>

    not such luck
    AskItOnline.com - Need answers? Ask it online.
    Create powerful online surveys with ease in minutes!
    Sign up for your FREE account today!
    Follow us on Twitter

  8. #8
    SitePoint Wizard triexa's Avatar
    Join Date
    Dec 2002
    Location
    Canada
    Posts
    2,476
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    On local it had no effect. On the triexa.com it caused EVERY page to be "Internal Server Error"
    AskItOnline.com - Need answers? Ask it online.
    Create powerful online surveys with ease in minutes!
    Sign up for your FREE account today!
    Follow us on Twitter

  9. #9
    SitePoint Wizard silver trophy
    Join Date
    Mar 2006
    Posts
    6,132
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    not positive but the error may be because your host doesnt allow you to override that setting.

    youd prob have better luck in the apache forum.

  10. #10
    SitePoint Wizard triexa's Avatar
    Join Date
    Dec 2002
    Location
    Canada
    Posts
    2,476
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    hmm, maybe. Either way I have e-mailed them

    Ironically it works on another domain under the same account I set up more recently. Perhaps they changed their default config for new domains...

    See what they say I suppose! As for getting it to at least work locally for now...
    AskItOnline.com - Need answers? Ask it online.
    Create powerful online surveys with ease in minutes!
    Sign up for your FREE account today!
    Follow us on Twitter

  11. #11
    ********* Genius Mike's Avatar
    Join Date
    Apr 2001
    Location
    Canada
    Posts
    5,458
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I'd suggest Mod Rewrite to do this
    Mike
    It's not who I am underneath, but what I do that defines me.

  12. #12
    SitePoint Wizard triexa's Avatar
    Join Date
    Dec 2002
    Location
    Canada
    Posts
    2,476
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Mike
    I'd suggest Mod Rewrite to do this
    go on
    AskItOnline.com - Need answers? Ask it online.
    Create powerful online surveys with ease in minutes!
    Sign up for your FREE account today!
    Follow us on Twitter

  13. #13
    ********* Genius Mike's Avatar
    Join Date
    Apr 2001
    Location
    Canada
    Posts
    5,458
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I suck at explanations, here's a good article: http://www.datakoncepts.com/seo

    And possible samples:
    This goes in .htaccess

    Code:
    RewriteEngine On
    RewriteRule ^/articles(/([a-z-]+))?$ articles.php?title=$2 [L]
    That will send site.com/articles/how-to-use-mod-rewrite to site.com/articles.php?title=how-to-use-mod-rewrite

    Anyone going to just site.com/articles will be redirected to articles.php with the title variable being empty

    You'll need to learn some regex to customize it, but as I have it, it will only match lowercase letters and hyphens.

    Redirects with mod rewrite are done behind the scenes, the user never knows...
    Mike
    It's not who I am underneath, but what I do that defines me.

  14. #14
    SitePoint Wizard triexa's Avatar
    Join Date
    Dec 2002
    Location
    Canada
    Posts
    2,476
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I found this example on my host's wiki, but no explanation

    Options +FollowSymLinks
    RewriteEngine on
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule .* process_url.php [L]

    What is FollowSymLinks?

    What is the !-f and !-d flags? and what about the [L], as you have also used?

    then I was thinking, I could just use process.php, check the info and include() the correct page..?
    AskItOnline.com - Need answers? Ask it online.
    Create powerful online surveys with ease in minutes!
    Sign up for your FREE account today!
    Follow us on Twitter


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •