Ignore:
Timestamp:
Jun 3, 2006 7:47:48 PM (18 years ago)
Author:
scdev
Message:

Q - Merged branches/2.0singleton into trunk. Completed updating classes to use singleton methods. Implemented tests. Fixed some bugs. Changed some interfaces.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bin/module_maker/module.cli.php

    r119 r136  
    129129
    130130// Get DB tables.
    131 $qid = DB::query("SHOW TABLES");
     131$qid = $db->query("SHOW TABLES");
    132132while (list($row) = mysql_fetch_row($qid)) {
    133133    $tables[] = $row;
     
    136136// Make sure requested table is in database.
    137137if (!in_array($db_tbl, $tables)) {
    138     die(sprintf("%s Warning: %s does not exist in database %s. Please select one of: \n\n%s\n\n", basename($_SERVER['argv'][0]), $db_tbl, App::getParam('db_name'), join("\n", $tables)));
     138    die(sprintf("%s Warning: %s does not exist in database %s. Please select one of: \n\n%s\n\n", basename($_SERVER['argv'][0]), $db_tbl, $app->getParam('db_name'), join("\n", $tables)));
    139139}
    140140
    141141// Ensure requested table contains columns.
    142142// Get DB table column info.
    143 $qid = DB::query("DESCRIBE " . DB::escapeString($db_tbl));
     143$qid = $db->query("DESCRIBE " . $db->escapeString($db_tbl));
    144144while ($row = mysql_fetch_row($qid)) {
    145145    $cols[] = $row;
     
    266266        // If file upload errors, redirect to edit operation for the inserted record.
    267267        if (\$upload->anyErrors() || false === \$new_file) {
    268             App::dieURL(\$_SERVER['PHP_SELF'] . '?op=edit&%PRIMARY_KEY%=' . \$%PRIMARY_KEY%);
     268            \$app->dieURL(\$_SERVER['PHP_SELF'] . '?op=edit&%PRIMARY_KEY%=' . \$%PRIMARY_KEY%);
    269269        }
    270270E_O_F;
     
    300300
    301301$search['date'] = '/%DATE%/';
    302 $replace['date'] = date(App::getParam('date_format'));
     302$replace['date'] = date($app->getParam('date_format'));
    303303
    304304$search['name_plural'] = '/%NAME_PLURAL%/';
Note: See TracChangeset for help on using the changeset viewer.