Login   Register  
PHP Classes
elePHPant
Icontem

File: pictcaptcha_link.php

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of Patricio Cardó  >  Pict CAPTCHA  >  pictcaptcha_link.php  >  Download  
File: pictcaptcha_link.php
Role: Auxiliary script
Content type: text/plain
Description: linker file
Class: Pict CAPTCHA
CAPTCHA validation making the user select pictures
Author: By
Last change:
Date: 2013-05-08 04:53
Size: 949 bytes
 

Contents

Class file image Download
<?php
session_start
();
$dir = (isset($_SESSION["pictcapt_dir"]))? $_SESSION["pictcapt_dir"] : __DIR__."/";

if(!empty(
$_GET["ty"])){
    if(
$_GET["ty"] == "arrow"){
        include 
$dir."imgs/defold.gif";
    }elseif(
$_GET["ty"] == "js"){
        
header('Content-type: text/javascript');
        include 
$dir."pictcaptcha.js";
    }elseif(
$_GET["ty"] == "css"){
        
header('Content-type: text/css');
        include 
$dir."pictcaptcha.css";
    }elseif(
$_GET["ty"] == "reload"){
        include 
$dir."imgs/reload.gif";
    }elseif(
$_GET["ty"] == "ifr" && !empty($_GET["sesna"])){
            include 
$dir."pictcaptcha_f.php";
//    print "<pre>".var_export($_SESSION, true)."</pre>";    
    
}elseif($_GET["ty"] == "img" && isset($_SESSION["pictcapt_".$_GET["sesna"]])){
        include 
$dir."pictcaptcha_conf.php";
        
$assoc unserialize($_SESSION["pictcapt_".$_GET["sesna"]]);
        
$obj $assoc[$_GET["id"]];
        include 
$dir."imgs/"$pict_capt_vars["objects"][$obj]["img"];
    }
}else{
    include 
$dir."imgs/equis.gif";
}
?>