PHP Classes
elePHPant
Icontem

File: sample.php

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of Jonathan Discipulo  >  Forex Class for PHP 5  >  sample.php  >  Download  
File: sample.php
Role: Example script
Content type: text/plain
Description: Sample File
Class: Forex Class for PHP 5
Convert money between currencies using iGoogle API
Author: By
Last change:
Date: 2 years ago
Size: 358 bytes
 

Contents

Class file image Download
<?php

require_once('class.forex.php');

$forex = new Forex();
$forex->convert( '1', 'USD', 'PHP' );

echo
$forex->get('from') . ' ' . $forex->get('amount') . ' is equal to ' . $forex->get('to') . ' ' . $forex->get('converted') . ' as of ' . $forex->get('stamp') . '<br>';

echo
"<xmp>";
print_r( $forex->getResultArray() );
echo
"</xmp>";

?>