PHP implements a function that decodes a uuencode encoded string Convert_uudecode ()

Source: Internet
Author: User

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/)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.