netglue / zf2-tripadvisor-module
ZF2 module that provides easy syndication of tripadvisor reviews for a zend framework website
Installs: 51
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 1
Open Issues: 0
Type:module
Requires
- php: >=5.3.3
- zendframework/zendframework: 2.*
Requires (Dev)
- satooshi/php-coveralls: dev-master
This package is auto-updated.
Last update: 2020-06-02 15:06:52 UTC
README
Install
The only supported method of installation is with composer:
$ composer require netglue/zf2-tripadvisor-module
Once installed, activate the module by adding NetglueTripAdvisor
to your application config and copy the config/module.config.php.dist
to your autoload directory as something like tripadvisor.global.php
and customise the options to suit your needs.
How it works
There is a simple scraper that loads the remote TA reviews page selected and traverses the DOM to extract the reviews from the page.
This is susceptible to breaking if Trip Advisor alter their markup
Future Plans
If I get the time, I might consider persisting the reviews so that if/when TA do alter their markup, at least we'll be able to continue to present the old reviews.
Tests
The module has a test suite you can run. phpunit
has not been declared as a dev dependency so it must be installed separately if not.
$ cd path/to/vendor/zf2-tripadvisor-module
$ composer install
$ phpunit
Contributing & Reporting Bugs
Please feel free to report issues but without a pull request, I'm unlikely to be able to fix things in a timely manner. Please also include tests along with any changes.
If you're using this module, it'd be nice to know, so drop me a line on gsteel at gmail