You are here

function shurly_service_output_txt in ShURLy 6

Same name and namespace in other branches
  1. 8 shurly_service/shurly_service.inc \shurly_service_output_txt()
  2. 7 shurly_service/shurly_service.inc \shurly_service_output_txt()

Output txt data Just outputs the shortUrl attribute... won't show errors

File

shurly_service/shurly_service.inc, line 152
Link general search functionalities to services module.

Code

function shurly_service_output_txt($data, $input) {
  if ($data['success']) {
    print $data[$input['primary']];
  }
  else {
    print t("ERROR: !error", array(
      '!error' => $data['error'],
    ));
  }
}