本文整理汇总了PHP中thesaurus::validate方法的典型用法代码示例。如果您正苦于以下问题:PHP thesaurus::validate方法的具体用法?PHP thesaurus::validate怎么用?PHP thesaurus::validate使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类thesaurus
的用法示例。
在下文中一共展示了thesaurus::validate方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: action
//.........这里部分代码省略.........
session::destroy("searchshow");
$_arg[linkaction] = "";
if ($_arg[id] == NULL) {
break;
} elseif ($_arg[id] > 0) {
session::set("show", $_arg[id]);
break;
} else {
session::delete("show");
break;
}
break;
//------------------------------------------------------------------------------
//------------------------------------------------------------------------------
case swap:
if ($_arg[id]) {
thesaurus::swap_link($_arg[id], $_arg[_ID]);
}
break;
case change:
if ($_arg[id]) {
// thesaurus::change_link($_arg);
}
break;
case add:
// add new descriptor
session::destroy("show");
session::destroy("searchshow");
// session::set("",1);
break;
// clean database
// clean database
case correct:
thesaurus::validate(true);
echoalert("Datenbank bereinigt");
break;
//------------------------------------------------------------------------------
// open hyrarchy down to selected entry
//------------------------------------------------------------------------------
// open hyrarchy down to selected entry
case showhyrarchy:
if ($_arg[id]) {
$hyrarchyArray = thesaurus::get_hyrarchy($_arg[id]);
// don't open selected entry
// array_pop($hyrarchyArray);
foreach ($hyrarchyArray as $entry) {
// echo $entry . " ";
echo session::open($entry);
}
session::set("hyrarchy", TRUE);
// hide search window
session::destroy("searchshow");
// if nothing selected for display, show ID
if (!session::get(show)) {
session::set("show", $_arg[id]);
}
break;
}
//------------------------------------------------------------------------------
// debug on/off
//------------------------------------------------------------------------------
// debug on/off
case debugon:
system::setval(debug, TRUE);
break;
case debugoff:
示例2: database
?>
</noscript>
</head>
<body>
<div id="overDiv" style="position:absolute; visibility:hidden; z-index:1000;"></div>
<?php
//echoalert($_JS);
// connect database
$daba = new database();
$daba->connect("localhost", "iggmp", "1s87J37r0");
$daba->select("thesaurus");
if (right::link()) {
thesaurus::validate();
}
// show login or logged user
user::show();
// headline
?>
<div id='header'>
<a href='index.php'>OpenThesaurus</a><br>
<?php
// show count of entries
echo " <i class='normal'>(";
echo database::count() . " Einträge mit ";
echo database::linkcount() . " Verknüpfungen";
echo ")</i>";
?>