Version Notes
Recaptcha extension - version 2
Download this release
Release Info
| Developer | Chris |
| Extension | Fontis_Recaptcha |
| Version | 2.4.0.4 |
| Comparing to | |
| See all releases | |
Code changes from version 2.4.0.3 to 2.4.0.4
- app/code/community/Fontis/Recaptcha/Block/Review/Form.php +30 -0
- app/code/community/Fontis/Recaptcha/Helper/Data.php +178 -0
- app/code/community/Fontis/Recaptcha/Model/Source/Recaptchalanguage.php +37 -0
- app/code/community/Fontis/Recaptcha/Model/Source/Recaptchatheme.php +35 -0
- app/code/community/Fontis/Recaptcha/controllers/AccountController.php +57 -0
- app/code/community/Fontis/Recaptcha/controllers/ContactsController.php +82 -0
- app/code/community/Fontis/Recaptcha/controllers/ProductController.php +63 -0
- app/code/community/Fontis/Recaptcha/controllers/ReviewController.php +62 -0
- app/code/community/Fontis/Recaptcha/etc/config.xml +151 -0
- app/code/community/Fontis/Recaptcha/etc/system.xml +242 -0
- app/code/community/Fontis/Recaptcha/install.txt +0 -3
- app/design/frontend/base/default/layout/fontis_recaptcha.xml +59 -0
- app/design/frontend/base/default/template/fontis/recaptcha/contacts.phtml +78 -0
- app/design/frontend/base/default/template/fontis/recaptcha/form.phtml +141 -0
- app/design/frontend/base/default/template/fontis/recaptcha/recaptcha.phtml +112 -0
- app/design/frontend/base/default/template/fontis/recaptcha/register.phtml +185 -0
- app/design/frontend/base/default/template/fontis/recaptcha/send.phtml +148 -0
- app/design/frontend/default/default/layout/fontis_recaptcha.xml +59 -0
- app/design/frontend/default/default/template/fontis/recaptcha/contacts.phtml +74 -0
- app/design/frontend/default/default/template/fontis/recaptcha/form.phtml +127 -0
- app/design/frontend/default/default/template/fontis/recaptcha/recaptcha.phtml +112 -0
- app/design/frontend/default/default/template/fontis/recaptcha/register.phtml +153 -0
- app/design/frontend/default/default/template/fontis/recaptcha/send.phtml +142 -0
- app/etc/modules/Fontis_Recaptcha.xml +31 -0
- package.xml +4 -4
- skin/frontend/base/default/images/fontis/help.png +0 -0
- skin/frontend/base/default/images/fontis/refresh.png +0 -0
- skin/frontend/base/default/images/fontis/sound.png +0 -0
- skin/frontend/base/default/images/fontis/text.png +0 -0
- skin/frontend/default/default/images/fontis/help.png +0 -0
- skin/frontend/default/default/images/fontis/refresh.png +0 -0
- skin/frontend/default/default/images/fontis/sound.png +0 -0
- skin/frontend/default/default/images/fontis/text.png +0 -0
app/code/community/Fontis/Recaptcha/Block/Review/Form.php
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Fontis Recaptcha Extension
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 11 |
+
* If you did not receive a copy of the license and are unable to
|
| 12 |
+
* obtain it through the world-wide-web, please send an email
|
| 13 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 14 |
+
*
|
| 15 |
+
* @category Fontis
|
| 16 |
+
* @package Fontis_Recaptcha
|
| 17 |
+
* @author Denis Margetic
|
| 18 |
+
* @author Chris Norton
|
| 19 |
+
* @copyright Copyright (c) 2011 Fontis Pty. Ltd. (http://www.fontis.com.au)
|
| 20 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 21 |
+
*/
|
| 22 |
+
|
| 23 |
+
class Fontis_Recaptcha_Block_Review_Form extends Mage_Review_Block_Form
|
| 24 |
+
{
|
| 25 |
+
public function __construct()
|
| 26 |
+
{
|
| 27 |
+
parent::__construct();
|
| 28 |
+
$this->setTemplate('fontis/recaptcha/form.phtml');
|
| 29 |
+
}
|
| 30 |
+
}
|
app/code/community/Fontis/Recaptcha/Helper/Data.php
ADDED
|
@@ -0,0 +1,178 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Fontis Recaptcha Extension
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 11 |
+
* If you did not receive a copy of the license and are unable to
|
| 12 |
+
* obtain it through the world-wide-web, please send an email
|
| 13 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 14 |
+
*
|
| 15 |
+
* This code has been adopted from the reCAPTCHA module available at:
|
| 16 |
+
* http://www.google.com/recaptcha
|
| 17 |
+
* The original reCAPTCHA module was written by:
|
| 18 |
+
* Mike Crawford
|
| 19 |
+
* Ben Maurer
|
| 20 |
+
*
|
| 21 |
+
* @category Fontis
|
| 22 |
+
* @package Fontis_Recaptcha
|
| 23 |
+
* @author Denis Margetic
|
| 24 |
+
* @author Chris Norton
|
| 25 |
+
* @copyright Copyright (c) 2011 Fontis Pty. Ltd. (http://www.fontis.com.au)
|
| 26 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 27 |
+
*/
|
| 28 |
+
class Fontis_Recaptcha_Helper_Data extends Mage_Core_Helper_Abstract
|
| 29 |
+
{
|
| 30 |
+
const RECAPTCHA_API_SERVER_HOST = "www.google.com";
|
| 31 |
+
const RECAPTCHA_API_SERVER_PATH = "/recaptcha/api";
|
| 32 |
+
const RECAPTCHA_API_SECURE_SERVER = "https://www.google.com/recaptcha/api";
|
| 33 |
+
|
| 34 |
+
/**
|
| 35 |
+
* Encodes the given data into a query string format
|
| 36 |
+
* @param $data - array of string elements to be encoded
|
| 37 |
+
* @return string - encoded request
|
| 38 |
+
*/
|
| 39 |
+
function _recaptcha_qsencode ($data)
|
| 40 |
+
{
|
| 41 |
+
$req = "";
|
| 42 |
+
foreach ( $data as $key => $value )
|
| 43 |
+
$req .= $key . '=' . urlencode( stripslashes($value) ) . '&';
|
| 44 |
+
|
| 45 |
+
// Cut the last '&'
|
| 46 |
+
$req=substr($req,0,strlen($req)-1);
|
| 47 |
+
return $req;
|
| 48 |
+
}
|
| 49 |
+
|
| 50 |
+
/**
|
| 51 |
+
* Submits an HTTP POST to a reCAPTCHA server
|
| 52 |
+
* @param string $host
|
| 53 |
+
* @param string $path
|
| 54 |
+
* @param array $data
|
| 55 |
+
* @param int port
|
| 56 |
+
* @return array response
|
| 57 |
+
*/
|
| 58 |
+
function _recaptcha_http_post($host, $path, $data, $port = 80)
|
| 59 |
+
{
|
| 60 |
+
$req = $this->_recaptcha_qsencode ($data);
|
| 61 |
+
|
| 62 |
+
$http_request = "POST $path HTTP/1.0\r\n";
|
| 63 |
+
$http_request .= "Host: $host\r\n";
|
| 64 |
+
$http_request .= "Content-Type: application/x-www-form-urlencoded;\r\n";
|
| 65 |
+
$http_request .= "Content-Length: " . strlen($req) . "\r\n";
|
| 66 |
+
$http_request .= "User-Agent: reCAPTCHA/PHP\r\n";
|
| 67 |
+
$http_request .= "\r\n";
|
| 68 |
+
$http_request .= $req;
|
| 69 |
+
|
| 70 |
+
$response = '';
|
| 71 |
+
if( false == ( $fs = @fsockopen($host, $port, $errno, $errstr, 10) ) ) {
|
| 72 |
+
die ('Could not open socket');
|
| 73 |
+
}
|
| 74 |
+
|
| 75 |
+
fwrite($fs, $http_request);
|
| 76 |
+
|
| 77 |
+
while ( !feof($fs) )
|
| 78 |
+
$response .= fgets($fs, 1160); // One TCP-IP packet
|
| 79 |
+
fclose($fs);
|
| 80 |
+
$response = explode("\r\n\r\n", $response, 2);
|
| 81 |
+
|
| 82 |
+
return $response;
|
| 83 |
+
}
|
| 84 |
+
|
| 85 |
+
/**
|
| 86 |
+
* Gets the challenge HTML (javascript and non-javascript version).
|
| 87 |
+
* This is called from the browser, and the resulting reCAPTCHA HTML widget
|
| 88 |
+
* is embedded within the HTML form it was called from.
|
| 89 |
+
* @param string $pubkey A public key for reCAPTCHA
|
| 90 |
+
* @param string $error The error given by reCAPTCHA (optional, default is null)
|
| 91 |
+
* @param boolean $use_ssl Should the request be made over ssl? (optional, default is false)
|
| 92 |
+
|
| 93 |
+
* @return string - The HTML to be embedded in the user's form.
|
| 94 |
+
*/
|
| 95 |
+
function recaptcha_get_html ($pubkey, $error = null, $use_ssl = false)
|
| 96 |
+
{
|
| 97 |
+
if ($pubkey == null || $pubkey == '') {
|
| 98 |
+
die ("To use reCAPTCHA you must get an API key from <a href='http://recaptcha.net/api/getkey'>http://recaptcha.net/api/getkey</a>");
|
| 99 |
+
}
|
| 100 |
+
|
| 101 |
+
if ($use_ssl) {
|
| 102 |
+
$server = self::RECAPTCHA_API_SECURE_SERVER;
|
| 103 |
+
} else {
|
| 104 |
+
$server = 'http://' . self::RECAPTCHA_API_SERVER_HOST . self::RECAPTCHA_API_SERVER_PATH;
|
| 105 |
+
}
|
| 106 |
+
|
| 107 |
+
$errorpart = "";
|
| 108 |
+
if ($error) {
|
| 109 |
+
$errorpart = "&error=" . $error;
|
| 110 |
+
}
|
| 111 |
+
return '<script type="text/javascript" src="'. $server . '/challenge?k=' . $pubkey . $errorpart . '"></script>
|
| 112 |
+
|
| 113 |
+
<noscript>
|
| 114 |
+
<iframe src="'. $server . '/noscript?k=' . $pubkey . $errorpart . '" height="300" width="500" frameborder="0"></iframe><br/>
|
| 115 |
+
<textarea name="recaptcha_challenge_field" rows="3" cols="40"></textarea>
|
| 116 |
+
<input type="hidden" name="recaptcha_response_field" value="manual_challenge"/>
|
| 117 |
+
</noscript>';
|
| 118 |
+
}
|
| 119 |
+
|
| 120 |
+
/**
|
| 121 |
+
* Calls an HTTP POST function to verify if the user's guess was correct
|
| 122 |
+
* @param string $privkey
|
| 123 |
+
* @param string $remoteip
|
| 124 |
+
* @param string $challenge
|
| 125 |
+
* @param string $response
|
| 126 |
+
* @param array $extra_params an array of extra variables to post to the server
|
| 127 |
+
* @return ReCaptchaResponse
|
| 128 |
+
*/
|
| 129 |
+
function recaptcha_check_answer ($privkey, $remoteip, $challenge, $response, $extra_params = array())
|
| 130 |
+
{
|
| 131 |
+
if ($privkey == null || $privkey == '') {
|
| 132 |
+
die ("To use reCAPTCHA you must get an API key from <a href='http://recaptcha.net/api/getkey'>http://recaptcha.net/api/getkey</a>");
|
| 133 |
+
}
|
| 134 |
+
|
| 135 |
+
if ($remoteip == null || $remoteip == '') {
|
| 136 |
+
die ("For security reasons, you must pass the remote ip to reCAPTCHA");
|
| 137 |
+
}
|
| 138 |
+
|
| 139 |
+
//discard spam submissions
|
| 140 |
+
if ($challenge == null || strlen($challenge) == 0 || $response == null || strlen($response) == 0) {
|
| 141 |
+
return false;
|
| 142 |
+
}
|
| 143 |
+
|
| 144 |
+
$response = $this->_recaptcha_http_post (self::RECAPTCHA_API_SERVER_HOST, self::RECAPTCHA_API_SERVER_PATH . "/verify", array ( 'privatekey' => $privkey,
|
| 145 |
+
'remoteip' => $remoteip,
|
| 146 |
+
'challenge' => $challenge,
|
| 147 |
+
'response' => $response
|
| 148 |
+
) + $extra_params
|
| 149 |
+
);
|
| 150 |
+
|
| 151 |
+
$answers = explode ("\n", $response [1]);
|
| 152 |
+
|
| 153 |
+
if (trim ($answers [0]) == 'true') {
|
| 154 |
+
return true;
|
| 155 |
+
}
|
| 156 |
+
return false;
|
| 157 |
+
}
|
| 158 |
+
|
| 159 |
+
/**
|
| 160 |
+
* gets a URL where the user can sign up for reCAPTCHA. If your application
|
| 161 |
+
* has a configuration page where you enter a key, you should provide a link
|
| 162 |
+
* using this function.
|
| 163 |
+
* @param string $domain The domain where the page is hosted
|
| 164 |
+
* @param string $appname The name of your application
|
| 165 |
+
*/
|
| 166 |
+
function recaptcha_get_signup_url ($domain = null, $appname = null)
|
| 167 |
+
{
|
| 168 |
+
return "http://recaptcha.net/api/getkey?" . $this->_recaptcha_qsencode (array ('domain' => $domain, 'app' => $appname));
|
| 169 |
+
}
|
| 170 |
+
|
| 171 |
+
function _recaptcha_aes_pad($val)
|
| 172 |
+
{
|
| 173 |
+
$block_size = 16;
|
| 174 |
+
$numpad = $block_size - (strlen ($val) % $block_size);
|
| 175 |
+
return str_pad($val, strlen ($val) + $numpad, chr($numpad));
|
| 176 |
+
}
|
| 177 |
+
}
|
| 178 |
+
?>
|
app/code/community/Fontis/Recaptcha/Model/Source/Recaptchalanguage.php
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Fontis Recaptcha Extension
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 11 |
+
* If you did not receive a copy of the license and are unable to
|
| 12 |
+
* obtain it through the world-wide-web, please send an email
|
| 13 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 14 |
+
*
|
| 15 |
+
* @category Fontis
|
| 16 |
+
* @package Fontis_Recaptcha
|
| 17 |
+
* @author Denis Margetic
|
| 18 |
+
* @author Chris Norton
|
| 19 |
+
* @copyright Copyright (c) 2011 Fontis Pty. Ltd. (http://www.fontis.com.au)
|
| 20 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 21 |
+
*/
|
| 22 |
+
|
| 23 |
+
class Fontis_Recaptcha_Model_Source_Recaptchalanguage
|
| 24 |
+
{
|
| 25 |
+
public function toOptionArray()
|
| 26 |
+
{
|
| 27 |
+
return array(array('value' => 'en', 'label' => 'English'),
|
| 28 |
+
array('value' => 'fr', 'label' => 'French'),
|
| 29 |
+
array('value' => 'de', 'label' => 'German'),
|
| 30 |
+
array('value' => 'nl', 'label' => 'Dutch'),
|
| 31 |
+
array('value' => 'pt', 'label' => 'Portuguese'),
|
| 32 |
+
array('value' => 'ru', 'label' => 'Russian'),
|
| 33 |
+
array('value' => 'es', 'label' => 'Spanish'),
|
| 34 |
+
array('value' => 'tr', 'label' => 'Turkish'),
|
| 35 |
+
);
|
| 36 |
+
}
|
| 37 |
+
}
|
app/code/community/Fontis/Recaptcha/Model/Source/Recaptchatheme.php
ADDED
|
@@ -0,0 +1,35 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Fontis Recaptcha Extension
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 11 |
+
* If you did not receive a copy of the license and are unable to
|
| 12 |
+
* obtain it through the world-wide-web, please send an email
|
| 13 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 14 |
+
*
|
| 15 |
+
* @category Fontis
|
| 16 |
+
* @package Fontis_Recaptcha
|
| 17 |
+
* @author Denis Margetic
|
| 18 |
+
* @author Chris Norton
|
| 19 |
+
* @copyright Copyright (c) 2011 Fontis Pty. Ltd. (http://www.fontis.com.au)
|
| 20 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 21 |
+
*/
|
| 22 |
+
|
| 23 |
+
class Fontis_Recaptcha_Model_Source_Recaptchatheme
|
| 24 |
+
{
|
| 25 |
+
public function toOptionArray()
|
| 26 |
+
{
|
| 27 |
+
return array(array('value' => 'clean', 'label' => 'Clean'),
|
| 28 |
+
array('value' => 'white', 'label' => 'White'),
|
| 29 |
+
array('value' => 'red', 'label' => 'Red'),
|
| 30 |
+
array('value' => 'blackglass', 'label' => 'Blackglass'),
|
| 31 |
+
array('value' => 'magento', 'label' => 'Magento'),
|
| 32 |
+
array('value' => 'custom', 'label' => 'Custom'),
|
| 33 |
+
);
|
| 34 |
+
}
|
| 35 |
+
}
|
app/code/community/Fontis/Recaptcha/controllers/AccountController.php
ADDED
|
@@ -0,0 +1,57 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Fontis Recaptcha Extension
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 11 |
+
* If you did not receive a copy of the license and are unable to
|
| 12 |
+
* obtain it through the world-wide-web, please send an email
|
| 13 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 14 |
+
*
|
| 15 |
+
* @category Fontis
|
| 16 |
+
* @package Fontis_Recaptcha
|
| 17 |
+
* @author Denis Margetic
|
| 18 |
+
* @author Chris Norton
|
| 19 |
+
* @copyright Copyright (c) 2011 Fontis Pty. Ltd. (http://www.fontis.com.au)
|
| 20 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 21 |
+
*/
|
| 22 |
+
include_once "Mage/Customer/controllers/AccountController.php";
|
| 23 |
+
|
| 24 |
+
class Fontis_Recaptcha_AccountController extends Mage_Customer_AccountController
|
| 25 |
+
{
|
| 26 |
+
public function createPostAction()
|
| 27 |
+
{
|
| 28 |
+
if (Mage::getStoreConfig("fontis_recaptcha/recaptcha/customer"))
|
| 29 |
+
{ // check that recaptcha is actually enabled
|
| 30 |
+
|
| 31 |
+
$privatekey = Mage::getStoreConfig("fontis_recaptcha/setup/private_key");
|
| 32 |
+
// check response
|
| 33 |
+
$resp = Mage::helper("fontis_recaptcha")->recaptcha_check_answer( $privatekey,
|
| 34 |
+
$_SERVER["REMOTE_ADDR"],
|
| 35 |
+
$_POST["recaptcha_challenge_field"],
|
| 36 |
+
$_POST["recaptcha_response_field"]
|
| 37 |
+
);
|
| 38 |
+
|
| 39 |
+
if ($resp == true)
|
| 40 |
+
{ // if recaptcha response is correct, use core functionality
|
| 41 |
+
parent::createPostAction();
|
| 42 |
+
}
|
| 43 |
+
else
|
| 44 |
+
{
|
| 45 |
+
$this->_getSession()->addError($this->__('Your reCAPTCHA entry is incorrect. Please try again.'));
|
| 46 |
+
$this->_getSession()->setCustomerFormData($this->getRequest()->getPost());
|
| 47 |
+
$this->_redirectReferer();
|
| 48 |
+
return;
|
| 49 |
+
}
|
| 50 |
+
}
|
| 51 |
+
else
|
| 52 |
+
{ // if recaptcha is not enabled, use core function
|
| 53 |
+
parent::createPostAction();
|
| 54 |
+
}
|
| 55 |
+
}
|
| 56 |
+
}
|
| 57 |
+
?>
|
app/code/community/Fontis/Recaptcha/controllers/ContactsController.php
ADDED
|
@@ -0,0 +1,82 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Fontis Recaptcha Extension
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 11 |
+
* If you did not receive a copy of the license and are unable to
|
| 12 |
+
* obtain it through the world-wide-web, please send an email
|
| 13 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 14 |
+
*
|
| 15 |
+
* @category Fontis
|
| 16 |
+
* @package Fontis_Recaptcha
|
| 17 |
+
* @author Denis Margetic
|
| 18 |
+
* @author Chris Norton
|
| 19 |
+
* @copyright Copyright (c) 2011 Fontis Pty. Ltd. (http://www.fontis.com.au)
|
| 20 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 21 |
+
*/
|
| 22 |
+
include_once "Mage/Contacts/controllers/IndexController.php";
|
| 23 |
+
|
| 24 |
+
class Fontis_Recaptcha_ContactsController extends Mage_Contacts_IndexController
|
| 25 |
+
{
|
| 26 |
+
|
| 27 |
+
public function indexAction()
|
| 28 |
+
{
|
| 29 |
+
|
| 30 |
+
|
| 31 |
+
$this->loadLayout();
|
| 32 |
+
$this->getLayout()->getBlock('contactForm')->setFormAction( Mage::getUrl('*/*/post') );
|
| 33 |
+
|
| 34 |
+
$this->_initLayoutMessages('customer/session');
|
| 35 |
+
$this->_initLayoutMessages('catalog/session');
|
| 36 |
+
$this->renderLayout();
|
| 37 |
+
}
|
| 38 |
+
|
| 39 |
+
|
| 40 |
+
public function postAction()
|
| 41 |
+
{
|
| 42 |
+
if( !(Mage::getStoreConfig("fontis_recaptcha/recaptcha/when_loggedin") && (Mage::getSingleton('customer/session')->isLoggedIn())) )
|
| 43 |
+
{
|
| 44 |
+
if (Mage::getStoreConfig("fontis_recaptcha/recaptcha/contacts"))
|
| 45 |
+
{
|
| 46 |
+
$privatekey = Mage::getStoreConfig("fontis_recaptcha/setup/private_key");
|
| 47 |
+
// check response
|
| 48 |
+
$resp = Mage::helper("fontis_recaptcha")->recaptcha_check_answer( $privatekey,
|
| 49 |
+
$_SERVER["REMOTE_ADDR"],
|
| 50 |
+
$_POST["recaptcha_challenge_field"],
|
| 51 |
+
$_POST["recaptcha_response_field"]
|
| 52 |
+
);
|
| 53 |
+
if ($resp == true)
|
| 54 |
+
{ // if recaptcha response is correct, use core functionality
|
| 55 |
+
parent::postAction();
|
| 56 |
+
}
|
| 57 |
+
else
|
| 58 |
+
{ // if recaptcha response is incorrect, reload the page
|
| 59 |
+
|
| 60 |
+
Mage::getSingleton('customer/session')->addError(Mage::helper('contacts')->__('Your reCAPTCHA entry is incorrect. Please try again.'));
|
| 61 |
+
|
| 62 |
+
$_SESSION['contact_comment'] = $_POST['comment'];
|
| 63 |
+
$_SESSION['contact_name'] = $_POST['name'];
|
| 64 |
+
$_SESSION['contact_email'] = $_POST['email'];
|
| 65 |
+
$_SESSION['contact_telephone'] = $_POST['telephone'];
|
| 66 |
+
|
| 67 |
+
$this->_redirect('contacts/');
|
| 68 |
+
return;
|
| 69 |
+
}
|
| 70 |
+
}
|
| 71 |
+
else
|
| 72 |
+
{ // if recaptcha is not enabled, use core function alone
|
| 73 |
+
parent::postAction();
|
| 74 |
+
}
|
| 75 |
+
}
|
| 76 |
+
else
|
| 77 |
+
{ // if recaptcha is not enabled, use core function alone
|
| 78 |
+
parent::postAction();
|
| 79 |
+
}
|
| 80 |
+
}
|
| 81 |
+
}
|
| 82 |
+
?>
|
app/code/community/Fontis/Recaptcha/controllers/ProductController.php
ADDED
|
@@ -0,0 +1,63 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Fontis Recaptcha Extension
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 11 |
+
* If you did not receive a copy of the license and are unable to
|
| 12 |
+
* obtain it through the world-wide-web, please send an email
|
| 13 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 14 |
+
*
|
| 15 |
+
* @category Fontis
|
| 16 |
+
* @package Fontis_Recaptcha
|
| 17 |
+
* @author Denis Margetic
|
| 18 |
+
* @author Chris Norton
|
| 19 |
+
* @copyright Copyright (c) 2011 Fontis Pty. Ltd. (http://www.fontis.com.au)
|
| 20 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 21 |
+
*/
|
| 22 |
+
include_once "Mage/Sendfriend/controllers/ProductController.php";
|
| 23 |
+
|
| 24 |
+
class Fontis_Recaptcha_ProductController extends Mage_Sendfriend_ProductController
|
| 25 |
+
{
|
| 26 |
+
public function sendmailAction()
|
| 27 |
+
{
|
| 28 |
+
if( !(Mage::getStoreConfig("fontis_recaptcha/recaptcha/when_loggedin") && (Mage::getSingleton('customer/session')->isLoggedIn())) )
|
| 29 |
+
{
|
| 30 |
+
if (Mage::getStoreConfig("fontis_recaptcha/recaptcha/sendfriend"))
|
| 31 |
+
{
|
| 32 |
+
$privatekey = Mage::getStoreConfig("fontis_recaptcha/setup/private_key");
|
| 33 |
+
// check response
|
| 34 |
+
$resp = Mage::helper("fontis_recaptcha")->recaptcha_check_answer( $privatekey,
|
| 35 |
+
$_SERVER["REMOTE_ADDR"],
|
| 36 |
+
$_POST["recaptcha_challenge_field"],
|
| 37 |
+
$_POST["recaptcha_response_field"]
|
| 38 |
+
);
|
| 39 |
+
$data = $this->getRequest()->getPost();
|
| 40 |
+
if ($resp == true)
|
| 41 |
+
{ // if recaptcha response is correct, use core functionality
|
| 42 |
+
parent::sendmailAction();
|
| 43 |
+
}
|
| 44 |
+
else
|
| 45 |
+
{ // if recaptcha response is incorrect, reload the page
|
| 46 |
+
Mage::getSingleton('catalog/session')->addError($this->__('Your reCAPTCHA entry is incorrect. Please try again.'));
|
| 47 |
+
Mage::getSingleton('catalog/session')->setSendfriendFormData($data);
|
| 48 |
+
$this->_redirectReferer();
|
| 49 |
+
return;
|
| 50 |
+
}
|
| 51 |
+
}
|
| 52 |
+
else
|
| 53 |
+
{ // if recaptcha is not enabled, use core function alone
|
| 54 |
+
parent::sendmailAction();
|
| 55 |
+
}
|
| 56 |
+
}
|
| 57 |
+
else
|
| 58 |
+
{ // if recaptcha is not enabled, use core function alone
|
| 59 |
+
parent::sendmailAction();
|
| 60 |
+
}
|
| 61 |
+
}
|
| 62 |
+
}
|
| 63 |
+
?>
|
app/code/community/Fontis/Recaptcha/controllers/ReviewController.php
ADDED
|
@@ -0,0 +1,62 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Fontis Recaptcha Extension
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 11 |
+
* If you did not receive a copy of the license and are unable to
|
| 12 |
+
* obtain it through the world-wide-web, please send an email
|
| 13 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 14 |
+
*
|
| 15 |
+
* @category Fontis
|
| 16 |
+
* @package Fontis_Recaptcha
|
| 17 |
+
* @author Denis Margetic
|
| 18 |
+
* @author Chris Norton
|
| 19 |
+
* @copyright Copyright (c) 2011 Fontis Pty. Ltd. (http://www.fontis.com.au)
|
| 20 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 21 |
+
*/
|
| 22 |
+
include_once "Mage/Review/controllers/ProductController.php";
|
| 23 |
+
|
| 24 |
+
class Fontis_Recaptcha_ReviewController extends Mage_Review_ProductController
|
| 25 |
+
{
|
| 26 |
+
public function postAction()
|
| 27 |
+
{
|
| 28 |
+
if( !(Mage::getStoreConfig("fontis_recaptcha/recaptcha/when_loggedin") && (Mage::getSingleton('customer/session')->isLoggedIn())) )
|
| 29 |
+
{
|
| 30 |
+
if (Mage::getStoreConfig("fontis_recaptcha/recaptcha/review"))
|
| 31 |
+
{
|
| 32 |
+
$privatekey = Mage::getStoreConfig("fontis_recaptcha/setup/private_key");
|
| 33 |
+
// check response
|
| 34 |
+
$resp = Mage::helper("fontis_recaptcha")->recaptcha_check_answer( $privatekey,
|
| 35 |
+
$_SERVER["REMOTE_ADDR"],
|
| 36 |
+
$_POST["recaptcha_challenge_field"],
|
| 37 |
+
$_POST["recaptcha_response_field"]
|
| 38 |
+
);
|
| 39 |
+
$data = $this->getRequest()->getPost();
|
| 40 |
+
if ($resp == true)
|
| 41 |
+
{ // if recaptcha response is correct, use core functionality
|
| 42 |
+
parent::postAction();
|
| 43 |
+
}
|
| 44 |
+
else
|
| 45 |
+
{ // if recaptcha response is incorrect, reload the page
|
| 46 |
+
Mage::getSingleton('core/session')->addError($this->__('Your reCAPTCHA entry is incorrect. Please try again.'));
|
| 47 |
+
Mage::getSingleton('review/session')->setFormData($data);
|
| 48 |
+
$this->_redirectReferer();
|
| 49 |
+
return;
|
| 50 |
+
}
|
| 51 |
+
}
|
| 52 |
+
else
|
| 53 |
+
{ // if recaptcha is not enabled, use core function alone
|
| 54 |
+
parent::postAction();
|
| 55 |
+
}
|
| 56 |
+
}
|
| 57 |
+
else
|
| 58 |
+
{ // if recaptcha is not enabled, use core function alone
|
| 59 |
+
parent::postAction();
|
| 60 |
+
}
|
| 61 |
+
}
|
| 62 |
+
}
|
app/code/community/Fontis/Recaptcha/etc/config.xml
ADDED
|
@@ -0,0 +1,151 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<!--
|
| 3 |
+
/**
|
| 4 |
+
* Fontis Recaptcha Extension
|
| 5 |
+
*
|
| 6 |
+
* NOTICE OF LICENSE
|
| 7 |
+
*
|
| 8 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 9 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 10 |
+
* It is also available through the world-wide-web at this URL:
|
| 11 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 12 |
+
* If you did not receive a copy of the license and are unable to
|
| 13 |
+
* obtain it through the world-wide-web, please send an email
|
| 14 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 15 |
+
*
|
| 16 |
+
* @category Fontis
|
| 17 |
+
* @package Fontis_Recaptcha
|
| 18 |
+
* @author Denis Margetic
|
| 19 |
+
* @author Chris Norton
|
| 20 |
+
* @copyright Copyright (c) 2011 Fontis Pty. Ltd. (http://www.fontis.com.au)
|
| 21 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 22 |
+
*/
|
| 23 |
+
-->
|
| 24 |
+
<config>
|
| 25 |
+
<modules>
|
| 26 |
+
<Fontis_Recaptcha>
|
| 27 |
+
<version>2.4.0</version>
|
| 28 |
+
</Fontis_Recaptcha>
|
| 29 |
+
</modules>
|
| 30 |
+
<global>
|
| 31 |
+
<rewrite>
|
| 32 |
+
<fontis_recaptcha>
|
| 33 |
+
<from><![CDATA[#^/customer/account/createpost/#]]></from>
|
| 34 |
+
<to>/recaptcha/account/createpost/</to>
|
| 35 |
+
</fontis_recaptcha>
|
| 36 |
+
</rewrite>
|
| 37 |
+
<rewrite>
|
| 38 |
+
<fontis_recaptcha2>
|
| 39 |
+
<from><![CDATA[#^/sendfriend/product/sendmail/#]]></from>
|
| 40 |
+
<to>/recaptcha/product/sendmail/</to>
|
| 41 |
+
</fontis_recaptcha2>
|
| 42 |
+
</rewrite>
|
| 43 |
+
<rewrite>
|
| 44 |
+
<fontis_recaptcha3>
|
| 45 |
+
<from><![CDATA[#^/review/product/post/#]]></from>
|
| 46 |
+
<to>/recaptcha/review/post/</to>
|
| 47 |
+
</fontis_recaptcha3>
|
| 48 |
+
</rewrite>
|
| 49 |
+
<rewrite>
|
| 50 |
+
<fontis_recaptcha4>
|
| 51 |
+
<from><![CDATA[#^/contacts/contacts/post/#]]></from>
|
| 52 |
+
<to>/recaptcha/contacts/post/</to>
|
| 53 |
+
</fontis_recaptcha4>
|
| 54 |
+
</rewrite>
|
| 55 |
+
<rewrite>
|
| 56 |
+
<fontis_recaptcha5>
|
| 57 |
+
<from><![CDATA[#^/contacts#]]></from>
|
| 58 |
+
<to>/recaptcha/contacts/</to>
|
| 59 |
+
</fontis_recaptcha5>
|
| 60 |
+
</rewrite>
|
| 61 |
+
|
| 62 |
+
<models>
|
| 63 |
+
<fontis_recaptcha>
|
| 64 |
+
<class>Fontis_Recaptcha_Model</class>
|
| 65 |
+
</fontis_recaptcha>
|
| 66 |
+
</models>
|
| 67 |
+
<blocks>
|
| 68 |
+
<review>
|
| 69 |
+
<rewrite>
|
| 70 |
+
<form>Fontis_Recaptcha_Block_Review_Form</form>
|
| 71 |
+
</rewrite>
|
| 72 |
+
</review>
|
| 73 |
+
</blocks>
|
| 74 |
+
<helpers>
|
| 75 |
+
<fontis_recaptcha>
|
| 76 |
+
<class>Fontis_Recaptcha_Helper</class>
|
| 77 |
+
</fontis_recaptcha>
|
| 78 |
+
</helpers>
|
| 79 |
+
</global>
|
| 80 |
+
<frontend>
|
| 81 |
+
<routers>
|
| 82 |
+
<fontis_recaptcha>
|
| 83 |
+
<use>standard</use>
|
| 84 |
+
<args>
|
| 85 |
+
<module>Fontis_Recaptcha</module>
|
| 86 |
+
<frontName>recaptcha</frontName>
|
| 87 |
+
</args>
|
| 88 |
+
</fontis_recaptcha>
|
| 89 |
+
</routers>
|
| 90 |
+
<layout>
|
| 91 |
+
<updates>
|
| 92 |
+
<fontis_recaptcha module="Fontis_Recaptcha">
|
| 93 |
+
<file>fontis_recaptcha.xml</file>
|
| 94 |
+
</fontis_recaptcha>
|
| 95 |
+
</updates>
|
| 96 |
+
</layout>
|
| 97 |
+
</frontend>
|
| 98 |
+
<default>
|
| 99 |
+
<fontis_recaptcha>
|
| 100 |
+
<setup>
|
| 101 |
+
<public_key></public_key>
|
| 102 |
+
<private_key></private_key>
|
| 103 |
+
<recaptcha_theme>magento</recaptcha_theme>
|
| 104 |
+
<language>en</language>
|
| 105 |
+
<textbox><b>Recaptcha helps stop spam.</b></textbox>
|
| 106 |
+
</setup>
|
| 107 |
+
<recaptcha>
|
| 108 |
+
<when_loggedin>1</when_loggedin>
|
| 109 |
+
<sendfriend>1</sendfriend>
|
| 110 |
+
<contacts>1</contacts>
|
| 111 |
+
<customer>1</customer>
|
| 112 |
+
<review>1</review>
|
| 113 |
+
</recaptcha>
|
| 114 |
+
<translation>
|
| 115 |
+
<enable_translation>disable</enable_translation>
|
| 116 |
+
<text_captcha>Type the two words:</text_captcha>
|
| 117 |
+
<audio_captcha>Type words you hear:</audio_captcha>
|
| 118 |
+
<play_again>Play Again?</play_again>
|
| 119 |
+
<cant_hear_this>Can't hear the audio? Click here</cant_hear_this>
|
| 120 |
+
<visual_challenge>Get a visual challenge</visual_challenge>
|
| 121 |
+
<audio_challenge>Get an audio challenge</audio_challenge>
|
| 122 |
+
<refresh_btn>Get a new challenge</refresh_btn>
|
| 123 |
+
<help_btn>Help</help_btn>
|
| 124 |
+
</translation>
|
| 125 |
+
</fontis_recaptcha>
|
| 126 |
+
</default>
|
| 127 |
+
<adminhtml>
|
| 128 |
+
<acl>
|
| 129 |
+
<resources>
|
| 130 |
+
<all>
|
| 131 |
+
<title>Allow Everything</title>
|
| 132 |
+
</all>
|
| 133 |
+
<admin>
|
| 134 |
+
<children>
|
| 135 |
+
<system>
|
| 136 |
+
<children>
|
| 137 |
+
<config>
|
| 138 |
+
<children>
|
| 139 |
+
<fontis_recaptcha>
|
| 140 |
+
<title>Recaptcha</title>
|
| 141 |
+
</fontis_recaptcha>
|
| 142 |
+
</children>
|
| 143 |
+
</config>
|
| 144 |
+
</children>
|
| 145 |
+
</system>
|
| 146 |
+
</children>
|
| 147 |
+
</admin>
|
| 148 |
+
</resources>
|
| 149 |
+
</acl>
|
| 150 |
+
</adminhtml>
|
| 151 |
+
</config>
|
app/code/community/Fontis/Recaptcha/etc/system.xml
ADDED
|
@@ -0,0 +1,242 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<!--
|
| 3 |
+
/**
|
| 4 |
+
* Fontis Recaptcha Extension
|
| 5 |
+
*
|
| 6 |
+
* NOTICE OF LICENSE
|
| 7 |
+
*
|
| 8 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 9 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 10 |
+
* It is also available through the world-wide-web at this URL:
|
| 11 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 12 |
+
* If you did not receive a copy of the license and are unable to
|
| 13 |
+
* obtain it through the world-wide-web, please send an email
|
| 14 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 15 |
+
*
|
| 16 |
+
* @category Fontis
|
| 17 |
+
* @package Fontis_Recaptcha
|
| 18 |
+
* @author Denis Margetic
|
| 19 |
+
* @author Chris Norton
|
| 20 |
+
* @copyright Copyright (c) 2011 Fontis Pty. Ltd. (http://www.fontis.com.au)
|
| 21 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 22 |
+
*/
|
| 23 |
+
-->
|
| 24 |
+
<config>
|
| 25 |
+
<tabs>
|
| 26 |
+
<fontis_extensions translate="label" module="fontis_recaptcha">
|
| 27 |
+
<label>Fontis Extensions</label>
|
| 28 |
+
<sort_order>1000000</sort_order>
|
| 29 |
+
</fontis_extensions>
|
| 30 |
+
</tabs>
|
| 31 |
+
<sections>
|
| 32 |
+
<fontis_recaptcha>
|
| 33 |
+
<label>Recaptcha</label>
|
| 34 |
+
<tab>fontis_extensions</tab>
|
| 35 |
+
<frontend_type>text</frontend_type>
|
| 36 |
+
<sort_order>999999</sort_order>
|
| 37 |
+
<show_in_default>1</show_in_default>
|
| 38 |
+
<show_in_website>1</show_in_website>
|
| 39 |
+
<show_in_store>1</show_in_store>
|
| 40 |
+
<groups>
|
| 41 |
+
<setup translate="label">
|
| 42 |
+
<label>Recaptcha Setup</label>
|
| 43 |
+
<frontend_type>text</frontend_type>
|
| 44 |
+
<sort_order>2</sort_order>
|
| 45 |
+
<show_in_default>1</show_in_default>
|
| 46 |
+
<show_in_website>1</show_in_website>
|
| 47 |
+
<show_in_store>1</show_in_store>
|
| 48 |
+
<fields>
|
| 49 |
+
<public_key translate="label">
|
| 50 |
+
<label>Public Key</label>
|
| 51 |
+
<frontend_type>text</frontend_type>
|
| 52 |
+
<sort_order>10</sort_order>
|
| 53 |
+
<show_in_default>1</show_in_default>
|
| 54 |
+
<show_in_website>1</show_in_website>
|
| 55 |
+
<show_in_store>1</show_in_store>
|
| 56 |
+
</public_key>
|
| 57 |
+
<private_key translate="label">
|
| 58 |
+
<label>Private Key</label>
|
| 59 |
+
<frontend_type>text</frontend_type>
|
| 60 |
+
<sort_order>11</sort_order>
|
| 61 |
+
<show_in_default>1</show_in_default>
|
| 62 |
+
<show_in_website>1</show_in_website>
|
| 63 |
+
<show_in_store>1</show_in_store>
|
| 64 |
+
</private_key>
|
| 65 |
+
<theme translate="label">
|
| 66 |
+
<label>Recaptcha Theme</label>
|
| 67 |
+
<frontend_type>select</frontend_type>
|
| 68 |
+
<source_model>fontis_recaptcha/source_recaptchatheme</source_model>
|
| 69 |
+
<sort_order>1</sort_order>
|
| 70 |
+
<show_in_default>1</show_in_default>
|
| 71 |
+
<show_in_website>1</show_in_website>
|
| 72 |
+
<show_in_store>1</show_in_store>
|
| 73 |
+
</theme>
|
| 74 |
+
<language translate="label">
|
| 75 |
+
<label>Language</label>
|
| 76 |
+
<frontend_type>select</frontend_type>
|
| 77 |
+
<source_model>fontis_recaptcha/source_recaptchalanguage</source_model>
|
| 78 |
+
<sort_order>2</sort_order>
|
| 79 |
+
<show_in_default>1</show_in_default>
|
| 80 |
+
<show_in_website>1</show_in_website>
|
| 81 |
+
<show_in_store>1</show_in_store>
|
| 82 |
+
</language>
|
| 83 |
+
<textbox translate="label">
|
| 84 |
+
<label>Info Message</label>
|
| 85 |
+
<frontend_type>text</frontend_type>
|
| 86 |
+
<sort_order>3</sort_order>
|
| 87 |
+
<show_in_default>1</show_in_default>
|
| 88 |
+
<show_in_website>1</show_in_website>
|
| 89 |
+
<show_in_store>1</show_in_store>
|
| 90 |
+
</textbox>
|
| 91 |
+
</fields>
|
| 92 |
+
</setup>
|
| 93 |
+
<recaptcha translate="label">
|
| 94 |
+
<label>Recaptcha Controls</label>
|
| 95 |
+
<frontend_type>text</frontend_type>
|
| 96 |
+
<sort_order>5</sort_order>
|
| 97 |
+
<show_in_default>1</show_in_default>
|
| 98 |
+
<show_in_website>1</show_in_website>
|
| 99 |
+
<show_in_store>1</show_in_store>
|
| 100 |
+
<fields>
|
| 101 |
+
<when_loggedin translate="label">
|
| 102 |
+
<label>Hide for Logged-in Customers</label>
|
| 103 |
+
<frontend_type>select</frontend_type>
|
| 104 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
| 105 |
+
<sort_order>1</sort_order>
|
| 106 |
+
<show_in_default>1</show_in_default>
|
| 107 |
+
<show_in_website>1</show_in_website>
|
| 108 |
+
<show_in_store>1</show_in_store>
|
| 109 |
+
</when_loggedin>
|
| 110 |
+
<sendfriend translate="label">
|
| 111 |
+
<label>Email to a Friend Form</label>
|
| 112 |
+
<frontend_type>select</frontend_type>
|
| 113 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
| 114 |
+
<sort_order>2</sort_order>
|
| 115 |
+
<show_in_default>1</show_in_default>
|
| 116 |
+
<show_in_website>1</show_in_website>
|
| 117 |
+
<show_in_store>1</show_in_store>
|
| 118 |
+
</sendfriend>
|
| 119 |
+
<contacts translate="label">
|
| 120 |
+
<label>Contact Us Form</label>
|
| 121 |
+
<frontend_type>select</frontend_type>
|
| 122 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
| 123 |
+
<sort_order>2</sort_order>
|
| 124 |
+
<show_in_default>1</show_in_default>
|
| 125 |
+
<show_in_website>1</show_in_website>
|
| 126 |
+
<show_in_store>1</show_in_store>
|
| 127 |
+
</contacts>
|
| 128 |
+
<customer translate="label">
|
| 129 |
+
<label>Account Creation Form</label>
|
| 130 |
+
<frontend_type>select</frontend_type>
|
| 131 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
| 132 |
+
<sort_order>2</sort_order>
|
| 133 |
+
<show_in_default>1</show_in_default>
|
| 134 |
+
<show_in_website>1</show_in_website>
|
| 135 |
+
<show_in_store>1</show_in_store>
|
| 136 |
+
</customer>
|
| 137 |
+
<review translate="label">
|
| 138 |
+
<label>Product Review Form</label>
|
| 139 |
+
<frontend_type>select</frontend_type>
|
| 140 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
| 141 |
+
<sort_order>2</sort_order>
|
| 142 |
+
<show_in_default>1</show_in_default>
|
| 143 |
+
<show_in_website>1</show_in_website>
|
| 144 |
+
<show_in_store>1</show_in_store>
|
| 145 |
+
</review>
|
| 146 |
+
</fields>
|
| 147 |
+
</recaptcha>
|
| 148 |
+
<translation translat="translation">
|
| 149 |
+
<label>Translation (Leave a field empty to use its default values)</label>
|
| 150 |
+
<frontend_type>text</frontend_type>
|
| 151 |
+
<sort_order>12</sort_order>
|
| 152 |
+
<show_in_default>1</show_in_default>
|
| 153 |
+
<show_in_website>1</show_in_website>
|
| 154 |
+
<show_in_store>1</show_in_store>
|
| 155 |
+
<fields>
|
| 156 |
+
<enable_translation translate="label">
|
| 157 |
+
<label>Enable Custom Translation</label>
|
| 158 |
+
<frontend_type>select</frontend_type>
|
| 159 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
| 160 |
+
<sort_order>8</sort_order>
|
| 161 |
+
<show_in_default>1</show_in_default>
|
| 162 |
+
<show_in_website>1</show_in_website>
|
| 163 |
+
<show_in_store>1</show_in_store>
|
| 164 |
+
</enable_translation>
|
| 165 |
+
<text_captcha translate="label">
|
| 166 |
+
<label>Text Captcha Instructions</label>
|
| 167 |
+
<frontend_type>text</frontend_type>
|
| 168 |
+
<sort_order>8</sort_order>
|
| 169 |
+
<show_in_default>1</show_in_default>
|
| 170 |
+
<show_in_website>1</show_in_website>
|
| 171 |
+
<show_in_store>1</show_in_store>
|
| 172 |
+
</text_captcha>
|
| 173 |
+
<audio_captcha translate="label">
|
| 174 |
+
<label>Audio Captcha Instructions</label>
|
| 175 |
+
<frontend_type>text</frontend_type>
|
| 176 |
+
<sort_order>9</sort_order>
|
| 177 |
+
<show_in_default>1</show_in_default>
|
| 178 |
+
<show_in_website>1</show_in_website>
|
| 179 |
+
<show_in_store>1</show_in_store>
|
| 180 |
+
</audio_captcha>
|
| 181 |
+
<play_again translate="label">
|
| 182 |
+
<label>Play Again</label>
|
| 183 |
+
<frontend_type>text</frontend_type>
|
| 184 |
+
<sort_order>10</sort_order>
|
| 185 |
+
<show_in_default>1</show_in_default>
|
| 186 |
+
<show_in_website>1</show_in_website>
|
| 187 |
+
<show_in_store>1</show_in_store>
|
| 188 |
+
</play_again>
|
| 189 |
+
<cant_hear_this translate="label">
|
| 190 |
+
<label>Can't hear this</label>
|
| 191 |
+
<frontend_type>text</frontend_type>
|
| 192 |
+
<sort_order>11</sort_order>
|
| 193 |
+
<show_in_default>1</show_in_default>
|
| 194 |
+
<show_in_website>1</show_in_website>
|
| 195 |
+
<show_in_store>1</show_in_store>
|
| 196 |
+
</cant_hear_this>
|
| 197 |
+
<visual_challenge translate="label">
|
| 198 |
+
<label>Visual Challenge Tooltip</label>
|
| 199 |
+
<frontend_type>text</frontend_type>
|
| 200 |
+
<sort_order>12</sort_order>
|
| 201 |
+
<show_in_default>1</show_in_default>
|
| 202 |
+
<show_in_website>1</show_in_website>
|
| 203 |
+
<show_in_store>1</show_in_store>
|
| 204 |
+
</visual_challenge>
|
| 205 |
+
<audio_challenge translate="label">
|
| 206 |
+
<label>Audio Challenge Tooltip</label>
|
| 207 |
+
<frontend_type>text</frontend_type>
|
| 208 |
+
<sort_order>13</sort_order>
|
| 209 |
+
<show_in_default>1</show_in_default>
|
| 210 |
+
<show_in_website>1</show_in_website>
|
| 211 |
+
<show_in_store>1</show_in_store>
|
| 212 |
+
</audio_challenge>
|
| 213 |
+
<refresh_btn translate="label">
|
| 214 |
+
<label>Refresh Button Tooltip</label>
|
| 215 |
+
<frontend_type>text</frontend_type>
|
| 216 |
+
<sort_order>14</sort_order>
|
| 217 |
+
<show_in_default>1</show_in_default>
|
| 218 |
+
<show_in_website>1</show_in_website>
|
| 219 |
+
<show_in_store>1</show_in_store>
|
| 220 |
+
</refresh_btn>
|
| 221 |
+
<help_btn translate="label">
|
| 222 |
+
<label>Help Button Tooltip</label>
|
| 223 |
+
<frontend_type>text</frontend_type>
|
| 224 |
+
<sort_order>15</sort_order>
|
| 225 |
+
<show_in_default>1</show_in_default>
|
| 226 |
+
<show_in_website>1</show_in_website>
|
| 227 |
+
<show_in_store>1</show_in_store>
|
| 228 |
+
</help_btn >
|
| 229 |
+
<incorrect_try_again translate="label">
|
| 230 |
+
<label>Incorrect, Try again.</label>
|
| 231 |
+
<frontend_type>text</frontend_type>
|
| 232 |
+
<sort_order>16</sort_order>
|
| 233 |
+
<show_in_default>1</show_in_default>
|
| 234 |
+
<show_in_website>1</show_in_website>
|
| 235 |
+
<show_in_store>1</show_in_store>
|
| 236 |
+
</incorrect_try_again>
|
| 237 |
+
</fields>
|
| 238 |
+
</translation>
|
| 239 |
+
</groups>
|
| 240 |
+
</fontis_recaptcha>
|
| 241 |
+
</sections>
|
| 242 |
+
</config>
|
app/code/community/Fontis/Recaptcha/install.txt
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
If you're having trouble installing this extension, put the following key into Magento connect:
|
| 2 |
-
|
| 3 |
-
http://pear.fontis.com.au/Fontis_Recaptcha
|
|
|
|
|
|
|
|
|
app/design/frontend/base/default/layout/fontis_recaptcha.xml
ADDED
|
@@ -0,0 +1,59 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<!--
|
| 3 |
+
/**
|
| 4 |
+
* Fontis Recaptcha Extension
|
| 5 |
+
*
|
| 6 |
+
* NOTICE OF LICENSE
|
| 7 |
+
*
|
| 8 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 9 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 10 |
+
* It is also available through the world-wide-web at this URL:
|
| 11 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 12 |
+
* If you did not receive a copy of the license and are unable to
|
| 13 |
+
* obtain it through the world-wide-web, please send an email
|
| 14 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 15 |
+
*
|
| 16 |
+
* @category Fontis
|
| 17 |
+
* @package Fontis_Recaptcha
|
| 18 |
+
* @author Denis Margetic
|
| 19 |
+
* @author Chris Norton
|
| 20 |
+
* @copyright Copyright (c) 2011 Fontis Pty. Ltd. (http://www.fontis.com.au)
|
| 21 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 22 |
+
*/
|
| 23 |
+
-->
|
| 24 |
+
<layout version="0.1.0">
|
| 25 |
+
<sendfriend_product_send>
|
| 26 |
+
<remove name="sendfriend.send"/>
|
| 27 |
+
|
| 28 |
+
<reference name="content">
|
| 29 |
+
<block type="sendfriend/send" name="recaptcha_sendfriend_send" template="fontis/recaptcha/send.phtml">
|
| 30 |
+
<block type="core/template" name="recaptcha.box" as="recaptcha_box" template="fontis/recaptcha/recaptcha.phtml"/>
|
| 31 |
+
</block>
|
| 32 |
+
</reference>
|
| 33 |
+
</sendfriend_product_send>
|
| 34 |
+
|
| 35 |
+
<contacts_contacts_index>
|
| 36 |
+
<update handle="contacts_index_index" />
|
| 37 |
+
|
| 38 |
+
<reference name="contactForm">
|
| 39 |
+
<action method="setTemplate"><template>fontis/recaptcha/contacts.phtml</template></action>
|
| 40 |
+
<block type="core/template" name="recaptcha.box" as="recaptcha_box" template="fontis/recaptcha/recaptcha.phtml"/>
|
| 41 |
+
</reference>
|
| 42 |
+
</contacts_contacts_index>
|
| 43 |
+
|
| 44 |
+
<customer_account_create>
|
| 45 |
+
<remove name="customer_form_register"/>
|
| 46 |
+
|
| 47 |
+
<reference name="content">
|
| 48 |
+
<block type="customer/form_register" name="recaptcha_form_register" template="fontis/recaptcha/register.phtml">
|
| 49 |
+
<block type="core/template" name="recaptcha.box" as="recaptcha_box" template="fontis/recaptcha/recaptcha.phtml"/>
|
| 50 |
+
</block>
|
| 51 |
+
</reference>
|
| 52 |
+
</customer_account_create>
|
| 53 |
+
|
| 54 |
+
<review_product_list>
|
| 55 |
+
<block name="product.review.form" >
|
| 56 |
+
<block type="core/template" name="recaptcha.box" as="recaptcha_box" template="fontis/recaptcha/recaptcha.phtml"/>
|
| 57 |
+
</block>
|
| 58 |
+
</review_product_list>
|
| 59 |
+
</layout>
|
app/design/frontend/base/default/template/fontis/recaptcha/contacts.phtml
ADDED
|
@@ -0,0 +1,78 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Fontis Recaptcha Extension
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 11 |
+
* If you did not receive a copy of the license and are unable to
|
| 12 |
+
* obtain it through the world-wide-web, please send an email
|
| 13 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 14 |
+
*
|
| 15 |
+
* @category Fontis
|
| 16 |
+
* @package Fontis_Recaptcha
|
| 17 |
+
* @author Denis Margetic
|
| 18 |
+
* @author Chris Norton
|
| 19 |
+
* @copyright Copyright (c) 2009 Fontis Pty. Ltd. (http://www.fontis.com.au)
|
| 20 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 21 |
+
*/
|
| 22 |
+
?>
|
| 23 |
+
<div id="messages_product_view"><?php echo $this->getMessagesBlock()->getGroupedHtml() ?></div>
|
| 24 |
+
<div class="page-title">
|
| 25 |
+
<h1><?php echo Mage::helper('contacts')->__('Contact Us') ?></h1>
|
| 26 |
+
</div>
|
| 27 |
+
<form action="<?php echo $this->getFormAction(); ?>" id="contactForm" method="post">
|
| 28 |
+
<div class="fieldset">
|
| 29 |
+
<h2 class="legend"><?php echo Mage::helper('contacts')->__('Contact Information') ?></h2>
|
| 30 |
+
<ul class="form-list">
|
| 31 |
+
<li class="fields">
|
| 32 |
+
<div class="field">
|
| 33 |
+
<label for="name" class="required"><em>*</em><?php echo Mage::helper('contacts')->__('Name') ?></label>
|
| 34 |
+
<div class="input-box">
|
| 35 |
+
<input name="name" id="name" title="<?php echo Mage::helper('contacts')->__('Name') ?>" value="<?php echo $this->htmlEscape($this->helper('contacts')->getUserName()) ?>" class="input-text required-entry" type="text" />
|
| 36 |
+
</div>
|
| 37 |
+
</div>
|
| 38 |
+
<div class="field">
|
| 39 |
+
<label for="email" class="required"><em>*</em><?php echo Mage::helper('contacts')->__('Email') ?></label>
|
| 40 |
+
<div class="input-box">
|
| 41 |
+
<input name="email" id="email" title="<?php echo Mage::helper('contacts')->__('Email') ?>" value="<?php echo $this->htmlEscape($this->helper('contacts')->getUserEmail()) ?>" class="input-text required-entry validate-email" type="text" />
|
| 42 |
+
</div>
|
| 43 |
+
</div>
|
| 44 |
+
</li>
|
| 45 |
+
<li>
|
| 46 |
+
<label for="telephone"><?php echo Mage::helper('contacts')->__('Telephone') ?></label>
|
| 47 |
+
<div class="input-box">
|
| 48 |
+
<input name="telephone" id="telephone" title="<?php echo Mage::helper('contacts')->__('Telephone') ?>" value="" class="input-text" type="text" />
|
| 49 |
+
</div>
|
| 50 |
+
</li>
|
| 51 |
+
<li class="wide">
|
| 52 |
+
<label for="comment" class="required"><em>*</em><?php echo Mage::helper('contacts')->__('Comment') ?></label>
|
| 53 |
+
<div class="input-box">
|
| 54 |
+
<textarea name="comment" id="comment" title="<?php echo Mage::helper('contacts')->__('Comment') ?>" class="required-entry input-text" cols="5" rows="3"></textarea>
|
| 55 |
+
</div>
|
| 56 |
+
</li>
|
| 57 |
+
</ul>
|
| 58 |
+
</div>
|
| 59 |
+
|
| 60 |
+
<?php // recaptcha
|
| 61 |
+
if( !(Mage::getStoreConfig("fontis_recaptcha/recaptcha/when_loggedin") && (Mage::getSingleton('customer/session')->isLoggedIn())) )
|
| 62 |
+
{
|
| 63 |
+
if (Mage::getStoreConfig("fontis_recaptcha/recaptcha/contacts"))
|
| 64 |
+
echo $this->getChildHtml('recaptcha_box');
|
| 65 |
+
}
|
| 66 |
+
?>
|
| 67 |
+
|
| 68 |
+
<div class="buttons-set">
|
| 69 |
+
<p class="required"><?php echo Mage::helper('contacts')->__('* Required Fields') ?></p>
|
| 70 |
+
<input type="text" name="hideit" id="hideit" value="" style="display:none !important;" />
|
| 71 |
+
<button type="submit" title="<?php echo Mage::helper('contacts')->__('Submit') ?>" class="button"><span><span><?php echo Mage::helper('contacts')->__('Submit') ?></span></span></button>
|
| 72 |
+
</div>
|
| 73 |
+
</form>
|
| 74 |
+
<script type="text/javascript">
|
| 75 |
+
//<![CDATA[
|
| 76 |
+
var contactForm = new VarienForm('contactForm', true);
|
| 77 |
+
//]]>
|
| 78 |
+
</script>
|
app/design/frontend/base/default/template/fontis/recaptcha/form.phtml
ADDED
|
@@ -0,0 +1,141 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Magento
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Academic Free License (AFL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE_AFL.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/afl-3.0.php
|
| 11 |
+
* If you did not receive a copy of the license and are unable to
|
| 12 |
+
* obtain it through the world-wide-web, please send an email
|
| 13 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 14 |
+
*
|
| 15 |
+
* DISCLAIMER
|
| 16 |
+
*
|
| 17 |
+
* Do not edit or add to this file if you wish to upgrade Magento to newer
|
| 18 |
+
* versions in the future. If you wish to customize Magento for your
|
| 19 |
+
* needs please refer to http://www.magentocommerce.com for more information.
|
| 20 |
+
*
|
| 21 |
+
* @category design_default
|
| 22 |
+
* @package Mage
|
| 23 |
+
* @copyright Copyright (c) 2008 Irubin Consulting Inc. DBA Varien (http://www.varien.com)
|
| 24 |
+
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
| 25 |
+
*/
|
| 26 |
+
?>
|
| 27 |
+
<div class="form-add">
|
| 28 |
+
<h2><?php echo $this->__('Write Your Own Review') ?></h2>
|
| 29 |
+
<?php if ($this->getAllowWriteReviewFlag()): ?>
|
| 30 |
+
<form action="<?php echo $this->getAction() ?>" method="post" id="review-form">
|
| 31 |
+
<fieldset>
|
| 32 |
+
<?php echo $this->getChildHtml('form_fields_before')?>
|
| 33 |
+
<h3><?php echo $this->__("You're reviewing:"); ?> <span><?php echo $this->htmlEscape($this->getProductInfo()->getName()) ?></span></h3>
|
| 34 |
+
<?php if( $this->getRatings() && $this->getRatings()->getSize()): ?>
|
| 35 |
+
<h4><?php echo $this->__('How do you rate this product?') ?> <em class="required">*</em></h4>
|
| 36 |
+
<span id="input-message-box"></span>
|
| 37 |
+
<table class="data-table" id="product-review-table">
|
| 38 |
+
<col />
|
| 39 |
+
<col width="1" />
|
| 40 |
+
<col width="1" />
|
| 41 |
+
<col width="1" />
|
| 42 |
+
<col width="1" />
|
| 43 |
+
<col width="1" />
|
| 44 |
+
<thead>
|
| 45 |
+
<tr>
|
| 46 |
+
<th> </th>
|
| 47 |
+
<th><span class="nobr"><?php echo $this->__('1 star') ?></span></th>
|
| 48 |
+
<th><span class="nobr"><?php echo $this->__('2 stars') ?></span></th>
|
| 49 |
+
<th><span class="nobr"><?php echo $this->__('3 stars') ?></span></th>
|
| 50 |
+
<th><span class="nobr"><?php echo $this->__('4 stars') ?></span></th>
|
| 51 |
+
<th><span class="nobr"><?php echo $this->__('5 stars') ?></span></th>
|
| 52 |
+
</tr>
|
| 53 |
+
</thead>
|
| 54 |
+
<tbody>
|
| 55 |
+
<?php foreach ($this->getRatings() as $_rating): ?>
|
| 56 |
+
<tr>
|
| 57 |
+
<th><?php echo $this->escapeHtml($_rating->getRatingCode()) ?></th>
|
| 58 |
+
<?php foreach ($_rating->getOptions() as $_option): ?>
|
| 59 |
+
<td class="value"><input type="radio" name="ratings[<?php echo $_rating->getId() ?>]" id="<?php echo $this->escapeHtml($_rating->getRatingCode()) ?>_<?php echo $_option->getValue() ?>" value="<?php echo $_option->getId() ?>" class="radio" /></td>
|
| 60 |
+
<?php endforeach; ?>
|
| 61 |
+
</tr>
|
| 62 |
+
<?php endforeach; ?>
|
| 63 |
+
</tbody>
|
| 64 |
+
</table>
|
| 65 |
+
<input type="hidden" name="validate_rating" class="validate-rating" value="" />
|
| 66 |
+
<script type="text/javascript">decorateTable('product-review-table')</script>
|
| 67 |
+
<?php endif; ?>
|
| 68 |
+
<ul class="form-list">
|
| 69 |
+
<li>
|
| 70 |
+
<label for="nickname_field" class="required"><em>*</em><?php echo $this->__('Nickname') ?></label>
|
| 71 |
+
<div class="input-box">
|
| 72 |
+
<input type="text" name="nickname" id="nickname_field" class="input-text required-entry" value="<?php echo $this->htmlEscape($data->getNickname()) ?>" />
|
| 73 |
+
</div>
|
| 74 |
+
</li>
|
| 75 |
+
<li>
|
| 76 |
+
<label for="summary_field" class="required"><em>*</em><?php echo $this->__('Summary of Your Review') ?></label>
|
| 77 |
+
<div class="input-box">
|
| 78 |
+
<input type="text" name="title" id="summary_field" class="input-text required-entry" value="<?php echo $this->htmlEscape($data->getTitle()) ?>" />
|
| 79 |
+
</div>
|
| 80 |
+
</li>
|
| 81 |
+
<li>
|
| 82 |
+
<label for="review_field" class="required"><em>*</em><?php echo $this->__('Review') ?></label>
|
| 83 |
+
<div class="input-box">
|
| 84 |
+
<textarea name="detail" id="review_field" cols="5" rows="3" class="required-entry"><?php echo $this->htmlEscape($data->getDetail()) ?></textarea>
|
| 85 |
+
</div>
|
| 86 |
+
</li>
|
| 87 |
+
</ul>
|
| 88 |
+
</fieldset>
|
| 89 |
+
|
| 90 |
+
<?php // recaptcha
|
| 91 |
+
if( !(Mage::getStoreConfig("fontis_recaptcha/recaptcha/when_loggedin") && (Mage::getSingleton('customer/session')->isLoggedIn())) )
|
| 92 |
+
{
|
| 93 |
+
if (Mage::getStoreConfig("fontis_recaptcha/recaptcha/review"))
|
| 94 |
+
echo $this->getChildHtml('recaptcha_box');
|
| 95 |
+
}
|
| 96 |
+
?>
|
| 97 |
+
|
| 98 |
+
<div class="buttons-set">
|
| 99 |
+
<button type="submit" title="<?php echo $this->__('Submit Review') ?>" class="button"><span><span><?php echo $this->__('Submit Review') ?></span></span></button>
|
| 100 |
+
</div>
|
| 101 |
+
</form>
|
| 102 |
+
<script type="text/javascript">
|
| 103 |
+
//<![CDATA[
|
| 104 |
+
var dataForm = new VarienForm('review-form');
|
| 105 |
+
Validation.addAllThese(
|
| 106 |
+
[
|
| 107 |
+
['validate-rating', '<?php echo $this->__('Please select one of each of the ratings above') ?>', function(v) {
|
| 108 |
+
var trs = $('product-review-table').select('tr');
|
| 109 |
+
var inputs;
|
| 110 |
+
var error = 1;
|
| 111 |
+
|
| 112 |
+
for( var j=0; j < trs.length; j++ ) {
|
| 113 |
+
var tr = trs[j];
|
| 114 |
+
if( j > 0 ) {
|
| 115 |
+
inputs = tr.select('input');
|
| 116 |
+
|
| 117 |
+
for( i in inputs ) {
|
| 118 |
+
if( inputs[i].checked == true ) {
|
| 119 |
+
error = 0;
|
| 120 |
+
}
|
| 121 |
+
}
|
| 122 |
+
|
| 123 |
+
if( error == 1 ) {
|
| 124 |
+
return false;
|
| 125 |
+
} else {
|
| 126 |
+
error = 1;
|
| 127 |
+
}
|
| 128 |
+
}
|
| 129 |
+
}
|
| 130 |
+
return true;
|
| 131 |
+
}]
|
| 132 |
+
]
|
| 133 |
+
);
|
| 134 |
+
//]]>
|
| 135 |
+
</script>
|
| 136 |
+
<?php else: ?>
|
| 137 |
+
<p class="review-nologged" id="review-form">
|
| 138 |
+
<?php echo $this->__('Only registered users can write reviews. Please, <a href="%s">log in</a> or <a href="%s">register</a>', $this->getLoginLink(), Mage::helper('customer')->getRegisterUrl()) ?>
|
| 139 |
+
</p>
|
| 140 |
+
<?php endif ?>
|
| 141 |
+
</div>
|
app/design/frontend/base/default/template/fontis/recaptcha/recaptcha.phtml
ADDED
|
@@ -0,0 +1,112 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Fontis Recaptcha Extension
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 11 |
+
* If you did not receive a copy of the license and are unable to
|
| 12 |
+
* obtain it through the world-wide-web, please send an email
|
| 13 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 14 |
+
*
|
| 15 |
+
* @category Fontis
|
| 16 |
+
* @package Fontis_Recaptcha
|
| 17 |
+
* @author Denis Margetic
|
| 18 |
+
* @author Chris Norton
|
| 19 |
+
* @copyright Copyright (c) 2009 Fontis Pty. Ltd. (http://www.fontis.com.au)
|
| 20 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 21 |
+
*/
|
| 22 |
+
?>
|
| 23 |
+
<?php
|
| 24 |
+
$theme = Mage::getStoreConfig("fontis_recaptcha/setup/theme");
|
| 25 |
+
$language = Mage::getStoreConfig("fontis_recaptcha/setup/language");
|
| 26 |
+
$publickey = Mage::getStoreConfig("fontis_recaptcha/setup/public_key");
|
| 27 |
+
$textbox = Mage::getStoreConfig("fontis_recaptcha/setup/textbox");
|
| 28 |
+
|
| 29 |
+
// translations
|
| 30 |
+
$use_custom_translation = Mage::getStoreConfig("fontis_recaptcha/translation/enable_translation");
|
| 31 |
+
$instructions_visual = Mage::getStoreConfig("fontis_recaptcha/translation/text_captcha");
|
| 32 |
+
$instructions_audio = Mage::getStoreConfig("fontis_recaptcha/translation/audio_captcha");
|
| 33 |
+
$play_again = Mage::getStoreConfig("fontis_recaptcha/translation/play_again");
|
| 34 |
+
$cant_hear_this = Mage::getStoreConfig("fontis_recaptcha/translation/cant_hear_this");
|
| 35 |
+
$visual_challenge = Mage::getStoreConfig("fontis_recaptcha/translation/visual_challenge");
|
| 36 |
+
$audio_challenge = Mage::getStoreConfig("fontis_recaptcha/translation/audio_challenge");
|
| 37 |
+
$refresh_btn = Mage::getStoreConfig("fontis_recaptcha/translation/refresh_btn");
|
| 38 |
+
$help_btn = Mage::getStoreConfig("fontis_recaptcha/translation/help_btn");
|
| 39 |
+
|
| 40 |
+
// set default for null values
|
| 41 |
+
$instructions_visual = (!$instructions_visual) ? 'Type the two words.' : addslashes($instructions_visual);
|
| 42 |
+
$instructions_audio = (!$instructions_audio) ? 'Type what you hear.' : addslashes($instructions_audio);
|
| 43 |
+
$play_again = (!$play_again) ? 'Play Again?' : addslashes($play_again);
|
| 44 |
+
$cant_hear_this = (!$cant_hear_this) ? 'Can\'t hear the audio? Click here.' : addslashes($cant_hear_this);
|
| 45 |
+
$visual_challenge = (!$visual_challenge) ? 'Get a visual challenge' : addslashes($visual_challenge);
|
| 46 |
+
$audio_challenge = (!$audio_challenge) ? 'Get an audio challenge' : addslashes($audio_challenge);
|
| 47 |
+
$refresh_btn = (!$refresh_btn) ? 'Get a new challenge' : addslashes($refresh_btn);
|
| 48 |
+
$help_btn = (!$help_btn) ? 'Help' : addslashes($help_btn);
|
| 49 |
+
?>
|
| 50 |
+
|
| 51 |
+
|
| 52 |
+
<?php if( $theme == 'magento'): ?>
|
| 53 |
+
<script>
|
| 54 |
+
var RecaptchaOptions = {
|
| 55 |
+
theme : 'custom',
|
| 56 |
+
lang : '<?= $language ?>',
|
| 57 |
+
custom_theme_widget: 'recaptcha_widget'
|
| 58 |
+
};
|
| 59 |
+
</script>
|
| 60 |
+
<div id="recaptcha_widget" class="group-select wide fieldset" style="display:none">
|
| 61 |
+
<h2 class="legend" style="background-image: none;">Recaptcha</h2>
|
| 62 |
+
<div style="margin-bottom: 10px; margin-top: 5px;"><?php echo $textbox; ?></div>
|
| 63 |
+
<div class="col2-set">
|
| 64 |
+
<div class="col-1" style="width: 310px; margin-right: 10px; background: transparent; border: 0px none;">
|
| 65 |
+
<div id="recaptcha_image" style="border: 1px solid #CCCCCC; margin-bottom: 10px;"></div>
|
| 66 |
+
<div style="text-align: left;">
|
| 67 |
+
<span class="recaptcha_only_if_image"><?php echo $instructions_visual; ?></span>
|
| 68 |
+
<span class="recaptcha_only_if_audio"><?php echo $instructions_audio; ?></span>
|
| 69 |
+
<input type="text" id="recaptcha_response_field" name="recaptcha_response_field" class="input-text required-entry" />
|
| 70 |
+
</div>
|
| 71 |
+
</div>
|
| 72 |
+
<div class="col-2" style="float: left; width: 25px; background: transparent; border: 0px none;">
|
| 73 |
+
<div><a href="javascript:Recaptcha.reload()"><img src="<?php echo $this->getSkinUrl('images/fontis/refresh.png');?>" title="<?php echo $refresh_btn;?>" alt="<?php echo $refresh_btn;?>"/></a></div>
|
| 74 |
+
<div class="recaptcha_only_if_image"><a href="javascript:Recaptcha.switch_type('audio')"><img src="<?php echo $this->getSkinUrl('images/fontis/sound.png');?>" title="<?php echo $audio_challenge;?>" alt="<?php echo $audio_challenge;?>"/></a></div>
|
| 75 |
+
<div class="recaptcha_only_if_audio"><a href="javascript:Recaptcha.switch_type('image')"><img src="<?php echo $this->getSkinUrl('images/fontis/text.png');?>" title="<?php echo $visual_challenge;?>" alt="<?php echo $visual_challenge;?>"/></a></div>
|
| 76 |
+
<div><a href="javascript:Recaptcha.showhelp()"><img src="<?php echo $this->getSkinUrl('images/fontis/help.png');?>" title="<?php echo $help_btn;?>" alt="<?php echo $help_btn;?>"/></a></div>
|
| 77 |
+
</div>
|
| 78 |
+
</div>
|
| 79 |
+
<?php echo Mage::helper("fontis_recaptcha")->recaptcha_get_html($publickey, null, Mage::app()->getRequest()->isSecure()); ?>
|
| 80 |
+
</div>
|
| 81 |
+
|
| 82 |
+
<?php elseif( $theme == 'custom' ): ?>
|
| 83 |
+
|
| 84 |
+
<!-- Replace this with your custom code here. -->
|
| 85 |
+
<p>To create your custom recaptcha theme copy default/templates/fontis/recaptcha.phtml to your_theme/templates/fontis/recaptcha.phtml and replace this text with custom theme code.</p>
|
| 86 |
+
|
| 87 |
+
<?php else: ?>
|
| 88 |
+
<script type="text/javascript">
|
| 89 |
+
var RecaptchaOptions = {
|
| 90 |
+
lang : '<?php echo $language ?>',
|
| 91 |
+
theme : '<?php echo $theme ?>',
|
| 92 |
+
<?php if ($use_custom_translation): ?>
|
| 93 |
+
custom_translations : {
|
| 94 |
+
instructions_visual : '<?php echo addslashes($instructions_visual) ?>',
|
| 95 |
+
instructions_audio : '<?php echo addslashes($instructions_audio) ?>',
|
| 96 |
+
play_again : '<?php echo addslashes($play_again) ?>',
|
| 97 |
+
cant_hear_this : '<?php echo addslashes($cant_hear_this) ?>',
|
| 98 |
+
visual_challenge : '<?php echo addslashes($visual_challenge) ?>',
|
| 99 |
+
audio_challenge : '<?php echo addslashes($audio_challenge) ?>',
|
| 100 |
+
refresh_btn : '<?php echo addslashes($refresh_btn) ?>',
|
| 101 |
+
help_btn : '<?php echo addslashes($help_btn) ?>'
|
| 102 |
+
}
|
| 103 |
+
<?php endif; ?>
|
| 104 |
+
};
|
| 105 |
+
</script>
|
| 106 |
+
|
| 107 |
+
<div style="margin-bottom: 10px;"><?php echo $textbox; ?></div>
|
| 108 |
+
<?php
|
| 109 |
+
echo Mage::helper("fontis_recaptcha")->recaptcha_get_html($publickey, null, Mage::app()->getRequest()->isSecure());
|
| 110 |
+
?>
|
| 111 |
+
|
| 112 |
+
<?php endif; ?>
|
app/design/frontend/base/default/template/fontis/recaptcha/register.phtml
ADDED
|
@@ -0,0 +1,185 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Fontis Recaptcha Extension
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 11 |
+
* If you did not receive a copy of the license and are unable to
|
| 12 |
+
* obtain it through the world-wide-web, please send an email
|
| 13 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 14 |
+
*
|
| 15 |
+
* @category Fontis
|
| 16 |
+
* @package Fontis_Recaptcha
|
| 17 |
+
* @author Denis Margetic
|
| 18 |
+
* @author Chris Norton
|
| 19 |
+
* @copyright Copyright (c) 2009 Fontis Pty. Ltd. (http://www.fontis.com.au)
|
| 20 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 21 |
+
*/
|
| 22 |
+
|
| 23 |
+
?>
|
| 24 |
+
<?php
|
| 25 |
+
/**
|
| 26 |
+
* Create account form template
|
| 27 |
+
*
|
| 28 |
+
* @see Mage_Customer_Block_Form_Register
|
| 29 |
+
*/
|
| 30 |
+
?>
|
| 31 |
+
<div class="account-create">
|
| 32 |
+
<div class="page-title">
|
| 33 |
+
<h1><?php echo $this->__('Create an Account') ?></h1>
|
| 34 |
+
</div>
|
| 35 |
+
<?php echo $this->getChildHtml('form_fields_before')?>
|
| 36 |
+
<?php echo $this->getMessagesBlock()->getGroupedHtml() ?>
|
| 37 |
+
<form action="<?php echo $this->getPostActionUrl() ?>" method="post" id="form-validate">
|
| 38 |
+
<div class="fieldset">
|
| 39 |
+
<input type="hidden" name="success_url" value="<?php echo $this->getSuccessUrl() ?>" />
|
| 40 |
+
<input type="hidden" name="error_url" value="<?php echo $this->getErrorUrl() ?>" />
|
| 41 |
+
<h2 class="legend"><?php echo $this->__('Personal Information') ?></h2>
|
| 42 |
+
<ul class="form-list">
|
| 43 |
+
<li class="fields">
|
| 44 |
+
<?php echo $this->getLayout()->createBlock('customer/widget_name')->setObject($this->getFormData())->toHtml() ?>
|
| 45 |
+
</li>
|
| 46 |
+
<li>
|
| 47 |
+
<label for="email_address" class="required"><em>*</em><?php echo $this->__('Email Address') ?></label>
|
| 48 |
+
<div class="input-box">
|
| 49 |
+
<input type="text" name="email" id="email_address" value="<?php echo $this->htmlEscape($this->getFormData()->getEmail()) ?>" title="<?php echo $this->__('Email Address') ?>" class="input-text validate-email required-entry" />
|
| 50 |
+
</div>
|
| 51 |
+
</li>
|
| 52 |
+
<?php if ($this->isNewsletterEnabled()): ?>
|
| 53 |
+
<li class="control">
|
| 54 |
+
<div class="input-box">
|
| 55 |
+
<input type="checkbox" name="is_subscribed" title="<?php echo $this->__('Sign Up for Newsletter') ?>" value="1" id="is_subscribed"<?php if($this->getFormData()->getIsSubscribed()): ?> checked="checked"<?php endif; ?> class="checkbox" />
|
| 56 |
+
</div>
|
| 57 |
+
<label for="is_subscribed"><?php echo $this->__('Sign Up for Newsletter') ?></label>
|
| 58 |
+
</li>
|
| 59 |
+
<?php endif ?>
|
| 60 |
+
<?php $_dob = $this->getLayout()->createBlock('customer/widget_dob') ?>
|
| 61 |
+
<?php if ($_dob->isEnabled()): ?>
|
| 62 |
+
<li><?php echo $_dob->setDate($this->getFormData()->getDob())->toHtml() ?></li>
|
| 63 |
+
<?php endif ?>
|
| 64 |
+
<?php $_taxvat = $this->getLayout()->createBlock('customer/widget_taxvat') ?>
|
| 65 |
+
<?php if ($_taxvat->isEnabled()): ?>
|
| 66 |
+
<li><?php echo $_taxvat->setTaxvat($this->getFormData()->getTaxvat())->toHtml() ?></li>
|
| 67 |
+
<?php endif ?>
|
| 68 |
+
<?php $_gender = $this->getLayout()->createBlock('customer/widget_gender') ?>
|
| 69 |
+
<?php if ($_gender->isEnabled()): ?>
|
| 70 |
+
<li><?php echo $_gender->setGender($this->getFormData()->getGender())->toHtml() ?></li>
|
| 71 |
+
<?php endif ?>
|
| 72 |
+
</ul>
|
| 73 |
+
</div>
|
| 74 |
+
<?php if($this->getShowAddressFields()): ?>
|
| 75 |
+
<div class="fieldset">
|
| 76 |
+
<input type="hidden" name="create_address" value="1" />
|
| 77 |
+
<h2 class="legend"><?php echo $this->__('Address Information') ?></h2>
|
| 78 |
+
<ul class="form-list">
|
| 79 |
+
<li class="fields">
|
| 80 |
+
<div class="field">
|
| 81 |
+
<label for="company"><?php echo $this->__('Company') ?></label>
|
| 82 |
+
<div class="input-box">
|
| 83 |
+
<input type="text" name="company" id="company" value="<?php echo $this->htmlEscape($this->getFormData()->getCompany()) ?>" title="<?php echo $this->__('Company') ?>" class="input-text" />
|
| 84 |
+
</div>
|
| 85 |
+
</div>
|
| 86 |
+
<div class="field">
|
| 87 |
+
<label for="telephone" class="required"><em>*</em><?php echo $this->__('Telephone') ?></label>
|
| 88 |
+
<div class="input-box">
|
| 89 |
+
<input type="text" name="telephone" id="telephone" value="<?php echo $this->htmlEscape($this->getFormData()->getTelephone()) ?>" title="<?php echo $this->__('Telephone') ?>" class="input-text required-entry" />
|
| 90 |
+
</div>
|
| 91 |
+
</div>
|
| 92 |
+
</li>
|
| 93 |
+
<li class="wide">
|
| 94 |
+
<label for="street_1" class="required"><em>*</em><?php echo $this->__('Street Address') ?></label>
|
| 95 |
+
<div class="input-box">
|
| 96 |
+
<input type="text" name="street[]" value="<?php echo $this->htmlEscape($this->getFormData()->getStreet(1)) ?>" title="<?php echo $this->__('Street Address') ?>" id="street_1" class="input-text required-entry" />
|
| 97 |
+
</div>
|
| 98 |
+
</li>
|
| 99 |
+
<?php for ($_i=2, $_n=$this->helper('customer/address')->getStreetLines(); $_i<=$_n; $_i++): ?>
|
| 100 |
+
<li class="wide">
|
| 101 |
+
<div class="input-box">
|
| 102 |
+
<input type="text" name="street[]" value="<?php echo $this->htmlEscape($this->getFormData()->getStreet($_i)) ?>" title="<?php echo $this->__('Street Address %s', $_i) ?>" id="street_<?php echo $_i?>" class="input-text" />
|
| 103 |
+
</div>
|
| 104 |
+
</li>
|
| 105 |
+
<?php endfor ?>
|
| 106 |
+
<li class="fields">
|
| 107 |
+
<div class="field">
|
| 108 |
+
<label for="city" class="required"><em>*</em><?php echo $this->__('City') ?></label>
|
| 109 |
+
<div class="input-box">
|
| 110 |
+
<input type="text" name="city" value="<?php echo $this->htmlEscape($this->getFormData()->getCity()) ?>" title="<?php echo $this->__('City') ?>" class="input-text required-entry" id="city" />
|
| 111 |
+
</div>
|
| 112 |
+
</div>
|
| 113 |
+
<div class="field">
|
| 114 |
+
<label for="region_id" class="required"><em>*</em><?php echo $this->__('State/Province') ?></label>
|
| 115 |
+
<div class="input-box">
|
| 116 |
+
<select id="region_id" name="region_id" title="<?php echo $this->__('State/Province') ?>" class="validate-select" style="display:none;">
|
| 117 |
+
<option value=""><?php echo $this->__('Please select region, state or province') ?></option>
|
| 118 |
+
</select>
|
| 119 |
+
<script type="text/javascript">
|
| 120 |
+
//<![CDATA[
|
| 121 |
+
$('region_id').setAttribute('defaultValue', "<?php echo $this->getFormData()->getRegionId() ?>");
|
| 122 |
+
//]]>
|
| 123 |
+
</script>
|
| 124 |
+
<input type="text" id="region" name="region" value="<?php echo $this->htmlEscape($this->getRegion()) ?>" title="<?php echo $this->__('State/Province') ?>" class="input-text" style="display:none;" />
|
| 125 |
+
</div>
|
| 126 |
+
</div>
|
| 127 |
+
</li>
|
| 128 |
+
<li class="fields">
|
| 129 |
+
<div class="field">
|
| 130 |
+
<label for="zip" class="required"><em>*</em><?php echo $this->__('Zip/Postal Code') ?></label>
|
| 131 |
+
<div class="input-box">
|
| 132 |
+
<input type="text" name="postcode" value="<?php echo $this->htmlEscape($this->getFormData()->getPostcode()) ?>" title="<?php echo $this->__('Zip/Postal Code') ?>" id="zip" class="input-text validate-zip-international required-entry" />
|
| 133 |
+
</div>
|
| 134 |
+
</div>
|
| 135 |
+
<div class="field">
|
| 136 |
+
<label for="country" class="required"><em>*</em><?php echo $this->__('Country') ?></label>
|
| 137 |
+
<div class="input-box">
|
| 138 |
+
<?php echo $this->getCountryHtmlSelect() ?>
|
| 139 |
+
</div>
|
| 140 |
+
</div>
|
| 141 |
+
</li>
|
| 142 |
+
</ul>
|
| 143 |
+
<input type="hidden" name="default_billing" value="1" />
|
| 144 |
+
<input type="hidden" name="default_shipping" value="1" />
|
| 145 |
+
</div>
|
| 146 |
+
<?php endif; ?>
|
| 147 |
+
<div class="fieldset">
|
| 148 |
+
<h2 class="legend"><?php echo $this->__('Login Information') ?></h2>
|
| 149 |
+
<ul class="form-list">
|
| 150 |
+
<li class="fields">
|
| 151 |
+
<div class="field">
|
| 152 |
+
<label for="password" class="required"><em>*</em><?php echo $this->__('Password') ?></label>
|
| 153 |
+
<div class="input-box">
|
| 154 |
+
<input type="password" name="password" id="password" title="<?php echo $this->__('Password') ?>" class="input-text required-entry validate-password" />
|
| 155 |
+
</div>
|
| 156 |
+
</div>
|
| 157 |
+
<div class="field">
|
| 158 |
+
<label for="confirmation" class="required"><em>*</em><?php echo $this->__('Confirm Password') ?></label>
|
| 159 |
+
<div class="input-box">
|
| 160 |
+
<input type="password" name="confirmation" title="<?php echo $this->__('Confirm Password') ?>" id="confirmation" class="input-text required-entry validate-cpassword" />
|
| 161 |
+
</div>
|
| 162 |
+
</div>
|
| 163 |
+
</li>
|
| 164 |
+
</ul>
|
| 165 |
+
</div>
|
| 166 |
+
|
| 167 |
+
<?php if (Mage::getStoreConfig("fontis_recaptcha/recaptcha/customer")): ?>
|
| 168 |
+
<?php echo $this->getChildHtml('recaptcha_box') ?>
|
| 169 |
+
<?php endif; ?>
|
| 170 |
+
|
| 171 |
+
<div class="buttons-set">
|
| 172 |
+
<p class="required"><?php echo $this->__('* Required Fields') ?></p>
|
| 173 |
+
<p class="back-link"><a href="<?php echo $this->escapeUrl($this->getBackUrl()) ?>" class="back-link"><small>« </small><?php echo $this->__('Back') ?></a></p>
|
| 174 |
+
<button type="submit" title="<?php echo $this->__('Submit') ?>" class="button"><span><span><?php echo $this->__('Submit') ?></span></span></button>
|
| 175 |
+
</div>
|
| 176 |
+
</form>
|
| 177 |
+
<script type="text/javascript">
|
| 178 |
+
//<![CDATA[
|
| 179 |
+
var dataForm = new VarienForm('form-validate', true);
|
| 180 |
+
<?php if($this->getShowAddressFields()): ?>
|
| 181 |
+
new RegionUpdater('country', 'region', 'region_id', <?php echo $this->helper('directory')->getRegionJson() ?>, undefined, 'zip');
|
| 182 |
+
<?php endif; ?>
|
| 183 |
+
//]]>
|
| 184 |
+
</script>
|
| 185 |
+
</div>
|
app/design/frontend/base/default/template/fontis/recaptcha/send.phtml
ADDED
|
@@ -0,0 +1,148 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Fontis Recaptcha Extension
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 11 |
+
* If you did not receive a copy of the license and are unable to
|
| 12 |
+
* obtain it through the world-wide-web, please send an email
|
| 13 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 14 |
+
*
|
| 15 |
+
* @category Fontis
|
| 16 |
+
* @package Fontis_Recaptcha
|
| 17 |
+
* @author Denis Margetic
|
| 18 |
+
* @author Chris Norton
|
| 19 |
+
* @copyright Copyright (c) 2009 Fontis Pty. Ltd. (http://www.fontis.com.au)
|
| 20 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 21 |
+
*/
|
| 22 |
+
|
| 23 |
+
/**
|
| 24 |
+
* Send to friend form
|
| 25 |
+
*
|
| 26 |
+
* @see Mage_Sendfriend_Block_Index
|
| 27 |
+
*/
|
| 28 |
+
?>
|
| 29 |
+
<script type="text/javascript">
|
| 30 |
+
//<![CDATA[
|
| 31 |
+
i=0;
|
| 32 |
+
var recipCount = 1;
|
| 33 |
+
var maxRecip = <?php echo $this->getMaxRecipients() ?>;
|
| 34 |
+
function remove_recipient(i){
|
| 35 |
+
$('recipients_name'+i).up(2).remove();
|
| 36 |
+
recipCount--;
|
| 37 |
+
if(recipCount<maxRecip && maxRecip != 0) {
|
| 38 |
+
$('add_recipient_button').show();
|
| 39 |
+
$('max_recipient_message').hide();
|
| 40 |
+
}
|
| 41 |
+
return false;
|
| 42 |
+
}
|
| 43 |
+
|
| 44 |
+
function add_recipient(){
|
| 45 |
+
ul = $('recipients_options');
|
| 46 |
+
var li_mail = Element.extend(document.createElement("LI"));
|
| 47 |
+
li_mail.addClassName('fields additional-row');
|
| 48 |
+
li_mail.innerHTML = '<p><a href="delete_email" title="<?php echo $this->__('Remove Email') ?>" onclick="remove_recipient('+i+'); return false" class="btn-remove"><?php echo $this->__('Remove Email') ?>"<\/a><\/p>'
|
| 49 |
+
li_mail.innerHTML += '<div class="field"><label for="recipients_name'+i+'" class="required"><em>*<\/em><?php echo $this->__('Name:') ?><\/label><div class="input-box"><input name="recipients[name][]" type="text" class="input-text required-entry" id="recipients_name'+i+'" /><\/div>';
|
| 50 |
+
li_mail.innerHTML += '<div class="field"><label for="recipients_email'+i+'" class="required"><em>*<\/em><?php echo $this->__('Email Address:') ?><\/label><div class="input-box"><input name="recipients[email][]" value="" title="<?php echo $this->__('Email Address') ?>" id="recipients_email'+i+'" type="text" class="input-text required-entry validate-email" /><\/div><\/div>';
|
| 51 |
+
i++;
|
| 52 |
+
recipCount++;
|
| 53 |
+
if(recipCount>=maxRecip && maxRecip != 0) {
|
| 54 |
+
$('add_recipient_button').hide();
|
| 55 |
+
$('max_recipient_message').show();
|
| 56 |
+
}
|
| 57 |
+
|
| 58 |
+
ul.appendChild(li_mail);
|
| 59 |
+
}
|
| 60 |
+
//]]>
|
| 61 |
+
</script>
|
| 62 |
+
|
| 63 |
+
<div class="send-friend">
|
| 64 |
+
<?php echo $this->getMessagesBlock()->getGroupedHtml() ?>
|
| 65 |
+
<div class="page-title">
|
| 66 |
+
<h1><?php echo $this->__('Email to a Friend') ?></h1>
|
| 67 |
+
</div>
|
| 68 |
+
<form action="<?php echo $this->getSendUrl() ?>" method="post" id="product_sendtofriend_form">
|
| 69 |
+
<div class="fieldset">
|
| 70 |
+
<?php echo $this->getBlockHtml('formkey')?>
|
| 71 |
+
<h2 class="legend"><?php echo $this->__('Sender:') ?></h2>
|
| 72 |
+
<ul class="form-list" id="sender_options">
|
| 73 |
+
<li class="fields">
|
| 74 |
+
<div class="field">
|
| 75 |
+
<label for="sender_name" class="required"><em>*</em><?php echo $this->__('Name:') ?></label>
|
| 76 |
+
<div class="input-box">
|
| 77 |
+
<input name="sender[name]" value="<?php echo $this->htmlEscape($this->getUserName()) ?>" title="<?php echo $this->__('Name') ?>" id="sender_name" type="text" class="input-text required-entry" />
|
| 78 |
+
</div>
|
| 79 |
+
</div>
|
| 80 |
+
<div class="field">
|
| 81 |
+
<label for="sender_email" class="required"><em>*</em><?php echo $this->__('Email:') ?></label>
|
| 82 |
+
<div class="input-box">
|
| 83 |
+
<input name="sender[email]" value="<?php echo $this->htmlEscape($this->getEmail()) ?>" title="<?php echo $this->__('Email Address') ?>" id="sender_email" type="text" class="input-text required-entry validate-email" />
|
| 84 |
+
</div>
|
| 85 |
+
</div>
|
| 86 |
+
</li>
|
| 87 |
+
<li class="wide">
|
| 88 |
+
<label for="sender_message" class="required"><em>*</em><?php echo $this->__('Message:') ?></label>
|
| 89 |
+
<div class="input-box">
|
| 90 |
+
<textarea name="sender[message]" class="input-text required-entry" id="sender_message" cols="3" rows="3"><?php echo $this->htmlEscape($this->getMessage())?></textarea>
|
| 91 |
+
</div>
|
| 92 |
+
</li>
|
| 93 |
+
</ul>
|
| 94 |
+
</div>
|
| 95 |
+
<div class="fieldset">
|
| 96 |
+
<h2 class="legend"><?php echo $this->__('Recipient:') ?></h2>
|
| 97 |
+
<ul class="form-list" id="recipients_options">
|
| 98 |
+
<li class="fields">
|
| 99 |
+
<div class="field">
|
| 100 |
+
<label for="recipients_name" class="required"><em>*</em><?php echo $this->__('Name:') ?></label>
|
| 101 |
+
<div class="input-box">
|
| 102 |
+
<input name="recipients[name][]" type="text" class="input-text required-entry" id="recipients_name" />
|
| 103 |
+
</div>
|
| 104 |
+
</div>
|
| 105 |
+
<div class="field">
|
| 106 |
+
<label for="recipients_email" class="required"><em>*</em><?php echo $this->__('Email Address:') ?></label>
|
| 107 |
+
<div class="input-box">
|
| 108 |
+
<input name="recipients[email][]" value="" title="<?php echo $this->__('Email Address') ?>" id="recipients_email" type="text" class="input-text required-entry validate-email" />
|
| 109 |
+
</div>
|
| 110 |
+
</div>
|
| 111 |
+
</li>
|
| 112 |
+
</ul>
|
| 113 |
+
</div>
|
| 114 |
+
|
| 115 |
+
<?php // recaptcha
|
| 116 |
+
if( !(Mage::getStoreConfig("fontis_recaptcha/recaptcha/when_loggedin") && (Mage::getSingleton('customer/session')->isLoggedIn())) )
|
| 117 |
+
{
|
| 118 |
+
if (Mage::getStoreConfig("fontis_recaptcha/recaptcha/sendfriend"))
|
| 119 |
+
echo $this->getChildHtml('recaptcha_box');
|
| 120 |
+
}
|
| 121 |
+
?>
|
| 122 |
+
|
| 123 |
+
<div class="buttons-set">
|
| 124 |
+
<p class="back-link"><a href="#" onclick="history.back(); return false;"><small>« </small><?php echo $this->__('Back') ?></a></p>
|
| 125 |
+
<button type="submit" class="button<?php if (!$this->canSend()):?> disabled<?php endif ?>"<?php if (!$this->canSend()):?> disabled="disabled"<?php endif ?>><span><span><?php echo $this->__('Send Email') ?></span></span></button>
|
| 126 |
+
<div id="max_recipient_message" style="display:none;">
|
| 127 |
+
<?php if ($this->getMaxRecipients()): ?>
|
| 128 |
+
<p class="limit"><?php echo $this->__('Maximum %d email addresses allowed.', $this->getMaxRecipients()) ?></p>
|
| 129 |
+
<?php endif; ?>
|
| 130 |
+
</div>
|
| 131 |
+
<?php if (1 < $this->getMaxRecipients()): ?>
|
| 132 |
+
<p id="add_recipient_button">
|
| 133 |
+
<button type="button" onclick="add_recipient();" class="button"><span><span><?php echo $this->__('Add Recipient') ?></span></span></button>
|
| 134 |
+
</p>
|
| 135 |
+
<?php endif; ?>
|
| 136 |
+
</div>
|
| 137 |
+
</form>
|
| 138 |
+
<script type="text/javascript">
|
| 139 |
+
//<![CDATA[
|
| 140 |
+
var productSendtofriendForm = new VarienForm('product_sendtofriend_form');
|
| 141 |
+
productSendtofriendForm.submit = function() {
|
| 142 |
+
if(this.validator.validate()) {
|
| 143 |
+
this.form.submit();
|
| 144 |
+
}
|
| 145 |
+
}.bind(productSendtofriendForm);
|
| 146 |
+
//]]>
|
| 147 |
+
</script>
|
| 148 |
+
</div>
|
app/design/frontend/default/default/layout/fontis_recaptcha.xml
ADDED
|
@@ -0,0 +1,59 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<!--
|
| 3 |
+
/**
|
| 4 |
+
* Fontis Recaptcha Extension
|
| 5 |
+
*
|
| 6 |
+
* NOTICE OF LICENSE
|
| 7 |
+
*
|
| 8 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 9 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 10 |
+
* It is also available through the world-wide-web at this URL:
|
| 11 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 12 |
+
* If you did not receive a copy of the license and are unable to
|
| 13 |
+
* obtain it through the world-wide-web, please send an email
|
| 14 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 15 |
+
*
|
| 16 |
+
* @category Fontis
|
| 17 |
+
* @package Fontis_Recaptcha
|
| 18 |
+
* @author Denis Margetic
|
| 19 |
+
* @author Chris Norton
|
| 20 |
+
* @copyright Copyright (c) 2011 Fontis Pty. Ltd. (http://www.fontis.com.au)
|
| 21 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 22 |
+
*/
|
| 23 |
+
-->
|
| 24 |
+
<layout version="0.1.0">
|
| 25 |
+
<sendfriend_product_send>
|
| 26 |
+
<remove name="sendfriend.send"/>
|
| 27 |
+
|
| 28 |
+
<reference name="content">
|
| 29 |
+
<block type="sendfriend/send" name="recaptcha_sendfriend_send" template="fontis/recaptcha/send.phtml">
|
| 30 |
+
<block type="core/template" name="recaptcha.box" as="recaptcha_box" template="fontis/recaptcha/recaptcha.phtml"/>
|
| 31 |
+
</block>
|
| 32 |
+
</reference>
|
| 33 |
+
</sendfriend_product_send>
|
| 34 |
+
|
| 35 |
+
<contacts_contacts_index>
|
| 36 |
+
<update handle="contacts_index_index" />
|
| 37 |
+
|
| 38 |
+
<reference name="contactForm">
|
| 39 |
+
<action method="setTemplate"><template>fontis/recaptcha/contacts.phtml</template></action>
|
| 40 |
+
<block type="core/template" name="recaptcha.box" as="recaptcha_box" template="fontis/recaptcha/recaptcha.phtml"/>
|
| 41 |
+
</reference>
|
| 42 |
+
</contacts_contacts_index>
|
| 43 |
+
|
| 44 |
+
<customer_account_create>
|
| 45 |
+
<remove name="customer_form_register"/>
|
| 46 |
+
|
| 47 |
+
<reference name="content">
|
| 48 |
+
<block type="customer/form_register" name="recaptcha_form_register" template="fontis/recaptcha/register.phtml">
|
| 49 |
+
<block type="core/template" name="recaptcha.box" as="recaptcha_box" template="fontis/recaptcha/recaptcha.phtml"/>
|
| 50 |
+
</block>
|
| 51 |
+
</reference>
|
| 52 |
+
</customer_account_create>
|
| 53 |
+
|
| 54 |
+
<review_product_list>
|
| 55 |
+
<block name="product.review.form" >
|
| 56 |
+
<block type="core/template" name="recaptcha.box" as="recaptcha_box" template="fontis/recaptcha/recaptcha.phtml"/>
|
| 57 |
+
</block>
|
| 58 |
+
</review_product_list>
|
| 59 |
+
</layout>
|
app/design/frontend/default/default/template/fontis/recaptcha/contacts.phtml
ADDED
|
@@ -0,0 +1,74 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Fontis Recaptcha Extension
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 11 |
+
* If you did not receive a copy of the license and are unable to
|
| 12 |
+
* obtain it through the world-wide-web, please send an email
|
| 13 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 14 |
+
*
|
| 15 |
+
* @category Fontis
|
| 16 |
+
* @package Fontis_Recaptcha
|
| 17 |
+
* @author Denis Margetic
|
| 18 |
+
* @author Chris Norton
|
| 19 |
+
* @copyright Copyright (c) 2011 Fontis Pty. Ltd. (http://www.fontis.com.au)
|
| 20 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 21 |
+
*/
|
| 22 |
+
?>
|
| 23 |
+
<div id="messages_product_view"><?php echo $this->getMessagesBlock()->getGroupedHtml() ?></div>
|
| 24 |
+
<div class="page-head">
|
| 25 |
+
<h3><?php echo Mage::helper('contacts')->__('Contact Us') ?></h3>
|
| 26 |
+
</div>
|
| 27 |
+
<form action="<?php echo $this->getFormAction(); ?>" id="contactForm" method="post">
|
| 28 |
+
<fieldset class="group-select">
|
| 29 |
+
<h4 class="legend"><?php echo Mage::helper('contacts')->__('Contact Information') ?></h4>
|
| 30 |
+
<ul>
|
| 31 |
+
<li>
|
| 32 |
+
<div class="input-box">
|
| 33 |
+
<label for="name"><?php echo Mage::helper('contacts')->__('Name') ?> <span class="required">*</span></label><br />
|
| 34 |
+
<input name="name" id="name" title="<?php echo Mage::helper('contacts')->__('Name') ?>" value="<?php echo $this->htmlEscape($this->helper('contacts')->getUserName()) ?>" class="required-entry input-text" type="text" />
|
| 35 |
+
</div>
|
| 36 |
+
|
| 37 |
+
<div class="input-box">
|
| 38 |
+
<label for="email"><?php echo Mage::helper('contacts')->__('Email') ?> <span class="required">*</span></label><br />
|
| 39 |
+
<input name="email" id="email" title="<?php echo Mage::helper('contacts')->__('Email') ?>" value="<?php echo $this->htmlEscape($this->helper('contacts')->getUserEmail()) ?>" class="required-entry input-text validate-email" type="text" />
|
| 40 |
+
</div>
|
| 41 |
+
|
| 42 |
+
<div class="clear"></div>
|
| 43 |
+
|
| 44 |
+
<div class="input-box">
|
| 45 |
+
<label for="telephone"><?php echo Mage::helper('contacts')->__('Telephone') ?></label><br />
|
| 46 |
+
<input name="telephone" id="telephone" title="<?php echo Mage::helper('contacts')->__('Telephone') ?>" value="" class="input-text" type="text" />
|
| 47 |
+
</div>
|
| 48 |
+
|
| 49 |
+
<div class="clear"></div>
|
| 50 |
+
|
| 51 |
+
<div class="input-box">
|
| 52 |
+
<label for="comment"><?php echo Mage::helper('contacts')->__('Comment') ?></label><br />
|
| 53 |
+
<textarea name="comment" id="comment" title="<?php echo Mage::helper('contacts')->__('Comment') ?>" class="required-entry input-text" style="height:150px;width:525px;" cols="50" rows="5"></textarea>
|
| 54 |
+
</div>
|
| 55 |
+
</li>
|
| 56 |
+
</ul>
|
| 57 |
+
</fieldset>
|
| 58 |
+
|
| 59 |
+
<?php // recaptcha
|
| 60 |
+
if( !(Mage::getStoreConfig("fontis_recaptcha/recaptcha/when_loggedin") && (Mage::getSingleton('customer/session')->isLoggedIn())) )
|
| 61 |
+
{
|
| 62 |
+
if (Mage::getStoreConfig("fontis_recaptcha/recaptcha/contacts"))
|
| 63 |
+
echo $this->getChildHtml('recaptcha_box');
|
| 64 |
+
}
|
| 65 |
+
?>
|
| 66 |
+
|
| 67 |
+
<div class="button-set">
|
| 68 |
+
<p class="required"><?php echo Mage::helper('contacts')->__('* Required Fields') ?></p>
|
| 69 |
+
<button class="form-button" type="submit"><span><?php echo Mage::helper('contacts')->__('Submit') ?></span></button>
|
| 70 |
+
</div>
|
| 71 |
+
</form>
|
| 72 |
+
<script type="text/javascript">
|
| 73 |
+
var contactForm = new VarienForm('contactForm', true);
|
| 74 |
+
</script>
|
app/design/frontend/default/default/template/fontis/recaptcha/form.phtml
ADDED
|
@@ -0,0 +1,127 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Fontis Recaptcha Extension
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 11 |
+
* If you did not receive a copy of the license and are unable to
|
| 12 |
+
* obtain it through the world-wide-web, please send an email
|
| 13 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 14 |
+
*
|
| 15 |
+
* @category Fontis
|
| 16 |
+
* @package Fontis_Recaptcha
|
| 17 |
+
* @author Denis Margetic
|
| 18 |
+
* @author Chris Norton
|
| 19 |
+
* @copyright Copyright (c) 2011 Fontis Pty. Ltd. (http://www.fontis.com.au)
|
| 20 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 21 |
+
*/
|
| 22 |
+
?>
|
| 23 |
+
<div class="page-head">
|
| 24 |
+
<h3><?php echo $this->__('Write Your Own Review') ?></h3>
|
| 25 |
+
</div>
|
| 26 |
+
<h4><?php echo $this->__("You're reviewing: %s", $this->htmlEscape($this->getProductInfo()->getName())) ?></h4>
|
| 27 |
+
<form action="<?php echo $this->getAction() ?>" method="post" id="review-form">
|
| 28 |
+
<fieldset>
|
| 29 |
+
<?php if( $this->getRatings() && $this->getRatings()->getSize()): ?>
|
| 30 |
+
<div class="product-review-box">
|
| 31 |
+
<strong><?php echo $this->__('How do you rate this product?') ?><span class="required">*</span></strong><br />
|
| 32 |
+
<span id="input-message-box"></span>
|
| 33 |
+
<table class="data-table" id="product-review-table" cellspacing="0">
|
| 34 |
+
<thead>
|
| 35 |
+
<tr>
|
| 36 |
+
<th> </th>
|
| 37 |
+
<th><?php echo $this->__('1 star') ?></th>
|
| 38 |
+
<th><?php echo $this->__('2 stars') ?></th>
|
| 39 |
+
<th><?php echo $this->__('3 stars') ?></th>
|
| 40 |
+
<th><?php echo $this->__('4 stars') ?></th>
|
| 41 |
+
<th><?php echo $this->__('5 stars') ?></th>
|
| 42 |
+
</tr>
|
| 43 |
+
</thead>
|
| 44 |
+
<tbody>
|
| 45 |
+
<?php $_oddIterator = 1; ?>
|
| 46 |
+
<?php foreach ($this->getRatings() as $_rating): ?>
|
| 47 |
+
<tr class="odd<?php if($_oddIterator == $this->getRatings()->getSize()): $_oddIterator = 0; ?> last<?php endif; ?>">
|
| 48 |
+
<td class="label"><?php echo $_rating->getRatingCode() ?></td>
|
| 49 |
+
<?php $_iterator = 1; ?>
|
| 50 |
+
<?php foreach ($_rating->getOptions() as $_option): ?>
|
| 51 |
+
<!--<td <?php if($_iterator == 5): ?>class="last"<?php endif; ?> style="width:60px;"><input type="radio" <?php if($_iterator == 5): $_iterator=0; ?>class="validate-one-required-by-name"<?php endif; ?> name="ratings[<?php echo $_rating->getId() ?>]" id="<?php echo $_rating->getRatingCode() ?>_<?php echo $_option->getValue() ?>" value="<?php echo $_option->getId() ?>"/></td>-->
|
| 52 |
+
<td<?php if($_iterator == 5): ?> class="last"<?php endif; ?> style="width:60px;"><input type="radio" name="ratings[<?php echo $_rating->getId() ?>]" id="<?php echo $_rating->getRatingCode() ?>_<?php echo $_option->getValue() ?>" value="<?php echo $_option->getId() ?>" /></td>
|
| 53 |
+
<?php $_iterator++ ?>
|
| 54 |
+
<?php endforeach; ?>
|
| 55 |
+
</tr>
|
| 56 |
+
<?php $_oddIterator ++; ?>
|
| 57 |
+
<?php endforeach; ?>
|
| 58 |
+
</tbody>
|
| 59 |
+
</table>
|
| 60 |
+
<input type="hidden" name="validate_rating" class="validate-rating" value="" />
|
| 61 |
+
<script type="text/javascript">decorateTable('product-review-table')</script>
|
| 62 |
+
</div>
|
| 63 |
+
<?php endif; ?>
|
| 64 |
+
<?php // do not remove div - some problem whith validator in IE ?>
|
| 65 |
+
<div>
|
| 66 |
+
<label for="nickname_field"><?php echo $this->__('Nickname') ?><span class="required">*</span></label><br />
|
| 67 |
+
<input class="input-text required-entry" name="nickname" id="nickname_field" style="width: 450px;" type="text" value="<?php echo $this->htmlEscape($data->getNickname()) ?>" />
|
| 68 |
+
</div>
|
| 69 |
+
|
| 70 |
+
<div>
|
| 71 |
+
<label for="summary_field"><?php echo $this->__('Summary of Your Review') ?><span class="required">*</span></label><br />
|
| 72 |
+
<input name="title" class="input-text required-entry" id="summary_field" style="width: 450px;" type="text" value="<?php echo $this->htmlEscape($data->getTitle()) ?>" />
|
| 73 |
+
</div>
|
| 74 |
+
|
| 75 |
+
<div>
|
| 76 |
+
<label for="review_field"><?php echo $this->__('Review') ?><span class="required">*</span></label><br />
|
| 77 |
+
<textarea class="required-entry" name="detail" id="review_field" cols="53" rows="10" style="width: 450px;"><?php echo $this->htmlEscape($data->getDetail()) ?></textarea>
|
| 78 |
+
</div>
|
| 79 |
+
|
| 80 |
+
<?php // recaptcha
|
| 81 |
+
if( !(Mage::getStoreConfig("fontis_recaptcha/recaptcha/when_loggedin") && (Mage::getSingleton('customer/session')->isLoggedIn())) )
|
| 82 |
+
{
|
| 83 |
+
if (Mage::getStoreConfig("fontis_recaptcha/recaptcha/review"))
|
| 84 |
+
echo $this->getChildHtml('recaptcha_box');
|
| 85 |
+
}
|
| 86 |
+
?>
|
| 87 |
+
|
| 88 |
+
<div class="button-set">
|
| 89 |
+
<button class="form-button right" type="submit"><span><?php echo $this->__('Submit Review') ?></span></button>
|
| 90 |
+
</div>
|
| 91 |
+
</fieldset>
|
| 92 |
+
</form>
|
| 93 |
+
<script type="text/javascript">
|
| 94 |
+
//<![CDATA[
|
| 95 |
+
var dataForm = new VarienForm('review-form');
|
| 96 |
+
|
| 97 |
+
Validation.addAllThese(
|
| 98 |
+
[
|
| 99 |
+
['validate-rating', '<?php echo $this->__('Please select one of each of the ratings above') ?>', function(v) {
|
| 100 |
+
var trs = $('product-review-table').getElementsBySelector('tr');
|
| 101 |
+
var inputs;
|
| 102 |
+
var error = 1;
|
| 103 |
+
|
| 104 |
+
for( var j=0; j < trs.length; j++ ) {
|
| 105 |
+
var tr = trs[j];
|
| 106 |
+
if( j > 0 ) {
|
| 107 |
+
inputs = tr.getElementsBySelector('input');
|
| 108 |
+
|
| 109 |
+
for( i in inputs ) {
|
| 110 |
+
if( inputs[i].checked == true ) {
|
| 111 |
+
error = 0;
|
| 112 |
+
}
|
| 113 |
+
}
|
| 114 |
+
|
| 115 |
+
if( error == 1 ) {
|
| 116 |
+
return false;
|
| 117 |
+
} else {
|
| 118 |
+
error = 1;
|
| 119 |
+
}
|
| 120 |
+
}
|
| 121 |
+
}
|
| 122 |
+
return true;
|
| 123 |
+
}]
|
| 124 |
+
]
|
| 125 |
+
);
|
| 126 |
+
//]]>
|
| 127 |
+
</script>
|
app/design/frontend/default/default/template/fontis/recaptcha/recaptcha.phtml
ADDED
|
@@ -0,0 +1,112 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Fontis Recaptcha Extension
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 11 |
+
* If you did not receive a copy of the license and are unable to
|
| 12 |
+
* obtain it through the world-wide-web, please send an email
|
| 13 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 14 |
+
*
|
| 15 |
+
* @category Fontis
|
| 16 |
+
* @package Fontis_Recaptcha
|
| 17 |
+
* @author Denis Margetic
|
| 18 |
+
* @author Chris Norton
|
| 19 |
+
* @copyright Copyright (c) 2009 Fontis Pty. Ltd. (http://www.fontis.com.au)
|
| 20 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 21 |
+
*/
|
| 22 |
+
?>
|
| 23 |
+
<?php
|
| 24 |
+
$theme = Mage::getStoreConfig("fontis_recaptcha/setup/theme");
|
| 25 |
+
$language = Mage::getStoreConfig("fontis_recaptcha/setup/language");
|
| 26 |
+
$publickey = Mage::getStoreConfig("fontis_recaptcha/setup/public_key");
|
| 27 |
+
$textbox = Mage::getStoreConfig("fontis_recaptcha/setup/textbox");
|
| 28 |
+
|
| 29 |
+
// translations
|
| 30 |
+
$use_custom_translation = Mage::getStoreConfig("fontis_recaptcha/translation/enable_translation");
|
| 31 |
+
$instructions_visual = Mage::getStoreConfig("fontis_recaptcha/translation/text_captcha");
|
| 32 |
+
$instructions_audio = Mage::getStoreConfig("fontis_recaptcha/translation/audio_captcha");
|
| 33 |
+
$play_again = Mage::getStoreConfig("fontis_recaptcha/translation/play_again");
|
| 34 |
+
$cant_hear_this = Mage::getStoreConfig("fontis_recaptcha/translation/cant_hear_this");
|
| 35 |
+
$visual_challenge = Mage::getStoreConfig("fontis_recaptcha/translation/visual_challenge");
|
| 36 |
+
$audio_challenge = Mage::getStoreConfig("fontis_recaptcha/translation/audio_challenge");
|
| 37 |
+
$refresh_btn = Mage::getStoreConfig("fontis_recaptcha/translation/refresh_btn");
|
| 38 |
+
$help_btn = Mage::getStoreConfig("fontis_recaptcha/translation/help_btn");
|
| 39 |
+
|
| 40 |
+
// set default for null values
|
| 41 |
+
$instructions_visual = (!$instructions_visual) ? 'Type the two words.' : addslashes($instructions_visual);
|
| 42 |
+
$instructions_audio = (!$instructions_audio) ? 'Type what you hear.' : addslashes($instructions_audio);
|
| 43 |
+
$play_again = (!$play_again) ? 'Play Again?' : addslashes($play_again);
|
| 44 |
+
$cant_hear_this = (!$cant_hear_this) ? 'Can\'t hear the audio? Click here.' : addslashes($cant_hear_this);
|
| 45 |
+
$visual_challenge = (!$visual_challenge) ? 'Get a visual challenge' : addslashes($visual_challenge);
|
| 46 |
+
$audio_challenge = (!$audio_challenge) ? 'Get an audio challenge' : addslashes($audio_challenge);
|
| 47 |
+
$refresh_btn = (!$refresh_btn) ? 'Get a new challenge' : addslashes($refresh_btn);
|
| 48 |
+
$help_btn = (!$help_btn) ? 'Help' : addslashes($help_btn);
|
| 49 |
+
?>
|
| 50 |
+
|
| 51 |
+
|
| 52 |
+
<?php if( $theme == 'magento'): ?>
|
| 53 |
+
<script>
|
| 54 |
+
var RecaptchaOptions = {
|
| 55 |
+
theme : 'custom',
|
| 56 |
+
lang : '<?= $language ?>',
|
| 57 |
+
custom_theme_widget: 'recaptcha_widget'
|
| 58 |
+
};
|
| 59 |
+
</script>
|
| 60 |
+
<div id="recaptcha_widget" class="group-select wide fieldset" style="display:none">
|
| 61 |
+
<h2 class="legend" style="background-image: none;">Recaptcha</h2>
|
| 62 |
+
<div style="margin-bottom: 10px; margin-top: 5px;"><?php echo $textbox; ?></div>
|
| 63 |
+
<div class="col2-set">
|
| 64 |
+
<div class="col-1" style="width: 310px; margin-right: 10px; background: transparent; border: 0px none;">
|
| 65 |
+
<div id="recaptcha_image" style="border: 1px solid #CCCCCC; margin-bottom: 10px;"></div>
|
| 66 |
+
<div style="text-align: left;">
|
| 67 |
+
<span class="recaptcha_only_if_image"><?php echo $instructions_visual; ?></span>
|
| 68 |
+
<span class="recaptcha_only_if_audio"><?php echo $instructions_audio; ?></span>
|
| 69 |
+
<input type="text" id="recaptcha_response_field" name="recaptcha_response_field" class="input-text required-entry" />
|
| 70 |
+
</div>
|
| 71 |
+
</div>
|
| 72 |
+
<div class="col-2" style="float: left; width: 25px; background: transparent; border: 0px none;">
|
| 73 |
+
<div><a href="javascript:Recaptcha.reload()"><img src="<?php echo $this->getSkinUrl('images/fontis/refresh.png');?>" title="<?php echo $refresh_btn;?>" alt="<?php echo $refresh_btn;?>"/></a></div>
|
| 74 |
+
<div class="recaptcha_only_if_image"><a href="javascript:Recaptcha.switch_type('audio')"><img src="<?php echo $this->getSkinUrl('images/fontis/sound.png');?>" title="<?php echo $audio_challenge;?>" alt="<?php echo $audio_challenge;?>"/></a></div>
|
| 75 |
+
<div class="recaptcha_only_if_audio"><a href="javascript:Recaptcha.switch_type('image')"><img src="<?php echo $this->getSkinUrl('images/fontis/text.png');?>" title="<?php echo $visual_challenge;?>" alt="<?php echo $visual_challenge;?>"/></a></div>
|
| 76 |
+
<div><a href="javascript:Recaptcha.showhelp()"><img src="<?php echo $this->getSkinUrl('images/fontis/help.png');?>" title="<?php echo $help_btn;?>" alt="<?php echo $help_btn;?>"/></a></div>
|
| 77 |
+
</div>
|
| 78 |
+
</div>
|
| 79 |
+
<?php echo Mage::helper("fontis_recaptcha")->recaptcha_get_html($publickey, null, Mage::app()->getRequest()->isSecure()); ?>
|
| 80 |
+
</div>
|
| 81 |
+
|
| 82 |
+
<?php elseif( $theme == 'custom' ): ?>
|
| 83 |
+
|
| 84 |
+
<!-- Replace this with your custom code here. -->
|
| 85 |
+
<p>To create your custom recaptcha theme copy default/templates/fontis/recaptcha.phtml to your_theme/templates/fontis/recaptcha.phtml and replace this text with custom theme code.</p>
|
| 86 |
+
|
| 87 |
+
<?php else: ?>
|
| 88 |
+
<script type="text/javascript">
|
| 89 |
+
var RecaptchaOptions = {
|
| 90 |
+
lang : '<?php echo $language ?>',
|
| 91 |
+
theme : '<?php echo $theme ?>',
|
| 92 |
+
<?php if ($use_custom_translation): ?>
|
| 93 |
+
custom_translations : {
|
| 94 |
+
instructions_visual : '<?php echo addslashes($instructions_visual) ?>',
|
| 95 |
+
instructions_audio : '<?php echo addslashes($instructions_audio) ?>',
|
| 96 |
+
play_again : '<?php echo addslashes($play_again) ?>',
|
| 97 |
+
cant_hear_this : '<?php echo addslashes($cant_hear_this) ?>',
|
| 98 |
+
visual_challenge : '<?php echo addslashes($visual_challenge) ?>',
|
| 99 |
+
audio_challenge : '<?php echo addslashes($audio_challenge) ?>',
|
| 100 |
+
refresh_btn : '<?php echo addslashes($refresh_btn) ?>',
|
| 101 |
+
help_btn : '<?php echo addslashes($help_btn) ?>'
|
| 102 |
+
}
|
| 103 |
+
<?php endif; ?>
|
| 104 |
+
};
|
| 105 |
+
</script>
|
| 106 |
+
|
| 107 |
+
<div style="margin-bottom: 10px;"><?php echo $textbox; ?></div>
|
| 108 |
+
<?php
|
| 109 |
+
echo Mage::helper("fontis_recaptcha")->recaptcha_get_html($publickey, null, Mage::app()->getRequest()->isSecure());
|
| 110 |
+
?>
|
| 111 |
+
|
| 112 |
+
<?php endif; ?>
|
app/design/frontend/default/default/template/fontis/recaptcha/register.phtml
ADDED
|
@@ -0,0 +1,153 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Fontis Recaptcha Extension
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 11 |
+
* If you did not receive a copy of the license and are unable to
|
| 12 |
+
* obtain it through the world-wide-web, please send an email
|
| 13 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 14 |
+
*
|
| 15 |
+
* @category Fontis
|
| 16 |
+
* @package Fontis_Recaptcha
|
| 17 |
+
* @author Denis Margetic
|
| 18 |
+
* @author Chris Norton
|
| 19 |
+
* @copyright Copyright (c) 2011 Fontis Pty. Ltd. (http://www.fontis.com.au)
|
| 20 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 21 |
+
*/
|
| 22 |
+
?>
|
| 23 |
+
<?php
|
| 24 |
+
/**
|
| 25 |
+
* Create account form template
|
| 26 |
+
*
|
| 27 |
+
* @see Mage_Customer_Block_Form_Register
|
| 28 |
+
*/
|
| 29 |
+
?>
|
| 30 |
+
<div class="page-head">
|
| 31 |
+
<h3><?php echo $this->__('Create an Account') ?></h3>
|
| 32 |
+
</div>
|
| 33 |
+
<?php echo $this->getMessagesBlock()->getGroupedHtml() ?>
|
| 34 |
+
<form action="<?php echo $this->getPostActionUrl() ?>" method="post" id="form-validate">
|
| 35 |
+
<fieldset class="group-select wide">
|
| 36 |
+
<input type="hidden" name="success_url" value="<?php echo $this->getSuccessUrl() ?>" />
|
| 37 |
+
<input type="hidden" name="error_url" value="<?php echo $this->getErrorUrl() ?>" />
|
| 38 |
+
<h4 class="legend"><?php echo $this->__('Personal Information') ?></h4>
|
| 39 |
+
<ul>
|
| 40 |
+
<li>
|
| 41 |
+
<?php echo $this->getLayout()->createBlock('customer/widget_name')->setObject($this->getFormData())->toHtml() ?>
|
| 42 |
+
</li>
|
| 43 |
+
<li>
|
| 44 |
+
<div class="input-box">
|
| 45 |
+
<label for="email_address"><?php echo $this->__('Email Address') ?> <span class="required">*</span></label><br/>
|
| 46 |
+
<input type="text" name="email" id="email_address" value="<?php echo $this->htmlEscape($this->getFormData()->getEmail()) ?>" title="<?php echo $this->__('Email Address') ?>" class="validate-email required-entry input-text" />
|
| 47 |
+
</div>
|
| 48 |
+
</li>
|
| 49 |
+
<?php if ($this->isNewsletterEnabled()): ?>
|
| 50 |
+
<li>
|
| 51 |
+
<input type="checkbox" name="is_subscribed" title="<?php echo $this->__('Sign Up for Newsletter') ?>" value="1" id="is_subscribed" <?php if($this->getFormData()->getIsSubscribed()): ?> checked="checked"<?php endif ?> />
|
| 52 |
+
<label for="is_subscribed"><?php echo $this->__('Sign Up for Newsletter') ?></label>
|
| 53 |
+
</li>
|
| 54 |
+
<?php endif ?>
|
| 55 |
+
<?php $_dob = $this->getLayout()->createBlock('customer/widget_dob') ?>
|
| 56 |
+
<?php if ($_dob->isEnabled()): ?>
|
| 57 |
+
<li><?php echo $_dob->setDate($this->getFormData()->getDob())->toHtml() ?></li>
|
| 58 |
+
<?php endif ?>
|
| 59 |
+
<?php $_taxvat = $this->getLayout()->createBlock('customer/widget_taxvat') ?>
|
| 60 |
+
<?php if ($_taxvat->isEnabled()): ?>
|
| 61 |
+
<li><?php echo $_taxvat->setTaxvat($this->getFormData()->getTaxvat())->toHtml() ?></li>
|
| 62 |
+
<?php endif ?>
|
| 63 |
+
</ul>
|
| 64 |
+
</fieldset>
|
| 65 |
+
<?php if($this->getShowAddressFields()): ?>
|
| 66 |
+
<input type="hidden" name="create_address" value="1" />
|
| 67 |
+
<fieldset class="group-select wide">
|
| 68 |
+
<h4 class="legend"><?php echo $this->__('Address Information') ?></h4>
|
| 69 |
+
<ul>
|
| 70 |
+
<li>
|
| 71 |
+
<div class="input-box">
|
| 72 |
+
<label for="company"><?php echo $this->__('Company') ?></label><br />
|
| 73 |
+
<input type="text" name="company" id="company" value="<?php echo $this->htmlEscape($this->getFormData()->getCompany()) ?>" title="<?php echo $this->__('Company') ?>" class="input-text" />
|
| 74 |
+
</div>
|
| 75 |
+
<div class="input-box">
|
| 76 |
+
<label for="lastname"><?php echo $this->__('Telephone') ?> <span class="required">*</span></label><br />
|
| 77 |
+
<input type="text" name="telephone" id="telephone" value="<?php echo $this->htmlEscape($this->getFormData()->getTelephone()) ?>" title="<?php echo $this->__('Telephone') ?>" class="required-entry input-text" />
|
| 78 |
+
</div>
|
| 79 |
+
</li>
|
| 80 |
+
<li>
|
| 81 |
+
<label for="street_1"><?php echo $this->__('Street Address') ?> <span class="required">*</span></label><br />
|
| 82 |
+
<input type="text" name="street[]" value="<?php echo $this->htmlEscape($this->getFormData()->getStreet(1)) ?>" title="<?php echo $this->__('Street Address') ?>" id="street_1" class="required-entry input-text" />
|
| 83 |
+
</li>
|
| 84 |
+
<?php for ($_i=2, $_n=$this->helper('customer/address')->getStreetLines(); $_i<=$_n; $_i++): ?>
|
| 85 |
+
<li>
|
| 86 |
+
<input type="text" name="street[]" value="<?php echo $this->htmlEscape($this->getFormData()->getStreet($_i)) ?>" title="<?php echo $this->__('Street Address '.$_i) ?>" id="street_<?php echo $_i?>" class="input-text" />
|
| 87 |
+
<?php endfor ?>
|
| 88 |
+
</li>
|
| 89 |
+
<li>
|
| 90 |
+
<div class="input-box">
|
| 91 |
+
<label for="city"><?php echo $this->__('City') ?> <span class="required">*</span></label><br />
|
| 92 |
+
<input type="text" name="city" value="<?php echo $this->htmlEscape($this->getFormData()->getCity()) ?>" title="<?php echo $this->__('City') ?>" class="required-entry input-text" id="city" />
|
| 93 |
+
</div>
|
| 94 |
+
<div class="input-box">
|
| 95 |
+
<label for="region_id"><?php echo $this->__('State/Province') ?> <span class="required">*</span></label><br />
|
| 96 |
+
<select id="region_id" name="region_id" title="<?php echo $this->__('State/Province') ?>" class="validate-select" style="display:none">
|
| 97 |
+
<option value=""><?php echo $this->__('Please select region, state or province') ?></option>
|
| 98 |
+
</select>
|
| 99 |
+
<script type="text/javascript">
|
| 100 |
+
$('region_id').setAttribute('defaultValue', "<?php echo $this->getFormData()->getRegionId() ?>");
|
| 101 |
+
</script>
|
| 102 |
+
<input type="text" id="region" name="region" value="<?php echo $this->htmlEscape($this->getRegion()) ?>" title="<?php echo $this->__('State/Province') ?>" class="input-text" style="display:none" />
|
| 103 |
+
</div>
|
| 104 |
+
</li>
|
| 105 |
+
<li>
|
| 106 |
+
<div class="input-box">
|
| 107 |
+
<label for="zip"><?php echo $this->__('Zip/Postal Code') ?> <span class="required">*</span></label><br/>
|
| 108 |
+
<input type="text" name="postcode" value="<?php echo $this->htmlEscape($this->getFormData()->getPostcode()) ?>" title="<?php echo $this->__('Zip/Postal Code') ?>" id="zip" class="validate-zip-international required-entry input-text" />
|
| 109 |
+
</div>
|
| 110 |
+
<div class="input-box">
|
| 111 |
+
<label for="country"><?php echo $this->__('Country') ?> <span class="required">*</span></label><br/>
|
| 112 |
+
<?php echo $this->getCountryHtmlSelect() ?>
|
| 113 |
+
</div>
|
| 114 |
+
</li>
|
| 115 |
+
</ul>
|
| 116 |
+
</fieldset>
|
| 117 |
+
<input type="hidden" name="default_billing" value="1" />
|
| 118 |
+
<input type="hidden" name="default_shipping" value="1" />
|
| 119 |
+
<?php endif; ?>
|
| 120 |
+
<fieldset class="group-select wide">
|
| 121 |
+
<h4 class="legend"><?php echo $this->__('Login Information') ?></h4>
|
| 122 |
+
<ul>
|
| 123 |
+
<li>
|
| 124 |
+
<div class="input-box">
|
| 125 |
+
<label for="password"><?php echo $this->__('Password') ?> <span class="required">*</span></label><br/>
|
| 126 |
+
<input type="password" name="password" id="password" title="<?php echo $this->__('Password') ?>" class="required-entry validate-password input-text" />
|
| 127 |
+
</div>
|
| 128 |
+
<div class="input-box">
|
| 129 |
+
<label for="confirmation"><?php echo $this->__('Confirm Password') ?> <span class="required">*</span></label><br />
|
| 130 |
+
<input type="password" name="confirmation" title="<?php echo $this->__('Confirm Password') ?>" id="confirmation" class="required-entry validate-cpassword input-text" />
|
| 131 |
+
</div>
|
| 132 |
+
</li>
|
| 133 |
+
</ul>
|
| 134 |
+
</fieldset>
|
| 135 |
+
|
| 136 |
+
<?php if (Mage::getStoreConfig("fontis_recaptcha/recaptcha/customer")): ?>
|
| 137 |
+
<?php echo $this->getChildHtml('recaptcha_box') ?>
|
| 138 |
+
<?php endif; ?>
|
| 139 |
+
|
| 140 |
+
<div class="button-set">
|
| 141 |
+
<p class="required"><?php echo $this->__('* Required Fields') ?></p>
|
| 142 |
+
<a href="<?php echo $this->getBackUrl() ?>" class="left">« <?php echo $this->__('Back') ?></a>
|
| 143 |
+
<button class="form-button" type="submit"><span><?php echo $this->__('Submit') ?></span></button>
|
| 144 |
+
</div>
|
| 145 |
+
</form>
|
| 146 |
+
<script type="text/javascript">
|
| 147 |
+
//<![CDATA[
|
| 148 |
+
var dataForm = new VarienForm('form-validate', true);
|
| 149 |
+
<?php if($this->getShowAddressFields()): ?>
|
| 150 |
+
new RegionUpdater('country', 'region', 'region_id', <?php echo $this->helper('directory')->getRegionJson() ?>);
|
| 151 |
+
<?php endif; ?>
|
| 152 |
+
//]]>
|
| 153 |
+
</script>
|
app/design/frontend/default/default/template/fontis/recaptcha/send.phtml
ADDED
|
@@ -0,0 +1,142 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Fontis Recaptcha Extension
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 11 |
+
* If you did not receive a copy of the license and are unable to
|
| 12 |
+
* obtain it through the world-wide-web, please send an email
|
| 13 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 14 |
+
*
|
| 15 |
+
* @category Fontis
|
| 16 |
+
* @package Fontis_Recaptcha
|
| 17 |
+
* @author Denis Margetic
|
| 18 |
+
* @author Chris Norton
|
| 19 |
+
* @copyright Copyright (c) 2011 Fontis Pty. Ltd. (http://www.fontis.com.au)
|
| 20 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 21 |
+
*/
|
| 22 |
+
|
| 23 |
+
/**
|
| 24 |
+
* Send to friend form
|
| 25 |
+
*
|
| 26 |
+
* @see Mage_Sendfriend_Block_Index
|
| 27 |
+
*/
|
| 28 |
+
?>
|
| 29 |
+
<script type="text/javascript">
|
| 30 |
+
//<![CDATA[
|
| 31 |
+
i=0;
|
| 32 |
+
var recipCount = 1;
|
| 33 |
+
var maxRecip = <?php echo $this->getMaxRecipients() ?>;
|
| 34 |
+
function remove_recipient(i){
|
| 35 |
+
$('recipients_name'+i).up(2).remove();
|
| 36 |
+
recipCount--;
|
| 37 |
+
if(recipCount<maxRecip && maxRecip != 0) {
|
| 38 |
+
$('add_recipient_button').show();
|
| 39 |
+
$('max_recipient_message').hide();
|
| 40 |
+
}
|
| 41 |
+
return false;
|
| 42 |
+
}
|
| 43 |
+
|
| 44 |
+
function add_recipient(){
|
| 45 |
+
ul = $('recipients_options');
|
| 46 |
+
var li_mail = Element.extend(document.createElement("LI"));
|
| 47 |
+
li_mail.addClassName('addElement');
|
| 48 |
+
li_mail.innerHTML = '<div align="right"><a href="delete_email" onclick="remove_recipient('+i+');return false"><img src="<?php echo $this->getSkinUrl('images/list_remove_btn.gif') ?>" alt="<?php echo $this->__('Remove Email') ?>"/><\/a><\/div>'
|
| 49 |
+
li_mail.innerHTML += '<div class="left"><label for="recipients_name"><?php echo $this->__('Name:') ?> <span class="required">*<\/span><\/label><br /><div style="width:250px"><input name="recipients[name][]" type="text" class="input-text required-entry" id="recipients_name'+i+'" style="width:250px;" /><\/div><br /><br /><\/div>';
|
| 50 |
+
li_mail.innerHTML += '<div class="right"><label for="recipients_email"><?php echo $this->__('Email Address:') ?><span class="required">*<\/span><\/label><br /><div style="width:250px"><input name="recipients[email][]" value="" title="<?php echo $this->__('Email Address') ?>" id="recipients_email'+i+'" type="text" class="input-text required-entry validate-email" style="width:250px;" /><\/div><\/div>';
|
| 51 |
+
i++;
|
| 52 |
+
recipCount++;
|
| 53 |
+
if(recipCount>=maxRecip && maxRecip != 0) {
|
| 54 |
+
$('add_recipient_button').hide();
|
| 55 |
+
$('max_recipient_message').show();
|
| 56 |
+
}
|
| 57 |
+
|
| 58 |
+
ul.appendChild(li_mail);
|
| 59 |
+
}
|
| 60 |
+
//]]>
|
| 61 |
+
</script>
|
| 62 |
+
|
| 63 |
+
<?php echo $this->getMessagesBlock()->getGroupedHtml() ?>
|
| 64 |
+
<div class="page-head">
|
| 65 |
+
<h3><?php echo $this->__('Email to a Friend') ?></h3>
|
| 66 |
+
</div>
|
| 67 |
+
<form action="<?php echo $this->getUrl('*/*/sendmail', array('id'=>$this->getProductId(), 'cat_id'=>$this->getCategoryId())) ?>" method="post" id="product_sendtofriend_form">
|
| 68 |
+
<div class="col-1 login-box">
|
| 69 |
+
<div class="col-1 registered-users">
|
| 70 |
+
<div class="content ">
|
| 71 |
+
<div>
|
| 72 |
+
<h4><?php echo $this->__('Sender:') ?></h4>
|
| 73 |
+
<ul class="form-list" id="sender_options">
|
| 74 |
+
<li>
|
| 75 |
+
<div class="left">
|
| 76 |
+
<label for="sender_name"><?php echo $this->__('Name:') ?> <span class="required">*</span></label><br/>
|
| 77 |
+
<div style="width:250px"><input name="sender[name]" value="<?php echo $this->htmlEscape($this->getUserName()) ?>" title="<?php echo $this->__('Name') ?>" id="sender_name" type="text" class="input-text required-entry" style="width:250px;" /></div>
|
| 78 |
+
</div>
|
| 79 |
+
<div class="right">
|
| 80 |
+
<label for="sender_email"><?php echo $this->__('Email:') ?> <span class="required">*</span></label><br/>
|
| 81 |
+
<div style="width:250px"><input name="sender[email]" value="<?php echo $this->htmlEscape($this->getEmail()) ?>" title="<?php echo $this->__('Email Address') ?>" id="sender_email" type="text" class="input-text required-entry validate-email" style="width:250px;" /></div>
|
| 82 |
+
</div>
|
| 83 |
+
</li>
|
| 84 |
+
<li>
|
| 85 |
+
<label for="sender_message"><?php echo $this->__('Message:') ?> <span class="required">*</span></label><br/>
|
| 86 |
+
<textarea name="sender[message]" class="input-text required-entry" id="sender_message" cols="3" rows="3" style="width:100%;height:100px"><?php echo $this->htmlEscape($this->getFormData()->getData('sender/message'))?></textarea>
|
| 87 |
+
</li>
|
| 88 |
+
</ul>
|
| 89 |
+
</div>
|
| 90 |
+
<div>
|
| 91 |
+
<div>
|
| 92 |
+
<br />
|
| 93 |
+
<h4><?php echo $this->__('Recipient:') ?></h4>
|
| 94 |
+
<ul class="form-list" id="recipients_options">
|
| 95 |
+
<li>
|
| 96 |
+
<div class="left">
|
| 97 |
+
<label for="recipients_name"><?php echo $this->__('Name:') ?> <span class="required">*</span></label><br/>
|
| 98 |
+
<div style="width:250px"><input name="recipients[name][]" type="text" class="input-text required-entry" id="recipients_name" style="width:250px;" /></div><br /><br />
|
| 99 |
+
</div>
|
| 100 |
+
<div class="right">
|
| 101 |
+
<label for="recipients_email"><?php echo $this->__('Email Address:') ?> <span class="required">*</span></label><br/>
|
| 102 |
+
<div style="width:250px"><input name="recipients[email][]" value="" title="<?php echo $this->__('Email Address') ?>" id="recipients_email" type="text" class="input-text required-entry validate-email" style="width:250px;" /></div>
|
| 103 |
+
</div>
|
| 104 |
+
</li>
|
| 105 |
+
</ul>
|
| 106 |
+
<div id="max_recipient_message" style="display:none">
|
| 107 |
+
<?php if ($this->getMaxRecipients()): ?>
|
| 108 |
+
<?php echo $this->__('Maximum %d email addresses allowed.', $this->getMaxRecipients()) ?>
|
| 109 |
+
<?php endif; ?>
|
| 110 |
+
</div>
|
| 111 |
+
<?php if (1 < $this->getMaxRecipients()): ?>
|
| 112 |
+
<div id="add_recipient_button">
|
| 113 |
+
<button class="form-button" onclick="add_recipient();" type="button"><span><?php echo $this->__('Add Recipient') ?></span></button>
|
| 114 |
+
</div>
|
| 115 |
+
<?php endif; ?>
|
| 116 |
+
</div>
|
| 117 |
+
</div>
|
| 118 |
+
<div style="clear:both"></div>
|
| 119 |
+
</div>
|
| 120 |
+
|
| 121 |
+
<?php // recaptcha
|
| 122 |
+
if( !(Mage::getStoreConfig("fontis_recaptcha/recaptcha/when_loggedin") && (Mage::getSingleton('customer/session')->isLoggedIn())) )
|
| 123 |
+
{
|
| 124 |
+
if (Mage::getStoreConfig("fontis_recaptcha/recaptcha/sendfriend"))
|
| 125 |
+
echo $this->getChildHtml('recaptcha_box');
|
| 126 |
+
}
|
| 127 |
+
?>
|
| 128 |
+
|
| 129 |
+
<div class="button-set">
|
| 130 |
+
<button class="form-button right" type="submit"><span><?php echo $this->__('Send email') ?></span></button>
|
| 131 |
+
</div>
|
| 132 |
+
</div>
|
| 133 |
+
</div>
|
| 134 |
+
</form>
|
| 135 |
+
<script type="text/javascript">
|
| 136 |
+
var productSendtofriendForm = new VarienForm('product_sendtofriend_form');
|
| 137 |
+
productSendtofriendForm.submit = function() {
|
| 138 |
+
if(this.validator.validate()) {
|
| 139 |
+
this.form.submit();
|
| 140 |
+
}
|
| 141 |
+
}.bind(productSendtofriendForm);
|
| 142 |
+
</script>
|
app/etc/modules/Fontis_Recaptcha.xml
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<!--
|
| 3 |
+
/**
|
| 4 |
+
* Fontis Recaptcha Extension
|
| 5 |
+
*
|
| 6 |
+
* NOTICE OF LICENSE
|
| 7 |
+
*
|
| 8 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 9 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 10 |
+
* It is also available through the world-wide-web at this URL:
|
| 11 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 12 |
+
* If you did not receive a copy of the license and are unable to
|
| 13 |
+
* obtain it through the world-wide-web, please send an email
|
| 14 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 15 |
+
*
|
| 16 |
+
* @category Fontis
|
| 17 |
+
* @package Fontis_Recaptcha
|
| 18 |
+
* @author Denis Margetic
|
| 19 |
+
* @author Chris Norton
|
| 20 |
+
* @copyright Copyright (c) 2010 Fontis Pty. Ltd. (http://www.fontis.com.au)
|
| 21 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 22 |
+
*/
|
| 23 |
+
-->
|
| 24 |
+
<config>
|
| 25 |
+
<modules>
|
| 26 |
+
<Fontis_Recaptcha>
|
| 27 |
+
<active>true</active>
|
| 28 |
+
<codePool>community</codePool>
|
| 29 |
+
</Fontis_Recaptcha>
|
| 30 |
+
</modules>
|
| 31 |
+
</config>
|
package.xml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
| 1 |
<?xml version="1.0"?>
|
| 2 |
<package>
|
| 3 |
<name>Fontis_Recaptcha</name>
|
| 4 |
-
<version>2.4.0.
|
| 5 |
<stability>stable</stability>
|
| 6 |
<license uri="http://opensource.org/licenses/osl-3.0.php">Open Software License (OSL 3.0)</license>
|
| 7 |
<channel>community</channel>
|
|
@@ -11,8 +11,8 @@
|
|
| 11 |
<notes>Recaptcha extension - version 2</notes>
|
| 12 |
<authors><author><name>Chris</name><user>Norton</user><email>chris.norton@fontis.com.au</email></author></authors>
|
| 13 |
<date>2012-05-23</date>
|
| 14 |
-
<time>
|
| 15 |
-
<contents><target name="magecommunity"><dir name="Fontis"><dir name="Recaptcha"><file name="
|
| 16 |
<compatible/>
|
| 17 |
-
<dependencies><required><php><min>5.2.2</min><max>6.0.0</max></php
|
| 18 |
</package>
|
| 1 |
<?xml version="1.0"?>
|
| 2 |
<package>
|
| 3 |
<name>Fontis_Recaptcha</name>
|
| 4 |
+
<version>2.4.0.4</version>
|
| 5 |
<stability>stable</stability>
|
| 6 |
<license uri="http://opensource.org/licenses/osl-3.0.php">Open Software License (OSL 3.0)</license>
|
| 7 |
<channel>community</channel>
|
| 11 |
<notes>Recaptcha extension - version 2</notes>
|
| 12 |
<authors><author><name>Chris</name><user>Norton</user><email>chris.norton@fontis.com.au</email></author></authors>
|
| 13 |
<date>2012-05-23</date>
|
| 14 |
+
<time>23:34:13</time>
|
| 15 |
+
<contents><target name="magecommunity"><dir name="Fontis"><dir name="Recaptcha"><dir name="Block"><dir name="Review"><file name="Form.php" hash="cd78b92e1ea6282b4fee447d8c98cab1"/></dir></dir><dir name="Helper"><file name="Data.php" hash="aa65e79f1d40d6110cb93dd87a10592c"/></dir><dir name="Model"><dir name="Source"><file name="Recaptchalanguage.php" hash="4276c7f0d529c9cd5789a2693da8c975"/><file name="Recaptchatheme.php" hash="af1cc2ae59c8a29cd950e88d25b403c2"/></dir></dir><dir name="controllers"><file name="AccountController.php" hash="4d56ea77359b23cfe1b8ed48f2823bee"/><file name="ContactsController.php" hash="e21e7081e7d0baf9211a96760d5bd014"/><file name="ProductController.php" hash="be6ee9462615eaf9f8ba83cfc538835d"/><file name="ReviewController.php" hash="817dee5c56aec00435f4f2a9a23d908a"/></dir><dir name="etc"><file name="config.xml" hash="70542472f1d8b63938211788b644952e"/><file name="system.xml" hash="fa2eb2107027bd50fde6a1e0a945d958"/></dir></dir></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="fontis_recaptcha.xml" hash="d8b2cd12ef202e9380122860d10f7097"/></dir><dir name="template"><dir name="fontis"><dir name="recaptcha"><file name="contacts.phtml" hash="34be3783c9811db6be3de3f79f4917c9"/><file name="form.phtml" hash="4bfb5063db3f32e4206039e28ef1c014"/><file name="recaptcha.phtml" hash="55ba8f7e16f2f56335a1c1c3e12b629f"/><file name="register.phtml" hash="d0a5189b8186fbadcc95950c14eeab9c"/><file name="send.phtml" hash="f8fa95d1cd3d2d812c4f4abd7f511ed8"/></dir></dir></dir></dir></dir><dir name="default"><dir name="default"><dir name="layout"><file name="fontis_recaptcha.xml" hash="d8b2cd12ef202e9380122860d10f7097"/></dir><dir name="template"><dir name="fontis"><dir name="recaptcha"><file name="contacts.phtml" hash="6be2be1277d3b39537daebf47d5213b0"/><file name="form.phtml" hash="594506e66f52f4d27f6a63eb4a0001a1"/><file name="recaptcha.phtml" hash="55ba8f7e16f2f56335a1c1c3e12b629f"/><file name="register.phtml" hash="eb88eacccd0e9144828eaf5db63bde8c"/><file name="send.phtml" hash="85c0f86a14e9251db81b755facbf29b3"/></dir></dir></dir></dir></dir></dir></target><target name="mageskin"><dir name="frontend"><dir name="base"><dir name="default"><dir name="images"><dir name="fontis"><file name="help.png" hash="c3812c74bc524179f4ccf5d2db7b3cbf"/><file name="refresh.png" hash="6b95778460f660aa7c08f47d244780a7"/><file name="sound.png" hash="8158cd1e7493e88be977a0be37d73aaf"/><file name="text.png" hash="dfcf6dcfd81693487e5642fc8e735dd6"/></dir></dir></dir></dir><dir name="default"><dir name="default"><dir name="images"><dir name="fontis"><file name="help.png" hash="c3812c74bc524179f4ccf5d2db7b3cbf"/><file name="refresh.png" hash="6b95778460f660aa7c08f47d244780a7"/><file name="sound.png" hash="8158cd1e7493e88be977a0be37d73aaf"/><file name="text.png" hash="dfcf6dcfd81693487e5642fc8e735dd6"/></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Fontis_Recaptcha.xml" hash="5d85569faf8e3fe65be0b4ed0d9e3bd3"/></dir></target></contents>
|
| 16 |
<compatible/>
|
| 17 |
+
<dependencies><required><php><min>5.2.2</min><max>6.0.0</max></php></required></dependencies>
|
| 18 |
</package>
|
skin/frontend/base/default/images/fontis/help.png
ADDED
|
Binary file
|
skin/frontend/base/default/images/fontis/refresh.png
ADDED
|
Binary file
|
skin/frontend/base/default/images/fontis/sound.png
ADDED
|
Binary file
|
skin/frontend/base/default/images/fontis/text.png
ADDED
|
Binary file
|
skin/frontend/default/default/images/fontis/help.png
ADDED
|
Binary file
|
skin/frontend/default/default/images/fontis/refresh.png
ADDED
|
Binary file
|
skin/frontend/default/default/images/fontis/sound.png
ADDED
|
Binary file
|
skin/frontend/default/default/images/fontis/text.png
ADDED
|
Binary file
|
