当前位置: 首页>>代码示例>>PHP>>正文


PHP WT_Filter::escapeUrl方法代码示例

本文整理汇总了PHP中WT_Filter::escapeUrl方法的典型用法代码示例。如果您正苦于以下问题:PHP WT_Filter::escapeUrl方法的具体用法?PHP WT_Filter::escapeUrl怎么用?PHP WT_Filter::escapeUrl使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在WT_Filter的用法示例。


在下文中一共展示了WT_Filter::escapeUrl方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: unset

        unset($xrefs[$old_xref]);
        WT_DB::exec("UNLOCK TABLES");
        WT_DB::exec("COMMIT");
        try {
            WT_DB::prepare("UPDATE `##favorite` SET xref = ? WHERE xref = ? AND gedcom_id = ?")->execute(array($new_xref, $old_xref, WT_GED_ID));
        } catch (Exception $ex) {
            // Perhaps the favorites module was not installed?
        }
        // How much time do we have left?
        if (microtime(true) - $start_time > ini_get('max_execution_time') - 5) {
            echo '<p>', WT_I18N::translate('The server’s time limit was reached.'), '</p>';
            break;
        }
    }
    if ($xrefs) {
    }
} else {
    echo '<p>', WT_I18N::translate('In a family tree, each record has an internal reference number (called an “XREF”) such as “F123” or "R14".'), '</p>';
    echo '<p>', WT_I18N::translate('You can renumber a family tree so that these reference numbers are unique across all family trees.'), '</p>';
}
echo '<p>', WT_I18N::plural('This family tree has %s record which uses the same “XREF” as another family tree.', 'This family tree has %s records which use the same “XREF” as another family tree.', count($xrefs), count($xrefs)), '</p>';
if ($xrefs) {
    // We use GET (not POST) for this update operation - because we want the user to
    // be able to press F5 to continue after a timeout.
    echo '<form method="GET" action="', WT_SCRIPT_NAME, '">';
    echo '<p>', WT_I18N::translate('You can renumber this family tree.');
    echo '<input type="submit" name="go" value="', WT_I18N::translate('go'), '"></p>';
    echo '<input type="hidden" name="ged" value="', WT_Filter::escapeUrl(WT_GEDCOM), '">';
    echo '</form>';
    echo '<p>', WT_I18N::translate('Caution!  This may take a long time.  Be patient.'), '</p>';
}
开发者ID:brambravo,项目名称:webtrees,代码行数:31,代码来源:admin_trees_renumber.php


注:本文中的WT_Filter::escapeUrl方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。