espcms_publicespcms_tool.php

Functions

espcms_out()

espcms_out(  $str) 

Parameters

$str

espcms_magic_quotes()

espcms_magic_quotes() 

stripslashes_deep()

stripslashes_deep(  $value) 

Parameters

$value

add_magic_quotes()

add_magic_quotes(  $array) 

Parameters

$array

espcms_action_url()

espcms_action_url(  $action) 

Parameters

$action

espcms_server_url()

espcms_server_url(  $type = false) 

Parameters

$type

espcms_host()

espcms_host(  $urlkey = null,   $ishttp = true) 

Parameters

$urlkey
$ishttp

espcms_combine_url()

espcms_combine_url(  $baseURL,   $keysArr = array(),   $left_str = '?') 

Parameters

$baseURL
$keysArr
$left_str

espcms_add_self_url()

espcms_add_self_url(  $add_url_key = array()) 

Parameters

$add_url_key

linkOut()

linkOut(  $action_key = array()) 

Parameters

$action_key

espcms_url_out()

espcms_url_out(  $action_key = array(),   $is_rewrite = false,   $lng = false,   $type_path = false) 

Parameters

$action_key
$is_rewrite
$lng
$type_path

espcms_url_html_out()

espcms_url_html_out(  $action_key = array(),   $lng = false,   $end_oblink = true,   $is_html_extension = false) 

Parameters

$action_key
$lng
$end_oblink
$is_html_extension

espcms_find_array_key()

espcms_find_array_key(  $array = array(),   $string = null,   $field = null,   $refield = null) 

Parameters

$array
$string
$field
$refield

espcms_array_findkey()

espcms_array_findkey(  $array = array(),   $field = false) 

Parameters

$array
$field

espcms_array_getvalue()

espcms_array_getvalue(  $var = array()) 

Parameters

$var

espcms_array_onedim()

espcms_array_onedim(  $array = array(),   $array_key = false) 

Parameters

$array
$array_key

espcms_val_array_key()

espcms_val_array_key(  $value = false) 

Parameters

$value

espcms_array_keytokey()

espcms_array_keytokey(  $array = array(),   $key1 = false,   $key2 = false,   $key3 = false) 

Parameters

$array
$key1
$key2
$key3

espcms_replace_arraytostr()

espcms_replace_arraytostr(  $formatval,   $array = array()) 

Parameters

$formatval
$array

token()

token(  $token_px = false) 

Parameters

$token_px

is_token()

is_token(  $tokenname,   $tokenkey) 

Parameters

$tokenname
$tokenkey

cache_id()

cache_id() 

random_code()

random_code(  $len1 = 10,   $len2 = 8) 

Parameters

$len1
$len2

request_url()

request_url() 

random()

random(  $length = 6,   $numeric = false) 

Parameters

$length
$numeric

treelist()

treelist(  $text,   $fontline = '─') 

Parameters

$text
$fontline

real_remote_ip()

real_remote_ip(  $iplong = false) 

Parameters

$iplong

real_server_ip()

real_server_ip(  $iplong = false) 

Parameters

$iplong

ip_shift()

ip_shift(  $str,   $type = 1) 

Parameters

$str
$type

espcms_set_cookie()

espcms_set_cookie(  $key,   $value,   $time) 

Parameters

$key
$value
$time

espcms_set_session()

espcms_set_session(  $key,   $value) 

Parameters

$key
$value

espcms_get_session()

espcms_get_session(  $key) 

Parameters

$key

espcms_get_auto_start()

espcms_get_auto_start() 

espcms_del_session()

espcms_del_session(  $key) 

Parameters

$key

espcms_encrypt()

espcms_encrypt(  $data,   $key) 

Parameters

$data
$key

espcms_decrypt()

espcms_decrypt(  $data,   $key) 

Parameters

$data
$key

espcms_ismoney()

espcms_ismoney(  $value,   $matches = "/^(([0-9]\d{0,20})|0)(\.\d{1,3})?$/i") 

Parameters

$value
$matches

espcms_istime()

espcms_istime(  $value,   $matches = "/^[\d]{4}\-[\d]{1,2}\-[\d]{1,2} [\d]{1,2}:[\d]{1,2}:[\d]{1,2}$/i") 

Parameters

$value
$matches

espcms_istime_long()

espcms_istime_long(  $value,   $matches = "/^[\d]{4}\-[\d]{1,2}\-[\d]{1,2} [\d]{1,2}:[\d]{1,2}$/i") 

Parameters

$value
$matches

espcms_islongfig()

espcms_islongfig(  $value,   $matches = "/^[\d]+(,[\d]+)*$/i") 

Parameters

$value
$matches

espcms_isdata()

espcms_isdata(  $value,   $matches = "/^[\d]{4}\-[\d]{1,2}\-[\d]{1,2}$/i") 

Parameters

$value
$matches

espcms_ismatches()

espcms_ismatches(  $value,   $matches = "/^[0-9]+$/i") 

