\

Namespaces

CodeIgniter
Config
My
Phpcmf
Psr
Xcx
Zend

Classes

AlipayNotify
AlipayNotify
AlipaySubmit
AlipaySubmit
FrameFiller
JsApiPay JSAPI支付实现类 该类实现了从微信公众平台获取code、通过code获取openid和access_token、 生成jsapi支付js接口所需的参数、生成获取共享收货地址所需的参数
NativePay 刷卡支付实现类
Oauth
OAuthException
PayNotifyCallBack 回调基础类
php5replace
PHPExcel PHPExcel
QC
QRbitstream
QRcode
QRencode
QRimage
QRinput
QRinputItem
QRmask
QRrawcode
QRrs
QRrsblock
QRrsItem
QRspec
QRsplit
qrstr
QRtools
SaeTClientV2 新浪微博操作类V2
SaeTOAuthV2 新浪微博 OAuth 认证类(OAuth2)
Uploader UEditor编辑器通用上传类
URL
WxPayApi 接口访问类,包含所有微信支付API列表的封装,类中方法为static方法, 每个接口有默认超时时间(除提交被扫支付为10s,上报超时时间为1s外,其他均为6s)
WxPayBizPayUrl 扫码支付模式一生成二维码参数
WxPayCloseOrder 关闭订单输入对象
WxPayDataBase 数据对象基础类,该类中定义数据类最基本的行为,包括: 计算/设置/获取签名、输出xml格式的参数、从xml读取数据对象等
WxPayDownloadBill 下载对账单输入对象
WxPayJsApiPay 提交JSAPI输入对象
WxPayMicroPay 提交被扫输入对象
WxPayNotify 回调基础类
WxPayNotifyReply 回调基础类
WxPayOrderQuery 订单查询输入对象
WxPayRefund 提交退款输入对象
WxPayRefundQuery 退款查询输入对象
WxPayReport 测速上报输入对象
WxPayResults 接口调用结果类
WxPayReverse 撤销输入对象
WxPayShortUrl 短链转换输入对象
WxPayUnifiedOrder 统一下单输入对象

Constants

$name

$name = (int) $cache[$name]

$var

$var = $value

ADMIN_URL

ADMIN_URL = $pageURL . $_SERVER['HTTP_HOST'] . '/'

ADMIN_URL

ADMIN_URL = dr_http_prefix(DOMAIN_NAME . '/')

APP_DIR

APP_DIR = ''

APP_NAMESPACE

APP_NAMESPACE = 'App'

APPID

APPID = $config['appid']

微信支付ajax实时监测状态接口 $result // 支付记录表的回调详情

APPID

APPID = $config['appid']

微信支付回调接口

APPID

APPID = $config['appid']

APPPATH

APPPATH = realpath($paths->appDirectory) . DIRECTORY_SEPARATOR

APPPATH

APPPATH = COREPATH

APPSECRET

APPSECRET = $config['appsecret']

APPSECRET

APPSECRET = $config['appsecret']

APPSECRET

APPSECRET = $config['appsecret']

APPSPATH

APPSPATH = FCPATH . 'App/'

BASEPATH

BASEPATH = FCPATH . 'System/'

CI_DEBUG

CI_DEBUG = 1

CI_DEBUG

CI_DEBUG = IS_DEV

CI_DEBUG

CI_DEBUG = 1

CI_DEBUG

CI_DEBUG = 0

CLASS_PATH

CLASS_PATH = FCPATH . "ThirdParty/Qq/"

CLIENT_URL

CLIENT_URL = SITE_URL

CMF_VERSION

CMF_VERSION = $this->cmf_version['version']

CMSPATH

CMSPATH = FCPATH . 'Fcms/'

CMSURI

CMSURI = $uri

COMPOSER_PATH

COMPOSER_PATH = FCPATH . 'Vendor/autoload.php'

COREPATH

COREPATH = FCPATH . 'Core/'

DAY

DAY = 86400

DECADE

DECADE = 315360000

DOMAIN_NAME

DOMAIN_NAME = strtolower($_SERVER['HTTP_HOST'])

DR_CMS

DR_CMS = $app['id']

DR_NAME

DR_NAME = $app['name']

DR_VERSION

DR_VERSION = $app['version']

ENVIRONMENT

ENVIRONMENT = $_SERVER['CI_ENVIRONMENT'] ?? 'production'

EVENT_PRIORITY_HIGH

EVENT_PRIORITY_HIGH = 10

EVENT_PRIORITY_LOW

EVENT_PRIORITY_LOW = 200

EVENT_PRIORITY_NORMAL

EVENT_PRIORITY_NORMAL = 100

EXIT__AUTO_MAX

EXIT__AUTO_MAX = 125

EXIT__AUTO_MIN

EXIT__AUTO_MIN = 9

EXIT_CONFIG

EXIT_CONFIG = 3

EXIT_DATABASE

EXIT_DATABASE = 8

EXIT_ERROR

EXIT_ERROR = 1

EXIT_SUCCESS

EXIT_SUCCESS = 0

EXIT_UNKNOWN_CLASS

EXIT_UNKNOWN_CLASS = 5

EXIT_UNKNOWN_FILE

EXIT_UNKNOWN_FILE = 4

EXIT_UNKNOWN_METHOD

EXIT_UNKNOWN_METHOD = 6

EXIT_USER_INPUT

EXIT_USER_INPUT = 7

FC_ADDRESS_CITY

FC_ADDRESS_CITY = 'address'

FC_NOW_HOST

FC_NOW_HOST = $pageURL . '/'

FC_NOW_URL

FC_NOW_URL = $pageURL . ($_SERVER['REQUEST_URI'] ? $_SERVER['REQUEST_URI'] : $_SERVER['PHP_SELF'])

FC_PAY

FC_PAY = 1

FC_PAY

FC_PAY = 1

FCPATH

FCPATH = dirname(__FILE__) . '/src/'

HOME_THEME_PATH

HOME_THEME_PATH = (SYS_THEME_ROOT ? SITE_URL : ROOT_URL) . 'static/' . SITE_THEME . '/'

HOUR

HOUR = 3600

IS_ADMIN

IS_ADMIN = TRUE

后台管理中心

IS_ADMIN

IS_ADMIN = TRUE

后台管理中心

IS_ADMIN

IS_ADMIN = FALSE

IS_AJAX

IS_AJAX = !empty($_SERVER['HTTP_X_REQUESTED_WITH']) && strtolower($_SERVER['HTTP_X_REQUESTED_WITH']) === 'xmlhttprequest'

IS_AJAX_POST

IS_AJAX_POST = IS_POST

IS_API

IS_API = 'pay'

支付回调接口URL

IS_API

IS_API = 'pay'

支付回调接口URL

IS_API

IS_API = 'pay'

支付回调接口URL

IS_API

IS_API = 'pay'

支付回调接口URL

IS_API

IS_API = 'pay'

支付回调接口URL

IS_API

IS_API = isset($_GET['s']) && $_GET['s'] == 'api'

IS_API_HTTP

IS_API_HTTP = 0

IS_API_HTTP

IS_API_HTTP = 0

IS_CLIENT

IS_CLIENT = '{CLIENT}'

IS_CLIENT

IS_CLIENT = ''

IS_COMMENT

IS_COMMENT = $this->module['comment']

IS_DEV

IS_DEV = 0

IS_EDIT_TPL

IS_EDIT_TPL = 0

IS_EDIT_TPL

IS_EDIT_TPL = 0

IS_INSTALL

IS_INSTALL = 1

http://www.kaiqibao.net 本文件是框架系统文件,二次开发时不可以修改本文件

IS_MEMBER

IS_MEMBER = FALSE

IS_MOBILE

IS_MOBILE = 1

Cms 移动端入口程序

IS_MOBILE

IS_MOBILE = 1

Cms 移动端入口程序

IS_MOBILE

IS_MOBILE = 1

Cms 移动端入口程序

IS_MODULE_RECYCLE

IS_MODULE_RECYCLE = 1

IS_MODULE_TG

IS_MODULE_TG = 1

IS_MODULE_TIME

IS_MODULE_TIME = 1

IS_MODULE_VERIFY

IS_MODULE_VERIFY = 1

IS_MODULE_VERIFY

IS_MODULE_VERIFY = 1

IS_POST

IS_POST = isset($_POST) && count($_POST) ? TRUE : FALSE

IS_SHARE

IS_SHARE = $this->module['share']

KEY

KEY = $config['key']

KEY

KEY = $config['key']

KEY

KEY = $config['key']

KINT_DIR

KINT_DIR = dirname(__FILE__)

KINT_PHP52

KINT_PHP52 = version_compare(PHP_VERSION, '5.2') >= 0

KINT_PHP522

KINT_PHP522 = version_compare(PHP_VERSION, '5.2.2') >= 0

KINT_PHP523

KINT_PHP523 = version_compare(PHP_VERSION, '5.2.3') >= 0

KINT_PHP524

KINT_PHP524 = version_compare(PHP_VERSION, '5.2.4') >= 0

KINT_PHP525

KINT_PHP525 = version_compare(PHP_VERSION, '5.2.5') >= 0

KINT_PHP53

KINT_PHP53 = version_compare(PHP_VERSION, '5.3') >= 0

KINT_PHP56

KINT_PHP56 = version_compare(PHP_VERSION, '5.6') >= 0

KINT_PHP70

KINT_PHP70 = version_compare(PHP_VERSION, '7.0') >= 0

KINT_PHP72

KINT_PHP72 = version_compare(PHP_VERSION, '7.2') >= 0

KINT_WIN

KINT_WIN = DIRECTORY_SEPARATOR !== '/'

LANG_PATH

LANG_PATH = ROOT_URL . 'api/language/' . SITE_LANGUAGE . '/'

LANG_PATH

LANG_PATH = '/api/language/' . SITE_LANGUAGE . '/'

MASTER_URL

MASTER_URL = 'https://www.kaiqibao.net/'

MAX_STRUCTURED_SYMBOLS

MAX_STRUCTURED_SYMBOLS = 16

MCHID

MCHID = $config['mchid']

MCHID

MCHID = $config['mchid']

MCHID

MCHID = $config['mchid']

MEMBER_URL

MEMBER_URL = (\Phpcmf\Service::IS_PC() ? SITE_URL : SITE_MURL) . (defined('MEMBER_PAGE') && MEMBER_PAGE ? MEMBER_PAGE : 'index.php?s=member')

MINUTE

MINUTE = 60

MOBILE_THEME_PATH

MOBILE_THEME_PATH = SITE_MURL . 'static/' . SITE_THEME . '/'

MOD_DIR

MOD_DIR = $dirname

MODULE_NAME

MODULE_NAME = $this->module['name']

MODULE_URL

MODULE_URL = $this->module['share'] ? '/' : $this->module['url']

MONTH

MONTH = 2592000

MYPATH

MYPATH = FCPATH . 'My/'

N1

N1 = 3

N2

N2 = 3

N3

N3 = 40

N4

N4 = 10

NOTIFY_API_URL

NOTIFY_API_URL = ROOT_URL . "index.php?s=api&c=pay&m=ajax&id=" . $id

NOTIFY_URL

NOTIFY_URL = ROOT_URL . "api/pay/" . $data['type'] . "/notify_url.php"

PHPCMF_FIELD_BAIDUMAP

PHPCMF_FIELD_BAIDUMAP = 1

PHPCMF_FIELD_COLOR

PHPCMF_FIELD_COLOR = 1

PHPCMF_FIELD_DATE

PHPCMF_FIELD_DATE = 1

PHPCMF_FIELD_FILE

PHPCMF_FIELD_FILE = 1

PHPCMF_FIELD_FILE

PHPCMF_FIELD_FILE = 1

PHPCMF_FIELD_LINKAGE

PHPCMF_FIELD_LINKAGE = 1

PHPCMF_FIELD_LINKAGE

PHPCMF_FIELD_LINKAGE = 1

PHPCMF_FIELD_TIME

PHPCMF_FIELD_TIME = 1

PHPCMF_FIELD_TOUCHSPIN

PHPCMF_FIELD_TOUCHSPIN = 1

PHPCMF_FIELD_UEDITOR

PHPCMF_FIELD_UEDITOR = 1

PHPEXCEL_ROOT

PHPEXCEL_ROOT = dirname(__FILE__) . '/'

POSCMS_FIELD_IMAGES

POSCMS_FIELD_IMAGES = 1

QR_CACHE_DIR

QR_CACHE_DIR = false

QR_CACHEABLE

QR_CACHEABLE = false

QR_DEFAULT_MASK

QR_DEFAULT_MASK = 2

QR_ECLEVEL_H

QR_ECLEVEL_H = 3

QR_ECLEVEL_L

QR_ECLEVEL_L = 0

QR_ECLEVEL_M

QR_ECLEVEL_M = 1

QR_ECLEVEL_Q

QR_ECLEVEL_Q = 2

QR_FIND_BEST_MASK

QR_FIND_BEST_MASK = true

QR_FIND_FROM_RANDOM

QR_FIND_FROM_RANDOM = 2

QR_FORMAT_PNG

QR_FORMAT_PNG = 1

QR_FORMAT_TEXT

QR_FORMAT_TEXT = 0

QR_IMAGE

QR_IMAGE = true

QR_LOG_DIR

QR_LOG_DIR = false

QR_MODE_8

QR_MODE_8 = 2

QR_MODE_AN

QR_MODE_AN = 1

QR_MODE_KANJI

QR_MODE_KANJI = 3

QR_MODE_NUL

QR_MODE_NUL = -1

QR_MODE_NUM

QR_MODE_NUM = 0

QR_MODE_STRUCTURE

QR_MODE_STRUCTURE = 4

QR_PNG_MAXIMUM_SIZE

QR_PNG_MAXIMUM_SIZE = 1024

QRCAP_EC

QRCAP_EC = 3

QRCAP_REMINDER

QRCAP_REMINDER = 2

QRCAP_WIDTH

QRCAP_WIDTH = 0

QRCAP_WORDS

QRCAP_WORDS = 1

QRSPEC_VERSION_MAX

QRSPEC_VERSION_MAX = 40

QRSPEC_WIDTH_MAX

QRSPEC_WIDTH_MAX = 177

REPORT_LEVENL

REPORT_LEVENL = 0

REPORT_LEVENL

REPORT_LEVENL = 0

REPORT_LEVENL

REPORT_LEVENL = 0

ROOT_THEME_PATH

ROOT_THEME_PATH = ROOT_URL . 'static/'

ROOT_THEME_PATH

ROOT_THEME_PATH = '/static/'

ROOT_URL

ROOT_URL = $this->site_info[1]['SITE_URL']

ROOTPATH

ROOTPATH = realpath(APPPATH . '../') . DIRECTORY_SEPARATOR

ROOTPATH

ROOTPATH = dirname(__FILE__) . '/'

SC_HTML_FILE

SC_HTML_FILE = 1

SC_HTML_FILE

SC_HTML_FILE = 1

SC_HTML_FILE

SC_HTML_FILE = 1

SECOND

SECOND = 1

SELF

SELF = pathinfo(__FILE__, PATHINFO_BASENAME)

SELF

SELF = pathinfo(__FILE__, PATHINFO_BASENAME)

SELF

SELF = pathinfo(__FILE__, PATHINFO_BASENAME)

SELF

SELF = pathinfo(__FILE__, PATHINFO_BASENAME)

SELF

SELF = pathinfo(__FILE__, PATHINFO_BASENAME)

SELF

SELF = pathinfo(__FILE__, PATHINFO_BASENAME)

SELF

SELF = pathinfo(__FILE__, PATHINFO_BASENAME)

SELF

SELF = pathinfo(__FILE__, PATHINFO_BASENAME)

SHOW_DEBUG_BACKTRACE

SHOW_DEBUG_BACKTRACE = true

SHOW_DEBUG_BACKTRACE

SHOW_DEBUG_BACKTRACE = true

SITE_EXPERIENCE

SITE_EXPERIENCE = dr_lang($this->member_cache['pay']['experience'] ? $this->member_cache['pay']['experience'] : '经验')

SITE_FID

SITE_FID = 0

SITE_ICP

SITE_ICP = $this->get_cache('site', SITE_ID, 'config', 'SITE_ICP')

SITE_ID

SITE_ID = '{SITE_ID}'

子站入口

SITE_ID

SITE_ID = '{SITE_ID}'

Cms 自定义终端入口程序

SITE_ID

SITE_ID = '{SITE_ID}'

模块自定义域名入口

SITE_ID

SITE_ID = 1

SITE_ID

SITE_ID = 1

SITE_IS_MOBILE

SITE_IS_MOBILE = $this->site_info[SITE_ID]['SITE_IS_MOBILE']

SITE_IS_MOBILE_HTML

SITE_IS_MOBILE_HTML = (int) $this->site_info[SITE_ID]['SITE_IS_MOBILE_HTML']

SITE_LANGUAGE

SITE_LANGUAGE = strlen($this->site_info[SITE_ID]['SITE_LANGUAGE']) ? $this->site_info[SITE_ID]['SITE_LANGUAGE'] : 'zh-cn'

SITE_LANGUAGE

SITE_LANGUAGE = 'zh-cn'

SITE_LOGIN_TIME

SITE_LOGIN_TIME = $this->member_cache['config']['logintime'] ? max(intval($this->member_cache['config']['logintime']), 500) : 36000

SITE_MURL

SITE_MURL = $this->site_info[SITE_ID]['SITE_MURL']

SITE_NAME

SITE_NAME = $this->site_info[SITE_ID]['SITE_NAME']

SITE_REWRITE

SITE_REWRITE = (int) $this->site_info[SITE_ID]['SITE_REWRITE']

SITE_SCORE

SITE_SCORE = dr_lang($this->member_cache['pay']['score'] ? $this->member_cache['pay']['score'] : '金币')

SITE_SEOJOIN

SITE_SEOJOIN = strlen($this->site_info[SITE_ID]['SITE_SEOJOIN']) ? $this->site_info[SITE_ID]['SITE_SEOJOIN'] : '_'

SITE_TEMPLATE

SITE_TEMPLATE = strlen($this->site_info[SITE_ID]['SITE_TEMPLATE']) ? $this->site_info[SITE_ID]['SITE_TEMPLATE'] : 'default'

SITE_THEME

SITE_THEME = strlen($this->site_info[SITE_ID]['SITE_THEME']) ? $this->site_info[SITE_ID]['SITE_THEME'] : 'default'

SITE_TIME_FORMAT

SITE_TIME_FORMAT = strlen($this->site_info[SITE_ID]['SITE_TIME_FORMAT']) ? $this->site_info[SITE_ID]['SITE_TIME_FORMAT'] : 'Y-m-d H:i:s'

SITE_TONGJI

SITE_TONGJI = $this->get_cache('site', SITE_ID, 'config', 'SITE_TONGJI')

SITE_URL

SITE_URL = $this->site_info[SITE_ID]['SITE_URL']

STRUCTURE_HEADER_BITS

STRUCTURE_HEADER_BITS = 20

SYS_TIME

SYS_TIME = $_SERVER['REQUEST_TIME'] ? $_SERVER['REQUEST_TIME'] : time()

SYS_UPLOAD_PATH

SYS_UPLOAD_PATH = ROOTPATH . $path . '/'

SYS_UPLOAD_URL

SYS_UPLOAD_URL = ROOT_URL . $path . '/'

SYSTEMPATH

SYSTEMPATH = BASEPATH

SYSTEMPATH

SYSTEMPATH = realpath($paths->systemDirectory) . DIRECTORY_SEPARATOR

TESTPATH

TESTPATH = WRITEPATH . 'tests/'

TESTPATH

TESTPATH = realpath($paths->testsDirectory) . DIRECTORY_SEPARATOR

THEME_PATH

THEME_PATH = (SYS_THEME_ROOT ? SITE_URL : ROOT_URL) . 'static/'

THEME_PATH

THEME_PATH = '/static/'

TPLPATH

TPLPATH = ROOTPATH . 'template/'

WB_AKEY

WB_AKEY = $appid

WB_SKEY

WB_SKEY = $appkey

WEBPATH

WEBPATH = dirname(__FILE__) . '/'

WEBPATH

WEBPATH = dirname(__FILE__) . '/'

WEBPATH

WEBPATH = dirname(__FILE__) . '/'

WEEK

WEEK = 604800

WRITEPATH

WRITEPATH = WEBPATH . 'cache/'

WRITEPATH

WRITEPATH = realpath($paths->writableDirectory) . DIRECTORY_SEPARATOR

WRITEPATH

WRITEPATH = ROOTPATH . 'cache/'

XCX_ID

XCX_ID = $this->xcx['id']

XCX_MID

XCX_MID = \Phpcmf\Service::L('Router')->class

XCX_PATH

XCX_PATH = dirname(APPPATH) . '/code/'

XCX_THEME_PATH

XCX_THEME_PATH = SITE_URL . XCX_DIR . 'static/'

XCX_URL

XCX_URL = dr_xcx_url('home/index')

YEAR

YEAR = 31536000

Functions

_array_search_dot()

_array_search_dot(array  $indexes, array  $array) : mixed|null

Used by dot_array_search to recursively search the array with wildcards.

Parameters

array $indexes
array $array

Returns

mixed|null

_format_feed_content_url_length()

_format_feed_content_url_length(string  $match) : string

格式化微博内容中url内容的长度

Parameters

string $match

匹配后的字符串

Returns

string —

格式化后的字符串

_has_protocol()

_has_protocol(string  $url) : false|integer

Test the protocol of a URI.

Parameters

string $url

Returns

false|integer

_list()

_list(string  $type = 'ul', mixed  $list = array(), string  $attributes = '', integer  $depth) : string

Generates the list

Generates an HTML ordered list from an single or multi-dimensional array.

Parameters

string $type
mixed $list
string $attributes
integer $depth

Returns

string

_media()

_media(string  $name, array  $types = array(), string  $unsupportedMessage = '', string  $attributes = '', array  $tracks = array()) : string

Generate media based tag

Parameters

string $name
array $types
string $unsupportedMessage

The message to display if the media tag is not supported by the browser.

string $attributes
array $tracks

Returns

string

_space_indent()

_space_indent(integer  $depth = 2) : string

Provide space indenting.

Parameters

integer $depth

Returns

string

alternator()

alternator() : string

Alternator

Allows strings to be alternated. See docs...

Returns

string

anchor()

anchor(mixed  $uri = '', string  $title = '', mixed  $attributes = '', \Config\App|null  $altConfig = null) : string

Anchor Link

Creates an anchor based on the local URL.

Parameters

mixed $uri

URI string or array of URI segments

string $title

The link title

mixed $attributes

Any attributes

\Config\App|null $altConfig

Alternate configuration to use

Returns

string

anchor_popup()

anchor_popup(string  $uri = '', string  $title = '', mixed  $attributes = false, \Config\App|null  $altConfig = null) : string

Anchor Link - Pop-up version

Creates an anchor based on the local URL. The link opens a new window based on the attributes specified.

Parameters

string $uri

the URL

string $title

the link title

mixed $attributes

any attributes

\Config\App|null $altConfig

Alternate configuration to use

Returns

string

argSort()

argSort(  $para) 

对数组排序

Parameters

$para

排序前的数组 return 排序后的数组

argSort()

argSort(  $para) 

对数组排序

Parameters

$para

排序前的数组 return 排序后的数组

array_key_first()

array_key_first(array  $arr) 

Parameters

array $arr

ascii_to_entities()

ascii_to_entities(string  $str) : string

High ASCII to Entities

Converts high ASCII text and MS Word special characters to character entities

Parameters

string $str

Returns

string

audio()

audio(mixed  $src, string  $unsupportedMessage = '', string  $attributes = '', array  $tracks = array(), boolean  $indexPage = false) : string

Audio

Generates an audio element to embed sounds

Parameters

mixed $src

Either a source string or an array of sources

string $unsupportedMessage

The message to display if the media tag is not supported by the browser.

string $attributes

HTML attributes

array $tracks
boolean $indexPage

Returns

string

auto_link()

auto_link(string  $str, string  $type = 'both', boolean  $popup = false) : string

Auto-linker

Automatically links URL and Email addresses. Note: There's a bit of extra code here to deal with URLs or emails that end in a period. We'll strip these off and add them after the link.

Parameters

string $str

the string

string $type

the type: email, url, or both

boolean $popup

whether to create pop-up links

Returns

string

base_url()

base_url(mixed  $uri = '', string  $protocol = null) : string

Return the base URL to use in views

Parameters

mixed $uri

URI string or array of URI segments

string $protocol

Returns

string

camelize()

camelize(string  $string) : string

Camelize

Takes multiple words separated by spaces or underscores and converts them to camel case.

Parameters

string $string

Input string

Returns

string

character_limiter()

character_limiter(string  $str, integer  $n = 500, string  $end_char = '…') : string

Character Limiter

Limits the string based on the character count. Preserves complete words so the character count may not be exactly as specified.

Parameters

string $str
integer $n
string $end_char

the end character. Usually an ellipsis

Returns

string

charsetDecode()

charsetDecode(  $input,   $_input_charset,   $_output_charset) 

实现多种字符解码方式

Parameters

$input

需要解码的字符串

$_input_charset

输入的解码格式 return 解码后的字符串

$_output_charset

输出的解码格式

charsetDecode()

charsetDecode(  $input,   $_input_charset,   $_output_charset) 

实现多种字符解码方式

Parameters

$input

需要解码的字符串

$_input_charset

输入的解码格式 return 解码后的字符串

$_output_charset

输出的解码格式

charsetEncode()

charsetEncode(  $input,   $_output_charset,   $_input_charset) 

实现多种字符编码方式

Parameters

$input

需要编码的字符串

$_output_charset

输出的编码格式

$_input_charset

输入的编码格式 return 编码后的字符串

charsetEncode()

charsetEncode(  $input,   $_output_charset,   $_input_charset) 

实现多种字符编码方式

Parameters

$input

需要编码的字符串

$_output_charset

输出的编码格式

$_input_charset

输入的编码格式 return 编码后的字符串

config()

config(  $name,   $getShared = true) 

Parameters

$name
$getShared

convert_accented_characters()

convert_accented_characters(string  $str) : string

Convert Accented Foreign Characters to ASCII

Parameters

string $str

Input string

Returns

string

counted()

counted(integer  $count, string  $string) : string

Counted

Takes a number and a word to return the plural or not E.g. 0 cats, 1 cat, 2 cats, ...

Parameters

integer $count

Number of items

string $string

Input string

Returns

string

createLinkstring()

createLinkstring(  $para) 

把数组所有元素,按照“参数=参数值”的模式用“&”字符拼接成字符串

Parameters

$para

需要拼接的数组 return 拼接完成以后的字符串

createLinkstring()

createLinkstring(  $para) 

把数组所有元素,按照“参数=参数值”的模式用“&”字符拼接成字符串

Parameters

$para

需要拼接的数组 return 拼接完成以后的字符串

createLinkstringUrlencode()

createLinkstringUrlencode(  $para) 

把数组所有元素,按照“参数=参数值”的模式用“&”字符拼接成字符串,并对字符串做urlencode编码

Parameters

$para

需要拼接的数组 return 拼接完成以后的字符串

createLinkstringUrlencode()

createLinkstringUrlencode(  $para) 

把数组所有元素,按照“参数=参数值”的模式用“&”字符拼接成字符串,并对字符串做urlencode编码

Parameters

$para

需要拼接的数组 return 拼接完成以后的字符串

ctype_alpha()

ctype_alpha(  $num) 

Parameters

$num

ctype_digit()

ctype_digit(  $num) 

Parameters

$num

current_url()

current_url(boolean  $returnObject = false) : string|\CodeIgniter\HTTP\URI

Current URL

Returns the full URL (including segments) of the page where this function is placed

Parameters

boolean $returnObject

True to return an object instead of a strong

Returns

string|\CodeIgniter\HTTP\URI

dasherize()

dasherize(string  $string) : string

Replaces underscores with dashes in the string.

Parameters

string $string

Input string

Returns

string

delete_cookie()

delete_cookie(mixed  $name, string  $domain = '', string  $path = '/', string  $prefix = '') : void

Delete a COOKIE

Parameters

mixed $name
string $domain

the cookie domain. Usually: .yourdomain.com

string $path

the cookie path

string $prefix

the cookie prefix

delete_files()

delete_files(string  $path, boolean  $del_dir = false, boolean  $htdocs = false, integer  $_level) : boolean

Delete Files

Deletes all files contained in the supplied directory path. Files must be writable or owned by the system in order to be deleted. If the second parameter is set to true, any directories contained within the supplied base directory will be nuked as well.

Parameters

string $path

File path

boolean $del_dir

Whether to delete any directories found in the path

boolean $htdocs

Whether to skip deleting .htaccess and index page files

integer $_level

Current directory depth level (default: 0; internal use only)

Returns

boolean

directory_map()

directory_map(string  $source_dir, integer  $directory_depth, boolean  $hidden = false) : array

Create a Directory Map

Reads the specified directory and builds an array representation of it. Sub-folders contained with the directory will be mapped as well.

Parameters

string $source_dir

Path to source

integer $directory_depth

Depth of directories to traverse (0 = fully recursive, 1 = current dir, etc)

boolean $hidden

Whether to show hidden files

Returns

array

doctype()

doctype(string  $type = 'html5') : string

Doctype

Generates a page document type declaration

Examples of valid options: html5, xhtml-11, xhtml-strict, xhtml-trans, xhtml-frame, html4-strict, html4-trans, and html4-frame. All values are saved in the doctypes config file.

Parameters

string $type

The doctype to be generated

Returns

string

dollar()

dollar(  $value,   $include_cents = TRUE) 

Parameters

$value
$include_cents

doSystemTest()

doSystemTest() 

dot_array_search()

dot_array_search(string  $index, array  $array) : mixed|null

Searches an array through dot syntax. Supports wildcard searches, like foo.*.bar

Parameters

string $index
array $array

Returns

mixed|null

dr_ajax_template()

dr_ajax_template(  $id,   $filename) 

动态调用模板

Parameters

$id
$filename

dr_array22array()

dr_array22array(  $a1,   $a2) 

两数组覆盖合并,1是老数据,2是新数据

Parameters

$a1
$a2

dr_array2array()

dr_array2array(  $a1,   $a2) 

两数组追加合并

Parameters

$a1
$a2

dr_array2string()

dr_array2string(array  $data) : string

将数组转换为字符串

Parameters

array $data

数组

Returns

string

dr_authcode()

dr_authcode(  $string,   $operation = 'DECODE') 

基于本地存储的加解密算法

Parameters

$string
$operation

dr_avatar()

dr_avatar(\intval  $uid) : string

会员头像

Parameters

\intval $uid

Returns

string

dr_avatar_path()

dr_avatar_path() 

dr_baidu_map()

dr_baidu_map(  $value,   $zoom = 15,   $width = 600,   $height = 400,   $ak = SYS_BDMAP_API,   $class = '',   $tips = '') 

百度地图调用

Parameters

$value
$zoom
$width
$height
$ak
$class
$tips

dr_baidu_map_form_hidden()

dr_baidu_map_form_hidden(  $field,   $ak = SYS_BDMAP_API) 

百度地图定位浏览器坐标并设置为隐藏表单域

Parameters

$field
$ak

dr_baidu_map_js()

dr_baidu_map_js(  $ak = SYS_BDMAP_API) 

百度地图JS

Parameters

$ak

dr_baidu_position_js()

dr_baidu_position_js(  $ak = SYS_BDMAP_API) 

百度地图定位浏览器坐标

Parameters

$ak

dr_base64_decode()

dr_base64_decode(string  $string) : string

Base64解密

Parameters

string $string

Returns

string

dr_base64_encode()

dr_base64_encode(string  $string) : string

Base64加密

Parameters

string $string

Returns

string

dr_block()

dr_block(\intval  $id,   $type,   $site) : array

资料块内容

Parameters

\intval $id
$type
$site

Returns

array

dr_cat_value()

dr_cat_value(  $get) 

Parameters

$get

dr_catcher_data()

dr_catcher_data(string  $url) : string

调用远程数据

Parameters

string $url

Returns

string

dr_catpos()

dr_catpos(\intval  $catid, string  $symbol = ' > ', string  $url = true, string  $html = '',   $dirname = MOD_DIR,   $url_call_func = '') : string

模块栏目面包屑导航

Parameters

\intval $catid

栏目id

string $symbol

面包屑间隔符号

string $url

是否显示URL

string $html

格式替换

$dirname
$url_call_func

Returns

string

dr_check_put_path()

dr_check_put_path(  $dir) 

Parameters

$dir

dr_check_put_path()

dr_check_put_path(  $dir) 

Parameters

$dir

dr_clear_emoji()

dr_clear_emoji(\type  $str) : \type

过滤emoji表情

Parameters

\type $str

Returns

\type

dr_clear_empty()

dr_clear_empty(  $value) 

清除空白字符

Parameters

$value

dr_clearhtml()

dr_clearhtml(string  $str) : string

清除HTML标记

Parameters

string $str

Returns

string

dr_cms_domain_name()

dr_cms_domain_name(  $url) 

获取cms域名部分

Parameters

$url

dr_code()

dr_code(  $width,   $height,   $url = '') 

验证码图片获取

Parameters

$width
$height
$url

dr_comment_emotion()

dr_comment_emotion() 

dr_comment_is_reply()

dr_comment_is_reply(  $reply,   $member,   $cuid) 

Parameters

$reply
$member
$cuid

dr_comment_url()

dr_comment_url(  $id,   $moddir = '') 

Parameters

$id
$moddir

dr_content_link()

dr_content_link(  $tags,   $content,   $num) 

内容文章显示内链

Parameters

$tags
$content
$num

dr_count()

dr_count(  $array_or_countable,   $mode = COUNT_NORMAL) 

Parameters

$array_or_countable
$mode

dr_date()

dr_date(integer  $time = NULL, string  $format = SITE_TIME_FORMAT, string  $color = NULL) : string

时间显示函数

Parameters

integer $time

时间戳

string $format

格式与date函数一致

string $color

当天显示颜色

Returns

string

dr_delete_html_file()

dr_delete_html_file(  $url,   $root = WEBPATH) 

Parameters

$url
$root

dr_dir_delete()

dr_dir_delete(  $path,   $del_dir = FALSE,   $htdocs = FALSE,   $_level) : boolean

删除目录及目录下面的所有文件

Parameters

$path
$del_dir
$htdocs
$_level

Returns

boolean —

如果成功则返回 TRUE,失败则返回 FALSE

dr_dir_map()

dr_dir_map(string  $source_dir, integer  $directory_depth, boolean  $hidden = FALSE) : array

目录扫描

Parameters

string $source_dir

Path to source

integer $directory_depth

Depth of directories to traverse (0 = fully recursive, 1 = current dir, etc)

boolean $hidden

Whether to show hidden files

Returns

array

dr_directory_map()

dr_directory_map(string  $source_dir, integer  $directory_depth, boolean  $hidden = FALSE) : array

Create a Directory Map

Reads the specified directory and builds an array representation of it. Sub-folders contained with the directory will be mapped as well.

Parameters

string $source_dir

Path to source

integer $directory_depth

Depth of directories to traverse (0 = fully recursive, 1 = current dir, etc)

boolean $hidden

Whether to show hidden files

Returns

array

dr_discount()

dr_discount(  $price,   $nowprice) 

Parameters

$price
$nowprice

dr_distance()

dr_distance(  $new,   $to,   $mark = '米,千米') 

Parameters

$new
$to
$mark

dr_domain_301()

dr_domain_301(  $domain,   $uri = '') 

Parameters

$domain
$uri

dr_donation()

dr_donation(  $id,   $title = '',   $dir = null,   $remove_div = 1) 

Parameters

$id
$title
$dir
$remove_div

dr_down_file()

dr_down_file(string  $id) : array

文件下载地址

Parameters

string $id

Returns

array

dr_dz_authcode()

dr_dz_authcode(  $string,   $operation = 'DECODE') 

Parameters

$string
$operation

dr_emoji2html()

dr_emoji2html(  $msg) 

Parameters

$msg

dr_fdate()

dr_fdate(  $sTime,   $formt = 'Y-m-d') : string

友好时间显示函数

Parameters

$sTime
$formt

Returns

string

dr_field_form()

dr_field_form(  $field,   $value = '',   $app = '',   $remove_div = 1) 

Parameters

$field
$value
$app
$remove_div

dr_field_input()

dr_field_input(  $name,   $type,   $option,   $value = NULL,   $id) : \intval

字段输出表单

Parameters

$name
$type
$option
$value
$id

Returns

\intval

dr_field_options()

dr_field_options(\intval  $id) : array

任意字段的选项值(用于options参数的字段,如复选框、下拉选择框、单选按钮)

Parameters

\intval $id

Returns

array

dr_fieldform()

dr_fieldform(  $field,   $value = '',   $remove_div = 1) 

字段表单调用 field 字段配置 value 默认值

Parameters

$field
$value
$remove_div

dr_file()

dr_file(string  $url) : string

完整的文件路径

Parameters

string $url

Returns

string

dr_file_map()

dr_file_map(string  $source_dir) : array

目录扫描

Parameters

string $source_dir

Path to source

Returns

array

dr_file_preview_html()

dr_file_preview_html(  $value,   $target) 

根据文件扩展名获取文件预览信息

Parameters

$value
$target

dr_form_hidden()

dr_form_hidden(  $data = array()) 

提交表单默认隐藏域

Parameters

$data

dr_form_search_hidden()

dr_form_search_hidden(  $p = array()) 

搜索表单隐藏域

Parameters

$p

dr_form_show_url()

dr_form_show_url(  $table,   $id,   $page) 

Parameters

$table
$id
$page

dr_format_create_sql()

dr_format_create_sql(  $sql) 

Parameters

$sql

dr_format_file_size()

dr_format_file_size(integer  $fileSize, integer  $round = 2) : string

格式化输出文件大小

Parameters

integer $fileSize

大小

integer $round

保留小数位

Returns

string

dr_format_html_file()

dr_format_html_file(  $file,   $root = WEBPATH) 

Parameters

$file
$root

dr_format_option_array()

dr_format_option_array(  $value) 

格式化复选框\单选框\选项值 字符串转换为数组

Parameters

$value

dr_format_son_list()

dr_format_son_list(  $list,   $type) 

Parameters

$list
$type

dr_furl()

dr_furl(  $name) 

Parameters

$name

dr_get_app_css()

dr_get_app_css(  $name) 

Parameters

$name

dr_get_app_css_dir()

dr_get_app_css_dir(  $name) 

Parameters

$name

dr_get_app_dir()

dr_get_app_dir(  $name) 

Parameters

$name

dr_get_app_list()

dr_get_app_list() 

dr_get_app_tpl()

dr_get_app_tpl(  $name = '') 

Parameters

$name

dr_get_array_key()

dr_get_array_key(  $array,   $value) 

http://www.kaiqibao.net 本文件是框架系统文件,二次开发时不可以修改本文件

Parameters

$array
$value

dr_get_cat_pname()

dr_get_cat_pname(array  $mod,   $catid, string  $symbol = '_') : string

模块栏目层次关系

Parameters

array $mod
$catid
string $symbol

Returns

string

dr_get_content_img()

dr_get_content_img(  $value,   $num) 

Parameters

$value
$num

dr_get_dir_path()

dr_get_dir_path(  $path) 

Parameters

$path

dr_get_domain_name()

dr_get_domain_name(  $url) 

Parameters

$url

dr_get_double_search()

dr_get_double_search(  $param,   $value) 

Parameters

$param
$value

dr_get_file()

dr_get_file(string  $id) : array

文件真实地址

Parameters

string $id

Returns

array

dr_get_file_url()

dr_get_file_url(array  $data,   $w,   $h) : string

根据附件信息获取文件地址

Parameters

array $data
$w
$h

Returns

string

dr_get_files()

dr_get_files(  $value) 

格式化多文件数组

Parameters

$value

dr_get_form_post_value()

dr_get_form_post_value(  $table) 

Parameters

$table

dr_get_ftable()

dr_get_ftable(  $id,   $value,   $class = '') 

Parameters

$id
$value
$class

dr_get_keyword()

dr_get_keyword(  $s) 

格式化搜索关键词参数

Parameters

$s

dr_get_keywords()

dr_get_keywords(  $kw,   $siteid = SITE_ID) 

提取关键字

Parameters

$kw
$siteid

dr_get_mform_post_value()

dr_get_mform_post_value(  $mid,   $table,   $cid) 

Parameters

$mid
$table
$cid

dr_get_order_string()

dr_get_order_string(  $str,   $order) 

Parameters

$str
$order

dr_get_page_pname()

dr_get_page_pname(\intval  $id, string  $symbol = '_',   $page) : string

单页层次关系

Parameters

\intval $id
string $symbol
$page

Returns

string

dr_get_tag_url()

dr_get_tag_url(  $name,   $mid = '') 

Parameters

$name
$mid

dr_get_theme()

dr_get_theme() : string|NULL

网站风格目录

Returns

string|NULL

dr_html2emoji()

dr_html2emoji(  $msg) 

Parameters

$msg

dr_html_auth()

dr_html_auth(  $is) 

静态生成时权限认证字符(加密)

Parameters

$is

dr_http_prefix()

dr_http_prefix(  $url) 

Parameters

$url

dr_hx_search_url()

dr_hx_search_url(  $params = array(),   $name = '',   $value = '') 

Parameters

$params
$name
$value

dr_hy_url()

dr_hy_url(  $uid) 

Parameters

$uid

dr_icon()

dr_icon(  $value) 

返回图标

Parameters

$value

dr_is_app()

dr_is_app(  $dir) 

插件是否被安装

Parameters

$dir

dr_is_app_dir()

dr_is_app_dir(  $name) 

Parameters

$name

dr_is_buy()

dr_is_buy(  $fid,   $id,   $uid,   $sku = '') 

Parameters

$fid
$id
$uid
$sku

dr_is_double_search()

dr_is_double_search(  $param,   $value) 

Parameters

$param
$value

dr_is_favorite()

dr_is_favorite(  $dir,   $id,   $uid) 

Parameters

$dir
$id
$uid

dr_is_image()

dr_is_image(  $value) 

Parameters

$value

dr_is_module()

dr_is_module(  $dir,   $siteid = SITE_ID) 

模块是否被安装

Parameters

$dir
$siteid

dr_is_son_buy()

dr_is_son_buy(  $dir,   $id,   $uid) 

Parameters

$dir
$id
$uid

dr_is_son_cart()

dr_is_son_cart(  $dir,   $id,   $uid) 

Parameters

$dir
$id
$uid

dr_is_store_favorite()

dr_is_store_favorite(  $id) 

Parameters

$id

dr_is_weixin_app()

dr_is_weixin_app() 

dr_keyword_highlight()

dr_keyword_highlight(string  $string, string  $keyword,   $rule = '') : string

关键字高亮显示

Parameters

string $string

字符串

string $keyword

关键字

$rule

Returns

string

dr_lang()

dr_lang(  $param) 

多语言输出

Parameters

$param

dr_level_next_value()

dr_level_next_value(  $array,   $id) 

下一个升级值

Parameters

$array
$id

dr_linkage()

dr_linkage(string  $code, \intval  $id, \intval  $level, string  $name = '') : array

联动菜单调用

Parameters

string $code

菜单代码

\intval $id

菜单id

\intval $level

调用级别,1表示顶级,2表示第二级,等等

string $name

菜单名称,如果有显示它的值,否则返回数组

Returns

array

dr_linkagepos()

dr_linkagepos(string  $code, \intval  $id, string  $symbol = ' > ', string  $url = '', string  $html = '') : string

联动菜单包屑导航

Parameters

string $code

联动菜单代码

\intval $id

id

string $symbol

间隔符号

string $url

url地址格式,必须存在[linkage],否则返回不带url的字符串

string $html

格式替换

Returns

string

dr_list_field_order()

dr_list_field_order(  $field) 

列表字段进行排序筛选

Parameters

$field

dr_list_function()

dr_list_function(  $func,   $value,   $param = array(),   $data = array()) 

执行函数

Parameters

$func
$value
$param
$data

dr_member_auth()

dr_member_auth(  $my,   $auth) 

验证用户权限 my 我的authid auth 目标权限组 return 1有权限 0无权限

Parameters

$my
$auth

dr_member_auth_id()

dr_member_auth_id(  $authid,   $postid) 

用于用户权限取取反值

Parameters

$authid
$postid

dr_member_group_etime()

dr_member_group_etime(  $days) 

Parameters

$days

dr_member_info()

dr_member_info(\intval  $uid, \intval  $name = '', \intval  $cache = -1) : string

调用会员详细信息(自定义字段需要手动格式化)

Parameters

\intval $uid

会员uid

\intval $name

输出字段

\intval $cache

缓存时间

Returns

string

dr_member_invite()

dr_member_invite(\intval  $uid, string  $name = 'uid') : 

获取到上级邀请者的信息

Parameters

\intval $uid

我的uid

string $name

字段信息

Returns

dr_member_menu_show()

dr_member_menu_show(  $t) 

Parameters

$t

dr_member_order()

dr_member_order(  $url) 

移除order字符串

Parameters

$url

dr_member_sync_url()

dr_member_sync_url(  $string) 

Parameters

$string

dr_member_url()

dr_member_url(  $url,   $query = array(),   $self = 'index.php') 

Parameters

$url
$query
$self

dr_member_username_info()

dr_member_username_info(  $username,   $name = '',   $cache = -1) 

Parameters

$username
$name
$cache

dr_mkdirs()

dr_mkdirs(string  $dir,   $null = true) : boolean|void

递归创建目录

Parameters

string $dir

目录名称

$null

Returns

boolean|void

dr_mobile_url()

dr_mobile_url(  $url = SITE_MURL) 

获取对应的手机端地址

Parameters

$url

dr_module_comment()

dr_module_comment(  $dir, \intval  $id) : string

模块评论js调用

Parameters

$dir
\intval $id

Returns

string

dr_module_table_prefix()

dr_module_table_prefix(  $dir,   $siteid = SITE_ID) 

模块表前缀

Parameters

$dir
$siteid

dr_module_url()

dr_module_url(  $dir) 

Parameters

$dir

dr_my_zone_info()

dr_my_zone_info(  $uid,   $name = '',   $cache = -1) 

Parameters

$uid
$name
$cache

dr_navigator_id()

dr_navigator_id(  $type,   $markid) 

Parameters

$type
$markid

dr_neilian()

dr_neilian(  $content,   $blank = 1,   $num = 1) 

Parameters

$content
$blank
$num

dr_notice_icon()

dr_notice_icon(  $type,   $c = '') 

Parameters

$type
$c

dr_notice_info()

dr_notice_info() 

dr_now_url()

dr_now_url() 

当前URL

dr_oauth_url()

dr_oauth_url(  $name,   $type,   $gourl = '') 

Parameters

$name
$type
$gourl

dr_object2array()

dr_object2array(object  $obj) : array

将对象转换为数组

Parameters

object $obj

数组对象

Returns

array

dr_order_info_status()

dr_order_info_status(  $data) 

Parameters

$data

dr_order_source()

dr_order_source(  $id) 

Parameters

$id

dr_page_catpos()

dr_page_catpos(\intval  $id, string  $symbol = ' > ', string  $html = '') : string

单页面包屑导航

Parameters

\intval $id
string $symbol
string $html

Returns

string

dr_page_value()

dr_page_value(  $id,   $field,   $site = SITE_ID) 

Parameters

$id
$field
$site

dr_pay_money_html()

dr_pay_money_html(  $data,   $v = 2) 

付款金额显示

Parameters

$data
$v

dr_pay_name()

dr_pay_name(  $name) 

付款名称

Parameters

$name

dr_pay_status()

dr_pay_status(  $data) 

付款状态的名称

Parameters

$data

dr_pay_type()

dr_pay_type(  $name) 

付款方式的名称

Parameters

$name

dr_pay_type_html()

dr_pay_type_html(  $name) 

付款方式显示

Parameters

$name

dr_payform()

dr_payform(  $mark,   $value,   $title = '',   $url = '',   $remove_div = 1) 

支付表单调用 mark 表名-主键id-字段id value 支付金额 title 支付说明

Parameters

$mark
$value
$title
$url
$remove_div

dr_preg_html()

dr_preg_html(  $html) 

正则替换和过滤内容

Parameters

$html

dr_price_value()

dr_price_value(  $value,   $num = 2) 

获取价格值

Parameters

$value
$num

dr_qq_map()

dr_qq_map(  $value,   $zoom = 10,   $width = 600,   $height = 400,   $ui,   $class = '') 

腾讯地图调用

Parameters

$value
$zoom
$width
$height
$ui
$class

dr_qrcode()

dr_qrcode(  $text,   $thumb = '',   $level = 'H',   $size = 5) 

二维码调用

Parameters

$text
$thumb
$level
$size

dr_qrcode_url()

dr_qrcode_url(  $text,   $uid,   $level = 'L',   $size = 5) 

Parameters

$text
$uid
$level
$size

dr_randcode()

dr_randcode() 

获取6位数字随机验证码

dr_random_color()

dr_random_color() : string

随机颜色

Returns

string

dr_redirect()

dr_redirect(  $url = '',   $method = 'auto',   $code = NULL) 

跳转地址

Parameters

$url
$method
$code

dr_related_cat()

dr_related_cat(  $data,   $catid) 

栏目下级或者同级栏目

Parameters

$data
$catid

dr_replace_emotion()

dr_replace_emotion(  $content) 

Parameters

$content

dr_return_data()

dr_return_data(  $code,   $msg = '',   $data = array()) 

数据返回统一格式

Parameters

$code
$msg
$data

dr_rewrite_decode()

dr_rewrite_decode(string  $params,   $join = '-',   $field = array()) : array

伪静态代码转换为数组

Parameters

string $params

参数字符串

$join
$field

Returns

array

dr_rewrite_encode()

dr_rewrite_encode(array  $params,   $join = '-',   $field = array()) : string

伪静态代码处理

Parameters

array $params

参数数组

$join
$field

Returns

string

dr_rp()

dr_rp(  $str,   $o,   $t) 

字符串替换函数

Parameters

$str
$o
$t

dr_safe_filename()

dr_safe_filename(  $string) 

安全过滤文件及目录名称函数

Parameters

$string

dr_safe_password()

dr_safe_password(  $string) 

安全过滤密码函数

Parameters

$string

dr_safe_replace()

dr_safe_replace(  $string,   $diy = null) 

安全过滤函数

Parameters

$string
$diy

dr_safe_replace_path()

dr_safe_replace_path(  $path) 

将路径进行安全转换变量模式

Parameters

$path

dr_safe_username()

dr_safe_username(  $string) 

安全过滤用户名函数

Parameters

$string

dr_save_bfb_data()

dr_save_bfb_data(  $data) 

Parameters

$data

dr_search_rewrite_decode()

dr_search_rewrite_decode(string  $params,   $search) : array

伪静态代码转换为数组

Parameters

string $params

参数字符串

$search

Returns

array

dr_search_rewrite_encode()

dr_search_rewrite_encode(array  $params, array  $search) : string

伪静态代码处理

Parameters

array $params

参数数组

array $search

搜索配置

Returns

string

dr_search_url()

dr_search_url(  $params = array(),   $name = '',   $value = '',   $moddir = '') 

Parameters

$params
$name
$value
$moddir

dr_sec2time()

dr_sec2time(  $times) 

秒转化时间

Parameters

$times

dr_share_cat_value()

dr_share_cat_value(  $id,   $field = '') 

Parameters

$id
$field

dr_show_hits()

dr_show_hits(\intval  $id,   $dom = "") : string

模块内容阅读量显示js

Parameters

\intval $id
$dom

Returns

string

dr_show_module_total()

dr_show_module_total(  $name, \intval  $id,   $dom) : string

模块内容收藏量显示js

Parameters

$name
\intval $id
$dom

Returns

string

dr_show_stars()

dr_show_stars(\intval  $num, \intval  $starthreshold = 4) : string

显示星星

Parameters

\intval $num
\intval $starthreshold

星星数在达到此阈值(设为 N)时,N 个星星显示为 1 个月亮、N 个月亮显示为 1 个太阳。

Returns

string

dr_site_footer()

dr_site_footer() 

dr_site_info()

dr_site_info(  $name,   $siteid = SITE_ID) 

Parameters

$name
$siteid

dr_sku_name()

dr_sku_name(  $key,   $data,   $type) 

sku获取名称

Parameters

$key
$data
$type

dr_sku_price()

dr_sku_price(  $value,   $number = 2,   $join = ' - ',   $zhe) 

sku 价格信息

Parameters

$value
$number
$join
$zhe

dr_son_type()

dr_son_type(  $type) 

Parameters

$type

dr_son_url()

dr_son_url(  $data) 

Parameters

$data

dr_sorting()

dr_sorting(  $name) 

排序操作

Parameters

$name

dr_square_point()

dr_square_point(  $lng,   $lat,   $distance = 0.5) : array

计算某个经纬度的周围某段距离的正方形的四个点

Parameters

$lng
$lat
$distance

Returns

array —

正方形的四个点的经纬度坐标

dr_star_level()

dr_star_level(  $num,   $shifen) 

Parameters

$num
$shifen

dr_store_default_order_message()

dr_store_default_order_message() 

dr_store_goods_html()

dr_store_goods_html(  $data) 

Parameters

$data

dr_store_order_deliver_status()

dr_store_order_deliver_status(  $data) 

Parameters

$data

dr_store_order_get_agent_name()

dr_store_order_get_agent_name() 

dr_store_order_get_order_sn()

dr_store_order_get_order_sn() 

dr_store_order_get_pay_type()

dr_store_order_get_pay_type() 

dr_store_order_html_error()

dr_store_order_html_error(  $msg) 

Parameters

$msg

dr_store_order_info_status()

dr_store_order_info_status(  $data) 

Parameters

$data

dr_store_order_score_status()

dr_store_order_score_status(  $t) 

Parameters

$t

dr_store_order_service_status()

dr_store_order_service_status(  $t) 

Parameters

$t

dr_store_order_service_type()

dr_store_order_service_type(  $id) 

Parameters

$id

dr_store_order_source()

dr_store_order_source(  $id) 

Parameters

$id

dr_store_order_status()

dr_store_order_status(  $data) 

Parameters

$data

dr_store_pay_status()

dr_store_pay_status(  $data) 

Parameters

$data

dr_store_sku_array()

dr_store_sku_array(  $string) 

Parameters

$string

dr_store_star_level()

dr_store_star_level(  $num) 

Parameters

$num

dr_strcut()

dr_strcut(  $string, \intval  $length = 100, string  $dot = '...') : string

字符截取

Parameters

$string
\intval $length
string $dot

Returns

string

dr_string2array()

dr_string2array(string  $data) : array

将字符串转换为数组

Parameters

string $data

字符串

Returns

array

dr_thumb()

dr_thumb(  $img,   $width,   $height,   $water,   $mode = 'auto') 

Parameters

$img
$width
$height
$water
$mode

dr_thumb_path()

dr_thumb_path() 

dr_to_html_file()

dr_to_html_file(  $url,   $root = WEBPATH) 

生成静态文件名

Parameters

$url
$root

dr_to_html_file_error()

dr_to_html_file_error(  $url,   $file,   $msg) 

生成静态文件的错误信息

Parameters

$url
$file
$msg

dr_tpl_file()

dr_tpl_file(  $file) 

Parameters

$file

dr_tpl_path()

dr_tpl_path(  $is_member = IS_MEMBER) 

Parameters

$is_member

dr_upload_temp_path()

dr_upload_temp_path() 

dr_url()

dr_url(  $url,   $query = array(),   $self = SELF) 

Parameters

$url
$query
$self

dr_url_prefix()

dr_url_prefix(  $url,   $domain = '',   $siteid = SITE_ID,   $is_mobile = '') 

Parameters

$url
$domain
$siteid
$is_mobile

dr_var_value()

dr_var_value(string  $name) : 

全局变量调用

Parameters

string $name

别名

Returns

dr_weixin_error_msg()

dr_weixin_error_msg(  $code) 

Parameters

$code

dr_xcx_cat_value()

dr_xcx_cat_value() 

dr_xcx_search_hidden()

dr_xcx_search_hidden(  $p = array()) 

搜索表单隐藏域

Parameters

$p

dr_xcx_url()

dr_xcx_url(  $url,   $query = array()) 

Parameters

$url
$query

dr_zhe_price()

dr_zhe_price(  $value,   $zhe) 

获取折扣价格值

Parameters

$value
$zhe

EchoConnInfo()

EchoConnInfo(  $conn) 

Parameters

$conn

EchoData()

EchoData(  $res,   $numfields,   $numrows) 

Parameters

$res
$numfields
$numrows

EchoFieldsHeader()

EchoFieldsHeader(  $res,   $numfields) 

Parameters

$res
$numfields

EchoHeader()

EchoHeader(  $errno) 

Parameters

$errno

EchoResultSetHeader()

EchoResultSetHeader(  $errno,   $affectrows,   $insertid,   $numfields,   $numrows) 

Parameters

$errno
$affectrows
$insertid
$numfields
$numrows

ellipsize()

ellipsize(string  $str, integer  $max_length, mixed  $position = 1, string  $ellipsis = '…') : string

Ellipsize String

This function will strip tags from a string, split it at its max_length and ellipsize

Parameters

string $str

String to ellipsize

integer $max_length

Max length of string

mixed $position

int (1|0) or float, .5, .2, etc for position to split

string $ellipsis

ellipsis ; Default '...'

Returns

string —

Ellipsized string

embed()

embed(string  $src, string  $type = 'unknown', string  $attributes = '', boolean  $indexPage = false) : string

Embed

Generates an embed element

Parameters

string $src

The path of the resource to embed

string $type

MIME-type

string $attributes

HTML attributes

boolean $indexPage

Returns

string

encode_php_tags()

encode_php_tags(string  $str) : string

Convert PHP tags to entities

Parameters

string $str

Returns

string

entities_to_ascii()

entities_to_ascii(string  $str, boolean  $all = true) : string

Entities to ASCII

Converts character entities back to ASCII

Parameters

string $str
boolean $all

Returns

string

excerpt()

excerpt(string  $text, string  $phrase = null, integer  $radius = 100, string  $ellipsis = '...') : string

Excerpt.

Allows to extract a piece of text surrounding a word or phrase.

Parameters

string $text

String to search the phrase

string $phrase

Phrase that will be searched for.

integer $radius

The amount of characters returned around the phrase.

string $ellipsis

Ending that will be appended

Returns

string —

If no $phrase is passed, will generate an excerpt of $radius characters from the beginning of $text.

form_button()

form_button(mixed  $data = '', string  $content = '', mixed  $extra = '') : string

Form Button

Parameters

mixed $data
string $content
mixed $extra

Returns

string

form_checkbox()

form_checkbox(mixed  $data = '', string  $value = '', boolean  $checked = false, mixed  $extra = '') : string

Checkbox Field

Parameters

mixed $data
string $value
boolean $checked
mixed $extra

Returns

string

form_close()

form_close(string  $extra = '') : string

Form Close Tag

Parameters

string $extra

Returns

string

form_datalist()

form_datalist(string  $name, string  $value, array  $options) : string

Datalist

The element specifies a list of pre-defined options for an element. Users will see a drop-down list of pre-defined options as they input data. The list attribute of the element, must refer to the id attribute of the element.

Parameters

string $name
string $value
array $options

Returns

string

form_dropdown()

form_dropdown(mixed  $data = '', mixed  $options = array(), mixed  $selected = array(), mixed  $extra = '') : string

Drop-down Menu

Parameters

mixed $data
mixed $options
mixed $selected
mixed $extra

Returns

string

form_fieldset()

form_fieldset(string  $legend_text = '', array  $attributes = array()) : string

Fieldset Tag

Used to produce

text. To close fieldset use form_fieldset_close()

Parameters

string $legend_text

The legend text

array $attributes

Additional attributes

Returns

string

form_fieldset_close()

form_fieldset_close(string  $extra = '') : string

Fieldset Close Tag

Parameters

string $extra

Returns

string

form_hidden()

form_hidden(string|array  $name, string|array  $value = '', boolean  $recursing = false) : string

Hidden Input Field

Generates hidden fields. You can pass a simple key/value string or an associative array with multiple values.

Parameters

string|array $name

Field name or associative array to create multiple fields

string|array $value

Field value

boolean $recursing

Returns

string

form_input()

form_input(mixed  $data = '', string  $value = '', mixed  $extra = '', string  $type = 'text') : string

Text Input Field. If 'type' is passed in the $type field, it will be used as the input type, for making 'email', 'phone', etc input fields.

Parameters

mixed $data
string $value
mixed $extra
string $type

Returns

string

form_label()

form_label(string  $label_text = '', string  $id = '', array  $attributes = array()) : string

Form Label Tag

Parameters

string $label_text

The text to appear onscreen

string $id

The id the label applies to

array $attributes

Additional attributes

Returns

string

form_multiselect()

form_multiselect(string  $name = '', array  $options = array(), array  $selected = array(), mixed  $extra = '') : string

Multi-select menu

Parameters

string $name
array $options
array $selected
mixed $extra

Returns

string

form_open()

form_open(string  $action = '', array|string  $attributes = array(), array  $hidden = array()) : string

Form Declaration

Creates the opening portion of the form.

Parameters

string $action

the URI segments of the form destination

array|string $attributes

a key/value pair of attributes, or string representation

array $hidden

a key/value pair hidden data

Returns

string

form_open_multipart()

form_open_multipart(string  $action = '', array|string  $attributes = array(), array  $hidden = array()) : string

Form Declaration - Multipart type

Creates the opening portion of the form, but with "multipart/form-data".

Parameters

string $action

The URI segments of the form destination

array|string $attributes

A key/value pair of attributes, or the same as a string

array $hidden

A key/value pair hidden data

Returns

string

form_password()

form_password(mixed  $data = '', string  $value = '', mixed  $extra = '') : string

Password Field

Identical to the input function but adds the "password" type

Parameters

mixed $data
string $value
mixed $extra

Returns

string

form_radio()

form_radio(mixed  $data = '', string  $value = '', boolean  $checked = false, mixed  $extra = '') : string

Radio Button

Parameters

mixed $data
string $value
boolean $checked
mixed $extra

Returns

string

form_reset()

form_reset(mixed  $data = '', string  $value = '', mixed  $extra = '') : string

Reset Button

Parameters

mixed $data
string $value
mixed $extra

Returns

string

form_submit()

form_submit(mixed  $data = '', string  $value = '', mixed  $extra = '') : string

Submit Button

Parameters

mixed $data
string $value
mixed $extra

Returns

string

form_textarea()

form_textarea(mixed  $data = '', string  $value = '', mixed  $extra = '') : string

Textarea field

Parameters

mixed $data
string $value
mixed $extra

Returns

string

form_upload()

form_upload(mixed  $data = '', string  $value = '', mixed  $extra = '') : string

Upload Field

Identical to the input function but adds the "file" type

Parameters

mixed $data
string $value
mixed $extra

Returns

string

get_cookie()

get_cookie(string  $index, boolean  $xssClean = false) : mixed

Fetch an item from the COOKIE array

Parameters

string $index
boolean $xssClean

Returns

mixed

get_dir_file_info()

get_dir_file_info(string  $source_dir, boolean  $top_level_only = true, boolean  $recursion = false) : array

Get Directory File Information

Reads the specified directory and builds an array containing the filenames, filesize, dates, and permissions

Any sub-folders contained within the specified path are read as well.

Parameters

string $source_dir

Path to source

boolean $top_level_only

Look only at the top level directory specified?

boolean $recursion

Internal variable to determine recursion status - do not use in calls

Returns

array

get_file_info()

get_file_info(string  $file, mixed  $returned_values = array('name', 'server_path', 'size', 'date')) : array|null

Get File Info

Given a file and path, returns the name, path, size, date modified Second parameter allows you to explicitly declare what information you want returned Options are: name, server_path, size, date, readable, writable, executable, fileperms Returns false if the file cannot be found.

Parameters

string $file

Path to file

mixed $returned_values

Array or comma separated string of information returned

Returns

array|null

get_filenames()

get_filenames(string  $source_dir, boolean  $include_path = false, boolean  $recursion = false) : array

Get Filenames

Reads the specified directory and builds an array containing the filenames. Any sub-folders contained within the specified path are read as well.

Parameters

string $source_dir

Path to source

boolean $include_path

Whether to include the path as part of the filename

boolean $recursion

Internal variable to determine recursion status - do not use in calls

Returns

array

GetBlock()

GetBlock(  $val) 

Parameters

$val

GetDummy()

GetDummy(  $count) 

Parameters

$count

gethostbyname()

gethostbyname(  $domain) 

Parameters

$domain

getHttpResponseGET()

getHttpResponseGET(  $url,   $cacert_url) 

远程获取数据,GET模式 注意: 1.使用Crul需要修改服务器中php.ini文件的设置,找到php_curl.dll去掉前面的";"就行了 2.文件夹中cacert.pem是SSL证书请保证其路径有效,目前默认路径是:getcwd().'\\cacert.pem'

Parameters

$url

指定URL完整路径地址

$cacert_url

指定当前工作目录绝对路径 return 远程输出的数据

getHttpResponseGET()

getHttpResponseGET(  $url,   $cacert_url) 

远程获取数据,GET模式 注意: 1.使用Crul需要修改服务器中php.ini文件的设置,找到php_curl.dll去掉前面的";"就行了 2.文件夹中cacert.pem是SSL证书请保证其路径有效,目前默认路径是:getcwd().'\\cacert.pem'

Parameters

$url

指定URL完整路径地址

$cacert_url

指定当前工作目录绝对路径 return 远程输出的数据

getHttpResponsePOST()

getHttpResponsePOST(  $url,   $cacert_url,   $para,   $input_charset = '') 

远程获取数据,POST模式 注意: 1.使用Crul需要修改服务器中php.ini文件的设置,找到php_curl.dll去掉前面的";"就行了 2.文件夹中cacert.pem是SSL证书请保证其路径有效,目前默认路径是:getcwd().'\\cacert.pem'

Parameters

$url

指定URL完整路径地址

$cacert_url

指定当前工作目录绝对路径

$para

请求的数据

$input_charset

编码格式。默认值:空值 return 远程输出的数据

getHttpResponsePOST()

getHttpResponsePOST(  $url,   $cacert_url,   $para,   $input_charset = '') 

远程获取数据,POST模式 注意: 1.使用Crul需要修改服务器中php.ini文件的设置,找到php_curl.dll去掉前面的";"就行了 2.文件夹中cacert.pem是SSL证书请保证其路径有效,目前默认路径是:getcwd().'\\cacert.pem'

Parameters

$url

指定URL完整路径地址

$cacert_url

指定当前工作目录绝对路径

$para

请求的数据

$input_charset

编码格式。默认值:空值 return 远程输出的数据

GetLongBinary()

GetLongBinary(  $num) 

Parameters

$num

GetShortBinary()

GetShortBinary(  $num) 

Parameters

$num

highlight_code()

highlight_code(string  $str) : string

Code Highlighter

Colorizes code strings

Parameters

string $str

the text string

Returns

string

highlight_phrase()

highlight_phrase(string  $str, string  $phrase, string  $tag_open = '<mark>', string  $tag_close = '</mark>') : string

Phrase Highlighter

Highlights a phrase within a text string

Parameters

string $str

the text string

string $phrase

the phrase you'd like to highlight

string $tag_open

the opening tag to precede the phrase with

string $tag_close

the closing tag to end the phrase with

Returns

string

humanize()

humanize(string  $string, string  $separator = '_') : string

Humanize

Takes multiple words separated by the separator, camelizes and changes them to spaces

Parameters

string $string

Input string

string $separator

Input separator

Returns

string

ihttp_request()

ihttp_request(  $url,   $post = '',   $extra = array(),   $timeout = 60) 

Parameters

$url
$post
$extra
$timeout

ihttp_response_parse()

ihttp_response_parse(  $data,   $chunked = false) 

Parameters

$data
$chunked

img()

img(mixed  $src = '', boolean  $indexPage = false, mixed  $attributes = '') : string

Image

Generates an image element

Parameters

mixed $src
boolean $indexPage
mixed $attributes

Returns

string

increment_string()

increment_string(string  $str, string  $separator = '_', integer  $first = 1) : string

Add's _1 to a string or increment the ending number to allow _2, _3, etc

Parameters

string $str

Required

string $separator

What should the duplicate number be appended with

integer $first

Which number should be used for the first dupe increment

Returns

string

index_page()

index_page(\Config\App|null  $altConfig = null) : string

Index page

Returns the "index_page" from your config file

Parameters

\Config\App|null $altConfig

Alternate configuration to use

Returns

string

is_php()

is_php(  $version) 

Parameters

$version

is_pluralizable()

is_pluralizable(string  $word) : boolean

Checks if the given word has a plural version.

Parameters

string $word

Word to check

Returns

boolean

link_tag()

link_tag(mixed  $href = '', string  $rel = 'stylesheet', string  $type = 'text/css', string  $title = '', string  $media = '', boolean  $indexPage = false) : string

Link

Generates link to a CSS file

Parameters

mixed $href

Stylesheet href or an array

string $rel
string $type
string $title
string $media
boolean $indexPage

should indexPage be added to the CSS path.

Returns

string

logResult()

logResult(  $word = '') 

写日志,方便测试(看网站需求,也可以改成把记录存入数据库) 注意:服务器需要开通fopen配置

Parameters

$word

要写入日志里的文本内容 默认值:空值

logResult()

logResult(  $word = '') 

写日志,方便测试(看网站需求,也可以改成把记录存入数据库) 注意:服务器需要开通fopen配置

Parameters

$word

要写入日志里的文本内容 默认值:空值

mailto()

mailto(string  $email, string  $title = '', mixed  $attributes = '') : string

Mailto Link

Parameters

string $email

the email address

string $title

the link title

mixed $attributes

any attributes

Returns

string

md5Sign()

md5Sign(  $prestr,   $key) 

签名字符串

Parameters

$prestr

需要签名的字符串

$key

私钥 return 签名结果

md5Sign()

md5Sign(  $prestr,   $key) 

签名字符串

Parameters

$prestr

需要签名的字符串

$key

私钥 return 签名结果

md5Verify()

md5Verify(  $prestr,   $sign,   $key) 

验证签名

Parameters

$prestr

需要签名的字符串

$sign

签名结果

$key

私钥 return 签名结果

md5Verify()

md5Verify(  $prestr,   $sign,   $key) 

验证签名

Parameters

$prestr

需要签名的字符串

$sign

签名结果

$key

私钥 return 签名结果

mime_content_type()

mime_content_type(  $filename) 

Parameters

$filename

now()

now(string  $timezone = null) : integer

Get "now" time

Returns time() based on the timezone parameter or on the app_timezone() setting

Parameters

string $timezone

Throws

\Exception

Returns

integer

object()

object(string  $data, string  $type = 'unknown', string  $attributes = '', array  $params = array(), boolean  $indexPage = false) : string

Object

Generates an object element that represents the media as either image or a resource plugin such as audio, video, Java applets, ActiveX, PDF and Flash

Parameters

string $data

A resource URL

string $type

Content-type of the resource

string $attributes

HTML attributes

array $params
boolean $indexPage

Returns

string

octal_permissions()

octal_permissions(integer  $perms) : string

Octal Permissions

Takes a numeric value representing a file's permissions and returns a three character string representing the file's octal permissions

Parameters

integer $perms

Permissions

Returns

string

ol()

ol(array  $list, string  $attributes = '') : string

Ordered List

Generates an HTML ordered list from an single or multi-dimensional array.

Parameters

array $list
string $attributes

HTML attributes

Returns

string

ordinal()

ordinal(integer  $integer) : string

Returns the suffix that should be added to a number to denote the position in an ordered sequence such as 1st, 2nd, 3rd, 4th.

Parameters

integer $integer

The integer to determine the suffix

Returns

string

ordinalize()

ordinalize(integer  $integer) : string

Turns a number into an ordinal string used to denote the position in an ordered sequence such as 1st, 2nd, 3rd, 4th.

Parameters

integer $integer

The integer to ordinalize

Returns

string

output()

output(  $description,   $succ,   $resStr) 

Parameters

$description
$succ
$resStr

paraFilter()

paraFilter(  $para) 

除去数组中的空值和签名参数

Parameters

$para

签名参数组 return 去掉空值与签名参数后的新签名参数组

paraFilter()

paraFilter(  $para) 

除去数组中的空值和签名参数

Parameters

$para

签名参数组 return 去掉空值与签名参数后的新签名参数组

param()

param(string  $name, string  $value, string  $type = 'ref', string  $attributes = '') : string

Param

Generates a param element that defines parameters for the object element.

Parameters

string $name

The name of the parameter

string $value

The value of the parameter

string $type

The MIME-type

string $attributes

HTML attributes

Returns

string

parse_form_attributes()

parse_form_attributes(string|array  $attributes, array  $default) : string

Parse the form attributes

Helper function used by some of the form helpers

Parameters

string|array $attributes

List of attributes

array $default

Default values

Returns

string

pascalize()

pascalize(string  $string) : string

Pascalize

Takes multiple words separated by spaces or underscores and converts them to Pascal case, which is camel case with an uppercase first letter.

Parameters

string $string

Input string

Returns

string

phpversion_int()

phpversion_int() 

plural()

plural(string  $string) : string

Plural

Takes a singular word and makes it plural

Parameters

string $string

Input string

Returns

string

prep_url()

prep_url(string  $str = '') : string

Prep URL - Simply adds the http:// part if no scheme is included.

Formerly used URI, but that does not play nicely with URIs missing the scheme.

Parameters

string $str

the URL

Returns

string

previous_url()

previous_url(boolean  $returnObject = false) : \CodeIgniter\HTTP\URI|mixed|string

Returns the previous URL the current visitor was on. For security reasons we first check in a saved session variable, if it exists, and use that.

If that's not available, however, we'll use a sanitized url from $_SERVER['HTTP_REFERER'] which can be set by the user so is untrusted and not set by certain browsers/servers.

Parameters

boolean $returnObject

Returns

\CodeIgniter\HTTP\URI|mixed|string

quotes_to_entities()

quotes_to_entities(string  $str) : string

Quotes to Entities

Converts single and double quotes to entities

Parameters

string $str

Returns

string

random_string()

random_string(string  $type = 'alnum', integer  $len = 8) : string

Create a Random String

Useful for generating passwords or hashes.

Parameters

string $type

Type of random string. basic, alpha, alnum, numeric, nozero, md5, sha1, and crypto

integer $len

Number of characters

Returns

string

reduce_multiples()

reduce_multiples(string  $str, string  $character = ',', boolean  $trim = false) : string

Reduce Multiples

Reduces multiple instances of a particular character. Example:

Fred, Bill,, Joe, Jimmy

becomes:

Fred, Bill, Joe, Jimmy

Parameters

string $str
string $character

the character you wish to reduce

boolean $trim

TRUE/FALSE - whether to trim the character from the beginning/end

Returns

string

safe_mailto()

safe_mailto(string  $email, string  $title = '', mixed  $attributes = '') : string

Encoded Mailto Link

Create a spam-protected mailto link written in Javascript

Parameters

string $email

the email address

string $title

the link title

mixed $attributes

any attributes

Returns

string

sanitize_filename()

sanitize_filename(string  $filename) : string

Sanitize a filename to use in a URI.

Parameters

string $filename

Returns

string

script_tag()

script_tag(mixed  $src = '', boolean  $indexPage = false) : string

Script

Generates link to a JS file

Parameters

mixed $src

Script source or an array

boolean $indexPage

Should indexPage be added to the JS path

Returns

string

set_checkbox()

set_checkbox(string  $field, string  $value = '', boolean  $default = false) : string

Set Checkbox

Let's you set the selected value of a checkbox via the value in the POST array. If Form Validation is active it retrieves the info from the validation class

Parameters

string $field
string $value
boolean $default

Returns

string

set_cookie()

set_cookie(string|array  $name, string  $value = '', string  $expire = '', string  $domain = '', string  $path = '/', string  $prefix = '', boolean  $secure = false, boolean  $httpOnly = false) 

Set cookie

Accepts seven parameters, or you can submit an associative array in the first parameter containing all the values.

Parameters

string|array $name

Cookie name or array containing binds

string $value

The value of the cookie

string $expire

The number of seconds until expiration

string $domain

For site-wide cookie. Usually: .yourdomain.com

string $path

The cookie path

string $prefix

The cookie prefix

boolean $secure

True makes the cookie secure

boolean $httpOnly

True makes the cookie accessible via http(s) only (no javascript)

set_radio()

set_radio(string  $field, string  $value = '', boolean  $default = false) : string

Set Radio

Let's you set the selected value of a radio field via info in the POST array. If Form Validation is active it retrieves the info from the validation class

Parameters

string $field
string $value
boolean $default

Returns

string

set_realpath()

set_realpath(string  $path, boolean  $check_existence = false) : string

Set Realpath

Parameters

string $path
boolean $check_existence

Checks to see if the path exists

Returns

string

set_select()

set_select(string  $field, string  $value = '', boolean  $default = false) : string

Set Select

Let's you set the selected value of a