Beispiel #1
0
    $heading = str_replace('_', ' ', $request);
    $content_name = ucwords($heading);
    if ($request == 'all_content') {
        $headers = array('content id', 'content name', 'description', 'content', 'created', 'link');
        $cells = array('contentid', 'contentname', 'contentdesc', 'contenttext', 'contentcreated');
        $query = 'SELECT * FROM ' . DB_CONTENT . '';
        $result = basicQuery($query);
        $link = '<a href="' . $root_content . 'content_viewer.inc.php?contentid=';
        $link_end = '">View content</a>';
        outputTable($headers, $cells, $result, $link, $link_end);
    } else {
        if ($request == 'all_users') {
            $headers = array('user id', 'username', 'first name', 'last name', 'created');
            $cells = array('userid', 'username', 'firstname', 'lastname', 'usercreated');
            $query = 'SELECT * FROM ' . DB_USERS . '';
            $result = basicQuery($query);
            $link = '<a href="' . $root_user . 'user_viewer.inc.php?userid=';
            $link_end = '">View User</a>';
            outputTable($headers, $cells, $result, $link, $link_end);
        } else {
            // for user error reporting
            exit('Invalid request - Please return to the <a href="../../">Home menu</a>.');
        }
    }
} else {
    exit('No request - Please return to the <a href="../../">Home menu</a>.');
}
?>

</body>
</html>
Beispiel #2
0
					Download
				</th>
			</tr>
		</thead>
		<tbody>
			<?php 
if ($_SERVER['REQUEST_METHOD'] == 'GET') {
    $list = explode("-", $_GET['date']);
    $date = $list[0] . $list[1];
    $Paysheets->SearchByAccount($_GET['acc'], $date);
    outputTable($Paysheets);
} else {
    $Users->GetAll();
    while ($Users->HasNext()) {
        $Paysheets->GetByAccount($Users->UserAccount);
        outputTable($Paysheets);
    }
}
function outputTable($Paysheets)
{
    while ($Paysheets->HasNext()) {
        $fileName = $Paysheets->FileName;
        $year = explode("-", $fileName);
        $month = explode(".", $year[2]);
        echo '<tr>
					<td>' . $Paysheets->Account . '</td>
					<td>
					' . $year[1] . '
					</td>
					<td>
					' . $month[0] . '
Beispiel #3
0
               </td>
               <td><img src="../Common/Images/titlebar_end.gif" width=8 height=30></td>
            </tr>
            </table>

          </td>

          <td width=8>&nbsp;</td>
          <td><nobr>
              <img src="../Common/Images/logout.gif" border=0 alt="Logout" align=absmiddle><span style='padding-left:2px'><a href='#'>Logout</a></span>
           </nobr></td>
        </tr>
   </table>
   <br>

<?php 
outputBreadcrumb($path);
?>
<br>
<?php 
outputTable("Browse Spaces", $currentNode, "{http://www.alfresco.org/model/content/1.0}folder", "There are no spaces");
?>
<br>
<?php 
outputTable("Content Items", $currentNode, "{http://www.alfresco.org/model/content/1.0}content", "There is no content");
?>

   </body>

</html>
Beispiel #4
0
<?php

/*
test.php
used for debugging and testing functions
*/
require_once "functions/output_helpers.php";
$object = new stdClass();
$object->prop1 = "value1";
$object->prop2 = "value2";
$object->prop3 = "value3";
echo outputTable($object, array("keys", "values"), true);
$array = array("key" => "value", "key1" => "value", "key2" => "value", "key3" => "value", "key4" => "value", "key5" => "value", "key6" => "value", "key7" => "value");
echo outputTable($array, array("keys", "values"), true);
$object_array = array($object, $object, $object, $object, $object, $object);
echo outputTable($object_array, array("prop1", "prop2", "prop3"));