special chars - why using GET results in trimmed variables?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • dutch disCo

    #1

    special chars - why using GET results in trimmed variables?

    Hi,

    I'm trying to use GET method to pass variables through my script files.
    Unfortunately, when a special char (&, ?, +) is being posted the
    variable gets trimmed in a very strange way. I'm aware, that's connected
    with the way the GET method passes variable values, but I don't know how
    to make GET to take the variable value "as it is" without interpreting
    special chars as special chars.

    So, how should I send GET variables in order not to get them trimmed
    when they contain special chars?

    Thanks in advance for your hints.
    Best regards
    dd
  • Joachim Weiß

    #2
    Re: special chars - why using GET results in trimmed variables?

    dutch disCo schrieb:[color=blue]
    > I'm trying to use GET method to pass variables through my script files.
    > Unfortunately, when a special char (&, ?, +) is being posted the[/color]
    ....

    Hi,

    i guess urlencode (http://de2.php.net/manual/en/function.urlencode.php)
    will help you.


    HIH
    Jo

    Comment

    • Smitro

      #3
      Re: special chars - why using GET results in trimmed variables?

      dutch disCo wrote:[color=blue]
      > Hi,
      >
      > I'm trying to use GET method to pass variables through my script files.
      > Unfortunately, when a special char (&, ?, +) is being posted the
      > variable gets trimmed in a very strange way. I'm aware, that's connected
      > with the way the GET method passes variable values, but I don't know how
      > to make GET to take the variable value "as it is" without interpreting
      > special chars as special chars.
      >
      > So, how should I send GET variables in order not to get them trimmed
      > when they contain special chars?
      >
      > Thanks in advance for your hints.
      > Best regards
      > dd[/color]

      This what your after?


      Comment

      • dutch disCo

        #4
        Re: special chars - why using GET results in trimmed variables?

        Joachim Weiß napisa³(a):[color=blue]
        > i guess urlencode (http://de2.php.net/manual/en/function.urlencode.php)
        > will help you.[/color]

        It was exactly what I needed. Thanks!
        dd

        Comment

        • John Dunlop

          #5
          Re: special chars - why using GET results in trimmed variables?

          dutch disCo wrote:
          [color=blue]
          > I'm trying to use GET method to pass variables through my script files.
          > Unfortunately, when a special char (&, ?, +) is being posted the
          > variable gets trimmed in a very strange way.[/color]

          What's special about the question mark?

          --
          Jock

          Comment

          Working...