SimplePie_Misc
Miscellaneous utilities
- Full name:
\SimplePie_Misc
- Parent class:
\SimplePie\Misc
- Warning: this class is deprecated. This means that this class will likely be removed in a future version.
Inherited methods
time_hms
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$seconds |
mixed |
absolutize_url
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$relative |
mixed | |
$base |
mixed |
get_element
Get a HTML/XML element from a HTML string
-
This method is static.
-
Warning: this method is deprecated. This means that this method will likely be removed in a future version.
Parameters:
Parameter | Type | Description |
---|---|---|
$realname |
string | Element name (including namespace prefix if applicable) |
$string |
string | HTML document |
element_implode
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$element |
mixed |
error
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$message |
mixed | |
$level |
mixed | |
$file |
mixed | |
$line |
mixed |
fix_protocol
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$url |
mixed | |
$http |
mixed |
array_merge_recursive
-
This method is static.
-
Warning: this method is deprecated. This means that this method will likely be removed in a future version.
Parameters:
Parameter | Type | Description |
---|---|---|
$array1 |
mixed | |
$array2 |
mixed |
parse_url
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$url |
mixed |
compress_parse_url
public static compress_parse_url(mixed $scheme = '', mixed $authority = '', mixed $path = '', mixed $query = '', mixed $fragment = ''): mixed
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$scheme |
mixed | |
$authority |
mixed | |
$path |
mixed | |
$query |
mixed | |
$fragment |
mixed |
normalize_url
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$url |
mixed |
percent_encoding_normalization
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$match |
mixed |
windows_1252_to_utf8
Converts a Windows-1252 encoded string to a UTF-8 encoded string
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$string |
string | Windows-1252 encoded string |
Return Value:
UTF-8 encoded string
change_encoding
Change a string from one encoding to another
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$data |
string | Raw data in $input encoding |
$input |
string | Encoding of $data |
$output |
string | Encoding you want |
Return Value:
False if we can't convert it
change_encoding_mbstring
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$data |
mixed | |
$input |
mixed | |
$output |
mixed |
change_encoding_iconv
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$data |
mixed | |
$input |
mixed | |
$output |
mixed |
change_encoding_uconverter
protected static change_encoding_uconverter(string $data, string $input, string $output): string|false
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$data |
string | |
$input |
string | |
$output |
string |
encoding
Normalize an encoding name
This is automatically generated by create.php
To generate it, run php create.php
on the command line, and copy the
output to replace this function.
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$charset |
string | Character set to standardise |
Return Value:
Standardised name
get_curl_version
- This method is static.
strip_comments
Strip HTML comments
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$data |
string | Data to strip comments from |
Return Value:
Comment stripped string
parse_date
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$dt |
mixed |
entities_decode
Decode HTML entities
-
This method is static.
-
Warning: this method is deprecated. This means that this method will likely be removed in a future version.
Parameters:
Parameter | Type | Description |
---|---|---|
$data |
string | Input data |
Return Value:
Output data
uncomment_rfc822
Remove RFC822 comments
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$string |
mixed |
Return Value:
Comment stripped string
parse_mime
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$mime |
mixed |
atom_03_construct_type
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$attribs |
mixed |
atom_10_construct_type
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$attribs |
mixed |
atom_10_content_construct_type
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$attribs |
mixed |
is_isegment_nz_nc
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$string |
mixed |
space_separated_tokens
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$string |
mixed |
codepoint_to_utf8
Converts a unicode codepoint to a UTF-8 character
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$codepoint |
int | Unicode codepoint |
Return Value:
UTF-8 character
parse_str
Similar to parse_str()
Returns an associative array of name/value pairs, where the value is an array of values that have used the same name
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$str |
string | The input string. |
xml_encoding
Detect XML encoding, as per XML 1.0 Appendix F.1
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$data |
string | XML data |
$registry |
\SimplePie\Registry | Class registry |
Return Value:
Possible encodings
output_javascript
- This method is static.
get_build
Get the SimplePie build timestamp
Uses the git index if it exists, otherwise uses the modification time of the newest file.
- This method is static.
get_default_useragent
Get the default user agent string
- This method is static.
debug
Format debugging information
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$sp |
mixed |
silence_errors
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$num |
mixed | |
$str |
mixed |
url_remove_credentials
Sanitize a URL by removing HTTP credentials.
- This method is static.
Parameters:
Parameter | Type | Description |
---|---|---|
$url |
string | the URL to sanitize. |
Return Value:
the same URL without HTTP credentials.
Automatically generated on 2025-03-18