コード例 #1
0
ファイル: Action.php プロジェクト: JackCanada/moodle-hacks
 /**
  * Returns the serialized content of the response class
  *
  * we actually use the json serializer underneath, so we send the actions array
  * to the json serializer and return the data
  *
  * @return string serialized response content
  * @access public
  */
 function getPayload()
 {
     $serializer = new HTML_AJAX_Serializer_JSON();
     return $serializer->serialize($this->_actions);
 }
コード例 #2
0
ファイル: Helper.php プロジェクト: veritech/pare-project
 /**
  * Generate a JSON String
  *
  * @param string	$input
  * @return string
  */
 function jsonEncode($input)
 {
     require_once 'HTML/AJAX/Serializer/JSON.php';
     $s = new HTML_AJAX_Serializer_JSON();
     return $s->serialize($input);
 }