Zend\Http\Client uses arg_separator.output to build URLs, resulting in possibly wrongly formed URLs #2745

Closed
demonkoryu opened this Issue Oct 12, 2012 · 2 comments

Comments

Projects
None yet
3 participants
@demonkoryu
Contributor

demonkoryu commented Oct 12, 2012

I've set arg_separator.output to &.
http_build_query() by default uses this separator in the query strings it builds. This results in HTTP requests like GET /index.php?arg=pie&oh=no.

Most HTTP servers don't understand that and bugger out.

As a workaround, I temporarily set arg_separator.output to & for the duration of Zend\Http\Client->send().

@ralphschindler

This comment has been minimized.

Show comment
Hide comment
@ralphschindler

ralphschindler Oct 16, 2012

Member

Why do you set arg_separator.output to & in the first place?

Member

ralphschindler commented Oct 16, 2012

Why do you set arg_separator.output to & in the first place?

@demonkoryu

This comment has been minimized.

Show comment
Hide comment
@demonkoryu

demonkoryu Oct 17, 2012

Contributor

For generating valid HTML when using transparent session IDs.

I've also might have set arg_separator.output to ;, but there's the same problem: Some web APIs don't understand that because they use the semicolon as pseudo array delimiters in their argument values.

Contributor

demonkoryu commented Oct 17, 2012

For generating valid HTML when using transparent session IDs.

I've also might have set arg_separator.output to ;, but there's the same problem: Some web APIs don't understand that because they use the semicolon as pseudo array delimiters in their argument values.

weierophinney added a commit that referenced this issue Nov 9, 2012

gianarb pushed a commit to zendframework/zend-http that referenced this issue May 15, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment