Sometimes it happens that there is a complex website that is can’t be parsed with so called „regular“ cURL + DOM xpath technique. People tend to protect their data with Javascript techniques, nowadays there are pure-Javascript sites popular, and, as you know, one can’t interpret JS using PHP or any other language you’re using for scraping (unless you scrape with nodejs, but I haven’t tried…
Kategorie: PHP
Backup of MySQL database with a PHP script
Sometimes you need to make a mysqldump backup without having SSH access or PHPMyAdmin. It can be done with PHP by means of SHOW TABLES/SHOW CREATE TABLE mysql queries. Below is an improved solution proposed here. Improvements: [list style=“upper-alpha tick“] [list_item]Got rid of memory_limit – writing to file on every iteration[/list_item] [list_item]gzip support – you don’t have to download huge uncompressed .sql[/list_item] [list_item]PHP notice fixed[/list_item]…
phpdaemon installation, configuration and usage tips & tricks
If you own a website with too many AJAX requests like autocomplete or real-time features like auction bidding that require quick response and you also use Zend Framework or any other PHP heavy library/framework on your backend, then you end up with way too many HTTP requests to the backend each of them requires framework bootstrapping. You can launch any PHP profiler like xdebug to…
Using Zencoder with Zend Framework
Zencoder is an API-based online video and audio encoding service. Zencoder converts videos from your website, application, or video library into formats that are compatible with web playback, mobile phone, or any other device you need to support. Zencoder have friendly API and php library. We can use this library with Zend Framework after some modifications. Click here to download modified library.
USPS Web Tools guide
Besides its primary role – delivering mail, USPS allows several other functions by means of https://www.usps.com/webtools/. In order to use them you’ll need to make xml in conformance with USPS Web Tools documentation and send it as for example cURL request. Below given is a class that will handle all these cURL requests. It’s the class serving all the requests in this article. We’ll need…