Login   Register  
PHP Classes
elePHPant
Icontem

File: readme.txt

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of Sudhir Chauhan  >  Binary XML  >  readme.txt  >  Download  
File: readme.txt
Role: Documentation
Content type: text/plain
Description: readme.txt
Class: Binary XML
Generate and parse XML documents with binary files
Author: By
Last change:
Date: 5 years ago
Size: 773 bytes
 

Contents

Class file image Download
Created by chauhansudhir@gmail.com
* This is an example to demonstatrate how we can embed binary in XML. Here an array of images path
* given to generateBinaryXML method and XML document saved in the given path. savePath should be a
* physical path because images are large in size and results large XML document.



create output folder and implement the following code


require('BinaryXML.php');
$binaryXML = new BinaryXML();
$savePath = 'test.xml';
$images = Array('1.jpg', '2.jpg', '3.jpg', '4.jpg');
$result = $binaryXML->generateBinaryXML($images, $savePath, true, '1.0');
if ($result) {
	print 'XML generated';
}
else {
	print 'XML not generated';
}

# parse XML and saves images to output folder
$binaryXML->parseXML($savePath, 'output/');