1: <?php
2: $ytetimestart1 = microtime(true);
3: if (!defined("start_path")) {
4: define("start_path", getcwd());
5: }
6: if (defined("PHARAPP")) {
7: define("PROJ_PATH", PHARAPP);
8: } else {
9: define("PROJ_PATH", start_path);
10: }
11: $cacheFileList = array();
12: /**
13: * Cache a request URL if it doesn't need processing.
14: * SphpBase::sphp_api()->addCacheList("index",100)
15: * Cache index Gate with all events and refersh interval is 100 seconds. Cache will update the index Gate with
16: * interval of 100 seconds.
17: * @param string $url match for cache like cache "index" or "index-page"
18: * @param int $sec Expiry Time in seconds -1 mean never expire
19: * @param string $type <p>
20: * type = Default Gate mean url has Gate name only and response to all events basis on this Gate
21: * type = ce mean Gate-event cache only that event
22: * type = cep mean Gate-event-evtp cache only that event with that parameter
23: * type = e event on any Gate will be use cache
24: * Cache all index Gate responses for 1 hour
25: * addCacheList("index", 3600);
26: *
27: * Cache specific Gate + event
28: * addCacheList("blog-view", 1800, "ce");
29: *
30: * Cache with Gate + event + event parameter
31: * addCacheList("shop-product-shirt", 3600, "cep");
32: *
33: * Cache only match event from any Gate and with any event parameter
34: * addCacheList("info", 3600, "e");
35: *
36: * </p>
37: */
38: function addCacheList($url, $sec = 0, $type = "Gate") {}
39: /**
40: * Check if URL register with cache list
41: * @param string $url
42: * @return boolean
43: */
44: function isRegisterCacheItem($url) {}
45: /**
46: * Read Cache Item from Cache List
47: * @param string $url
48: * @return array
49: */
50: function getCacheItem($url) {}
51: /**
52: * Invalidate Cache Item
53: * @param string $url
54: */
55: function clearCacheItem($url) {}
56: /** isPharApp()
57: * Check if Gate run as Phar Gate.
58: * @return boolean
59: */
60: function isPharApp() {}
61: include_once("{$phppath}/Score/global/global.php");
62: $response_method = "NORMAL";
63: if (defined("PHARAPPW")) {
64: $basepath = "";
65: $respath = str_replace("..", "../..", $respath);
66: }
67: define("NEWLINE", "\n");
68: define("RLINE", "\r");
69: define("TABCHAR", "\t");
70: /**
71: * Read Global variable
72: * @param string $param
73: * @return mixed
74: */
75: function readGlobal($param) {}
76: /**
77: * Write Global variable
78: * @param string $param
79: * @param object $val
80: */
81: function writeGlobal($param, $val) {}
82: /**
83: * include with all global variables in close environment like include in function.
84: * @param string $filepath
85: */
86: function includeOnce($filepath) {}
87: /**
88: * Experimental don't use.
89: * include with all global variables in close environment like include in function.
90: * when sphp_mannually_start_engine defined then it use include otherwise it use include_once
91: * @param string $filepath
92: */
93: function includeOnce2($filepath) {}
94: /**
95: * Get $GLOBALS PHP Variable
96: * @return array
97: */
98: function getGlobals() {}
99: /**
100: * Encrypt String
101: * @param string $strdata
102: * @param string $key Optional Default=sbrtyu837
103: * @return string
104: */
105: function encryptme($strdata, $key = "sartajphp211") {}
106: /**
107: *
108: * @param string $strdata
109: * @param string $key
110: * @return string
111: */
112: function decryptme($strdata, $key = "sartajphp211") {}
113: /**
114: * Convert to secure Value.
115: * @param string $val
116: * @param string $key secure key
117: * @return string
118: */
119: function val2Secure($val, $key = "sartajphp211"){}
120: /**
121: * Return true if value is secure with val2secure function
122: * @param string $sval
123: */
124: function isSecureVal($sval){}
125: /**
126: * Restore Secure Value to back.
127: * @param string $val
128: * @param string $key secure key
129: * @return string
130: */
131: function secure2Val($sval, $key = "sartajphp211"){}
132: class stmycache {
133: public $url_extension = ".html";
134: public $act = "";
135: public $sact = "";
136: public $evtp = "";
137: public $gate = "";
138: public $blnrooturi = true;
139: public $htmlfileName = "";
140: public $blnCash = false;
141: public $blnPost = false;
142: public $blnCashExp = true;
143: public $method = "";
144: public $mode = "SERVER";
145: public $protocol = "";
146: public $blnsecure = false;
147: public $uri = "";
148: public $scriptpath = "";
149: public $argv = array();
150: public $type = "NORMAL";
151: public $isNativeClient = false;
152: public $edtmode = false;
153: public $edtctrl = "";
154: public $ytetimestart1 = 0;
155: public $ytetimestart2 = 0;
156: public function ytetilm(){}
157: public function findbdataToStr($str1) {}
158: public function getPostFormData($data) {}
159: public function escapetag($str) {}
160: public function route() {}
161: public function getURLSafeRet($val) {}
162: public function checkCache($postdata) {}
163: }
164: function startSartajPHPEngine() {}
165: