$95 GRAYBYTE WORDPRESS FILE MANAGER $65

SERVER : vnpttt-amd7f72-h1.vietnix.vn #1 SMP Fri May 24 12:42:50 UTC 2024
SERVER IP : 103.200.23.149 | ADMIN IP 216.73.216.22
OPTIONS : CRL = ON | WGT = ON | SDO = OFF | PKEX = OFF
DEACTIVATED : NONE

/home/bqrcodec/contact.ucceurope.co/wp-content/plugins/wp-all-import-pro/classes/

HOME
Current File : /home/bqrcodec/contact.ucceurope.co/wp-content/plugins/wp-all-import-pro/classes//arraytoxml.php
<?php

class PMXI_ArrayToXML
{
    /**
    * The main function for converting to an XML document.
    * Pass in a multi dimensional array and this recrusively loops through and builds up an XML document.
    *
    * @param array $data
    * @param string $rootNodeName - what you want the root node to be - defaultsto data.
    * @param SimpleXMLElement $xml - should only be used recursively
    * @return string XML
    */
    public static function toXml($data, $rootNodeName = 'data', $xml=null, $lvl = 0)
    {

    	$data = apply_filters('wp_all_import_json_to_xml', $data);

      if ($xml == null)
      {
          $xml = simplexml_load_string('<?xml version="1.0" encoding="utf-8"?><'.$rootNodeName .'/>');
      }

     	if ( !empty($data)){
	        // loop through the data passed in.
	        foreach($data as $key => $value)
	        {
	            // no numeric keys in our xml please!
	            if (!$key or is_numeric($key))
	            {
	                // make string key...
	                $key = "item_" . $lvl;

	            }

	            // replace anything not alpha numeric
	            // preg_replace('/^[0-9]+/i', '', preg_replace('/[^a-z0-9_]/i', '', $key))
	            $key = preg_replace('/[^a-z0-9_]/i', '', $key);

                if ($key && is_numeric($key[0])) $key = 'v' . $key;

	            // if there is another array found recursively call this function
	            if (is_array($value) or is_object($value))
	            {
	                $node = $xml->addChild($key);
	                // recrusive call.
	                PMXI_ArrayToXML::toXml($value, $rootNodeName, $node, $lvl + 1);
	            }
	            else
	            {
	                // Allow disabling non-ascii character removal. Use the existing CSV filter for simplicity.
					$filter_non_ascii_chars = apply_filters('wp_all_import_csv_to_xml_remove_non_ascii_characters', true);

					// Add single node.
					$value = htmlspecialchars(($filter_non_ascii_chars ? preg_replace('/[^\x{0009}\x{000a}\x{000d}\x{0020}-\x{D7FF}\x{E000}-\x{FFFD}]+/u', ' ', $value) : $value));

					$xml->addChild($key, $value);

	            }

	        }
	    }
        // pass back as string. or simple xml object if you want!
        return $xml->asXML();
    }


}

Current_dir [ WRITEABLE ] Document_root [ WRITEABLE ]


[ Back ]
NAME
SIZE
LAST TOUCH
USER
CAN-I?
FUNCTIONS
..
--
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0755
PHPExcel
--
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0755
XmlStreamReader
--
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0755
filesystem
--
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0755
ftp
--
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0755
PHPExcel.php
30.876 KB
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0644
api.php
29.057 KB
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0644
arraytoxml.php
2.221 KB
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0644
chunk.php
11.885 KB
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0644
cli.php
7.526 KB
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0644
config.php
2.214 KB
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0644
download.php
0.944 KB
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0644
error.php
3.07 KB
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0644
handler.php
4.599 KB
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0644
helper.php
4.105 KB
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0644
input.php
2.367 KB
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0644
installer.php
1.022 KB
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0644
nested.php
2.593 KB
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0644
render.php
13.154 KB
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0644
session.php
1.956 KB
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0644
updater.php
24.927 KB
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0644
upload.php
43.045 KB
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0644
zip.php
1.596 KB
25 Jul 2024 12.20 AM
bqrcodec / bqrcodec
0644

GRAYBYTE WORDPRESS FILE MANAGER @ 2026 CONTACT ME
Static GIF