In two examples, BETA Stock Ticker for Emma and BETA Electric Imp Agents Documentation example for “Http In”, the External Url is used with a curl statement for example:
curl -d “FB” “https://agents.electricimp.com/AGENT_URL”
or
curl -d “0” “https://agents.electricimp.com/AGENT_URL”
How do I use the above statement? Where do I put it? I tried in a webpage using PHP with no luck.
curl is a command prompt program and needs to be operated in your favorite terminal program. You may already have this program installed if you are on OS X or Linux - otherwise you will need to download it from: http://curl.haxx.se/download.html
@autolibearth - here’s an example in php:
`<?php
$url = “https://agents.electricimp.com/AGENT_URL”;
$curl = curl_init();
curl_setopt( $curl, CURLOPT_URL, $url );
curl_setopt( $curl, CURLOPT_RETURNTRANSFER, 1 );
$result = curl_exec( $curl );
curl_close( $curl );
?>`