本文整理汇总了PHP中PMA_getDeleteDataOrTablelink函数的典型用法代码示例。如果您正苦于以下问题:PHP PMA_getDeleteDataOrTablelink函数的具体用法?PHP PMA_getDeleteDataOrTablelink怎么用?PHP PMA_getDeleteDataOrTablelink使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了PMA_getDeleteDataOrTablelink函数的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: PMA_getHtmlForDeleteDataOrTable
/**
* Get HTML for Delete data or table (truncate table, drop table)
*
* @param array $truncate_table_url_params url parameter array for truncate table
* @param array $dropTableUrlParams url parameter array for drop table
*
* @return string $html_output
*/
function PMA_getHtmlForDeleteDataOrTable($truncate_table_url_params, $dropTableUrlParams)
{
$html_output = '<div class="operations_half_width">' . '<fieldset class="caution">' . '<legend>' . __('Delete data or table') . '</legend>';
$html_output .= '<ul>';
if (!empty($truncate_table_url_params)) {
$html_output .= PMA_getDeleteDataOrTablelink($truncate_table_url_params, 'TRUNCATE_TABLE', __('Empty the table (TRUNCATE)'), 'truncate_tbl_anchor');
}
if (!empty($dropTableUrlParams)) {
$html_output .= PMA_getDeleteDataOrTablelink($dropTableUrlParams, 'DROP_TABLE', __('Delete the table (DROP)'), 'drop_tbl_anchor');
}
$html_output .= '</ul></fieldset></div>';
return $html_output;
}
示例2: testGetDeleteDataOrTablelink
/**
* Test for PMA_getDeleteDataOrTablelink
*
* @return void
*/
public function testGetDeleteDataOrTablelink()
{
$this->assertRegExp('/.*TRUNCATE.TABLE.foo.*id_truncate.*Truncate table.*/m', PMA_getDeleteDataOrTablelink(array("sql" => 'TRUNCATE TABLE foo'), "TRUNCATE_TABLE", "Truncate table", "id_truncate"));
}