1: <?php
2: /**
3: * Maniaplanet Web Services SDK for PHP
4: *
5: * @see http://code.google.com/p/maniaplanet-ws-sdk/
6: * @copyright Copyright (c) 2009-2011 NADEO (http://www.nadeo.com)
7: * @license http://www.gnu.org/licenses/lgpl.html LGPL License 3
8: * @author $Author: maximeraoust $:
9: * @version $Revision: 90 $:
10: * @date $Date: 2012-01-02 12:46:29 +0100 (lun., 02 janv. 2012) $:
11: */
12:
13: namespace Maniaplanet\WebServices;
14:
15: /**
16: * Access to public Manialink data
17: */
18: class Manialinks extends HTTPClient
19: {
20:
21: /**
22: * Retrieves information about a Manialink code.
23: *
24: * @param string $code Short Manialink code
25: * @return object
26: * @throws \TrackMania\WebServices\Exception
27: */
28: function get($code)
29: {
30: if(!$code)
31: {
32: throw new Exception('Invalid Manialink code');
33: }
34: return $this->execute('GET', '/manialinks/%s/', array($code));
35: }
36:
37: }
38:
39: ?>