diff --git a/addons/ajax.js b/addons/ajax.js deleted file mode 100755 index f869c23..0000000 --- a/addons/ajax.js +++ /dev/null @@ -1,9 +0,0 @@ -jQuery(document).on("submitResponse.default", function(e, response){ - jQuery("#fc-ninja").html("
Loading new challenge...
"); - jQuery.post(the_ajax_script.ajaxurl, - { 'action': 'new_fc' }, - function(newfc_ajax){ - jQuery("#fc-ninja").html(newfc_ajax); - } - ); -}); \ No newline at end of file diff --git a/addons/wp_funcaptcha_cf7.php b/addons/wp_funcaptcha_cf7.php deleted file mode 100755 index 046b838..0000000 --- a/addons/wp_funcaptcha_cf7.php +++ /dev/null @@ -1,90 +0,0 @@ -name)) - return ''; - - $html = funcaptcha_get_fc_html(); - - $html .= ' '; - - - return apply_filters('wpcf7_funcaptcha_html_output', $html); -} - -/** -* validate funcaptcha -* -* @return array -*/ -function funcaptchacf7_validate($result, $tag) { - $tag = new WPCF7_Shortcode( $tag ); - $name = $tag->name; - - $funcaptcha = funcaptcha_API(); - $options = funcaptcha_get_settings(); - - if ( $funcaptcha->checkResult($options['private_key']) ) { - return $result; - } else { - $result['valid'] = false; - $result['reason'] = array($name => $options['error_message']); - return $result; - } -} - -/** -* setup [funcaptcha] tag -* -* @return null -*/ -function funcaptchacf7_tag_generator() { - wpcf7_add_tag_generator('funcaptcha', 'FunCaptcha', 'funcaptchacf7-tag-pane', 'funcaptchacf7_tag_pane'); -} - -/** -* display funcaptcha in contact form 7 editor -* -* @return null -*/ -function funcaptchacf7_tag_pane($contact_form) { - ?> -$message
\n"; - return array( - "html" => $html, - "api_server" => "https://" . $this->funcaptcha_host, - ); - } - } - - /** - * Set security level of FunCaptcha - * - * Possible options are: - * 0 - Automatic-- security rises for suspicious users - * 20 - Enhanced security-- always use Enhanced security - * - * See our website for more details on these options - * - * @param int $security - Security level - * @return boolean - */ - public function setSecurityLevel($security) { - $this->funcaptcha_security_level = $security; - $this->msgLog("DEBUG", "Security Level: '$this->funcaptcha_security_level'"); - } - - /** - * Set theme of FunCaptcha - * - * See here for options: https://www.funcaptcha.co/themes/ - * - * @param int $theme - theme option, 0 is default. - * @return boolean - */ - public function setTheme($theme) { - $this->funcaptcha_theme = $theme; - $this->msgLog("DEBUG", "Theme: '$this->funcaptcha_theme'"); - } - - /** - * Set proxy for FunCaptcha - * - * @param int $proxy - Proxy server (including port, eg: 111.11.11.111:8080) - * @return boolean - */ - public function setProxy($proxy) { - $this->funcaptcha_proxy = $proxy; - $this->msgLog("DEBUG", "Proxy: '$this->funcaptcha_proxy'"); - } - - /** - * Set lightbox mode of FunCaptcha - * - * - * See our website for more details on these options - * - * @param boolean $enable - Enable lightbox mode. - * @param boolean $submit_button_id - ID of button to be used to display lightbox. - * @param boolean $submit_javascript_function_name - Name of javascript function to call on lightbox FunCaptcha completion. - * @return boolean - */ - public function setLightboxMode($enable, $submit_button_id=null, $submit_javascript_function_name=null) { - $this->funcaptcha_lightbox_mode = $enable; - $this->funcaptcha_lightbox_button_id = $submit_button_id; - $this->funcaptcha_lightbox_submit_javascript = $submit_javascript_function_name; - $this->msgLog("DEBUG", "Lightbox mode: '$this->funcaptcha_lightbox_mode'"); - $this->msgLog("DEBUG", "Lightbox Button ID: '$this->funcaptcha_lightbox_button_id'"); - $this->msgLog("DEBUG", "Lightbox JS Name: '$this->funcaptcha_lightbox_submit_javascript'"); - } - - /** - * Verify if user has solved the FunCaptcha - * - * @param string $private_key - FunCaptcha private key - * @param array $args - Additional information to pass to FunCaptcha servers - * @return boolean - */ - public function checkResult($private_key, $args=null) { - $this->funcaptcha_private_key = $private_key; - - $this->msgLog("DEBUG", ("Session token to check: " . $_POST['fc-token'])); - - if ($this->funcaptcha_private_key == "") - { - $this->msgLog("ERROR", "Warning: Private key is not set."); - } - else - { - $this->msgLog("DEBUG", "Private key: '$this->funcaptcha_private_key'"); - } - - if ($_POST['fc-token']) { - $data = array( - 'private_key' => $this->funcaptcha_private_key, - 'session_token' => $_POST['fc-token'], - 'fc_rc_challenge' => $_POST['fc_rc_challenge'], - 'args' => $args - ); - $result = $this->doPostReturnObject('/fc/v/', $data); - } - else - { - $this->msgLog("ERROR", "Unable check the result. Please check that you passed in the correct public, private keys."); - } - return $result->solved; - } - - /** - * Internal function - does HTTPs post and returns result. - * - * @param string $url_path - server path - * @param array $data - data to send - * @return object - */ - protected function doPostReturnObject($url_path, $data) { - $result = ""; - $fields_string = ""; - $data_string = ""; - foreach($data as $key=>$value) { - if (is_array($value)) { - if ( ! empty($value)) { - foreach ($value as $k => $v) { - $data_string .= $key . '['. $k .']=' . $v . '&'; - } - } else { - $data_string .= $key . '=&'; - } - } else { - $data_string .= $key.'='.$value.'&'; - } - } - rtrim($data_string,'&'); - - $curl_url = "https://"; - $curl_url.= $this->funcaptcha_host; - $curl_url.= $url_path; - - // Log it. - $this->msgLog("DEBUG", "cURl: url='$curl_url', data='$data_string'"); - - if (function_exists('curl_init') and function_exists('curl_exec')) { - if ($ch = curl_init($curl_url)) - { - // Set the cURL options. - curl_setopt($ch, CURLOPT_POST, count($data)); - curl_setopt($ch, CURLOPT_POSTFIELDS, $data_string); - if (isset($this->funcaptcha_proxy)) { - curl_setopt($ch,CURLOPT_PROXY, $this->funcaptcha_proxy); - } - curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); - curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0); - curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false); - - // Execute the cURL request. - $result = curl_exec($ch); - curl_close($ch); - } - else - { - // Log it. - $this->msgLog("DEBUG", "Unable to enable cURL: url='$curl_url'"); - } - } else { - // Log it. - // Build a header - $http_request = "POST $url_path HTTP/1.1\r\n"; - $http_request .= "Host: $this->funcaptcha_host\r\n"; - $http_request .= "Content-Type: application/x-www-form-urlencoded;\r\n"; - $http_request .= "Content-Length: " . strlen($data_string) . "\r\n"; - $http_request .= "User-Agent: FunCaptcha/PHP " . $this->funcaptcha_plugin_version . "\r\n"; - $http_request .= "Connection: Close\r\n"; - $http_request .= "\r\n"; - $http_request .= $data_string ."\r\n"; - - $result = ''; - $errno = $errstr = ""; - $fs = fsockopen("ssl://" . $this->funcaptcha_host, 443, $errno, $errstr, 10); - - if( false == $fs ) { - $this->msgLog("ERROR", "Could not open socket"); - } else { - fwrite($fs, $http_request); - while (!feof($fs)) { - $result .= fgets($fs, 4096); - } - $result = explode("\r\n\r\n", $result, 2); - $result = $result[1]; - } - } - $result = $this->JSONDecode($result); - - return $result; - } - - /** - * Internal function - does does JSON decoding of data from server. - * - * @param string $string - json to decode - * @return object - */ - protected function JSONDecode($string) { - $result = array(); - if (function_exists("json_decode")) { - try { - $result = json_decode( $string); - } catch (Exception $e) { - $this->msgLog("ERROR", "Exception when calling json_decode: " . $e->getMessage()); - $result = null; - } - } else if (file_Exists($this->funcaptcha_json_path)) { - require_once($this->funcaptcha_json_path); - $json = new Services_JSON(); - $result = $json->decode($string); - } else { - $this->msgLog("ERROR", "No JSON decode function available."); - } - return $result; - } - - /** - * Log a message - * - * @param string $type - type of error - * @param string $message - message to log - * @return null - */ - protected function msgLog($type, $message) - { - - // Is it an error message? - if (FALSE !== stripos($type, "error")) - { - error_log($message); - } - - // Build the full message. - $debug_message = "$type: $message
\n"; - - // Output to screen if in debug mode - if ($this->funcaptcha_debug) - { - echo "$debug_message"; - } - } - - /** - * Debug mode, enables showing output of errors. - * - * @param boolean $mode debug state - */ - public function debugMode($mode) - { - $this->funcaptcha_debug = $mode; - } - -} -endif; \ No newline at end of file diff --git a/images/fc_meta_logo.png b/images/fc_meta_logo.png deleted file mode 100644 index 3f9679b..0000000 Binary files a/images/fc_meta_logo.png and /dev/null differ diff --git a/images/funcaptcha_gf.png b/images/funcaptcha_gf.png deleted file mode 100644 index 1ecbc84..0000000 Binary files a/images/funcaptcha_gf.png and /dev/null differ diff --git a/images/headingbg.png b/images/headingbg.png deleted file mode 100644 index 8579f0c..0000000 Binary files a/images/headingbg.png and /dev/null differ diff --git a/json.php b/json.php deleted file mode 100755 index 61b766f..0000000 --- a/json.php +++ /dev/null @@ -1,803 +0,0 @@ - - * @author Matt Knapp
- * // create a new instance of Services_JSON
- * $json = new Services_JSON();
- *
- * // convert a complexe value to JSON notation, and send it to the browser
- * $value = array('foo', 'bar', array(1, 2, 'baz'), array(3, array(4)));
- * $output = $json->encode($value);
- *
- * print($output);
- * // prints: ["foo","bar",[1,2,"baz"],[3,[4]]]
- *
- * // accept incoming POST data, assumed to be in JSON notation
- * $input = file_get_contents('php://input', 1000000);
- * $value = $json->decode($input);
- *
- */
-class Services_JSON
-{
- /**
- * constructs a new JSON instance
- *
- * @param int $use object behavior flags; combine with boolean-OR
- *
- * possible values:
- * - SERVICES_JSON_LOOSE_TYPE: loose typing.
- * "{...}" syntax creates associative arrays
- * instead of objects in decode().
- * - SERVICES_JSON_SUPPRESS_ERRORS: error suppression.
- * Values which can't be encoded (e.g. resources)
- * appear as NULL instead of throwing errors.
- * By default, a deeply-nested resource will
- * bubble up with an error, so all return values
- * from encode() should be checked with isError()
- */
- function Services_JSON($use = 0)
- {
- $this->use = $use;
- }
-
- /**
- * convert a string from one UTF-16 char to one UTF-8 char
- *
- * Normally should be handled by mb_convert_encoding, but
- * provides a slower PHP-only method for installations
- * that lack the multibye string extension.
- *
- * @param string $utf16 UTF-16 character
- * @return string UTF-8 character
- * @access private
- */
- function utf162utf8($utf16)
- {
- // oh please oh please oh please oh please oh please
- if(function_exists('mb_convert_encoding')) {
- return mb_convert_encoding($utf16, 'UTF-8', 'UTF-16');
- }
-
- $bytes = (ord($utf16{0}) << 8) | ord($utf16{1});
-
- switch(true) {
- case ((0x7F & $bytes) == $bytes):
- // this case should never be reached, because we are in ASCII range
- // see: http://www.cl.cam.ac.uk/~mgk25/unicode.html#utf-8
- return chr(0x7F & $bytes);
-
- case (0x07FF & $bytes) == $bytes:
- // return a 2-byte UTF-8 character
- // see: http://www.cl.cam.ac.uk/~mgk25/unicode.html#utf-8
- return chr(0xC0 | (($bytes >> 6) & 0x1F))
- . chr(0x80 | ($bytes & 0x3F));
-
- case (0xFFFF & $bytes) == $bytes:
- // return a 3-byte UTF-8 character
- // see: http://www.cl.cam.ac.uk/~mgk25/unicode.html#utf-8
- return chr(0xE0 | (($bytes >> 12) & 0x0F))
- . chr(0x80 | (($bytes >> 6) & 0x3F))
- . chr(0x80 | ($bytes & 0x3F));
- }
-
- // ignoring UTF-32 for now, sorry
- return '';
- }
-
- /**
- * convert a string from one UTF-8 char to one UTF-16 char
- *
- * Normally should be handled by mb_convert_encoding, but
- * provides a slower PHP-only method for installations
- * that lack the multibye string extension.
- *
- * @param string $utf8 UTF-8 character
- * @return string UTF-16 character
- * @access private
- */
- function utf82utf16($utf8)
- {
- // oh please oh please oh please oh please oh please
- if(function_exists('mb_convert_encoding')) {
- return mb_convert_encoding($utf8, 'UTF-16', 'UTF-8');
- }
-
- switch(strlen($utf8)) {
- case 1:
- // this case should never be reached, because we are in ASCII range
- // see: http://www.cl.cam.ac.uk/~mgk25/unicode.html#utf-8
- return $utf8;
-
- case 2:
- // return a UTF-16 character from a 2-byte UTF-8 char
- // see: http://www.cl.cam.ac.uk/~mgk25/unicode.html#utf-8
- return chr(0x07 & (ord($utf8{0}) >> 2))
- . chr((0xC0 & (ord($utf8{0}) << 6))
- | (0x3F & ord($utf8{1})));
-
- case 3:
- // return a UTF-16 character from a 3-byte UTF-8 char
- // see: http://www.cl.cam.ac.uk/~mgk25/unicode.html#utf-8
- return chr((0xF0 & (ord($utf8{0}) << 4))
- | (0x0F & (ord($utf8{1}) >> 2)))
- . chr((0xC0 & (ord($utf8{1}) << 6))
- | (0x7F & ord($utf8{2})));
- }
-
- // ignoring UTF-32 for now, sorry
- return '';
- }
-
- /**
- * encodes an arbitrary variable into JSON format
- *
- * @param mixed $var any number, boolean, string, array, or object to be encoded.
- * see argument 1 to Services_JSON() above for array-parsing behavior.
- * if var is a strng, note that encode() always expects it
- * to be in ASCII or UTF-8 format!
- *
- * @return mixed JSON string representation of input var or an error if a problem occurs
- * @access public
- */
- function encode($var)
- {
- switch (gettype($var)) {
- case 'boolean':
- return $var ? 'true' : 'false';
-
- case 'NULL':
- return 'null';
-
- case 'integer':
- return (int) $var;
-
- case 'double':
- case 'float':
- return (float) $var;
-
- case 'string':
- // STRINGS ARE EXPECTED TO BE IN ASCII OR UTF-8 FORMAT
- $ascii = '';
- $strlen_var = strlen($var);
-
- /*
- * Iterate over every character in the string,
- * escaping with a slash or encoding to UTF-8 where necessary
- */
- for ($c = 0; $c < $strlen_var; ++$c) {
-
- $ord_var_c = ord($var{$c});
-
- switch (true) {
- case $ord_var_c == 0x08:
- $ascii .= '\b';
- break;
- case $ord_var_c == 0x09:
- $ascii .= '\t';
- break;
- case $ord_var_c == 0x0A:
- $ascii .= '\n';
- break;
- case $ord_var_c == 0x0C:
- $ascii .= '\f';
- break;
- case $ord_var_c == 0x0D:
- $ascii .= '\r';
- break;
-
- case $ord_var_c == 0x22:
- case $ord_var_c == 0x2F:
- case $ord_var_c == 0x5C:
- // double quote, slash, slosh
- $ascii .= '\\'.$var{$c};
- break;
-
- case (($ord_var_c >= 0x20) && ($ord_var_c <= 0x7F)):
- // characters U-00000000 - U-0000007F (same as ASCII)
- $ascii .= $var{$c};
- break;
-
- case (($ord_var_c & 0xE0) == 0xC0):
- // characters U-00000080 - U-000007FF, mask 110XXXXX
- // see http://www.cl.cam.ac.uk/~mgk25/unicode.html#utf-8
- $char = pack('C*', $ord_var_c, ord($var{$c + 1}));
- $c += 1;
- $utf16 = $this->utf82utf16($char);
- $ascii .= sprintf('\u%04s', bin2hex($utf16));
- break;
-
- case (($ord_var_c & 0xF0) == 0xE0):
- // characters U-00000800 - U-0000FFFF, mask 1110XXXX
- // see http://www.cl.cam.ac.uk/~mgk25/unicode.html#utf-8
- $char = pack('C*', $ord_var_c,
- ord($var{$c + 1}),
- ord($var{$c + 2}));
- $c += 2;
- $utf16 = $this->utf82utf16($char);
- $ascii .= sprintf('\u%04s', bin2hex($utf16));
- break;
-
- case (($ord_var_c & 0xF8) == 0xF0):
- // characters U-00010000 - U-001FFFFF, mask 11110XXX
- // see http://www.cl.cam.ac.uk/~mgk25/unicode.html#utf-8
- $char = pack('C*', $ord_var_c,
- ord($var{$c + 1}),
- ord($var{$c + 2}),
- ord($var{$c + 3}));
- $c += 3;
- $utf16 = $this->utf82utf16($char);
- $ascii .= sprintf('\u%04s', bin2hex($utf16));
- break;
-
- case (($ord_var_c & 0xFC) == 0xF8):
- // characters U-00200000 - U-03FFFFFF, mask 111110XX
- // see http://www.cl.cam.ac.uk/~mgk25/unicode.html#utf-8
- $char = pack('C*', $ord_var_c,
- ord($var{$c + 1}),
- ord($var{$c + 2}),
- ord($var{$c + 3}),
- ord($var{$c + 4}));
- $c += 4;
- $utf16 = $this->utf82utf16($char);
- $ascii .= sprintf('\u%04s', bin2hex($utf16));
- break;
-
- case (($ord_var_c & 0xFE) == 0xFC):
- // characters U-04000000 - U-7FFFFFFF, mask 1111110X
- // see http://www.cl.cam.ac.uk/~mgk25/unicode.html#utf-8
- $char = pack('C*', $ord_var_c,
- ord($var{$c + 1}),
- ord($var{$c + 2}),
- ord($var{$c + 3}),
- ord($var{$c + 4}),
- ord($var{$c + 5}));
- $c += 5;
- $utf16 = $this->utf82utf16($char);
- $ascii .= sprintf('\u%04s', bin2hex($utf16));
- break;
- }
- }
-
- return '"'.$ascii.'"';
-
- case 'array':
- /*
- * As per JSON spec if any array key is not an integer
- * we must treat the the whole array as an object. We
- * also try to catch a sparsely populated associative
- * array with numeric keys here because some JS engines
- * will create an array with empty indexes up to
- * max_index which can cause memory issues and because
- * the keys, which may be relevant, will be remapped
- * otherwise.
- *
- * As per the ECMA and JSON specification an object may
- * have any string as a property. Unfortunately due to
- * a hole in the ECMA specification if the key is a
- * ECMA reserved word or starts with a digit the
- * parameter is only accessible using ECMAScript's
- * bracket notation.
- */
-
- // treat as a JSON object
- if (is_array($var) && count($var) && (array_keys($var) !== range(0, sizeof($var) - 1))) {
- $properties = array_map(array($this, 'name_value'),
- array_keys($var),
- array_values($var));
-
- foreach($properties as $property) {
- if(Services_JSON::isError($property)) {
- return $property;
- }
- }
-
- return '{' . join(',', $properties) . '}';
- }
-
- // treat it like a regular array
- $elements = array_map(array($this, 'encode'), $var);
-
- foreach($elements as $element) {
- if(Services_JSON::isError($element)) {
- return $element;
- }
- }
-
- return '[' . join(',', $elements) . ']';
-
- case 'object':
- $vars = get_object_vars($var);
-
- $properties = array_map(array($this, 'name_value'),
- array_keys($vars),
- array_values($vars));
-
- foreach($properties as $property) {
- if(Services_JSON::isError($property)) {
- return $property;
- }
- }
-
- return '{' . join(',', $properties) . '}';
-
- default:
- return ($this->use & SERVICES_JSON_SUPPRESS_ERRORS)
- ? 'null'
- : new Services_JSON_Error(gettype($var)." can not be encoded as JSON string");
- }
- }
-
- /**
- * array-walking function for use in generating JSON-formatted name-value pairs
- *
- * @param string $name name of key to use
- * @param mixed $value reference to an array element to be encoded
- *
- * @return string JSON-formatted name-value pair, like '"name":value'
- * @access private
- */
- function name_value($name, $value)
- {
- $encoded_value = $this->encode($value);
-
- if(Services_JSON::isError($encoded_value)) {
- return $encoded_value;
- }
-
- return $this->encode(strval($name)) . ':' . $encoded_value;
- }
-
- /**
- * reduce a string by removing leading and trailing comments and whitespace
- *
- * @param $str string string value to strip of comments and whitespace
- *
- * @return string string value stripped of comments and whitespace
- * @access private
- */
- function reduce_string($str)
- {
- $str = preg_replace(array(
-
- // eliminate single line comments in '// ...' form
- '#^\s*//(.+)$#m',
-
- // eliminate multi-line comments in '/* ... */' form, at start of string
- '#^\s*/\*(.+)\*/#Us',
-
- // eliminate multi-line comments in '/* ... */' form, at end of string
- '#/\*(.+)\*/\s*$#Us'
-
- ), '', $str);
-
- // eliminate extraneous space
- return trim($str);
- }
-
- /**
- * decodes a JSON string into appropriate variable
- *
- * @param string $str JSON-formatted string
- *
- * @return mixed number, boolean, string, array, or object
- * corresponding to given JSON input string.
- * See argument 1 to Services_JSON() above for object-output behavior.
- * Note that decode() always returns strings
- * in ASCII or UTF-8 format!
- * @access public
- */
- function decode($str)
- {
- $str = $this->reduce_string($str);
-
- switch (strtolower($str)) {
- case 'true':
- return true;
-
- case 'false':
- return false;
-
- case 'null':
- return null;
-
- default:
- $m = array();
-
- if (is_numeric($str)) {
- // Lookie-loo, it's a number
-
- // This would work on its own, but I'm trying to be
- // good about returning integers where appropriate:
- // return (float)$str;
-
- // Return float or int, as appropriate
- return ((float)$str == (integer)$str)
- ? (integer)$str
- : (float)$str;
-
- } elseif (preg_match('/^("|\').*(\1)$/s', $str, $m) && $m[1] == $m[2]) {
- // STRINGS RETURNED IN UTF-8 FORMAT
- $delim = substr($str, 0, 1);
- $chrs = substr($str, 1, -1);
- $utf8 = '';
- $strlen_chrs = strlen($chrs);
-
- for ($c = 0; $c < $strlen_chrs; ++$c) {
-
- $substr_chrs_c_2 = substr($chrs, $c, 2);
- $ord_chrs_c = ord($chrs{$c});
-
- switch (true) {
- case $substr_chrs_c_2 == '\b':
- $utf8 .= chr(0x08);
- ++$c;
- break;
- case $substr_chrs_c_2 == '\t':
- $utf8 .= chr(0x09);
- ++$c;
- break;
- case $substr_chrs_c_2 == '\n':
- $utf8 .= chr(0x0A);
- ++$c;
- break;
- case $substr_chrs_c_2 == '\f':
- $utf8 .= chr(0x0C);
- ++$c;
- break;
- case $substr_chrs_c_2 == '\r':
- $utf8 .= chr(0x0D);
- ++$c;
- break;
-
- case $substr_chrs_c_2 == '\\"':
- case $substr_chrs_c_2 == '\\\'':
- case $substr_chrs_c_2 == '\\\\':
- case $substr_chrs_c_2 == '\\/':
- if (($delim == '"' && $substr_chrs_c_2 != '\\\'') ||
- ($delim == "'" && $substr_chrs_c_2 != '\\"')) {
- $utf8 .= $chrs{++$c};
- }
- break;
-
- case preg_match('/\\\u[0-9A-F]{4}/i', substr($chrs, $c, 6)):
- // single, escaped unicode character
- $utf16 = chr(hexdec(substr($chrs, ($c + 2), 2)))
- . chr(hexdec(substr($chrs, ($c + 4), 2)));
- $utf8 .= $this->utf162utf8($utf16);
- $c += 5;
- break;
-
- case ($ord_chrs_c >= 0x20) && ($ord_chrs_c <= 0x7F):
- $utf8 .= $chrs{$c};
- break;
-
- case ($ord_chrs_c & 0xE0) == 0xC0:
- // characters U-00000080 - U-000007FF, mask 110XXXXX
- //see http://www.cl.cam.ac.uk/~mgk25/unicode.html#utf-8
- $utf8 .= substr($chrs, $c, 2);
- ++$c;
- break;
-
- case ($ord_chrs_c & 0xF0) == 0xE0:
- // characters U-00000800 - U-0000FFFF, mask 1110XXXX
- // see http://www.cl.cam.ac.uk/~mgk25/unicode.html#utf-8
- $utf8 .= substr($chrs, $c, 3);
- $c += 2;
- break;
-
- case ($ord_chrs_c & 0xF8) == 0xF0:
- // characters U-00010000 - U-001FFFFF, mask 11110XXX
- // see http://www.cl.cam.ac.uk/~mgk25/unicode.html#utf-8
- $utf8 .= substr($chrs, $c, 4);
- $c += 3;
- break;
-
- case ($ord_chrs_c & 0xFC) == 0xF8:
- // characters U-00200000 - U-03FFFFFF, mask 111110XX
- // see http://www.cl.cam.ac.uk/~mgk25/unicode.html#utf-8
- $utf8 .= substr($chrs, $c, 5);
- $c += 4;
- break;
-
- case ($ord_chrs_c & 0xFE) == 0xFC:
- // characters U-04000000 - U-7FFFFFFF, mask 1111110X
- // see http://www.cl.cam.ac.uk/~mgk25/unicode.html#utf-8
- $utf8 .= substr($chrs, $c, 6);
- $c += 5;
- break;
-
- }
-
- }
-
- return $utf8;
-
- } elseif (preg_match('/^\[.*\]$/s', $str) || preg_match('/^\{.*\}$/s', $str)) {
- // array, or object notation
-
- if ($str{0} == '[') {
- $stk = array(SERVICES_JSON_IN_ARR);
- $arr = array();
- } else {
- if ($this->use & SERVICES_JSON_LOOSE_TYPE) {
- $stk = array(SERVICES_JSON_IN_OBJ);
- $obj = array();
- } else {
- $stk = array(SERVICES_JSON_IN_OBJ);
- $obj = new stdClass();
- }
- }
-
- array_push($stk, array('what' => SERVICES_JSON_SLICE,
- 'where' => 0,
- 'delim' => false));
-
- $chrs = substr($str, 1, -1);
- $chrs = $this->reduce_string($chrs);
-
- if ($chrs == '') {
- if (reset($stk) == SERVICES_JSON_IN_ARR) {
- return $arr;
-
- } else {
- return $obj;
-
- }
- }
-
- //print("\nparsing {$chrs}\n");
-
- $strlen_chrs = strlen($chrs);
-
- for ($c = 0; $c <= $strlen_chrs; ++$c) {
-
- $top = end($stk);
- $substr_chrs_c_2 = substr($chrs, $c, 2);
-
- if (($c == $strlen_chrs) || (($chrs{$c} == ',') && ($top['what'] == SERVICES_JSON_SLICE))) {
- // found a comma that is not inside a string, array, etc.,
- // OR we've reached the end of the character list
- $slice = substr($chrs, $top['where'], ($c - $top['where']));
- array_push($stk, array('what' => SERVICES_JSON_SLICE, 'where' => ($c + 1), 'delim' => false));
- //print("Found split at {$c}: ".substr($chrs, $top['where'], (1 + $c - $top['where']))."\n");
-
- if (reset($stk) == SERVICES_JSON_IN_ARR) {
- // we are in an array, so just push an element onto the stack
- array_push($arr, $this->decode($slice));
-
- } elseif (reset($stk) == SERVICES_JSON_IN_OBJ) {
- // we are in an object, so figure
- // out the property name and set an
- // element in an associative array,
- // for now
- $parts = array();
-
- if (preg_match('/^\s*(["\'].*[^\\\]["\'])\s*:\s*(\S.*),?$/Uis', $slice, $parts)) {
- // "name":value pair
- $key = $this->decode($parts[1]);
- $val = $this->decode($parts[2]);
-
- if ($this->use & SERVICES_JSON_LOOSE_TYPE) {
- $obj[$key] = $val;
- } else {
- $obj->$key = $val;
- }
- } elseif (preg_match('/^\s*(\w+)\s*:\s*(\S.*),?$/Uis', $slice, $parts)) {
- // name:value pair, where name is unquoted
- $key = $parts[1];
- $val = $this->decode($parts[2]);
-
- if ($this->use & SERVICES_JSON_LOOSE_TYPE) {
- $obj[$key] = $val;
- } else {
- $obj->$key = $val;
- }
- }
-
- }
-
- } elseif ((($chrs{$c} == '"') || ($chrs{$c} == "'")) && ($top['what'] != SERVICES_JSON_IN_STR)) {
- // found a quote, and we are not inside a string
- array_push($stk, array('what' => SERVICES_JSON_IN_STR, 'where' => $c, 'delim' => $chrs{$c}));
- //print("Found start of string at {$c}\n");
-
- } elseif (($chrs{$c} == $top['delim']) &&
- ($top['what'] == SERVICES_JSON_IN_STR) &&
- ((strlen(substr($chrs, 0, $c)) - strlen(rtrim(substr($chrs, 0, $c), '\\'))) % 2 != 1)) {
- // found a quote, we're in a string, and it's not escaped
- // we know that it's not escaped becase there is _not_ an
- // odd number of backslashes at the end of the string so far
- array_pop($stk);
- //print("Found end of string at {$c}: ".substr($chrs, $top['where'], (1 + 1 + $c - $top['where']))."\n");
-
- } elseif (($chrs{$c} == '[') &&
- in_array($top['what'], array(SERVICES_JSON_SLICE, SERVICES_JSON_IN_ARR, SERVICES_JSON_IN_OBJ))) {
- // found a left-bracket, and we are in an array, object, or slice
- array_push($stk, array('what' => SERVICES_JSON_IN_ARR, 'where' => $c, 'delim' => false));
- //print("Found start of array at {$c}\n");
-
- } elseif (($chrs{$c} == ']') && ($top['what'] == SERVICES_JSON_IN_ARR)) {
- // found a right-bracket, and we're in an array
- array_pop($stk);
- //print("Found end of array at {$c}: ".substr($chrs, $top['where'], (1 + $c - $top['where']))."\n");
-
- } elseif (($chrs{$c} == '{') &&
- in_array($top['what'], array(SERVICES_JSON_SLICE, SERVICES_JSON_IN_ARR, SERVICES_JSON_IN_OBJ))) {
- // found a left-brace, and we are in an array, object, or slice
- array_push($stk, array('what' => SERVICES_JSON_IN_OBJ, 'where' => $c, 'delim' => false));
- //print("Found start of object at {$c}\n");
-
- } elseif (($chrs{$c} == '}') && ($top['what'] == SERVICES_JSON_IN_OBJ)) {
- // found a right-brace, and we're in an object
- array_pop($stk);
- //print("Found end of object at {$c}: ".substr($chrs, $top['where'], (1 + $c - $top['where']))."\n");
-
- } elseif (($substr_chrs_c_2 == '/*') &&
- in_array($top['what'], array(SERVICES_JSON_SLICE, SERVICES_JSON_IN_ARR, SERVICES_JSON_IN_OBJ))) {
- // found a comment start, and we are in an array, object, or slice
- array_push($stk, array('what' => SERVICES_JSON_IN_CMT, 'where' => $c, 'delim' => false));
- $c++;
- //print("Found start of comment at {$c}\n");
-
- } elseif (($substr_chrs_c_2 == '*/') && ($top['what'] == SERVICES_JSON_IN_CMT)) {
- // found a comment end, and we're in one now
- array_pop($stk);
- $c++;
-
- for ($i = $top['where']; $i <= $c; ++$i)
- $chrs = substr_replace($chrs, ' ', $i, 1);
-
- //print("Found end of comment at {$c}: ".substr($chrs, $top['where'], (1 + $c - $top['where']))."\n");
-
- }
-
- }
-
- if (reset($stk) == SERVICES_JSON_IN_ARR) {
- return $arr;
-
- } elseif (reset($stk) == SERVICES_JSON_IN_OBJ) {
- return $obj;
-
- }
-
- }
- }
- }
-
- /**
- * @todo Ultimately, this should just call PEAR::isError()
- */
- function isError($data, $code = null)
- {
- if (class_exists('pear')) {
- return PEAR::isError($data, $code);
- } elseif (is_object($data) && (get_class($data) == 'services_json_error' ||
- is_subclass_of($data, 'services_json_error'))) {
- return true;
- }
-
- return false;
- }
-}
-
-if (class_exists('PEAR_Error')) {
-
- class Services_JSON_Error extends PEAR_Error
- {
- function Services_JSON_Error($message = 'unknown error', $code = null,
- $mode = null, $options = null, $userinfo = null)
- {
- parent::PEAR_Error($message, $code, $mode, $options, $userinfo);
- }
- }
-
-} else {
-
- /**
- * @todo Ultimately, this class shall be descended from PEAR_Error
- */
- class Services_JSON_Error
- {
- function Services_JSON_Error($message = 'unknown error', $code = null,
- $mode = null, $options = null, $userinfo = null)
- {
-
- }
- }
-
-}
diff --git a/readme.txt b/readme.txt
index cd7c3ed..70963fd 100644
--- a/readme.txt
+++ b/readme.txt
@@ -1,311 +1 @@
-=== FunCaptcha - Anti-Spam CAPTCHA ===
-Contributors: swipeads
-Tags: captcha, antispam, comment, login, registration captcha, contact form 7 captcha, gravity forms captcha, buddypress CAPTCHA, bbPress
-Requires at least: 2.8.0
-Tested up to: 4.1
-Stable tag: 1.3.2
-
-Stop spam with a fun, fast mini-game CAPTCHA! FunCaptcha is free, and works on every desktop and mobile device. For BuddyPress, Ninja Forms, Gravity Forms, CF7, bbPress.
-
-== Description ==
-
-Spammers abuse your site, but users hate typing out twisty letters or ad phrases (aka CAPTCHA and reCAPTCHA). Automated spam filters make mistakes and require constant checking. FunCaptcha presents a mini-game CAPTCHA that blocks the bots while giving your users a few moments of fun. It's a real security solution hardened by experts and automatically updated to provide the best protection. Try [a demo](http://www.funcaptcha.co/) on our site!
-
-Users complete these little games faster than other CAPTCHAs, with fewer frustrating failures and no typing. They work on all browsers and mobile devices, using HTML5 with a fallback to Flash. Visually impaired users can complete an audio challenge CAPTCHA.
-
-The FunCaptcha widget works easily on registration and comment forms, as well as Contact Form 7, Gravity Forms and Ninja Forms. You can keep your anti-spam solutions such as Akismet, though you won't need to check those filters as often. We also fully support showing FunCaptcha on bbPress topic creation and for replies. You can automatically show FunCaptcha once your user submits the form, rather than displaying it on your page. Choose from several FunCaptcha themes to best match your websites color scheme.
-
-Learn more, give feedback, and ask questions at our website. Our epic battle against bots doesn't have to be a headache. Let's fight while having some fun!
-
-To remain secure, this plugin connects to the FunCaptcha API servers to display and validate users answers.
-
-== Installation ==
-
-[youtube http://www.youtube.com/watch?v=1XNEmuAwp7E]
-
-You can view instructions with images at [our site](http://www.funcaptcha.co/setup/) or watch the above video.
-
-= Install the Plugin =
-
-There is two methods to install FunCaptcha.
-
-Method one is by downloading the plugin from here and following these steps:
-
-1. Upload funcaptcha folder to the /wp-content/plugins/ directory.
-1. Activate the plugin through the 'Plugins' menu in WordPress.
-1. Plugin settings are located in 'Plugin', 'FunCaptcha'.
-
-Method two is by downloading it directly from your Wordpress dashboard by following these steps:
-
-1. Log in to your Wordpress blog as the administrator.
-1. Navigate to Plugins -> Add New.
-1. Enter "FunCaptcha" in the search box.
-1. Click "Install Now".
-1. Once installation has completed, click the "Activate Plugin" link.
-1. Plugin settings are located in 'Plugin', 'FunCaptcha'.
-
-In both cases it will warn you of needing to setup and activate FunCaptcha, which you can do directly from within the plugin.
-
-= Configure the Plugin =
-
-1. Navigate to Settings -> FunCaptcha
-1. If you have not already registered for an account, follow the instructions.
-1. After you've registered for an account you will be assigned a private and public Key. Copy and paste those keys into the FunCaptcha settings in your Wordpress admin.
-1. Select which locations which you would like FunCaptcha to be active on and when you're done, click the Save Settings button.
-
-== Frequently Asked Questions ==
-
-= How can I try out your CAPTCHA? =
-Try [a demo](http://www.funcaptcha.co/) of FunCaptcha on our site.
-
-= Does FunCaptcha work on mobile and all other platforms? =
-Yes. It is built on HTML5, with full support for mobiles. It works great with touch interfaces, and does not require any typing. All platforms used by a site’s customers are supported, including every kind of PC and Mac. A Flash version seamlessly appears for older browsers. In short, no user will be blocked.
-
-= Is there audio accessibility? =
-Yes. We use the well-known “reCAPTCHA” service to provide an audio CAPTCHA for those who need it.
-
-= Does it work if Javascript is turned off? =
-Yes. We fallback to a text CAPTCHA if the user has Javascript disabled. FunCaptcha works on all platforms, devices and form factors - all the way back to IE6 being fully supported.
-
-= Are other CAPTCHAs more secure? =
-Unfortunately, all typed-in CAPTCHAs are now being solved by bots to some degree. Some newer CAPTCHA alternatives are actually much easier for bots to solve than before! Once these new alternatives become popular enough to be worthwhile for hackers to target, they will crumble. FunCaptcha will stay ahead of the curve, and clearly explain how we do it-- not resort to a black box of promises.
-
-= What is a CAPTCHA? =
-A CAPTCHA (Completely Automated Public Turing test to tell Computers and Humans Apart) is a test to verify that a user is a human instead of a computer program, or “bot”. It stops bots from making user accounts and comments that spam other users, or “scraping” all of the content from a site in order to steal it for other uses.
-
-= What is wrong with CAPTCHAs now? =
-Most CAPTCHAs require the user to read and type in text. The text must be hard to read in order to be effective, so most CAPTCHAs are either annoying, or not difficult enough to stop bots. In any case, as more Internet traffic comes from mobile devices, typing turns off users. In short, everyone hates typed-out CAPTCHAs, and some users simply walk away.
-
-= What is FunCaptcha? =
-FunCaptcha is a CAPTCHA that presents a mini-game that blocks the bots while giving your users a few moments of fun. It’s a real security solution, hardened by experts and automatically updated to provide the best protection. Users complete these little games faster than other CAPTCHAs, with fewer frustrating failures and no typing. They work on all browsers and mobile devices. Visually impaired users can complete an audio challenge.
-
-= What is lightbox mode? =
-Lightbox mode will display FunCaptcha when the user clicks submit. This way FunCaptcha is shown in better context with the form, as a security verification method. This mode helps improve your users conversions as well as better fitting in with your sites custom theme. We recommend this mode being left on. If you have any issues with FunCaptcha not working, first try turning this off.
-
-= FunCaptcha does not appear / I am using JetPack for comments =
-We have noticed a few of our users are using the JetPack plugin, which currently does not support showing a CAPTCHA by third parties. You can disable the JetPack comment addon from your dashboard and it will work fine. There may be other plugins that cause our CAPTCHA to not appear. We recommend you note down any type of comment or registration plugins before you contact us to help us better assist you. If you have any other CAPTCHA plugins, please disable those as well. Our CAPTCHA will detect if you are using JetPack and warn you of the conflicting.
-
-= FunCaptcha shows an error message =
-This error message will only appear if you have not correctly added your private and public keys to the settings panel in your wordpress admin dashboard. Our CAPTCHA requires these to properly secure your website. If you contiune to see the error message even after entering correct keys, you may have a plugin that prevents external communication to our servers, such as "wp protection", please disable those as well.
-
-= I'm using the Contact Form 7 plugin. Can I use your CAPTCHA to protect my form? =
-Our CAPTCHA will appear as FunCaptcha as a short code option in Contact Form 7's Generate Tag dropdown.
-
-= I'm using the Gravity Forms plugin. Can I use your CAPTCHA to protect my form or registration pages? =
-FunCaptcha supports being displayed as a CAPTCHA for Gravity Forms using the advanced fields tab in Gravity Forms.
-
-= I'm using the Ninja Forms plugin. Can I use your CAPTCHA to protect my form or registration pages? =
-FunCaptcha supports being displayed as a CAPTCHA for Ninja Forms as a dropdown option when creating your form.
-
-= I'm using the Buddypress plugin. Can I use your CAPTCHA on my registration page? =
-Our CAPTCHA has full support for Buddypress and can be included on any Buddypress website. It will automatically work on any Buddypress registration forms and on any other location our CAPTCHA is enabled for.
-
-= I'm using your CAPTCHA on a page with both a Form and a comment box, and it only appears once? =
-Our CAPTCHA currently only supports being displayed once on the same page, so please only show it in a form if there is no comments on the same page.
-
-= If I want to use your CAPTCHA on another site, do I need new keys? =
-Yes, you can get those using the same account at our [website](https://swipeads.co/). Please login with the same account you're currently using for your wordpress site.
-
-= How long does it take to install your CAPTCHA? =
-Our CAPTCHA can be installed in less than two minutes, the entire signup process is kept within the plugin itself, unlike other CAPTCHAs such as ReCAPTCHA.
-
-= Can I customize your CAPTCHA? =
-We are rapidly updating and adding features to both our Wordpress plugin and our core technology platform, in future we will offer new ways for you to display the CAPTCHA to better match your website.
-
-= Can I reposition the CAPTCHA? =
-You can change how you'd like to align FunCaptcha in the settings to better match your websites layout. This works on your comment forms, lost password and registration forms, as well as Contact Form 7, BuddyPress and our Gravity Form addons. This setting will also align the submit button to match for the best user experience.
-
-= What does 'security level' mean? =
-By default, FunCaptcha's security level is Automatic, and you don't need to do a thing. But here are some details if you want to know what's going on under the hood.
-
-= Can I disabled the CAPTCHA for logged in users? =
-Yes, this is an option in the settings.
-
-If the security level is Automatic, security starts at the lowest, Standard level. That means that users do fewer challenges, but spambots also have less work to do to guess their way past the challenge. For most sites, this is fine. Most people will only need to solve two challenges, and almost no spambots will get through. The security level rises and falls automatically, adjusted by FunCaptcha's monitoring system. If our system suspects that a user is a spambot, the security level for that user automatically rises to Enhanced level, described below.
-
-The Enhanced security level makes users do a few more challenges. It's still easy and quick for humans, but becomes much harder for spambots to get through. No spambot that we see attacking our many sites is capable of getting through the Enhanced level.
-
-As a site publisher, you start off at the Automatic security level, which is probably your best option, so you don't need to do a thing. However, if you wish, you can adjust your settings so security remains always at a particular elevated level, and won't adjust automatically. For example, you can assure that all of your users (and all spambots!) will always play at the Enhanced security level. You can change this setting for any domain listed on your account page at [SwipeAds.co](http://www.funcaptcha.co/). If you use our WordPress plugin, you can also use the plugin settings page. (If these two places don't have the same security setting, the more elevated setting of the two will prevail.)
-
-= What do the stars do? =
-You earn stars as you complete FunCaptchas anywhere on the web. The faster you complete the CAPTCHA challenge, the more stars you get. Gettng 5 stars means you play the games as well as we, the creators, do– and we have lots of practice! Unless you are using a “cookie blocker” or a “do not track” function on your browser, your star count will keep increasing each time you play. Once you reach 100 stars, you will get a special reward. The reward is not implemented yet but stay tuned, and keep honing your FunCaptcha skills!
-
-= I'd like a certain feature or a way to make it fit the theme of my site better, is there anything I can do? =
-Please contact us on the support forums if you have any ideas on how to improve our CAPTCHA. You can also contact us on our [site](http://www.funcaptcha.co/contact-us/).
-
-= Other questions? =
-For a full list of frequently asked questions, please see our [FAQ page](http://www.funcaptcha.co/faqs).
-
-== Screenshots ==
-
-1. Comment Form
-2. Registration Form
-3. Lost Password Form
-4. Admin Page
-
-== Changelog ==
-
-= 1.3.2 =
-• Added support for new CF7 changes.
-
-= 1.3.1 =
-• Fixed a bug with CF7 & GF with new code base
-
-= 1.3.0 =
-• NinjaForms support
-
-= 1.2.4 =
-• Branding update
-
-= 1.2.3 =
-• Gravity Forms cache fix
-
-= 1.2.2 =
-* Fixed a bug with Gravity Forms not refreshing correctly
-* Tested support for Wordpress 4.1
-* Depreciating Popup/Lightbox mode, we recommend you disable this mode.
-* Added new FunCaptcha Logo & colour scheme
-
-= 1.2.1 =
-* Support for latest Contact Form 7 changes
-
-= 1.2.0 =
-* Tested support for Wordpress 4.0
-* Code cleanup
-
-= 1.1.6 =
-* file cleanup
-
-= 1.1.6 =
-* fixes
-
-= 1.1.5 =
-* url link fix
-
-= 1.1.4 =
-* bbPress if set to show on topic and comment posting, hide admin now works as expected.
-* Fixed url link with ajax_reload.js
-* Changed terminology of Lightbox mode to Popup mode
-
-= 1.1.3 =
-* misc updates.
-
-= 1.1.2 =
-* Install fix.
-
-= 1.1.1 =
-* Bug fix for multisites using Buddypress
-
-= 1.1.0 =
-* Theme selection, you can now change the visual appearance of FunCaptcha. See the selection at [our website](https://www.funcaptcha.co/themes/).
-* Support for versions of PHP without CURL or JSON support.
-
-= 1.0.0 =
-* Lightbox mode.
-* FunCaptcha can still validate users even with javascript turned off.
-
-= 0.5.1 =
-* Increased priority of FunCaptcha for error processing, prevents conflict with other plugins that check to see if form errors exist.
-
-= 0.5.0 =
-* bbPress support.
-
-= 0.4.4 =
-* Security improvements.
-* Made localhost not cause issues for registration purposes.
-
-= 0.4.3 =
-* Bug fixes.
-
-= 0.4.2 =
-* Easier to register link.
-
-= 0.4.1 =
-* Show form on both buddypress and regular registration forms for Multisites.
-
-= 0.4.0 =
-* Support for wordpress multisite registration forms.
-
-= 0.3.19 =
-* Made more clear the service connects to the funcaptcha API servers to verify solves.
-
-= 0.3.18 =
-* Fixed bug with missing files.
-
-= 0.3.17 =
-* Added FunCaptcha login form setting. You can now use FunCaptcha to protect your login forms.
-
-= 0.3.16 =
-* Updated error message.
-
-= 0.3.15 =
-* Updated to funcaptcha.co
-
-= 0.3.14 =
-* Added support for cache plugins.
-
-= 0.3.13 =
-* Added support for users with allow_url_include=0 set.
-
-= 0.3.12 =
-* Contact Form 7 support is now enabled by default.
-
-= 0.3.11 =
-* Added information about how to signup multiple Wordpress sites.
-
-= 0.3.10 =
-* Signup now automatically detects your site URL and prefills it for you.
-
-= 0.3.9 =
-* Can now hide from admins.
-
-= 0.3.8 =
-* Code cleanup and optimizations.
-
-= 0.3.7 =
-* User with Buddypress installed will now see FunCaptcha on Buddypress as well as the Wordpress registration forms.
-
-= 0.3.6 =
-* Added conflicting plugin warnings to activation tab.
-
-= 0.3.5 =
-* Updated nonce support, added additional settings security.
-
-= 0.3.4 =
-* Will now warn if FunCaptcha can detect any conflicting plugins.
-
-= 0.3.3 =
-* Patches CSRF vulnerability in the settings panel that was created in last update.
-
-= 0.3.2 =
-* FunCaptcha will no longer show the error message or prevent comments until you have inserted activation keys.
-* Fixed url link in settings.
-
-= 0.3.1 =
-* Can now adjust the alignment of FunCaptcha, left, right or centered.
-
-= 0.3.0 =
-* Adjustable security setting. You can now choose between Automatic and Enhanced security. If you choose Automatic, security starts at the lowest level, and rises and falls automatically, adjusted by FunCaptcha's monitoring system. The Enhanced level has more challenges to solve, but is very hard for spammer programs to get past. Please read more at our [FAQ](https://swipeads.co/faqs)
-
-= 0.2.2 =
-* Gravity Forms support. You can now use FunCaptcha in any Gravity Forms, using the advanced field elements.
-* Activate your account directly in the plugin to get your keys. No longer do you need to leave wordpress to register and activate an account to get your security keys. We have done our best to make this process as smooth and simple as possible.
-* Activate tab added to support the new in-built registration process. Public and Private keys have also been moved to this new tab.
-* Enhanced built in error checking. If your keys look incorrect we will now warn you.
-* Fixed bug where if logged in users was disabled may still require verification.
-
-= 0.2.1 =
-* Removed php short codes to add support for older versions of PHP or those that have them turned off.
-
-= 0.2.0 =
-* Buddypress support.
-* Now displays FunCaptcha before the comment submit button.
-* Fixed a visual issue on mobile devices if a themes width was less than 300pixels, now FunCaptcha will resize to fit.
-* New default settings.
-* Left aligned FunCaptcha to match wordpress style better.
-
-= 0.1.0 =
-* Bug fix.
-
-= 0.0.1 =
-* Beta release.
+This repo is deprecated. Please delete.
\ No newline at end of file
diff --git a/screenshot-1.png b/screenshot-1.png
deleted file mode 100644
index 935f57c..0000000
Binary files a/screenshot-1.png and /dev/null differ
diff --git a/screenshot-2.png b/screenshot-2.png
deleted file mode 100644
index ed6fd41..0000000
Binary files a/screenshot-2.png and /dev/null differ
diff --git a/screenshot-3.png b/screenshot-3.png
deleted file mode 100644
index 3bc2140..0000000
Binary files a/screenshot-3.png and /dev/null differ
diff --git a/screenshot-4.png b/screenshot-4.png
deleted file mode 100644
index 843803a..0000000
Binary files a/screenshot-4.png and /dev/null differ
diff --git a/wp_funcaptcha.php b/wp_funcaptcha.php
deleted file mode 100644
index 950140f..0000000
--- a/wp_funcaptcha.php
+++ /dev/null
@@ -1,1078 +0,0 @@
-' . __('Settings', 'captcha') . '';
- array_unshift( $links, $settings_link );
-
- return $links;
-}
-
-/**
-* enable meta links
-*
-* @return links array url links for being displayed under plugin
-*/
-function funcaptcha_register_plugin_meta_links($links, $file) {
-
- if ($file == PLUGIN_BASENAME) {
-
- $links[] = '' . __('Settings','captcha') . '';
- $links[] = '' . __('Contact','captcha') . '';
- }
- return $links;
-}
-
-
-/**
-* register stylesheet for registration
-*
-* @return null
-*/
-function funcaptcha_register_style() {
- wp_register_style('funcaptchaStylesheet', plugins_url('css/min_funcaptcha_styles.css', __FILE__));
-}
-
-/**
-* register stylesheet for login
-*
-* @return null
-*/
-function funcaptcha_login_styles() {
- $action = ( isset( $_GET['action'] ) ) ? $_GET['action'] : '';
- $options = funcaptcha_get_settings();
-
- if ( ( $action == 'lostpassword' && $options['password_form'] ) || ( $action == 'register' && $options['register_form'] ) ) {
- ?>setSecurityLevel($options['security_level']);
- $fc->setTheme($options['theme']);
- $fc->setLightboxMode($options['lightbox_mode']);
- return $fc;
-}
-
-/**
-* Show correct settings screen
-*
-* @return string echo of HTML
-*/
-function funcaptcha_show_settings() {
-
- $funcaptcha_options = funcaptcha_get_settings();
- $action = ( isset( $_POST['funcaptcha']['action'] ) ) ? $_POST['funcaptcha']['action'] : '';
- if ($action) {
- if ( ! current_user_can('activate_plugins') ) {
- die("Unauthorized to change settings. User is not an allowed to change plugin.");
- }
- }
- switch ( $action ) {
- case 'install':
- funcaptcha_install_plugin();
- break;
- case 'upgrade':
- funcaptcha_upgrade_plugin();
- break;
- case 'settings':
- funcaptcha_install_plugin();
- break;
- default:
- $action = funcaptcha_check_for_upgrade_or_install();
- break;
- }
-
- wp_enqueue_style('funcaptchaStylesheet');
-
- //debug code
- if (!in_array($action, array('install', 'upgrade', 'settings'))) {
- error_log("FATAL ERROR:"
- . print_r(debug_backtrace(), true));
- echo "Plugin error. Please contact the FunCaptcha support team.";
- return;
- }
-
- switch ($action) {
- case 'install':
- $page_opts = funcaptcha_get_install_page_options($action);
- break;
- case 'upgrade':
- $page_opts = funcaptcha_get_upgrade_page_options($action);
- break;
- case 'settings':
- $page_opts = funcaptcha_get_settings_page_options();
- break;
- }
-
- echo "Thanks for installing FunCaptcha.You must activate your FunCaptcha for it to be displayed.
' . $error . '
'; - } - echo "To complete your installation:
Warning: The plugin JetPack Comments has been detected. This will prevent FunCaptcha from working. You can disable JetPack Comments from the JetPack configuration page.
- getFunCaptcha($options['public_key']); - return $fc_arr["html"]; -} - - diff --git a/wp_funcaptcha_admin.php b/wp_funcaptcha_admin.php deleted file mode 100755 index 3b8e50c..0000000 --- a/wp_funcaptcha_admin.php +++ /dev/null @@ -1,109 +0,0 @@ - - //default text to display if nothing is entered. - $funcaptcha_Default = "Verification incomplete. Please solve the puzzle before you continue. The puzzle verifies that you are an actual user, not a spammer."; -?> - -
If you're having trouble getting FunCaptcha to work, please contact us and we'll get back to you.
-© Copyright SwipeAds. Version
diff --git a/wp_funcaptcha_admin_activate.php b/wp_funcaptcha_admin_activate.php deleted file mode 100755 index 26e442b..0000000 --- a/wp_funcaptcha_admin_activate.php +++ /dev/null @@ -1,75 +0,0 @@ - - //default text to display if nothing is entered. - $funcaptcha_Default = "Verification incomplete. Please solve the puzzle before you continue. The puzzle verifies that you are an actual user, not a spammer."; -?> - - -If you're having trouble getting FunCaptcha to work, please contact us and we'll get back to you.
-© Copyright SwipeAds. Version
\ No newline at end of file