Example #1
0
/**
 * Displays both the "List of current recipes" and
 * "Insert a new recipe" panels in a single table.
 * @param string $tableTitle The title to display in the html table
 * @param string $sessionToken A session token
 * @return void
 */
function showMainMenu($tableTitle, $sessionToken)
{
    printHTMLHeader();
    print '<table style="width: 75%;text-align:center">' . "\n" . '<tr>' . "\n" . '<th colspan="2" style="text-align:center;">' . 'PHP Demo: Google Base data API<br />' . '<font size="-1">' . '<span style="font-variant: small-caps;">Powered By</span> ' . '<a href="http://framework.zend.com/download/gdata">' . 'Zend Google Data Client Library</a></font></th>' . "\n" . '</tr>' . "\n" . '<tr><td colspan="2" align="center">' . $tableTitle . "</td></tr>\n" . '<tr>' . "\n";
    // Create the two sub-tables.
    showRecipeListPane($sessionToken);
    showRecipeInsertPane($sessionToken);
    // Add a "Sign out" link.
    print '<tr><th colspan="2" style="text-align: center">Or click here to' . ' <a href="http://www.google.com/accounts/Logout">sign out</a>' . ' of your Google account.</th></tr>' . "\n";
    // Close the master table.
    print '</table>' . "\n";
    printHTMLFooter();
}
/**
 * Displays both the "List of current recipes" and
 * "Insert a new recipe" panels in a single table.
 */
function showMainMenu($tableTitle, $sessionToken)
{
    print '<html>' . "\n";
    print '<head><title>PHP 4 Demo: Google Base data API</title>' . "\n";
    print '<link rel="stylesheet" type="text/css" href="http://code.google.com/css/dev_docs.css">' . "\n";
    print '</head>' . "\n";
    print '<body><center>' . "\n";
    print '<table style="width: 75%;text-align:center">' . "\n";
    print '<tr>' . "\n";
    print '<th colspan="2" style="text-align:center">PHP 4 Demo: Google Base data API' . "\n";
    print '</tr>' . "\n";
    print '<tr><td colspan="2" align="center">' . $tableTitle . '</td></tr>' . "\n";
    print '<tr>' . "\n";
    // Create the two sub-tables.
    showRecipeListPane($sessionToken);
    showRecipeInsertPane($sessionToken);
    // Add a "Sign out" link.
    print '<tr><th colspan="2" style="text-align: center">Or click here to' . ' <a href="http://www.google.com/accounts/Logout">sign out</a>' . ' of your Google account.</th></tr>' . "\n";
    // Close the master table.
    print '</table>' . "\n";
    print '</center></body></html>' . "\n";
}