本文整理匯總了PHP中Banner::getTables方法的典型用法代碼示例。如果您正苦於以下問題:PHP Banner::getTables方法的具體用法?PHP Banner::getTables怎麽用?PHP Banner::getTables使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Banner
的用法示例。
在下文中一共展示了Banner::getTables方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: install
function install()
{
global $application;
loadCoreFile('csv_parser.php');
$csv_parser = new CSV_Parser();
$tables = Banner::getTables();
$query = new DB_Table_Create($tables);
$table_banners_settings = 'banners_settings';
$columns = $tables[$table_banners_settings]['columns'];
list($flt, $Default_Settings) = $csv_parser->parse_file(dirname(__FILE__) . "/includes/default_settings.csv");
foreach ($Default_Settings as $key => $setting) {
$query = new DB_Insert($table_banners_settings);
$query->addInsertValue($setting["key"], $columns['setting_key']);
$query->addInsertValue($setting["value"], $columns['setting_value']);
$application->db->getDB_Result($query);
}
}
示例2: initQuery
function initQuery($params)
{
$tables = Banner::getTables();
$tr = $tables['banners_images']['columns'];
$this->addInsertValue($params[0]['bannerid'], $tr['bannerid']);
$this->addInsertValue($params[0]['image_path'], $tr['image_path']);
$this->addInsertValue($params[0]['image_type'], $tr['image_type']);
$this->addInsertValue($params[0]['image_x'], $tr['image_x']);
$this->addInsertValue($params[0]['image_y'], $tr['image_y']);
$this->addInsertValue($params[0]['image_size'], $tr['image_size']);
$this->addInsertValue($params[0]['filename'], $tr['filename']);
$this->addInsertValue($params[0]['date'], $tr['date']);
$this->addInsertValue($params[0]['alt'], $tr['alt']);
$this->addInsertValue($params[0]['url'], $tr['url']);
$this->addInsertValue($params[0]['type'], $tr['type']);
}