What I’d like to do is find out what is the last/final URL after following the redirections. I would prefer not to use cURL. I would like to stick with pure PHP (stream wrappers).
Category Archives: PHP
methods to speed up PHP based website’s performance
PHP is great for writing quick dynamic stuff for your website. Just a couple of lines of code can be written in 2 mins to insert or retrieve data from db. But with ease there is also some pain… the downside is that each request for a dynamic page can trigger multiple db queries, processing …
Continue reading “methods to speed up PHP based website’s performance”
Parsing a URL querystring into variables in PHP
It’s common knowledge you can read variable from a URL querystring by using $_GET array in PHP, but that’s only possible if the URL is “executed” in the browser.
Installing Memcache On Windows For PHP
Installing memcache on Windows XP / Vista is kind of like voodoo for those of us who are not disciplined with compiling code from source. I initially attempted to install memcache a few months ago after reading a few articles about how much performance it can pump into your web application. The problem is that …
file_get_contents() [function.file-get-contents]: Unable to find the wrapper "https"
I’m working on setting up credit card processing and needed to use a workaround for CURL, and the following code worked fine when I was using the test server (which wasn’t calling an SSL URL), but now when I am testing it on the working server with https, it doesn’t work ("failed to open stream").
PHP $_POST array empty although php://input and raw post data is available?
I just helped a friend get through a devious issue with his PHP installation that I thought i’d blog about. There are other posts discussing problems related to having a $_POST array be completely empty although reading POST data directly via php://input wrappers works.