Skip to content

Instantly share code, notes, and snippets.

@pedroresende
Created November 21, 2012 11:50
Show Gist options
  • Save pedroresende/4124511 to your computer and use it in GitHub Desktop.
Save pedroresende/4124511 to your computer and use it in GitHub Desktop.
echo "Exception trying to add and invalid Latitude and Longitude\n";
$content = $this->api->newContent( 'a_gmap_location_class' );
$content->setField( 'name', 'GMap Location Test Object' );
$values = array( 'address' => 'Oslo Norway', 'latitude' => '0.0' , 'longitude' => '0.0' );
$content->setField( 'gmap_location', $value );
$this->api->saveContent( $content );
@pedroresende
Copy link
Author

        echo "Exception trying to add and invalid Latitude and Longitude\n";
        $content = $this->api->newContent( 'a_gmap_location_class' );
        $content->setField( 'name', 'GMap Location Test Object' );
        $values = array( array( 'address' => 'Oslo Norway', 'latitude' => '0.0' , 'longitude' => '0.0' ) );
        $content->setField( 'gmap_location', $values );
        $this->api->saveContent( $content );   

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment