Initial checkin
This commit is contained in:
commit
d75eb444fc
4304 changed files with 369634 additions and 0 deletions
29
modules/text/text.ajax.php
Normal file
29
modules/text/text.ajax.php
Normal file
|
@ -0,0 +1,29 @@
|
|||
<?php
|
||||
If (!defined("in_astat")) {
|
||||
die("Dieses Script kann nicht ausserhalb des Frameworks laufen!");
|
||||
}
|
||||
$addnav["right"]=FALSE;
|
||||
$session->page_begin("Text Module", FALSE);
|
||||
|
||||
$topnav_home="<li><a href=\"/index.php\">Home</a></li>";
|
||||
|
||||
class text extends ajax_module{
|
||||
|
||||
function ajax(){
|
||||
global $module,$config,$db,$tpl,$log,$error;
|
||||
if($_POST['call']=="url"){
|
||||
if(isset($_POST['url'])&& $_POST['url']!=""){
|
||||
$url=$db->escape($_POST['url']);
|
||||
$result = $db->query("SELECT count(`id`) as `count` FROM `" . $config["prefix"] . "article` WHERE `url`='".$url."'");
|
||||
$row = $db->fetch_array($result, MYSQL_ASSOC);
|
||||
if($row["count"]==0){
|
||||
echo 0;
|
||||
}else{
|
||||
echo 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
?>
|
Loading…
Add table
Add a link
Reference in a new issue