SitePoint Sponsor

User Tag List

Results 1 to 4 of 4
  1. #1
    SitePoint Addict
    Join Date
    Sep 2000
    Location
    Ontario, Canada
    Posts
    320
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    problem with & in querystring

    It appears that search engines are spidering parts of my site after the querystring but are converting the "&" to "&" which is messing up my DB query.

    (edit: the forum is parsing my message so the amp; code isn't showing properly)

    So something like this is breaking my search:
    domain.com/file.php?a=b&=c

    Is there any way to convert the & in the querystring back to a "&" so it doesnt break my query?

    I'm thinking its an easy task but the code escapes me at the moment.
    Last edited by jdulberg; Oct 21, 2002 at 09:29.
    Jason Dulberg
    Extreme MTB
    http://extreme.nas.net

  2. #2
    Web-coding NINJA! silver trophy beetle's Avatar
    Join Date
    Jul 2002
    Location
    Dallas, TX
    Posts
    2,900
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You mean this right? &

    I've seen a discussion here regarding those before....ahh yes, here it is

    Not sure if the answer is there, but if not, I don't think I have one anyway...
    beetle a.k.a. Peter Bailey
    blogs: php | prophp | security | design | zen | software
    refs: dhtml | gecko | prototype | phpdocs | unicode | charsets
    tools: ide | ftp | regex | ffdev




  3. #3
    No. Phil.Roberts's Avatar
    Join Date
    May 2001
    Location
    Nottingham, UK
    Posts
    1,142
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I dont know if this is of interest to you (or anybody else) but I wrote a CGI class for PHP based on the CGI.pm Perl module. It allows you to use ; in your query strings regardles of whether PHP is set up to parse them natively.
    THE INSTRUCTIONS BELOW ARE OLD AND MAY BE INACCURATE.
    THIS INSTALL METHOD IS NOT RECOMMENDED, IT MAY RUN
    OVER YOUR DOG. <-- MediaWiki installation guide

  4. #4
    Ribbit... Eric.Coleman's Avatar
    Join Date
    Jun 2001
    Location
    In your basement
    Posts
    1,268
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    FYI, you can use ini_set to set ; to be used in the query string for PHP...

    I forget the exact setting, but I'll be sure to post it when I get home.

    Eric
    Eric Coleman
    We're consentratin' on fallin' apart
    We were contenders, now throwin' the fight
    I just wanna believe, I just wanna believe in us


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
  •