2017 © Pedro Peláez
 

silverstripe-module silverstripe-tripadvisor

Simple integration of TripAdvisor location profiles and reviews for SilverStripe.

image

level51/silverstripe-tripadvisor

Simple integration of TripAdvisor location profiles and reviews for SilverStripe.

  • Wednesday, August 12, 2015
  • by JZubero
  • Repository
  • 1 Watchers
  • 1 Stars
  • 3 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 3 Open issues
  • 3 Versions
  • 0 % Grown

The README.md

SilverStripe TripAdvisor Integration

This module provides a simple integration of TripAdvisor location profiles including awards, reviews, etc. Basically it is a wrapper for the Content API of TripAdvisor., (*1)

Official API documentation: https://developer-tripadvisor.com/content-api/, (*2)

Maintainer

Installation

composer require level51/silverstripe-tripadvisor

If you don't like composer you can just download and unpack it to the root of your SilverStripe project., (*3)

Prerequisites

  1. Obtain a valid TripAdvisor API key at: https://developer-tripadvisor.com/content-api/request-api-access/
  2. Get the ID of your location. You won't find it anywhere on the location profile's page, just check the URL.

Setup

  1. Provide your API key and location profile ID in the "Trip Advisor" tab of systems settings section.
  2. Execute the "Load TripAdvisor profile" action. This will create one TripAdvisorLocationProfile and three TripAdvisorReview records. Caution: This will drop the current profile data if already loaded.
  3. Go ahead and use it in your code (example snippets):
// Fetch location profile and output number of visits
$profile = TripAdvisorLocationProfile::current();
echo $profile->NumVisits;

// Fetch reviews and render with custom template
return TripAdvisorReview::get()->renderWith('ReviewGrid');

Notes

The logic uses the RestfulService class and hence does API calls via cURL. It follows the API guidelines in terms of caching so you don't have to worry about that., (*4)

The Versions

12/08 2015

dev-develop

dev-develop

Simple integration of TripAdvisor location profiles and reviews for SilverStripe.

  Sources   Download

The Requires

  • php >=5.3.2
  • ext-curl *

 

by Julian Scheuchenzuber

12/08 2015

0.1.0

0.1.0.0

Simple integration of TripAdvisor location profiles and reviews for SilverStripe.

  Sources   Download

The Requires

  • php >=5.3.2
  • ext-curl *

 

by Julian Scheuchenzuber

11/08 2015

dev-master

9999999-dev

Simple integration of TripAdvisor location profiles and reviews for SilverStripe.

  Sources   Download

The Requires

  • php >=5.3.2
  • ext-curl *

 

by Julian Scheuchenzuber