Documentation ¶
Index ¶
- Variables
- func Abs(number float64) float64
- func Addslashes(str string) string
- func Base64Decode(data string) (string, error)
- func Base64Encode(data string) string
- func BaseConvert(number string, frombase, tobase int) (string, error)
- func Basename(path string) string
- func Bin2hex(str string) (string, error)
- func Bindec(str string) (string, error)
- func Ceil(value float64) float64
- func Chmod(filename string, mode os.FileMode) bool
- func Chown(filename string, uid, gid int) bool
- func Copy(source, dest string) (bool, error)
- func Date(format string, timestamp int64) string
- func Decbin(number int64) string
- func Dechex(number int64) string
- func Decoct(number int64) string
- func Delete(filename string) error
- func Echo(args ...interface{})
- func Explode(delimiter, str string) []string
- func Fclose(handle *os.File) error
- func Fgetcsv(handle *os.File, length int, delimiter rune) ([][]string, error)
- func FileExists(filename string) bool
- func FileGetContents(filename string) (string, error)
- func FilePutContents(filename string, data string, mode os.FileMode) error
- func FileSize(filename string) (int64, error)
- func Filemtime(filename string) (int64, error)
- func Floor(value float64) float64
- func Getcwd() (string, error)
- func Gethostbyaddr(ipAddress string) (string, error)
- func Gethostbyname(hostname string) (string, error)
- func Gethostbynamel(hostname string) ([]string, error)
- func Gethostname() (string, error)
- func Glob(pattern string) ([]string, error)
- func HTMLEntityDecode(str string) string
- func HTTPBuildQuery(queryData url.Values) string
- func Hex2bin(data string) (string, error)
- func Hexdec(str string) (int64, error)
- func Htmlentities(str string) string
- func Htmlspecialchars(str string) string
- func HtmlspecialcharsDecode(str string) string
- func IP2long(ipAddress string) uint32
- func Implode(glue string, pieces []string) string
- func IsDir(filename string) (bool, error)
- func IsFile(filename string) bool
- func IsNan(val float64) bool
- func IsReadable(filename string) bool
- func IsWriteable(filename string) bool
- func Join(glue string, pieces []string) string
- func Lcfirst(str string) string
- func Long2ip(properAddress uint32) string
- func Max(nums ...float64) float64
- func Md5(str string) string
- func Md5File(path string) (string, error)
- func Min(nums ...float64) float64
- func Mkdir(filename string, mode os.FileMode) error
- func Octdec(str string) (int64, error)
- func Pathinfo(path string, options int) map[string]string
- func Pi() float64
- func Quotemeta(str string) string
- func Rand(min, max int) int
- func Rawurldecode(str string) (string, error)
- func Rawurlencode(str string) string
- func Realpath(path string) (string, error)
- func Rename(oldname, newname string) error
- func Round(value float64) float64
- func Sha1(str string) string
- func Sha1File(path string) (string, error)
- func Sleep(seconds int64)
- func Stat(filename string) (os.FileInfo, error)
- func StrReplace(search, replace, subject string, count int) string
- func Stripos(haystack, needle string, offset int) int
- func Stripslashes(str string) string
- func Strpos(haystack, needle string, offset int) int
- func Strripos(haystack, needle string, offset int) int
- func Strrpos(haystack, needle string, offset int) int
- func Strtolower(str string) string
- func Strtoupper(str string) string
- func Time() int64
- func Touch(filename string) (bool, error)
- func URLDecode(str string) (string, error)
- func URLEncode(str string) string
- func Ucfirst(str string) string
- func Ucwords(str string) string
- func Uniqid(prefix string) string
- func Unlink(filename string) error
- func Usleep(microSeconds int64)
Constants ¶
This section is empty.
Variables ¶
var Empty = php2go.Empty
Empty empty()
var Exec = php2go.Exec
Exec exec() returnVar, 0: succ; 1: fail Return the last line from the result of the command. command format eg:
"ls -a" "/bin/bash -c \"ls -a\""
var IsNumeric = php2go.IsNumeric
IsNumeric is_numeric() Numeric strings consist of optional sign, any number of digits, optional decimal part and optional exponential part. Thus +0123.45e6 is a valid numeric value. In PHP hexadecimal (e.g. 0xf4c3b00c) is not supported, but IsNumeric is supported.
var ParseURL = php2go.ParseURL
ParseURL parse_url() Parse a URL and return its components -1: all; 1: scheme; 2: host; 4: port; 8: user; 16: pass; 32: path; 64: query; 128: fragment
var Passthru = php2go.Passthru
Passthru passthru() returnVar, 0: succ; 1: fail
var System = php2go.System
System system() returnVar, 0: succ; 1: fail Returns the last line of the command output on success, and "" on failure.
Functions ¶
func BaseConvert ¶
BaseConvert base_convert()
func FileGetContents ¶
php file_get_contents()
func FilePutContents ¶
php file_put_contents()
func Gethostbyaddr ¶
Gethostbyaddr gethostbyaddr() Get the Internet host name corresponding to a given IP address
func Gethostbyname ¶
Gethostbyname gethostbyname() Get the IPv4 address corresponding to a given Internet host name
func Gethostbynamel ¶
Gethostbynamel gethostbynamel() Get a list of IPv4 addresses corresponding to a given Internet host name
func HTMLEntityDecode ¶
HTMLEntityDecode html_entity_decode()
func HTTPBuildQuery ¶
HTTPBuildQuery http_build_query()
func Htmlspecialchars ¶
func HtmlspecialcharsDecode ¶
func Pathinfo ¶
Pathinfo pathinfo() -1: all; 1: dirname; 2: basename; 4: extension; 8: filename Usage: Pathinfo("/home/go/path/src/php2go/php2go.go", 1|2|4|8)
func StrReplace ¶
StrReplace str_replace()
Types ¶
This section is empty.