#2 Added a url_encode method as a replacement for strdup

open
nobody
None
5
2010-06-24
2010-06-24
Anonymous
No

I'm providing a url_encode() function to replace the current. It had a /*FIX ME*/ comment in it, here it is.
It should be a drop in replacement.

Function is provided in the self-standing program that test one string which was encoded with PHP
to compare the output.

Discussion

  • Comment has been marked as spam. 
    Undo

    You can see all pending comments posted by this user  here

    Anonymous - 2010-06-24

    url_encode replacement for httpfs

     
  • Comment has been marked as spam. 
    Undo

    You can see all pending comments posted by this user  here

    Anonymous - 2010-06-24

    First patch is wrong as it url-encodes the whole URI and it should not. The path should be left as is and not encode '/'s

     
  • Comment has been marked as spam. 
    Undo

    You can see all pending comments posted by this user  here

    Anonymous - 2010-06-24

    Second , updated version of url_encode

     
  • Comment has been marked as spam. 
    Undo

    You can see all pending comments posted by this user  here

    Anonymous - 2010-06-24

    Added a second and updated version of url encode that should handle reserved and unreserved characters better

     
  • Michal Suchanek

    Michal Suchanek - 2012-09-03

    Thanks for these encode function.

    I guess I will need to look up the RFC which specifies what characters should be encoded and make some tests before I replace the strdup with it. Otherwise it might break more URLs than it fixes ;-)

     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.





No, thanks