Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor core/Http.php into subclasses #3703

Closed
xjpvictor opened this issue Jan 23, 2013 · 2 comments
Closed

Refactor core/Http.php into subclasses #3703

xjpvictor opened this issue Jan 23, 2013 · 2 comments
Labels
Bug For errors / faults / flaws / inconsistencies etc. worksforme The issue cannot be reproduced and things work as intended.
Milestone

Comments

@xjpvictor
Copy link

SEO widget is not showing domain age with the following settings:

  1. piwik is installed with a sub-domain, (eg. abc.xxx.com)
  2. curl is used
  3. open_basedir is set

It seems that sendHttpRequestBy in core/Http.php is not handling the redirection header when open_basedir is set and curl is used.

@robocoder
Copy link
Contributor

Yes, as the commented code states, when open_basedir is set, curl_setopt(CURLOPT_FOLLOWLOCATION) fails with php 5.2+.

Per Matt's comment in r7010, let's refactor core/Http.php into smaller subclasses (e.g., Stream, Socket, Curl). There would need to be some rework to detect the "best" method at runtime.

@mattab
Copy link
Member

mattab commented Feb 6, 2014

I definitely still think it should be refactored, but for simplicity let's close the ticket, as there would be more refactor tickets to create. Refactoring rocks! https://en.wikipedia.org/wiki/Code_refactoring

@xjpvictor xjpvictor added this to the 2.x - The Great Piwik 2.x Backlog milestone Jul 8, 2014
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug For errors / faults / flaws / inconsistencies etc. worksforme The issue cannot be reproduced and things work as intended.
Projects
None yet
Development

No branches or pull requests

3 participants