Version Notes
Recaptcha extension - version 2
Download this release
Release Info
Developer | Magento Core Team |
Extension | Fontis_Recaptcha |
Version | 2.0 |
Comparing to | |
See all releases |
Code changes from version 1.1.0 to 2.0
- app/code/community/Fontis/Recaptcha/Block/Review/Form.php +30 -0
- app/code/community/Fontis/Recaptcha/Model/Source/Recaptchalanguage.php +37 -0
- app/code/community/Fontis/Recaptcha/Model/Source/Recaptchatheme.php +2 -0
- app/code/community/Fontis/Recaptcha/controllers/AccountController.php +23 -84
- app/code/community/Fontis/Recaptcha/controllers/ContactsController.php +45 -65
- app/code/community/Fontis/Recaptcha/controllers/ProductController.php +28 -62
- app/code/community/Fontis/Recaptcha/controllers/ReviewController.php +62 -0
- app/code/community/Fontis/Recaptcha/etc/config.xml +85 -49
- app/code/community/Fontis/Recaptcha/etc/config.xml~ +0 -108
- app/code/community/Fontis/Recaptcha/etc/system.xml +93 -53
- app/design/frontend/default/default/layout/fontis_recaptcha.xml +49 -59
- app/design/frontend/default/default/template/fontis/recaptcha/contacts.phtml +74 -0
- app/design/frontend/default/default/template/fontis/recaptcha/form.phtml +107 -59
- app/design/frontend/default/default/template/fontis/recaptcha/recaptcha.phtml +68 -0
- app/design/frontend/default/default/template/fontis/recaptcha/register.phtml +6 -14
- app/design/frontend/default/default/template/fontis/recaptcha/send.phtml +10 -20
- package.xml +8 -8
- 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) 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 |
+
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/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) 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 |
+
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
CHANGED
@@ -28,6 +28,8 @@ class Fontis_Recaptcha_Model_Source_Recaptchatheme
|
|
28 |
array('value' => 'white', 'label' => 'White'),
|
29 |
array('value' => 'red', 'label' => 'Red'),
|
30 |
array('value' => 'blackglass', 'label' => 'Blackglass'),
|
|
|
|
|
31 |
);
|
32 |
}
|
33 |
}
|
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
CHANGED
@@ -25,94 +25,33 @@ class Fontis_Recaptcha_AccountController extends Mage_Customer_AccountController
|
|
25 |
{
|
26 |
public function createPostAction()
|
27 |
{
|
28 |
-
if (Mage::getStoreConfig("
|
29 |
-
|
30 |
-
|
|
|
31 |
// check response
|
32 |
-
$resp = Mage::helper("
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
if ($resp == true) { // if recaptcha response is correct, follow core functionality
|
38 |
-
if ($this->_getSession()->isLoggedIn()) {
|
39 |
-
$this->_redirect('*/*/');
|
40 |
-
return;
|
41 |
-
}
|
42 |
-
if ($this->getRequest()->isPost()) {
|
43 |
-
$errors = array();
|
44 |
-
$customer = Mage::getModel('customer/customer')->setId(null);
|
45 |
-
foreach (Mage::getConfig()->getFieldset('customer_account') as $code=>$node) {
|
46 |
-
if ($node->is('create') && ($value = $this->getRequest()->getParam($code)) !== null) {
|
47 |
-
$customer->setData($code, $value);
|
48 |
-
}
|
49 |
-
}
|
50 |
-
if ($this->getRequest()->getParam('is_subscribed', false)) {
|
51 |
-
$customer->setIsSubscribed(1);
|
52 |
-
}
|
53 |
-
$customer->getGroupId();
|
54 |
-
if ($this->getRequest()->getPost('create_address')) {
|
55 |
-
$address = Mage::getModel('customer/address')
|
56 |
-
->setData($this->getRequest()->getPost())
|
57 |
-
->setIsDefaultBilling($this->getRequest()->getParam('default_billing', false))
|
58 |
-
->setIsDefaultShipping($this->getRequest()->getParam('default_shipping', false))
|
59 |
-
->setId(null);
|
60 |
-
$customer->addAddress($address);
|
61 |
-
$errors = $address->validate();
|
62 |
-
if (!is_array($errors)) {
|
63 |
-
$errors = array();
|
64 |
-
}
|
65 |
-
}
|
66 |
-
try {
|
67 |
-
$validationCustomer = $customer->validate();
|
68 |
-
if (is_array($validationCustomer)) {
|
69 |
-
$errors = array_merge($validationCustomer, $errors);
|
70 |
-
}
|
71 |
-
$validationResult = count($errors) == 0;
|
72 |
|
73 |
-
|
74 |
-
|
75 |
-
|
76 |
-
|
77 |
-
|
78 |
-
|
79 |
-
|
80 |
-
|
81 |
-
|
82 |
-
|
83 |
-
$this->_getSession()->setCustomerAsLoggedIn($customer);
|
84 |
-
$url = $this->_welcomeCustomer($customer);
|
85 |
-
$this->_redirectSuccess($url);
|
86 |
-
return;
|
87 |
-
}
|
88 |
-
} else {
|
89 |
-
$this->_getSession()->setCustomerFormData($this->getRequest()->getPost());
|
90 |
-
if (is_array($errors)) {
|
91 |
-
foreach ($errors as $errorMessage) {
|
92 |
-
$this->_getSession()->addError($errorMessage);
|
93 |
-
}
|
94 |
-
} else {
|
95 |
-
$this->_getSession()->addError($this->__('Invalid customer data'));
|
96 |
-
}
|
97 |
-
}
|
98 |
-
} catch (Mage_Core_Exception $e) {
|
99 |
-
$this->_getSession()->addError($e->getMessage())
|
100 |
-
->setCustomerFormData($this->getRequest()->getPost());
|
101 |
-
} catch (Exception $e) {
|
102 |
-
$this->_getSession()->setCustomerFormData($this->getRequest()->getPost())
|
103 |
-
->addException($e, $this->__('Can\'t save customer'));
|
104 |
-
}
|
105 |
-
}
|
106 |
-
$this->_redirectError(Mage::getUrl('*/*/create', array('_secure'=>true)));
|
107 |
-
}else{ // if recaptcha response is incorrect, reload the page
|
108 |
-
$this->_getSession()->addError($this->__('Your reCAPTCHA entry is incorrect. Please try again.'));
|
109 |
-
$this->_getSession()->setCustomerFormData($this->getRequest()->getPost());
|
110 |
-
$this->_redirectReferer();
|
111 |
-
return;
|
112 |
}
|
113 |
-
}
|
|
|
|
|
114 |
parent::createPostAction();
|
115 |
}
|
116 |
}
|
117 |
}
|
118 |
-
?>
|
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
CHANGED
@@ -24,77 +24,57 @@ include_once "Mage/Contacts/controllers/IndexController.php";
|
|
24 |
class Fontis_Recaptcha_ContactsController extends Mage_Contacts_IndexController
|
25 |
{
|
26 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
27 |
public function postAction()
|
28 |
{
|
29 |
-
if (Mage::getStoreConfig("
|
30 |
-
|
31 |
-
|
32 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
33 |
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
$resp = Mage::helper("recaptcha")->recaptcha_check_answer( $privatekey,
|
39 |
-
$_SERVER["REMOTE_ADDR"],
|
40 |
-
$_POST["recaptcha_challenge_field"],
|
41 |
-
$_POST["recaptcha_response_field"]
|
42 |
-
);
|
43 |
-
$post = $this->getRequest()->getPost();
|
44 |
|
45 |
-
|
46 |
-
|
47 |
-
$translate = Mage::getSingleton('core/translate');
|
48 |
-
/* @var $translate Mage_Core_Model_Translate */
|
49 |
-
$translate->setTranslateInline(false);
|
50 |
-
try {
|
51 |
-
$postObject = new Varien_Object();
|
52 |
-
$postObject->setData($post);
|
53 |
-
$error = false;
|
54 |
-
if (!Zend_Validate::is(trim($post['name']) , 'NotEmpty')) {
|
55 |
-
$error = true;
|
56 |
-
}
|
57 |
-
if (!Zend_Validate::is(trim($post['comment']) , 'NotEmpty')) {
|
58 |
-
$error = true;
|
59 |
-
}
|
60 |
-
if (!Zend_Validate::is(trim($post['email']), 'EmailAddress')) {
|
61 |
-
$error = true;
|
62 |
-
}
|
63 |
-
if ($error) {
|
64 |
-
throw new Exception();
|
65 |
-
}
|
66 |
-
$mailTemplate = Mage::getModel('core/email_template');
|
67 |
-
/* @var $mailTemplate Mage_Core_Model_Email_Template */
|
68 |
-
$mailTemplate->setDesignConfig(array('area' => 'frontend'))
|
69 |
-
->setReplyTo($post['email'])
|
70 |
-
->sendTransactional( Mage::getStoreConfig('contacts/email/email_template'),
|
71 |
-
Mage::getStoreConfig('contacts/email/sender_email_identity'),
|
72 |
-
Mage::getStoreConfig('contacts/email/recipient_email'),
|
73 |
-
null,
|
74 |
-
array('data' => $postObject)
|
75 |
-
);
|
76 |
-
if (!$mailTemplate->getSentSuccess()) {
|
77 |
-
throw new Exception();
|
78 |
-
}
|
79 |
-
$translate->setTranslateInline(true);
|
80 |
-
Mage::getSingleton('customer/session')->addSuccess(Mage::helper('contacts')->__('Your inquiry was submitted and will be responded to as soon as possible. Thank you for contacting us.'));
|
81 |
-
$this->_redirect('*/*/');
|
82 |
-
return;
|
83 |
-
} catch (Exception $e) {
|
84 |
-
$translate->setTranslateInline(true);
|
85 |
-
Mage::getSingleton('customer/session')->addError(Mage::helper('contacts')->__('Unable to submit your request. Please, try again later.'));
|
86 |
-
$this->_redirect('*/*/');
|
87 |
-
return;
|
88 |
-
}
|
89 |
-
} else {
|
90 |
-
$this->_redirect('*/*/');
|
91 |
}
|
92 |
-
}else{ // if recaptcha response is incorrect, reload the page
|
93 |
-
Mage::getSingleton('customer/session')->addError(Mage::helper('contacts')->__('Your reCAPTCHA entry is incorrect. Please try again.'));
|
94 |
-
$this->_redirect('contacts/');
|
95 |
-
return;
|
96 |
}
|
97 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
98 |
parent::postAction();
|
99 |
}
|
100 |
}
|
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 |
}
|
app/code/community/Fontis/Recaptcha/controllers/ProductController.php
CHANGED
@@ -25,71 +25,37 @@ class Fontis_Recaptcha_ProductController extends Mage_Sendfriend_ProductControll
|
|
25 |
{
|
26 |
public function sendmailAction()
|
27 |
{
|
28 |
-
if (Mage::getStoreConfig("
|
29 |
-
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
$product = $this->_initProduct();
|
44 |
-
$sendToFriendModel = $this->_initSendToFriendModel();
|
45 |
-
$data = $this->getRequest()->getPost();
|
46 |
-
|
47 |
-
if ($resp == true) { // if recaptcha response is correct, follow core functionality
|
48 |
-
|
49 |
-
if (!$product || !$product->isVisibleInCatalog() || !$data) {
|
50 |
-
$this->_forward('noRoute');
|
51 |
-
return;
|
52 |
-
}
|
53 |
-
$categoryId = $this->getRequest()->getParam('cat_id', null);
|
54 |
-
if ($categoryId && $category = Mage::getModel('catalog/category')->load($categoryId)) {
|
55 |
-
Mage::register('current_category', $category);
|
56 |
}
|
57 |
-
|
58 |
-
|
59 |
-
|
60 |
-
|
61 |
-
|
62 |
-
|
63 |
-
if (true === $validateRes) {
|
64 |
-
$sendToFriendModel->send();
|
65 |
-
Mage::getSingleton('catalog/session')->addSuccess($this->__('Link to a friend was sent.'));
|
66 |
-
$this->_redirectSuccess($product->getProductUrl());
|
67 |
-
return;
|
68 |
-
} else {
|
69 |
-
Mage::getSingleton('catalog/session')->setFormData($data);
|
70 |
-
if (is_array($validateRes)) {
|
71 |
-
foreach ($validateRes as $errorMessage) {
|
72 |
-
Mage::getSingleton('catalog/session')->addError($errorMessage);
|
73 |
-
}
|
74 |
-
} else {
|
75 |
-
Mage::getSingleton('catalog/session')->addError($this->__('Some problems with data.'));
|
76 |
-
}
|
77 |
-
}
|
78 |
-
} catch (Mage_Core_Exception $e) {
|
79 |
-
Mage::getSingleton('catalog/session')->addError($e->getMessage());
|
80 |
-
} catch (Exception $e) {
|
81 |
-
Mage::getSingleton('catalog/session')
|
82 |
-
->addException($e, $this->__('Some emails were not sent'));
|
83 |
-
echo $e->getTraceAsString();
|
84 |
}
|
85 |
-
$this->_redirectError(Mage::getURL('*/*/send',array('id'=>$product->getId())));
|
86 |
-
} else { // if recaptcha response is incorrect, reload the page
|
87 |
-
Mage::getSingleton('catalog/session')->addError($this->__('Your reCAPTCHA entry is incorrect. Please try again.'));
|
88 |
-
Mage::getSingleton('catalog/session')->setFormData($data);
|
89 |
-
$this->_redirectReferer();
|
90 |
-
return;
|
91 |
}
|
92 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
93 |
parent::sendmailAction();
|
94 |
}
|
95 |
}
|
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')->setFormData($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 |
}
|
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) 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 |
+
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
CHANGED
@@ -24,85 +24,121 @@
|
|
24 |
<config>
|
25 |
<modules>
|
26 |
<Fontis_Recaptcha>
|
27 |
-
<version>
|
28 |
</Fontis_Recaptcha>
|
29 |
</modules>
|
30 |
<global>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
31 |
<models>
|
32 |
<fontis_recaptcha>
|
33 |
<class>Fontis_Recaptcha_Model</class>
|
34 |
</fontis_recaptcha>
|
35 |
</models>
|
36 |
-
<
|
37 |
-
<
|
38 |
-
<rewrite>
|
39 |
-
<product>
|
40 |
-
<to>recaptcha/product</to>
|
41 |
-
</product>
|
42 |
-
</rewrite>
|
43 |
-
</sendfriend>
|
44 |
-
<customer>
|
45 |
-
<rewrite>
|
46 |
-
<account>
|
47 |
-
<to>recaptcha/account</to>
|
48 |
-
</account>
|
49 |
-
</rewrite>
|
50 |
-
</customer>
|
51 |
-
<contacts>
|
52 |
<rewrite>
|
53 |
-
<
|
54 |
-
<to>recaptcha/contacts</to>
|
55 |
-
</index>
|
56 |
</rewrite>
|
57 |
-
</
|
58 |
-
</
|
59 |
<helpers>
|
60 |
-
<
|
61 |
<class>Fontis_Recaptcha_Helper</class>
|
62 |
-
</
|
63 |
</helpers>
|
64 |
</global>
|
65 |
<frontend>
|
66 |
<routers>
|
67 |
-
<
|
68 |
<use>standard</use>
|
69 |
<args>
|
70 |
<module>Fontis_Recaptcha</module>
|
71 |
<frontName>recaptcha</frontName>
|
72 |
</args>
|
73 |
-
</
|
74 |
</routers>
|
75 |
<layout>
|
76 |
<updates>
|
77 |
-
<
|
78 |
<file>fontis_recaptcha.xml</file>
|
79 |
-
</
|
80 |
</updates>
|
81 |
-
</layout>
|
82 |
</frontend>
|
83 |
<default>
|
84 |
-
<
|
85 |
-
<
|
86 |
<public_key></public_key>
|
87 |
<private_key></private_key>
|
88 |
-
<recaptcha_theme>
|
89 |
-
<
|
90 |
-
|
91 |
-
|
92 |
-
<sendfriend>
|
93 |
-
<recaptcha>
|
94 |
-
<enabled>1</enabled>
|
95 |
-
</recaptcha>
|
96 |
-
</sendfriend>
|
97 |
-
<contacts>
|
98 |
<recaptcha>
|
99 |
-
<
|
100 |
-
|
101 |
-
|
102 |
-
|
103 |
-
|
104 |
-
<enabled>1</enabled>
|
105 |
</recaptcha>
|
106 |
-
|
|
|
|
|
|
|
|
|
107 |
</default>
|
108 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
24 |
<config>
|
25 |
<modules>
|
26 |
<Fontis_Recaptcha>
|
27 |
+
<version>2.0.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 |
+
<magento>
|
115 |
+
<text_captcha>Enter the words above:</text_captcha>
|
116 |
+
<audio_captcha>Enter the words you hear:</audio_captcha>
|
117 |
+
</magento>
|
118 |
+
</fontis_recaptcha>
|
119 |
</default>
|
120 |
+
<adminhtml>
|
121 |
+
<acl>
|
122 |
+
<resources>
|
123 |
+
<all>
|
124 |
+
<title>Allow Everything</title>
|
125 |
+
</all>
|
126 |
+
<admin>
|
127 |
+
<children>
|
128 |
+
<system>
|
129 |
+
<children>
|
130 |
+
<config>
|
131 |
+
<children>
|
132 |
+
<fontis_recaptcha>
|
133 |
+
<title>Recaptcha</title>
|
134 |
+
</fontis_recaptcha>
|
135 |
+
</children>
|
136 |
+
</config>
|
137 |
+
</children>
|
138 |
+
</system>
|
139 |
+
</children>
|
140 |
+
</admin>
|
141 |
+
</resources>
|
142 |
+
</acl>
|
143 |
+
</adminhtml>
|
144 |
+
</config>
|
app/code/community/Fontis/Recaptcha/etc/config.xml~
DELETED
@@ -1,108 +0,0 @@
|
|
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) 2009 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>1.0.0</version>
|
28 |
-
</Fontis_Recaptcha>
|
29 |
-
</modules>
|
30 |
-
<global>
|
31 |
-
<models>
|
32 |
-
<fontis_recaptcha>
|
33 |
-
<class>Fontis_Recaptcha_Model</class>
|
34 |
-
</fontis_recaptcha>
|
35 |
-
</models>
|
36 |
-
<routers>
|
37 |
-
<sendfriend>
|
38 |
-
<rewrite>
|
39 |
-
<product>
|
40 |
-
<to>recaptcha/product</to>
|
41 |
-
</product>
|
42 |
-
</rewrite>
|
43 |
-
</sendfriend>
|
44 |
-
<customer>
|
45 |
-
<rewrite>
|
46 |
-
<account>
|
47 |
-
<to>recaptcha/account</to>
|
48 |
-
</account>
|
49 |
-
</rewrite>
|
50 |
-
</customer>
|
51 |
-
<contacts>
|
52 |
-
<rewrite>
|
53 |
-
<index>
|
54 |
-
<to>recaptcha/contacts</to>
|
55 |
-
</index>
|
56 |
-
</rewrite>
|
57 |
-
</contacts>
|
58 |
-
</routers>
|
59 |
-
<helpers>
|
60 |
-
<recaptcha>
|
61 |
-
<class>Fontis_Recaptcha_Helper</class>
|
62 |
-
</recaptcha>
|
63 |
-
</helpers>
|
64 |
-
</global>
|
65 |
-
<frontend>
|
66 |
-
<routers>
|
67 |
-
<recaptcha>
|
68 |
-
<use>standard</use>
|
69 |
-
<args>
|
70 |
-
<module>Fontis_Recaptcha</module>
|
71 |
-
<frontName>recaptcha</frontName>
|
72 |
-
</args>
|
73 |
-
</recaptcha>
|
74 |
-
</routers>
|
75 |
-
<layout>
|
76 |
-
<updates>
|
77 |
-
<recaptcha module="Fontis_Recaptcha">
|
78 |
-
<file>fontis_recaptcha.xml</file>
|
79 |
-
</recaptcha>
|
80 |
-
</updates>
|
81 |
-
</layout>
|
82 |
-
</frontend>
|
83 |
-
<default>
|
84 |
-
<admin>
|
85 |
-
<recaptcha>
|
86 |
-
<public_key></public_key>
|
87 |
-
<private_key></private_key>
|
88 |
-
<recaptcha_theme>clean</recaptcha_theme>
|
89 |
-
<when_loggedin>1</when_loggedin>
|
90 |
-
</recaptcha>
|
91 |
-
</admin>
|
92 |
-
<sendfriend>
|
93 |
-
<recaptcha>
|
94 |
-
<enabled>1</enabled>
|
95 |
-
</recaptcha>
|
96 |
-
</sendfriend>
|
97 |
-
<contacts>
|
98 |
-
<recaptcha>
|
99 |
-
<enabled>1</enabled>
|
100 |
-
</recaptcha>
|
101 |
-
</contacts>
|
102 |
-
<customer>
|
103 |
-
<recaptcha>
|
104 |
-
<enabled>1</enabled>
|
105 |
-
</recaptcha>
|
106 |
-
</customer>
|
107 |
-
</default>
|
108 |
-
</config>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
app/code/community/Fontis/Recaptcha/etc/system.xml
CHANGED
@@ -22,13 +22,26 @@
|
|
22 |
*/
|
23 |
-->
|
24 |
<config>
|
25 |
-
<
|
26 |
-
<
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
27 |
<groups>
|
28 |
-
<
|
29 |
-
<label>Recaptcha
|
30 |
<frontend_type>text</frontend_type>
|
31 |
-
<sort_order>
|
32 |
<show_in_default>1</show_in_default>
|
33 |
<show_in_website>1</show_in_website>
|
34 |
<show_in_store>1</show_in_store>
|
@@ -39,6 +52,7 @@
|
|
39 |
<sort_order>10</sort_order>
|
40 |
<show_in_default>1</show_in_default>
|
41 |
<show_in_website>1</show_in_website>
|
|
|
42 |
</public_key>
|
43 |
<private_key translate="label">
|
44 |
<label>Private Key</label>
|
@@ -46,92 +60,118 @@
|
|
46 |
<sort_order>11</sort_order>
|
47 |
<show_in_default>1</show_in_default>
|
48 |
<show_in_website>1</show_in_website>
|
|
|
49 |
</private_key>
|
50 |
-
<
|
51 |
<label>Recaptcha Theme</label>
|
52 |
<frontend_type>select</frontend_type>
|
53 |
<source_model>fontis_recaptcha/source_recaptchatheme</source_model>
|
54 |
<sort_order>1</sort_order>
|
55 |
<show_in_default>1</show_in_default>
|
56 |
<show_in_website>1</show_in_website>
|
57 |
-
|
58 |
-
|
59 |
-
|
|
|
60 |
<frontend_type>select</frontend_type>
|
61 |
-
<source_model>
|
62 |
<sort_order>2</sort_order>
|
63 |
<show_in_default>1</show_in_default>
|
64 |
<show_in_website>1</show_in_website>
|
65 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
66 |
</fields>
|
67 |
-
</
|
68 |
-
</groups>
|
69 |
-
</admin>
|
70 |
-
<sendfriend>
|
71 |
-
<groups>
|
72 |
<recaptcha translate="label">
|
73 |
-
<label>
|
74 |
<frontend_type>text</frontend_type>
|
75 |
<sort_order>5</sort_order>
|
76 |
<show_in_default>1</show_in_default>
|
77 |
<show_in_website>1</show_in_website>
|
78 |
<show_in_store>1</show_in_store>
|
79 |
<fields>
|
80 |
-
<
|
81 |
-
<label>
|
82 |
<frontend_type>select</frontend_type>
|
83 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
84 |
<sort_order>1</sort_order>
|
85 |
<show_in_default>1</show_in_default>
|
86 |
<show_in_website>1</show_in_website>
|
87 |
-
|
88 |
-
|
89 |
-
|
90 |
-
|
91 |
-
</sendfriend>
|
92 |
-
<customer>
|
93 |
-
<groups>
|
94 |
-
<recaptcha translate="label">
|
95 |
-
<label>Create New Account Recaptcha</label>
|
96 |
-
<frontend_type>text</frontend_type>
|
97 |
-
<sort_order>55</sort_order>
|
98 |
-
<show_in_default>1</show_in_default>
|
99 |
-
<show_in_website>1</show_in_website>
|
100 |
-
<show_in_store>1</show_in_store>
|
101 |
-
<fields>
|
102 |
-
<enabled translate="label">
|
103 |
-
<label>Enabled</label>
|
104 |
<frontend_type>select</frontend_type>
|
105 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
106 |
-
<sort_order>
|
107 |
<show_in_default>1</show_in_default>
|
108 |
<show_in_website>1</show_in_website>
|
109 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
110 |
</fields>
|
111 |
</recaptcha>
|
112 |
-
|
113 |
-
|
114 |
-
<contacts>
|
115 |
-
<groups>
|
116 |
-
<recaptcha translate="label">
|
117 |
-
<label>Contact Us Recaptcha</label>
|
118 |
<frontend_type>text</frontend_type>
|
119 |
-
<sort_order>
|
120 |
<show_in_default>1</show_in_default>
|
121 |
<show_in_website>1</show_in_website>
|
122 |
<show_in_store>1</show_in_store>
|
123 |
<fields>
|
124 |
-
<
|
125 |
-
<label>
|
126 |
-
<frontend_type>
|
127 |
-
<
|
128 |
-
<
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
129 |
<show_in_default>1</show_in_default>
|
130 |
<show_in_website>1</show_in_website>
|
131 |
-
|
|
|
132 |
</fields>
|
133 |
-
</
|
134 |
</groups>
|
135 |
-
</
|
136 |
</sections>
|
137 |
</config>
|
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>
|
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>
|
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 |
+
<magento translate="label">
|
149 |
+
<label>Recaptcha Magento Theme Setup</label>
|
|
|
|
|
|
|
|
|
150 |
<frontend_type>text</frontend_type>
|
151 |
+
<sort_order>11</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 |
+
<text_captcha translate="label">
|
157 |
+
<label>Text Captcha Instructions</label>
|
158 |
+
<frontend_type>text</frontend_type>
|
159 |
+
<sort_order>10</sort_order>
|
160 |
+
<show_in_default>1</show_in_default>
|
161 |
+
<show_in_website>1</show_in_website>
|
162 |
+
<show_in_store>1</show_in_store>
|
163 |
+
</text_captcha>
|
164 |
+
<audio_captcha translate="label">
|
165 |
+
<label>Audio Captcha Instructions</label>
|
166 |
+
<frontend_type>text</frontend_type>
|
167 |
+
<sort_order>10</sort_order>
|
168 |
<show_in_default>1</show_in_default>
|
169 |
<show_in_website>1</show_in_website>
|
170 |
+
<show_in_store>1</show_in_store>
|
171 |
+
</audio_captcha>
|
172 |
</fields>
|
173 |
+
</magento>
|
174 |
</groups>
|
175 |
+
</fontis_recaptcha>
|
176 |
</sections>
|
177 |
</config>
|
app/design/frontend/default/default/layout/fontis_recaptcha.xml
CHANGED
@@ -22,75 +22,65 @@
|
|
22 |
*/
|
23 |
-->
|
24 |
<layout version="0.1.0">
|
25 |
-
<
|
26 |
-
<
|
27 |
-
|
28 |
-
</reference>
|
29 |
-
<reference name="head">
|
30 |
-
<action method="addJs"><script>varien/product.js</script></action>
|
31 |
-
</reference>
|
32 |
<reference name="content">
|
33 |
-
<block type="sendfriend/send" name="
|
|
|
|
|
34 |
</reference>
|
35 |
-
</
|
36 |
-
|
|
|
37 |
<reference name="root">
|
38 |
-
|
39 |
-
|
|
|
|
|
|
|
|
|
|
|
40 |
</reference>
|
|
|
41 |
<reference name="content">
|
42 |
-
<block type="core/template" name="contactForm" template="fontis/recaptcha/
|
|
|
|
|
43 |
</reference>
|
44 |
-
</
|
45 |
-
|
46 |
-
|
47 |
-
<remove name="left"/>
|
48 |
<reference name="root">
|
49 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
50 |
</reference>
|
|
|
51 |
<reference name="content">
|
52 |
-
<block type="
|
|
|
|
|
53 |
</reference>
|
54 |
-
</
|
55 |
-
|
56 |
-
<!-- As Magento won't properly rewrite a single action in the controller, below handles update unchanged actions back to defaults -->
|
57 |
-
<recaptcha_account_login>
|
58 |
-
<update handle="customer_account_login"/>
|
59 |
-
</recaptcha_account_login>
|
60 |
-
<recaptcha_account_forgotpassword>
|
61 |
-
<update handle="customer_account_forgotpassword"/>
|
62 |
-
</recaptcha_account_forgotpassword>
|
63 |
-
<recaptcha_logged_in>
|
64 |
-
<update handle="customer_logged_in"/>
|
65 |
-
</recaptcha_logged_in>
|
66 |
-
<recaptcha_logged_out>
|
67 |
-
<update handle="customer_logged_out"/>
|
68 |
-
</recaptcha_logged_out>
|
69 |
-
<recaptcha_account_logoutsuccess>
|
70 |
-
<update handle="customer_account_logoutsuccess"/>
|
71 |
-
</recaptcha_account_logoutsuccess>
|
72 |
-
<recaptcha_account_confirmation>
|
73 |
-
<update handle="customer_account_confirmation"/>
|
74 |
-
</recaptcha_account_confirmation>
|
75 |
-
<recaptcha_account_edit>
|
76 |
-
<update handle="customer_account_edit"/>
|
77 |
-
</recaptcha_account_edit>
|
78 |
-
<recaptcha_account>
|
79 |
-
<update handle="customer_account"/>
|
80 |
-
</recaptcha_account>
|
81 |
-
<recaptcha_account_index>
|
82 |
-
<update handle="customer_account_index"/>
|
83 |
-
</recaptcha_account_index>
|
84 |
-
<recaptcha_address_index>
|
85 |
-
<update handle="customer_address_index"/>
|
86 |
-
</recaptcha_address_index>
|
87 |
-
<recaptcha_address_form>
|
88 |
-
<update handle="customer_address_form"/>
|
89 |
-
</recaptcha_address_form>
|
90 |
-
</layout>
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
|
|
|
|
|
95 |
|
|
|
|
|
|
|
|
|
|
|
|
|
96 |
|
|
|
|
|
|
|
|
|
|
|
|
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 |
+
<fontis_recaptcha_contacts_index>
|
36 |
<reference name="root">
|
37 |
+
<!--<action method="setTemplate">
|
38 |
+
<template>page/2columns-right.phtml</template>
|
39 |
+
</action>-->
|
40 |
+
|
41 |
+
<action method="setHeaderTitle" translate="title" module="contacts">
|
42 |
+
<title>Contact Us</title>
|
43 |
+
</action>
|
44 |
</reference>
|
45 |
+
|
46 |
<reference name="content">
|
47 |
+
<block type="core/template" name="contactForm" template="fontis/recaptcha/contacts.phtml">
|
48 |
+
<block type="core/template" name="recaptcha.box" as="recaptcha_box" template="fontis/recaptcha/recaptcha.phtml"/>
|
49 |
+
</block>
|
50 |
</reference>
|
51 |
+
</fontis_recaptcha_contacts_index>
|
52 |
+
|
53 |
+
<contacts_contacts_index>
|
|
|
54 |
<reference name="root">
|
55 |
+
<!--<action method="setTemplate">
|
56 |
+
<template>page/2columns-right.phtml</template>
|
57 |
+
</action>-->
|
58 |
+
|
59 |
+
<action method="setHeaderTitle" translate="title" module="contacts">
|
60 |
+
<title>Contact Us</title>
|
61 |
+
</action>
|
62 |
</reference>
|
63 |
+
|
64 |
<reference name="content">
|
65 |
+
<block type="core/template" name="contactForm" template="fontis/recaptcha/contacts.phtml">
|
66 |
+
<block type="core/template" name="recaptcha.box" as="recaptcha_box" template="fontis/recaptcha/recaptcha.phtml"/>
|
67 |
+
</block>
|
68 |
</reference>
|
69 |
+
</contacts_contacts_index>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
70 |
|
71 |
+
<customer_account_create>
|
72 |
+
<remove name="customer_form_register"/>
|
73 |
|
74 |
+
<reference name="content">
|
75 |
+
<block type="customer/form_register" name="recaptcha_form_register" template="fontis/recaptcha/register.phtml">
|
76 |
+
<block type="core/template" name="recaptcha.box" as="recaptcha_box" template="fontis/recaptcha/recaptcha.phtml"/>
|
77 |
+
</block>
|
78 |
+
</reference>
|
79 |
+
</customer_account_create>
|
80 |
|
81 |
+
<review_product_list>
|
82 |
+
<block name="product.review.form" >
|
83 |
+
<block type="core/template" name="recaptcha.box" as="recaptcha_box" template="fontis/recaptcha/recaptcha.phtml"/>
|
84 |
+
</block>
|
85 |
+
</review_product_list>
|
86 |
+
</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) 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-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 if($this->helper('contacts')->getUserName() == "") { if(isset($_SESSION["contact_name"])){ echo ($_SESSION["contact_name"]); unset($_SESSION["contact_name"]);}}else{ 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 if($this->helper('contacts')->getUserEmail() == "") { if(isset($_SESSION["contact_email"])){ echo ($_SESSION["contact_email"]); unset($_SESSION["contact_email"]);}}else{ 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="<?php if(isset($_SESSION["contact_telephone"])){ echo ($_SESSION["contact_telephone"]); unset($_SESSION["contact_telephone"]);} ?>" 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:auto;" cols="50" rows="5"><?php if(isset($_SESSION["contact_comment"])){ echo ($_SESSION["contact_comment"]); unset($_SESSION["contact_comment"]);} ?></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
CHANGED
@@ -1,83 +1,131 @@
|
|
1 |
<?php
|
2 |
/**
|
3 |
-
*
|
4 |
*
|
5 |
* NOTICE OF LICENSE
|
6 |
*
|
7 |
-
* This source file is subject to the
|
8 |
-
* that is bundled with this package in the file
|
9 |
* It is also available through the world-wide-web at this URL:
|
10 |
-
* http://opensource.org/licenses/
|
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 |
-
*
|
16 |
-
*
|
17 |
-
*
|
18 |
-
*
|
19 |
-
*
|
20 |
-
*
|
|
|
|
|
|
|
|
|
21 |
*/
|
22 |
?>
|
23 |
-
<div id="messages_product_view"><?php echo $this->getMessagesBlock()->getGroupedHtml() ?></div>
|
24 |
<div class="page-head">
|
25 |
-
<h3><?php echo
|
26 |
</div>
|
27 |
-
<
|
28 |
-
|
29 |
-
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
<
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
<
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
43 |
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
|
49 |
-
|
|
|
|
|
|
|
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("
|
61 |
-
|
62 |
-
|
63 |
-
|
64 |
-
|
65 |
-
if (Mage::getStoreConfig("contacts/recaptcha/enabled") && $logged_out) {
|
66 |
-
// set the recaptcha theme based on preferences
|
67 |
-
echo '<script> var RecaptchaOptions = { theme : \'';
|
68 |
-
echo Mage::getStoreConfig("admin/recaptcha/recaptcha_theme");
|
69 |
-
echo '\' }; </script>';
|
70 |
-
// show the recaptcha form
|
71 |
-
$publickey = Mage::getStoreConfig("admin/recaptcha/public_key");
|
72 |
-
echo Mage::helper("recaptcha")->recaptcha_get_html($publickey);
|
73 |
-
}
|
74 |
?>
|
75 |
-
|
76 |
<div class="button-set">
|
77 |
-
<
|
78 |
-
<button class="form-button" type="submit"><span><?php echo Mage::helper('contacts')->__('Submit') ?></span></button>
|
79 |
</div>
|
|
|
80 |
</form>
|
81 |
<script type="text/javascript">
|
82 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
83 |
</script>
|
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="page-head">
|
28 |
+
<h3><?php echo $this->__('Write Your Own Review') ?></h3>
|
29 |
</div>
|
30 |
+
<h4><?php echo $this->__("You're reviewing: %s", $this->htmlEscape($this->getProductInfo()->getName())) ?></h4>
|
31 |
+
<form action="<?php echo $this->getAction() ?>" method="post" id="review-form">
|
32 |
+
<fieldset>
|
33 |
+
<?php if( $this->getRatings() && $this->getRatings()->getSize()): ?>
|
34 |
+
<div class="product-review-box">
|
35 |
+
<strong><?php echo $this->__('How do you rate this product?') ?><span class="required">*</span></strong><br />
|
36 |
+
<span id="input-message-box"></span>
|
37 |
+
<table class="data-table" id="product-review-table" cellspacing="0">
|
38 |
+
<thead>
|
39 |
+
<tr>
|
40 |
+
<th> </th>
|
41 |
+
<th><?php echo $this->__('1 star') ?></th>
|
42 |
+
<th><?php echo $this->__('2 stars') ?></th>
|
43 |
+
<th><?php echo $this->__('3 stars') ?></th>
|
44 |
+
<th><?php echo $this->__('4 stars') ?></th>
|
45 |
+
<th><?php echo $this->__('5 stars') ?></th>
|
46 |
+
</tr>
|
47 |
+
</thead>
|
48 |
+
<tbody>
|
49 |
+
<?php $_oddIterator = 1; ?>
|
50 |
+
<?php foreach ($this->getRatings() as $_rating): ?>
|
51 |
+
<tr class="odd<?php if($_oddIterator == $this->getRatings()->getSize()): $_oddIterator = 0; ?> last<?php endif; ?>">
|
52 |
+
<td class="label"><?php echo $_rating->getRatingCode() ?></td>
|
53 |
+
<?php $_iterator = 1; ?>
|
54 |
+
<?php foreach ($_rating->getOptions() as $_option): ?>
|
55 |
+
<!--<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>-->
|
56 |
+
<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>
|
57 |
+
<?php $_iterator++ ?>
|
58 |
+
<?php endforeach; ?>
|
59 |
+
</tr>
|
60 |
+
<?php $_oddIterator ++; ?>
|
61 |
+
<?php endforeach; ?>
|
62 |
+
</tbody>
|
63 |
+
</table>
|
64 |
+
<input type="hidden" name="validate_rating" class="validate-rating" value="" />
|
65 |
+
<script type="text/javascript">decorateTable('product-review-table')</script>
|
66 |
+
</div>
|
67 |
+
<?php endif; ?>
|
68 |
+
<?php // do not remove div - some problem whith validator in IE ?>
|
69 |
+
<div>
|
70 |
+
<label for="nickname_field"><?php echo $this->__('Nickname') ?><span class="required">*</span></label><br />
|
71 |
+
<input class="input-text required-entry" name="nickname" id="nickname_field" style="width: 450px;" type="text" value="<?php echo $this->htmlEscape($data->getNickname()) ?>" />
|
72 |
+
</div>
|
73 |
|
74 |
+
<div>
|
75 |
+
<label for="summary_field"><?php echo $this->__('Summary of Your Review') ?><span class="required">*</span></label><br />
|
76 |
+
<input name="title" class="input-text required-entry" id="summary_field" style="width: 450px;" type="text" value="<?php echo $this->htmlEscape($data->getTitle()) ?>" />
|
77 |
+
</div>
|
78 |
|
79 |
+
<div>
|
80 |
+
<label for="review_field"><?php echo $this->__('Review') ?><span class="required">*</span></label><br />
|
81 |
+
<textarea class="required-entry" name="detail" id="review_field" cols="53" rows="10" style="width: 450px;"><?php echo $this->htmlEscape($data->getDetail()) ?></textarea>
|
82 |
+
</div>
|
83 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
84 |
<?php // recaptcha
|
85 |
+
if( !(Mage::getStoreConfig("fontis_recaptcha/recaptcha/when_loggedin") && (Mage::getSingleton('customer/session')->isLoggedIn())) )
|
86 |
+
{
|
87 |
+
if (Mage::getStoreConfig("fontis_recaptcha/recaptcha/review"))
|
88 |
+
echo $this->getChildHtml('recaptcha_box');
|
89 |
+
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
90 |
?>
|
91 |
+
|
92 |
<div class="button-set">
|
93 |
+
<button class="form-button right" type="submit"><span><?php echo $this->__('Submit Review') ?></span></button>
|
|
|
94 |
</div>
|
95 |
+
</fieldset>
|
96 |
</form>
|
97 |
<script type="text/javascript">
|
98 |
+
//<![CDATA[
|
99 |
+
var dataForm = new VarienForm('review-form');
|
100 |
+
|
101 |
+
Validation.addAllThese(
|
102 |
+
[
|
103 |
+
['validate-rating', '<?php echo $this->__('Please select one of each of the ratings above') ?>', function(v) {
|
104 |
+
var trs = $('product-review-table').getElementsBySelector('tr');
|
105 |
+
var inputs;
|
106 |
+
var error = 1;
|
107 |
+
|
108 |
+
for( var j=0; j < trs.length; j++ ) {
|
109 |
+
var tr = trs[j];
|
110 |
+
if( j > 0 ) {
|
111 |
+
inputs = tr.getElementsBySelector('input');
|
112 |
+
|
113 |
+
for( i in inputs ) {
|
114 |
+
if( inputs[i].checked == true ) {
|
115 |
+
error = 0;
|
116 |
+
}
|
117 |
+
}
|
118 |
+
|
119 |
+
if( error == 1 ) {
|
120 |
+
return false;
|
121 |
+
} else {
|
122 |
+
error = 1;
|
123 |
+
}
|
124 |
+
}
|
125 |
+
}
|
126 |
+
return true;
|
127 |
+
}]
|
128 |
+
]
|
129 |
+
);
|
130 |
+
//]]>
|
131 |
</script>
|
app/design/frontend/default/default/template/fontis/recaptcha/recaptcha.phtml
ADDED
@@ -0,0 +1,68 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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 |
+
|
30 |
+
|
31 |
+
<?php if( $theme == 'magento'): ?>
|
32 |
+
|
33 |
+
<?php echo "<script> var RecaptchaOptions = { theme : 'custom', lang : '$language', custom_theme_widget: 'recaptcha_widget' }; </script>"; ?>
|
34 |
+
<div id="recaptcha_widget" class="group-select wide" style="display:none">
|
35 |
+
<h4 class="legend" style="background-image: none;">Recaptcha</h4>
|
36 |
+
<div style="margin-bottom: 10px; margin-top: 5px;"><?php echo $textbox; ?></div>
|
37 |
+
<div class="col2-set">
|
38 |
+
<div class="col-1" style="width: 305px; margin-right: 15px; background: transparent; border: 0px none;">
|
39 |
+
<div id="recaptcha_image" style="border: 1px solid #CCCCCC; margin-bottom: 10px;"></div>
|
40 |
+
<div style="text-align: center;">
|
41 |
+
<span class="recaptcha_only_if_image"><?php echo Mage::getStoreConfig("fontis_recaptcha/magento/text_captcha") ?></span>
|
42 |
+
<span class="recaptcha_only_if_audio"><?php echo Mage::getStoreConfig("fontis_recaptcha/magento/audio_captcha") ?></span>
|
43 |
+
<input type="text" id="recaptcha_response_field" name="recaptcha_response_field" class="input-text required-entry" />
|
44 |
+
</div>
|
45 |
+
</div>
|
46 |
+
<div class="col-2" style="float: left; width: 25px; background: transparent; border: 0px none;">
|
47 |
+
<div><a href="javascript:Recaptcha.reload()"><img src="<?php echo $this->getSkinUrl('images/fontis/refresh.png');?>" title="Get another CAPTCHA" alt="Get another CAPTCHA"/></a></div>
|
48 |
+
<div class="recaptcha_only_if_image"><a href="javascript:Recaptcha.switch_type('audio')"><img src="<?php echo $this->getSkinUrl('images/fontis/sound.png');?>" title="Get an audio CAPTCHA" alt="Get an audio CAPTCHA"/></a></div>
|
49 |
+
<div class="recaptcha_only_if_audio"><a href="javascript:Recaptcha.switch_type('image')"><img src="<?php echo $this->getSkinUrl('images/fontis/text.png');?>" title="Get an image CAPTCHA" alt="Get an image CAPTCHA"/></a></div>
|
50 |
+
<div><a href="javascript:Recaptcha.showhelp()"><img src="<?php echo $this->getSkinUrl('images/fontis/help.png');?>" title="Help" alt="Help"/></a></div>
|
51 |
+
</div>
|
52 |
+
</div>
|
53 |
+
<?php echo Mage::helper("fontis_recaptcha")->recaptcha_get_html($publickey, null, Mage::app()->getRequest()->isSecure()); ?>
|
54 |
+
</div>
|
55 |
+
|
56 |
+
<?php elseif( $theme == 'custom' ): ?>
|
57 |
+
|
58 |
+
<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>
|
59 |
+
|
60 |
+
<?php else: ?>
|
61 |
+
|
62 |
+
<div style="margin-bottom: 10px;"><?php echo $textbox; ?></div>
|
63 |
+
<?php
|
64 |
+
echo "<script> var RecaptchaOptions = { theme : '$theme', lang : '$language' }; </script>";
|
65 |
+
echo Mage::helper("fontis_recaptcha")->recaptcha_get_html($publickey, null, Mage::app()->getRequest()->isSecure());
|
66 |
+
?>
|
67 |
+
|
68 |
+
<?php endif; ?>
|
app/design/frontend/default/default/template/fontis/recaptcha/register.phtml
CHANGED
@@ -132,19 +132,11 @@
|
|
132 |
</li>
|
133 |
</ul>
|
134 |
</fieldset>
|
135 |
-
|
136 |
-
<?php
|
137 |
-
|
138 |
-
|
139 |
-
|
140 |
-
echo Mage::getStoreConfig("admin/recaptcha/recaptcha_theme");
|
141 |
-
echo '\' }; </script>';
|
142 |
-
// show the recaptcha form
|
143 |
-
$publickey = Mage::getStoreConfig("admin/recaptcha/public_key");
|
144 |
-
echo Mage::helper("recaptcha")->recaptcha_get_html($publickey);
|
145 |
-
}
|
146 |
-
?>
|
147 |
-
|
148 |
<div class="button-set">
|
149 |
<p class="required"><?php echo $this->__('* Required Fields') ?></p>
|
150 |
<a href="<?php echo $this->getBackUrl() ?>" class="left">« <?php echo $this->__('Back') ?></a>
|
@@ -158,4 +150,4 @@
|
|
158 |
new RegionUpdater('country', 'region', 'region_id', <?php echo $this->helper('directory')->getRegionJson() ?>);
|
159 |
<?php endif; ?>
|
160 |
//]]>
|
161 |
-
</script>
|
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>
|
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
CHANGED
@@ -28,6 +28,7 @@
|
|
28 |
?>
|
29 |
|
30 |
<script type="text/javascript">
|
|
|
31 |
i=0;
|
32 |
var recipCount = 1;
|
33 |
var maxRecip = <?php echo $this->getMaxRecipients() ?>;
|
@@ -57,6 +58,7 @@
|
|
57 |
|
58 |
ul.appendChild(li_mail);
|
59 |
}
|
|
|
60 |
</script>
|
61 |
|
62 |
<?php echo $this->getMessagesBlock()->getGroupedHtml() ?>
|
@@ -84,10 +86,8 @@
|
|
84 |
<label for="sender_message"><?php echo $this->__('Message:') ?> <span class="required">*</span></label><br/>
|
85 |
<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>
|
86 |
</li>
|
87 |
-
|
88 |
</ul>
|
89 |
</div>
|
90 |
-
|
91 |
<div>
|
92 |
<div>
|
93 |
<br />
|
@@ -96,7 +96,7 @@
|
|
96 |
<li>
|
97 |
<div class="left">
|
98 |
<label for="recipients_name"><?php echo $this->__('Name:') ?> <span class="required">*</span></label><br/>
|
99 |
-
<div style="width:250px"><input name="recipients[name][]"
|
100 |
</div>
|
101 |
<div class="right">
|
102 |
<label for="recipients_email"><?php echo $this->__('Email Address:') ?> <span class="required">*</span></label><br/>
|
@@ -117,25 +117,15 @@
|
|
117 |
</div>
|
118 |
</div>
|
119 |
<div style="clear:both"></div>
|
120 |
-
|
121 |
</div>
|
122 |
-
|
123 |
-
<?php // recaptcha
|
124 |
-
if (Mage::getStoreConfig("admin/recaptcha/when_loggedin"))
|
125 |
-
$logged_out = !(Mage::getSingleton('customer/session')->isLoggedIn());
|
126 |
-
else
|
127 |
-
$logged_out = true;
|
128 |
|
129 |
-
|
130 |
-
|
131 |
-
|
132 |
-
|
133 |
-
|
134 |
-
|
135 |
-
|
136 |
-
echo Mage::helper("recaptcha")->recaptcha_get_html($publickey);
|
137 |
-
}
|
138 |
-
?>
|
139 |
|
140 |
<div class="button-set">
|
141 |
<button class="form-button right" type="submit"><span><?php echo $this->__('Send email') ?></span></button>
|
28 |
?>
|
29 |
|
30 |
<script type="text/javascript">
|
31 |
+
//<![CDATA[
|
32 |
i=0;
|
33 |
var recipCount = 1;
|
34 |
var maxRecip = <?php echo $this->getMaxRecipients() ?>;
|
58 |
|
59 |
ul.appendChild(li_mail);
|
60 |
}
|
61 |
+
//]]>
|
62 |
</script>
|
63 |
|
64 |
<?php echo $this->getMessagesBlock()->getGroupedHtml() ?>
|
86 |
<label for="sender_message"><?php echo $this->__('Message:') ?> <span class="required">*</span></label><br/>
|
87 |
<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>
|
88 |
</li>
|
|
|
89 |
</ul>
|
90 |
</div>
|
|
|
91 |
<div>
|
92 |
<div>
|
93 |
<br />
|
96 |
<li>
|
97 |
<div class="left">
|
98 |
<label for="recipients_name"><?php echo $this->__('Name:') ?> <span class="required">*</span></label><br/>
|
99 |
+
<div style="width:250px"><input name="recipients[name][]" type="text" class="input-text required-entry" id="recipients_name" style="width:250px;" /></div><br /><br />
|
100 |
</div>
|
101 |
<div class="right">
|
102 |
<label for="recipients_email"><?php echo $this->__('Email Address:') ?> <span class="required">*</span></label><br/>
|
117 |
</div>
|
118 |
</div>
|
119 |
<div style="clear:both"></div>
|
|
|
120 |
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
121 |
|
122 |
+
<?php // recaptcha
|
123 |
+
if( !(Mage::getStoreConfig("fontis_recaptcha/recaptcha/when_loggedin") && (Mage::getSingleton('customer/session')->isLoggedIn())) )
|
124 |
+
{
|
125 |
+
if (Mage::getStoreConfig("fontis_recaptcha/recaptcha/sendfriend"))
|
126 |
+
echo $this->getChildHtml('recaptcha_box');
|
127 |
+
}
|
128 |
+
?>
|
|
|
|
|
|
|
129 |
|
130 |
<div class="button-set">
|
131 |
<button class="form-button right" type="submit"><span><?php echo $this->__('Send email') ?></span></button>
|
package.xml
CHANGED
@@ -1,18 +1,18 @@
|
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>Fontis_Recaptcha</name>
|
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>
|
8 |
<extends/>
|
9 |
-
<summary>
|
10 |
-
<description>
|
11 |
-
<notes>
|
12 |
-
<authors><author><name>
|
13 |
-
<date>2009-
|
14 |
-
<time>23:
|
15 |
-
<contents><target name="magecommunity"><dir name="Fontis"><dir name="Recaptcha"><dir name="controllers"><file name="AccountController.php" hash="
|
16 |
<compatible/>
|
17 |
<dependencies/>
|
18 |
</package>
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>Fontis_Recaptcha</name>
|
4 |
+
<version>2.0</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>
|
8 |
<extends/>
|
9 |
+
<summary>Recaptcha extension</summary>
|
10 |
+
<description>Recaptcha extension</description>
|
11 |
+
<notes>Recaptcha extension - version 2</notes>
|
12 |
+
<authors><author><name>Denis Margetic</name><user>auto-converted</user><email>denis@fontis.com.au</email></author></authors>
|
13 |
+
<date>2009-10-04</date>
|
14 |
+
<time>23:09:17</time>
|
15 |
+
<contents><target name="magecommunity"><dir name="Fontis"><dir name="Recaptcha"><dir name="Block"><dir name="Review"><file name="Form.php" hash="3903a79f759ccd20d0de2e3838a0ff1d"/></dir></dir><dir name="controllers"><file name="AccountController.php" hash="7b70559028b6a9dc95f283668a9ced63"/><file name="ContactsController.php" hash="69e4c68336d878cedd9bb9165ff42533"/><file name="ProductController.php" hash="dc3f9ad700688b4129c184e97a0ea209"/><file name="ReviewController.php" hash="64dfecceea567e11b95708e0b2430b25"/></dir><dir name="etc"><file name="config.xml" hash="ad0571e36336d5dc80bb00447ff4f624"/><file name="system.xml" hash="c430d59f4a72048a2f8290a9d2e8f906"/></dir><dir name="Helper"><file name="Data.php" hash="d73a2b15052d0a20c8224ddb1b56b4b7"/></dir><dir name="Model"><dir name="Source"><file name="Recaptchalanguage.php" hash="62459b024ebae0f8bbc3ed54cc5f1850"/><file name="Recaptchatheme.php" hash="a4497170f3f22660ea6ca6c19a025a22"/></dir></dir></dir></dir></target><target name="mageskin"><dir name="frontend"><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="magedesign"><dir name="frontend"><dir name="default"><dir name="default"><dir name="layout"><file name="fontis_recaptcha.xml" hash="ac32f7fa9384ca4cfc85a82be197d23b"/></dir><dir name="template"><dir name="fontis"><dir name="recaptcha"><file name="contacts.phtml" hash="4c2e4c4b3eae4dbade1fe602b0066a6b"/><file name="form.phtml" hash="434310b975bfe67cd35945373fb90c51"/><file name="recaptcha.phtml" hash="61541bf0caf58789251c570fc53d0b4f"/><file name="register.phtml" hash="ece6b72da853e75ef8c3299fb32147d4"/><file name="send.phtml" hash="841127b3d34791cca67c311ba3e1d2f8"/></dir></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Fontis_Recaptcha.xml" hash="a08a1a2730c4345fb78e78c7b1176ffd"/></dir></target></contents>
|
16 |
<compatible/>
|
17 |
<dependencies/>
|
18 |
</package>
|
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
|