Instance
Decodes a uuencode encoded string:
<?php$str = ", 2&5l;&@=v]r;&0a '"; Echo Convert_uudecode ($STR);? >
Definition and usage
The Convert_uudecode () function decodes a uuencode encoded string.
This function is typically used with the Convert_uuencode () function.
Grammar
Convert_uudecode (String)
Parameter D describes
string is required. A string that specifies the Uuencode encoding to decode.
Technical details
Return value: Returns the decoded data as a string.
PHP version: 5+
More examples
Encode the string, and then decode it:
<?php$str = "Hello world!"; /Encode The string$encodestring = Convert_uuencode ($STR); Echo $encodeString. "<br>";//Decode The string$decodestring = Convert_uudecode ($encodeString); Echo $decodeString;? >
Convert_uudecode instances
XML file:
<?xml version= "1.0" encoding= "iso-8859-1"? ><note xmlns:b= "http://www.w3school.com.cn/example/" ><to >george</to><from>john</from>
PHP Code:
<?phpif (file_exists (' Test.xml ')) { $xml = simplexml_load_file (' Test.xml '); } Print_r ($xml->getdocnamespaces ());? >
The output is similar to:
Array ([b] = http://www.w3school.com.cn/example/)