Parameters

$value
$matches

espcms_array_ismatches()

espcms_array_ismatches(  $array,   $matches = "/^[0-9]+$/i") 

Parameters

$array
$matches

espcms_isemail()

espcms_isemail(  $value,   $matches = "/^\w+((-\w+)|(\.\w+))*\@[A-Za-z0-9]+((\.|-)[A-Za-z0-9]+)*\.[A-Za-z0-9]+$/i") 

Parameters

$value
$matches

espcms_isurl()

espcms_isurl(  $value,   $matches = "/^((https|http|ftp|rtsp|mms)?:\/\/)[^\s]+$/i") 

Parameters

$value
$matches

espcms_ismoblie()

espcms_ismoblie(  $value,   $matches = "/^1[0-9]{10}$/i") 

Parameters

$value
$matches

espcms_isact()

espcms_isact(  $value,   $matches = "/^[\w]+\/[\w]+\/[\w]+$/i") 

Parameters

$value
$matches

espcms_isip()

espcms_isip(  $value,   $matches = "/^((25[0-5]|2[0-4]\d|((1\d{2})|([1-9]?\d)))\.){3}(25[0-5]|2[0-4]\d|((1\d{2})|([1-9]?\d)))$/i") 

Parameters

$value
$matches

espcms_timeformat()

espcms_timeformat(  $time,   $type = 3,   $font = '-',   $ddstr = '') 

Parameters

$time
$type
$font
$ddstr

espcms_format_money()

espcms_format_money(  $money,   $len = 2,   $sign = '¥') 

Parameters

$money
$len
$sign

espcms_week()

espcms_week(  $time,   $type = 'cn',   $weekEm = true) 

Parameters

$time
$type
$weekEm

espcms_get_timemessage()

espcms_get_timemessage(  $timenow) 

Parameters

$timenow

unArrayEmpty()

unArrayEmpty(  $array) 

Parameters

$array

unArrayValue()

unArrayValue(  $array,   $val) 

Parameters

$array
$val

espcms_guid()

espcms_guid(  $opt = true) 

Parameters

$opt

espcms_is_dir_writeable()

espcms_is_dir_writeable(  $dir) 

Parameters

$dir

format_size()

format_size(  $size,   $type) 

Parameters

$size
$type

zoom()

zoom(  $picfile,   $dstW = 200,   $dstH = 200,   $iszoom = 1,   $bgcolor = null) 

Parameters

$picfile
$dstW
$dstH
$iszoom
$bgcolor

espcms_cuthtml()

espcms_cuthtml(  $sourcestr,   $cutlength = 20,   $lenstr = '',   $allow = '') 

Parameters

$sourcestr
$cutlength
$lenstr
$allow

espcms_cutstr()

espcms_cutstr(  $sourcestr,   $cutlength = 20,   $lenstr = '',   $x3) 

Parameters

$sourcestr
$cutlength
$lenstr
$x3

espcms_text_to_html()

espcms_text_to_html(  $txt,   $is_preg = true) 

Parameters

$txt
$is_preg

espcms_find_in_set()

espcms_find_in_set(  $val = false,   $explode_str = false) 

Parameters

$val
$explode_str

espcms_style()

espcms_style(  $title = false,   $style = false) 

Parameters

$title
$style

espcms_random()

espcms_random(  $style_str = false) 

Parameters

$style_str

espcms_h2t()

espcms_h2t(  $text = false,   $type = false) 

Parameters

$text
$type

espcms_t2h()

espcms_t2h(  $txt = false,   $is_preg = true) 

Parameters

$txt
$is_preg

espcms_ip()

espcms_ip(  $str,   $type = 1) 

Parameters

$str
$type

espcms_array_to_xml()

espcms_array_to_xml(  $arr) 

Parameters

$arr

espcms_curl_post()

espcms_curl_post(  $url = '',   $postData = '',   $options = array()) 

Parameters

$url
$postData
$options

espcms_postdb()

espcms_postdb(  $url,   $data = '') 

Parameters

$url
$data

espcms_sort_terms()

espcms_sort_terms(  $a,   $b) 

Parameters

$a
$b

get_htmlfilename()

get_htmlfilename(  $readfiletemplates,   $filetext = array(),   $protectval = null) 

Parameters

$readfiletemplates
$filetext
$protectval

format_array_replace_string()

format_array_replace_string(  $formatval,   $replace_array = array()) 

Parameters

$formatval
$replace_array

espcms_long_array()

espcms_long_array(  $array = array(),   $cut_str = '/',   $link_str = ',') 

Parameters

$array
$cut_str
$link_str

espcms_screening_key()

espcms_screening_key(  $content = false,   $badword = false,   $is_filter = false) 

Parameters

$content
$badword
$is_filter

dump_escape_string()

dump_escape_string(  $str) 

Parameters

$str

dump_null_string()

dump_null_string(  $str) 

Parameters

$str

remove_comment()

remove_comment(  $var) 

Parameters

$var