function index_action() { include LIB_PATH . "datacall.class.php"; $call = new datacall("plus/data/", $this->obj); $row = $call->get_data($_GET[id]); $row = str_replace("\n", "", $row); $row = str_replace("\r", "", $row); $row = str_replace("'", "\\'", $row); echo "document.write('{$row}');"; }
function smarty_function_call($paramer, &$smarty) { global $config, $views; include LIB_PATH . "datacall.class.php"; $obj = $views->obj; $call = new datacall(PLUS_PATH . "data/", $obj); $row = $call->get_data($paramer[id]); //Éú³É»º´æ $row = str_replace("\n", "", $row); $row = str_replace("\r", "", $row); return $row; }