Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Modif useragent

  • Loading branch information...
commit bc71d1dfc4aecc9a76397cc3981ba5382ac44cf7 1 parent 4495762
@jmtinghir authored
Showing with 3 additions and 3 deletions.
  1. +2 −2 nod.php
  2. +1 −1  test.php
View
4 nod.php
@@ -39,8 +39,8 @@ public function callCmd($cmd, $returnJson=false) {
curl_setopt($ch, CURLOPT_FAILONERROR, true);
curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 10);
curl_setopt($ch, CURLOPT_TIMEOUT, 60);
- curl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/5.0');
-
+ curl_setopt($ch, CURLOPT_USERAGENT, 'Nod-Php-Sdk');
+
$res = curl_exec($ch);
// $infos = curl_getinfo($ch);
$err = curl_error($ch);
View
2  test.php
@@ -15,6 +15,6 @@
</head>
<body>
<h1>Nantes Open Data : PHP SDK</h1>
- <p>Data = <?php var_dump($data->opendata->answer->status) ?></p>
+ <p>Data = <?php var_dump($data->opendata->request) ?></p>
</body>
</html>
Please sign in to comment.
Something went wrong with that request. Please try again.