aboutsummaryrefslogtreecommitdiff
path: root/mod/captcha/captcha.php
diff options
context:
space:
mode:
authorcash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>2011-01-04 02:25:04 +0000
committercash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>2011-01-04 02:25:04 +0000
commit7e14e7bd44deca48ce78f481185ef9bc8fefd9ca (patch)
tree7cd30b0ef178a09e6030737516a904a828b58f17 /mod/captcha/captcha.php
parent137229f132b0402778dcfe5a86d99be427c33da0 (diff)
downloadelgg-7e14e7bd44deca48ce78f481185ef9bc8fefd9ca.tar.gz
elgg-7e14e7bd44deca48ce78f481185ef9bc8fefd9ca.tar.bz2
moving captcha and crontrigger plugins out of core
git-svn-id: http://code.elgg.org/elgg/trunk@7823 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'mod/captcha/captcha.php')
-rw-r--r--mod/captcha/captcha.php35
1 files changed, 0 insertions, 35 deletions
diff --git a/mod/captcha/captcha.php b/mod/captcha/captcha.php
deleted file mode 100644
index c4b9135f9..000000000
--- a/mod/captcha/captcha.php
+++ /dev/null
@@ -1,35 +0,0 @@
-<?php
-/**
- * Elgg captcha plugin graphics file generator
- *
- * @package ElggCaptcha
- */
-
-global $CONFIG;
-$token = get_input('captcha_token');
-
-// Output captcha
-if ($token) {
- // Set correct header
- header("Content-type: image/jpeg");
-
- // Generate captcha
- $captcha = captcha_generate_captcha($token);
-
- // Pick a random background image
- $n = rand(1, $CONFIG->captcha_num_bg);
- $image = imagecreatefromjpeg($CONFIG->pluginspath . "captcha/backgrounds/bg$n.jpg");
-
- // Create a colour (black so its not a simple matter of masking out one colour and ocring the rest)
- $colour = imagecolorallocate($image, 0,0,0);
-
- // Write captcha to image
- //imagestring($image, 5, 30, 4, $captcha, $black);
- imagettftext($image, 30, 0, 10, 30, $colour, $CONFIG->pluginspath . "captcha/fonts/1.ttf", $captcha);
-
- // Output image
- imagejpeg($image);
-
- // Free memory
- imagedestroy($image);
-}