| 
<?php
//dotgo mobile emulator
 //for use with dotgoEm class ver 0.1 beta
 include('dotgoem.class.php');
 
 $emulate = new dotgoEm();
 
 if( !empty($_REQUEST['formPosted']) ){
 
 $query = $_REQUEST['query'];
 $shortCode = $_REQUEST['shortCode'];
 
 $response = $emulate->getResponse($query,$shortCode);
 
 }else{
 
 $_REQUEST['query'] = '';
 $_REQUEST['shortCode'] = '';
 $response = '';
 
 }
 
 ?>
 <!DOCTYPE html>
 <html>
 <head>
 <title></title>
 <style type="text/css">
 body{
 
 color: whitesmoke;
 background-color: black;
 
 }
 #apiResponse{
 
 width: 300px;
 height: 400px;
 border: thin solid white;
 
 }
 #queryText{
 
 width: 300px;
 
 }
 </style>
 </head>
 <body>
 <div id="apiResponse"><?PHP echo $response;?></div>
 <div><a href="http://dotgo.com/" target="_blank"><img src="img/DOTGO_powered.png" width="80" height="15" border="0"></a></div>
 <form method="POST">
 <input type="text" name="query" value="" id="queryText" autofocus="true"><br>
 <select name="shortCode">
 <option value="368266"<?PHP echo ( $_REQUEST['shortCode'] == '368266' ) ? ' selected' : '';?>>DOTCOM (368266)</option>
 <option value="368638"<?PHP echo ( $_REQUEST['shortCode'] == '368638' ) ? ' selected' : '';?>>DOTNET (368638)</option>
 <option value="368674"<?PHP echo ( $_REQUEST['shortCode'] == '368674' ) ? ' selected' : '';?>>DOTORG (368674)</option>
 </select><br>
 <input type="hidden" name="formPosted" value="1"><input type="submit" name="formSubmit" value="Send">
 </form>
 </body>
 </html>
 
 |