Location: PHPKode > projects > AxcotoCart > admin/themes/foreign.php
<?php
if (!defined("VCL")) {
  echo "Don't try to hack me :D";
  exit;
};

function thememancurrencies() {
  global $boardurl;
  global $context;
 
  if (isset($context['currencies'])) {
    echo "
	
    <div id='CurList'>
      <ul>
    ";
    foreach ($context['currencies'] as $currency) {
      echo "
        <li>",$currency['name'],"</li>";
    echo "
      </ul>
    </div>";
      
    
    };    
  };
  echo "

	<script language='javascript' src='{$boardurl}js/AdmRequest.js'></script>
  <div>
    New currency
    <form name='Currency' method='GET' action=\"#\" onSubmit=\"javascript:return false;\">
      Name<input type=text value='name' id='name' size=20 /><br />
      Value<input type=text value='value' id='value' size=20 /><br />
      Left symbol<input type=text name='leftSym' id='leftSym' size=20 /><br />
      Right symbol<input type=text name='rightSym' id='rightSym' size=20 /><br />
      <input type=submit name=\"save\" value='Save' onclick='saveCur();' />      
    </form>
  </div>	
	<a onclick=\"alert(document.getElementById('value').value);return false;\" href='#'>Get Val</a>
	";
};

/*
 * ----------------------------------
 * @Purpose: load template when adding currencyh completed
 * @Params:
 * 	-$result: eval 1 if add currency succed, or otherwise
 */
function themeaddcurrency($result) {
	if ($result) {
		echo "Adding",$context['currency']['name']," succeeded";		
	};
	if (isset($context['currencies'])) {
    echo "
	
    <div id='CurList'>
      <ul>
    ";
    foreach ($context['currencies'] as $currency) {
      echo "
        <li>",$currency['name'],"</li>";
    echo "
      </ul>
    </div>";
      
    
    };    
  };
  echo "
	<script language='javascript' src='{$boardurl}js/foreign.js'></script>
  <div>
    New currency
    <form name='Currency' method='GET' action=\"#\" onSubmit=\"javascript:return false;\">
      Name<input type=text value='name' name='name' id='name' size=20 /><br />
      Value<input type=text value='value' name='value' id='value' size=20 /><br />
      Left symbol <input type=text name='leftSym'  id='leftSym' size=20 /><br />
      Right symbol<input type=text name='rightSym' id='rightSym' size=20 /><br />
      <input type=submit name=\"save\" value='Save' onclick='saveCur();' />      
    </form>
  </div>";	
}
?>
Return current item: AxcotoCart