function Flgn_ready() { try { global $Grot_path; Fcom_setLogInfo("debug", "login ready:" . $Grot_path); $map = Net_URL_Mapper::getInstance(); $map->connect('/:app/:func/:type/:cont'); $url = $map->match($Grot_path); if ($url) { if (0 !== strcmp($url["app"], DROT_APP_NAME) || 0 !== strcmp($url["func"], DROT_FUNC_FNC)) { Frot_jumpFirst(); } if (0 === strcmp($url["type"], DROT_FTYPE_ATH)) { $ret = Fath_ctrl($url["cont"]); echo json_encode($ret); return; } } else { # Fcom_setLogInfo( DCOM_LOGLV_ERR , "".$Grot_path ); Fapp_jumpFirst(); } } catch (Exception $e) { throw new Exception('ERR(File:' . basename(__FILE__) . ',Line:' . __LINE__ . '):' . __FUNCTION__ . '()' . PHP_EOL . $e->getMessage()); } }
function Fapp_rdyFunc($url) { try { global $Grot_path; header("Content-Type: application/json; charset=utf-8"); if (0 === strcmp($url["type"], DROT_FTYPE_ATH)) { $ret = Fath_ctrl($url["cont"]); echo json_encode($ret); return; } else { if (0 === strcmp($url["type"], DROT_FTYPE_ITM)) { //$ret = array( 'ret' => true ); $ret = Fitm_ctrl($url["cont"]); echo json_encode($ret); return; } else { $noprm = Frot_getNoprmPath($url); $cont = Frot_getConts($noprm); if (null === $cont) { Fcom_setLogInfo(DCOM_LOGLV_ERR, $noprm . " is null."); Fapp_jumpFirst(); } else { echo $cont; } } } } catch (Exception $e) { throw new Exception('ERR(File:' . basename(__FILE__) . ',Line:' . __LINE__ . '):' . __FUNCTION__ . '()' . PHP_EOL . $e->getMessage()); } }
function Fapp_iniFunc($url) { try { header("Content-Type: application/json; charset=utf-8"); if (0 === strcmp($url["type"], DROT_FTYPE_ATH)) { $ret = Fath_ctrl($url["cont"]); } echo json_encode($ret); } catch (Exception $e) { throw new Exception('ERR(File:' . basename(__FILE__) . ',Line:' . __LINE__ . '):' . __FUNCTION__ . '()' . PHP_EOL . $e->getMessage()); } }