Version Notes
The extension opens up the standard Magento contact us page as an overlay, which gives your customers the ability to leave a message without browsing away from their current page.
Download this release
Release Info
| Developer | Productiveminds |
| Extension | Productiveminds_Contactus |
| Version | 0.1.6 |
| Comparing to | |
| See all releases | |
Version 0.1.6
- app/code/community/Productiveminds/Core/.DS_Store +0 -0
- app/code/community/Productiveminds/Core/Block/.DS_Store +0 -0
- app/code/community/Productiveminds/Core/Block/Adminhtml/Renderer/Attachedfiles.php +10 -0
- app/code/community/Productiveminds/Core/Block/Adminhtml/Support/Edit.php +21 -0
- app/code/community/Productiveminds/Core/Block/Adminhtml/Support/Edit/Form.php +17 -0
- app/code/community/Productiveminds/Core/Block/Adminhtml/Support/Edit/Tab/Form.php +69 -0
- app/code/community/Productiveminds/Core/Block/Adminhtml/Support/Edit/Tab/Options.php +9 -0
- app/code/community/Productiveminds/Core/Block/Adminhtml/Support/Edit/Tabs.php +31 -0
- app/code/community/Productiveminds/Core/Block/Adminhtml/System/Config/Form/Fieldset/Contactus.php +13 -0
- app/code/community/Productiveminds/Core/Block/Adminhtml/System/Config/Form/Fieldset/Promindsextensions/Item.php +25 -0
- app/code/community/Productiveminds/Core/Helper/Countrycat.php +371 -0
- app/code/community/Productiveminds/Core/Helper/Data.php +158 -0
- app/code/community/Productiveminds/Core/Model/Email.php +39 -0
- app/code/community/Productiveminds/Core/Model/System/Config/Source/Typeofissue.php +33 -0
- app/code/community/Productiveminds/Core/controllers/Adminhtml/IndexController.php +22 -0
- app/code/community/Productiveminds/Core/controllers/Adminhtml/SupportController.php +54 -0
- app/code/community/Productiveminds/Core/etc/adminhtml.xml +67 -0
- app/code/community/Productiveminds/Core/etc/config.xml +54 -0
- app/code/community/Productiveminds/Core/etc/system.xml +42 -0
- app/code/local/Productiveminds/Contactus/Block/Activate.php +49 -0
- app/code/local/Productiveminds/Contactus/Helper/Data.php +48 -0
- app/code/local/Productiveminds/Contactus/controllers/IndexController.php +157 -0
- app/code/local/Productiveminds/Contactus/etc/adminhtml.xml +39 -0
- app/code/local/Productiveminds/Contactus/etc/config.xml +65 -0
- app/code/local/Productiveminds/Contactus/etc/system.xml +117 -0
- app/design/adminhtml/default/default/layout/productiveminds/core.xml +16 -0
- app/design/frontend/base/default/layout/productiveminds/contactus.xml +55 -0
- app/design/frontend/base/default/template/productiveminds/contactus/contactus-live.phtml +71 -0
- app/design/frontend/base/default/template/productiveminds/contactus/contactus.phtml +72 -0
- app/design/frontend/base/default/template/productiveminds/contactus/form.phtml +99 -0
- app/design/frontend/base/default/template/productiveminds/contactus/link.phtml +41 -0
- app/design/frontend/base/default/template/productiveminds/contactus/overlay.phtml +46 -0
- app/etc/modules/Productiveminds_Contactus.xml +9 -0
- app/etc/modules/Productiveminds_Core.xml +9 -0
- app/locale/en_US/template/email/productiveminds/contactus.html +16 -0
- package.xml +18 -0
- skin/frontend/base/default/productiveminds/contactus/css/contactus.css +318 -0
- skin/frontend/base/default/productiveminds/contactus/css/overlay.css +51 -0
- skin/frontend/base/default/productiveminds/contactus/images/btn_bg.gif +0 -0
- skin/frontend/base/default/productiveminds/contactus/images/content_bg.gif +0 -0
- skin/frontend/base/default/productiveminds/contactus/images/window_close.png +0 -0
app/code/community/Productiveminds/Core/.DS_Store
ADDED
|
Binary file
|
app/code/community/Productiveminds/Core/Block/.DS_Store
ADDED
|
Binary file
|
app/code/community/Productiveminds/Core/Block/Adminhtml/Renderer/Attachedfiles.php
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
|
| 3 |
+
class Productiveminds_Core_Block_Adminhtml_Renderer_Attachedfiles extends Varien_Data_Form_Element_File {
|
| 4 |
+
public function getElementHtml()
|
| 5 |
+
{
|
| 6 |
+
$html = parent::getElementHtml();
|
| 7 |
+
$newntml = substr_replace($html, 'multiple="true"', -2, 0);
|
| 8 |
+
return $newntml;
|
| 9 |
+
}
|
| 10 |
+
}
|
app/code/community/Productiveminds/Core/Block/Adminhtml/Support/Edit.php
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
|
| 3 |
+
class Productiveminds_Core_Block_Adminhtml_Support_Edit extends Mage_Adminhtml_Block_Widget_Form_Container {
|
| 4 |
+
|
| 5 |
+
public function __construct() {
|
| 6 |
+
parent::__construct ();
|
| 7 |
+
|
| 8 |
+
$this->_objectId = 'id';
|
| 9 |
+
$this->_controller = 'adminhtml_support';
|
| 10 |
+
$this->_blockGroup = 'productivemindscore';
|
| 11 |
+
$this->_removeButton ( 'back' );
|
| 12 |
+
$this->_removeButton ( 'reset' );
|
| 13 |
+
$this->_removeButton ( 'save' );
|
| 14 |
+
$this->_headerText = Mage::helper ('productivemindscore')->__ ('Productiveminds Support');
|
| 15 |
+
}
|
| 16 |
+
|
| 17 |
+
public function getHeaderText() {
|
| 18 |
+
return Mage::helper('productivemindscore')->__('Productiveminds Support - Creating a Ticket');
|
| 19 |
+
}
|
| 20 |
+
|
| 21 |
+
}
|
app/code/community/Productiveminds/Core/Block/Adminhtml/Support/Edit/Form.php
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
|
| 3 |
+
class Productiveminds_Core_Block_Adminhtml_Support_Edit_Form extends Mage_Adminhtml_Block_Widget_Form {
|
| 4 |
+
|
| 5 |
+
protected function _prepareForm() {
|
| 6 |
+
$form = new Varien_Data_Form(array(
|
| 7 |
+
'id' => 'edit_form',
|
| 8 |
+
'action' => $this->getUrl('*/*/save'),
|
| 9 |
+
'method' => 'post',
|
| 10 |
+
'enctype' => "multipart/form-data",
|
| 11 |
+
)
|
| 12 |
+
);
|
| 13 |
+
$form->setUseContainer(true);
|
| 14 |
+
$this->setForm($form);
|
| 15 |
+
return parent::_prepareForm();
|
| 16 |
+
}
|
| 17 |
+
}
|
app/code/community/Productiveminds/Core/Block/Adminhtml/Support/Edit/Tab/Form.php
ADDED
|
@@ -0,0 +1,69 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
|
| 3 |
+
class Productiveminds_Core_Block_Adminhtml_Support_Edit_Tab_Form extends Mage_Adminhtml_Block_Widget_Form {
|
| 4 |
+
|
| 5 |
+
protected function _prepareForm() {
|
| 6 |
+
|
| 7 |
+
$adminId = Mage::getSingleton ( 'admin/session' )->getUser ()->getId ();
|
| 8 |
+
$user = Mage::getModel ( 'admin/user' )->load ( $adminId );
|
| 9 |
+
|
| 10 |
+
$form = new Varien_Data_Form ();
|
| 11 |
+
$this->setForm ( $form );
|
| 12 |
+
|
| 13 |
+
$helper = Mage::helper ( 'productivemindscore' );
|
| 14 |
+
|
| 15 |
+
$fieldset = $form->addFieldset ( 'productivemindscore_form', array (
|
| 16 |
+
'legend' => $helper->__ ( 'Support Tickets Details' ),
|
| 17 |
+
'class' => 'fieldset-wide'
|
| 18 |
+
) );
|
| 19 |
+
|
| 20 |
+
$fieldset->addField ( 'typeofissue', 'select', array (
|
| 21 |
+
'name' => 'typeofissue',
|
| 22 |
+
'label' => $helper->__ ( 'Type of issue' ),
|
| 23 |
+
'values' => Mage::getModel ( 'productivemindscore/system_config_source_typeofissue' )->toOptionArray (),
|
| 24 |
+
'required' => true,
|
| 25 |
+
'value' => false
|
| 26 |
+
) );
|
| 27 |
+
$fieldset->addField ( 'message', 'textarea', array (
|
| 28 |
+
'name' => 'message',
|
| 29 |
+
'label' => $helper->__ ( 'Issue Details' ),
|
| 30 |
+
'required' => true,
|
| 31 |
+
'note' => Mage::helper('productivemindscore')->__('Please provide as much details as possible'),
|
| 32 |
+
) );
|
| 33 |
+
|
| 34 |
+
$fieldset->addType ( 'attachedfiles', Mage::getConfig ()->getBlockClassName ('productivemindscore/adminhtml_renderer_attachedfiles') );
|
| 35 |
+
|
| 36 |
+
$fieldset->addField ( 'attachments', 'attachedfiles', array (
|
| 37 |
+
'name' => 'attachments[]',
|
| 38 |
+
'multiple' => true,
|
| 39 |
+
'label' => Mage::helper ( 'adminhtml' )->__ ( 'Attachment files' )
|
| 40 |
+
) );
|
| 41 |
+
|
| 42 |
+
$fieldset->addField ( 'useremail', 'text', array (
|
| 43 |
+
'name' => 'useremail',
|
| 44 |
+
'label' => Mage::helper ( 'adminhtml' )->__ ( 'Your e-mail' ),
|
| 45 |
+
'value' => $user['email'],
|
| 46 |
+
'required' => true
|
| 47 |
+
) );
|
| 48 |
+
|
| 49 |
+
$fieldset->addField ( 'username', 'text', array (
|
| 50 |
+
'name' => 'username',
|
| 51 |
+
'label' => Mage::helper ( 'adminhtml' )->__ ( 'Your name' ),
|
| 52 |
+
'value' => "{$user['firstname']} {$user['lastname']}",
|
| 53 |
+
'required' => true
|
| 54 |
+
) );
|
| 55 |
+
|
| 56 |
+
$fieldset->addField ( 'systeminfo', 'hidden', array (
|
| 57 |
+
'name' => 'systeminfo',
|
| 58 |
+
'value' => $helper->systemInfo ()
|
| 59 |
+
) );
|
| 60 |
+
|
| 61 |
+
$fieldset->addField ( 'save', 'submit', array (
|
| 62 |
+
'name' => 'save',
|
| 63 |
+
'class' => 'save',
|
| 64 |
+
'value' => $helper->__ ( 'Submit Issue' )
|
| 65 |
+
) );
|
| 66 |
+
|
| 67 |
+
return parent::_prepareForm ();
|
| 68 |
+
}
|
| 69 |
+
}
|
app/code/community/Productiveminds/Core/Block/Adminhtml/Support/Edit/Tab/Options.php
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
|
| 3 |
+
class Productiveminds_Core_Block_Adminhtml_Support_Edit_Tab_Options extends Mage_Adminhtml_Block_Widget_Form {
|
| 4 |
+
|
| 5 |
+
protected function _prepareForm()
|
| 6 |
+
{
|
| 7 |
+
return parent::_prepareForm();
|
| 8 |
+
}
|
| 9 |
+
}
|
app/code/community/Productiveminds/Core/Block/Adminhtml/Support/Edit/Tabs.php
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
|
| 3 |
+
class Productiveminds_Core_Block_Adminhtml_Support_Edit_Tabs extends Mage_Adminhtml_Block_Widget_Tabs {
|
| 4 |
+
|
| 5 |
+
public function __construct()
|
| 6 |
+
{
|
| 7 |
+
parent::__construct();
|
| 8 |
+
$this->setId('productivemindscore_tabs');
|
| 9 |
+
$this->setDestElementId('edit_form');
|
| 10 |
+
$this->setTitle(Mage::helper('productivemindscore')->__('Productiveminds Support'));
|
| 11 |
+
}
|
| 12 |
+
|
| 13 |
+
protected function _beforeToHtml()
|
| 14 |
+
{
|
| 15 |
+
$this->addTab('ticket_section', array(
|
| 16 |
+
'label' => Mage::helper('productivemindscore')->__('Create a support ticket'),
|
| 17 |
+
'title' => Mage::helper('productivemindscore')->__('Create a support ticket'),
|
| 18 |
+
'content' => $this->getLayout()->createBlock('productivemindscore/adminhtml_support_edit_tab_form')->toHtml(),
|
| 19 |
+
));
|
| 20 |
+
|
| 21 |
+
/* TODO
|
| 22 |
+
$this->addTab('productivemindscore_section', array(
|
| 23 |
+
'label' => Mage::helper('productivemindscore')->__('CONTACT INFORMATION'),
|
| 24 |
+
'title' => Mage::helper('productivemindscore')->__('CONTACT INFORMATION'),
|
| 25 |
+
'content' => $this->getLayout()->createBlock('productivemindscore/adminhtml_support_edit_tab_Options')->toHtml(),
|
| 26 |
+
));
|
| 27 |
+
*/
|
| 28 |
+
|
| 29 |
+
return parent::_beforeToHtml();
|
| 30 |
+
}
|
| 31 |
+
}
|
app/code/community/Productiveminds/Core/Block/Adminhtml/System/Config/Form/Fieldset/Contactus.php
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
|
| 3 |
+
class Productiveminds_Core_Block_Adminhtml_System_Config_Form_Fieldset_Contactus
|
| 4 |
+
extends Mage_Adminhtml_Block_System_Config_Form_Fieldset
|
| 5 |
+
{
|
| 6 |
+
public function render(Varien_Data_Form_Element_Abstract $element)
|
| 7 |
+
{
|
| 8 |
+
$html = $this->_getHeaderHtml($element);
|
| 9 |
+
$html .= Mage::helper('productivemindscore')->__(Mage::getStoreConfig('productivemindscore_sectns/contactus/text'));
|
| 10 |
+
$html .= $this->_getFooterHtml($element);
|
| 11 |
+
return $html;
|
| 12 |
+
}
|
| 13 |
+
}
|
app/code/community/Productiveminds/Core/Block/Adminhtml/System/Config/Form/Fieldset/Promindsextensions/Item.php
ADDED
|
@@ -0,0 +1,25 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
|
| 3 |
+
class Productiveminds_Core_Block_Adminhtml_System_Config_Form_Fieldset_Promindsextensions_Item extends Mage_Adminhtml_Block_System_Config_Form_Fieldset {
|
| 4 |
+
|
| 5 |
+
public function render(Varien_Data_Form_Element_Abstract $element)
|
| 6 |
+
{
|
| 7 |
+
$html = $this->_getHeaderHtml($element);
|
| 8 |
+
$modules = Mage::getConfig()->getNode('modules')->children();
|
| 9 |
+
$linkTitle = Mage::helper('productivemindscore')->__('Visit Extension');
|
| 10 |
+
foreach ($modules as $moduleName => $values) {
|
| 11 |
+
if (0 !== strpos($moduleName, 'Productiveminds_')) {
|
| 12 |
+
continue;
|
| 13 |
+
}
|
| 14 |
+
|
| 15 |
+
$field = $element->addField($moduleName, 'label', array(
|
| 16 |
+
'label' => $moduleName,
|
| 17 |
+
'value' => (string) $values->version
|
| 18 |
+
));
|
| 19 |
+
$html .= $field->toHtml();
|
| 20 |
+
}
|
| 21 |
+
$html .= $this->_getFooterHtml($element);
|
| 22 |
+
|
| 23 |
+
return $html;
|
| 24 |
+
}
|
| 25 |
+
}
|
app/code/community/Productiveminds/Core/Helper/Countrycat.php
ADDED
|
@@ -0,0 +1,371 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* A Magento module by ProductiveMinds
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This code is the work and copyright of Productive Minds Ltd, A UK registered company.
|
| 8 |
+
* The copyright owner prohibit any fom of distribution of this code
|
| 9 |
+
*
|
| 10 |
+
* DISCLAIMER
|
| 11 |
+
*
|
| 12 |
+
* You are strongly advised to backup ALL your server files and database before installing and/or configuring
|
| 13 |
+
* this Magento module. ProductiveMinds will not take any form of responsibility for any adverse effects that
|
| 14 |
+
* may be cause directly or indirectly by using this software. As a usual practice with Software deployment,
|
| 15 |
+
* the copyright owner recommended that you first install this software on a test server verify its appropriateness
|
| 16 |
+
* before finally deploying it to a live server.
|
| 17 |
+
*
|
| 18 |
+
* @category Productiveminds
|
| 19 |
+
* @package Productiveminds_Sitesecurity
|
| 20 |
+
* @copyright Copyright (c) 2010 - 2015 Productive Minds Ltd (http://www.productiveminds.com)
|
| 21 |
+
* @license http://www.productiveminds.com/license/license.txt
|
| 22 |
+
* @author ProductiveMinds <info@productiveminds.com>
|
| 23 |
+
*/
|
| 24 |
+
|
| 25 |
+
class Productiveminds_Core_Helper_Countrycat extends Mage_Core_Helper_Abstract
|
| 26 |
+
{
|
| 27 |
+
|
| 28 |
+
const CONTINENT_CODE_EUROPE = 'europe';
|
| 29 |
+
const CONTINENT_CODE_N_AMERICA = 'nAmerica';
|
| 30 |
+
const CONTINENT_CODE_AFRICA = 'africa';
|
| 31 |
+
const CONTINENT_CODE_S_AMERICA = 'sAmerica';
|
| 32 |
+
const CONTINENT_CODE_ANTARCTICA = 'antarctica';
|
| 33 |
+
const CONTINENT_CODE_ASIA = 'asia';
|
| 34 |
+
const CONTINENT_CODE_OCEANIA = 'oceania';
|
| 35 |
+
const CONTINENT_CODE_OTHER = 'other';
|
| 36 |
+
|
| 37 |
+
|
| 38 |
+
/**
|
| 39 |
+
* Renders user country
|
| 40 |
+
*
|
| 41 |
+
* @param string $coreRoute
|
| 42 |
+
*/
|
| 43 |
+
public function getCountryContinent($countryCode = 1, $model)
|
| 44 |
+
{
|
| 45 |
+
$europe = self::isEurope();
|
| 46 |
+
$northAmerica = self::isNorthAmerica();
|
| 47 |
+
$africa = self::isAfrica();
|
| 48 |
+
$southAmerica = self::isSouthAmerica();
|
| 49 |
+
$asia = self::isAsia();
|
| 50 |
+
$antarctica = self::isAntarctica();
|
| 51 |
+
$oceania = self::isOceania();
|
| 52 |
+
|
| 53 |
+
if(in_array($countryCode, $europe)) {
|
| 54 |
+
$catObj = $model->load(Productiveminds_Core_Helper_Countrycat::CONTINENT_CODE_EUROPE, 'code');
|
| 55 |
+
return $catObj->getCatId();
|
| 56 |
+
} else if(in_array($countryCode, $africa)) {
|
| 57 |
+
$catObj = $model->load(Productiveminds_Core_Helper_Countrycat::CONTINENT_CODE_AFRICA, 'code');
|
| 58 |
+
return $catObj->getCatId();
|
| 59 |
+
} else if(in_array($countryCode, $northAmerica)) {
|
| 60 |
+
$catObj = $model->load(Productiveminds_Core_Helper_Countrycat::CONTINENT_CODE_N_AMERICA, 'code');
|
| 61 |
+
return $catObj->getCatId();
|
| 62 |
+
} else if(in_array($countryCode, $southAmerica)) {
|
| 63 |
+
$catObj = $model->load(Productiveminds_Core_Helper_Countrycat::CONTINENT_CODE_S_AMERICA, 'code');
|
| 64 |
+
return $catObj->getCatId();
|
| 65 |
+
} else if(in_array($countryCode, $asia)) {
|
| 66 |
+
$catObj = $model->load(Productiveminds_Core_Helper_Countrycat::CONTINENT_CODE_ASIA, 'code');
|
| 67 |
+
return $catObj->getCatId();
|
| 68 |
+
} else if(in_array($countryCode, $antarctica)) {
|
| 69 |
+
$catObj = $model->load(Productiveminds_Core_Helper_Countrycat::CONTINENT_CODE_ANTARCTICA, 'code');
|
| 70 |
+
return $catObj->getCatId();
|
| 71 |
+
} else if(in_array($countryCode, $oceania)) {
|
| 72 |
+
$catObj = $model->load(Productiveminds_Core_Helper_Countrycat::CONTINENT_CODE_OCEANIA, 'code');
|
| 73 |
+
return $catObj->getCatId();
|
| 74 |
+
} else {
|
| 75 |
+
// Assign country to Other, if not found
|
| 76 |
+
$catObj = $model->load(Productiveminds_Core_Helper_Countrycat::CONTINENT_CODE_OTHER, 'code');
|
| 77 |
+
return $catObj->getCatId();
|
| 78 |
+
}
|
| 79 |
+
}
|
| 80 |
+
|
| 81 |
+
public static function isEurope() {
|
| 82 |
+
return
|
| 83 |
+
array(
|
| 84 |
+
'AL',// Albania
|
| 85 |
+
'AD',// Andorra
|
| 86 |
+
'AT',// Austria
|
| 87 |
+
'BE',// Belgium
|
| 88 |
+
'BA',// Bosnia and Herzegovina
|
| 89 |
+
'BG',// Bulgaria
|
| 90 |
+
'BY',// Belarus
|
| 91 |
+
'HR',// Croatia
|
| 92 |
+
'CY',// Republic of Cyprus
|
| 93 |
+
'CZ',// Czech Republic
|
| 94 |
+
'DK',// Denmark
|
| 95 |
+
'EE',// Estonia
|
| 96 |
+
'FO',// Faroe Islands
|
| 97 |
+
'FI',// Finland
|
| 98 |
+
'FR',// France
|
| 99 |
+
'DE',// Germany
|
| 100 |
+
'GI',// Gibraltar
|
| 101 |
+
'GR',// Greece
|
| 102 |
+
'GG',// Guernsey
|
| 103 |
+
'HU',// Hungary
|
| 104 |
+
'IS',// Iceland
|
| 105 |
+
'IE',// Ireland
|
| 106 |
+
'IM',// Isle of Man
|
| 107 |
+
'IT',// Italy
|
| 108 |
+
'JE',// Jersey
|
| 109 |
+
'LV',// Latvia
|
| 110 |
+
'LI',// Liechtenstein
|
| 111 |
+
'LT',// Lithuania
|
| 112 |
+
'LU',// Luxembourg
|
| 113 |
+
'MK',// Macedonia
|
| 114 |
+
'MT',// Malta
|
| 115 |
+
'MD',// moldova
|
| 116 |
+
'MC',// Monaco
|
| 117 |
+
'ME',// Montenegro
|
| 118 |
+
'NO',// Norway
|
| 119 |
+
'NL',// Netherlands
|
| 120 |
+
'AN',// Netherlands Antilles
|
| 121 |
+
'PL',// Poland
|
| 122 |
+
'PT',// Portugal
|
| 123 |
+
'RO',// Romania
|
| 124 |
+
'RU',// Russia
|
| 125 |
+
'SM',// San Marino
|
| 126 |
+
'RS',// Serbia
|
| 127 |
+
'SK',// Slovak Republic
|
| 128 |
+
'SI',// Slovenia
|
| 129 |
+
'ES',// Spain
|
| 130 |
+
'SJ',// Svalbard and Jan Mayen
|
| 131 |
+
'SE',// Sweden
|
| 132 |
+
'CH',// Switzerland
|
| 133 |
+
'UA',// Ukraine
|
| 134 |
+
'GB',// Include UK
|
| 135 |
+
'VA',// Vatican City
|
| 136 |
+
'AX',// �land Islands
|
| 137 |
+
);
|
| 138 |
+
}
|
| 139 |
+
|
| 140 |
+
public static function isNorthAmerica() {
|
| 141 |
+
return
|
| 142 |
+
array(
|
| 143 |
+
'AI',// Anguilla
|
| 144 |
+
'AG',// Antigua and Barbuda
|
| 145 |
+
'AW',// Aruba
|
| 146 |
+
'BS',// Bahamas
|
| 147 |
+
'BB',// Barbados
|
| 148 |
+
'BZ',// Belize
|
| 149 |
+
'BM',// Bermuda
|
| 150 |
+
'VG',// British Virgin Islands
|
| 151 |
+
'CA',// Canada
|
| 152 |
+
'KY',// Cayman Islands
|
| 153 |
+
'CR',// Costa Rica
|
| 154 |
+
'CU',// Cuba
|
| 155 |
+
'DM',// Dominica
|
| 156 |
+
'DO',// Dominican Republic
|
| 157 |
+
'EH',// Western Sahara
|
| 158 |
+
'SV',// El Salvador
|
| 159 |
+
'GL',// Greenland
|
| 160 |
+
'GD',// Grenada
|
| 161 |
+
'GP',// Guadeloupe
|
| 162 |
+
'GT',// Guatemala
|
| 163 |
+
'HT',// Haiti
|
| 164 |
+
'HN',// Honduras
|
| 165 |
+
'JM',// Jamaica
|
| 166 |
+
'MQ',// Martinique
|
| 167 |
+
'MX',// Mexico
|
| 168 |
+
'MS',// Montserrat
|
| 169 |
+
'NI',// Nicaragua
|
| 170 |
+
'PA',// Panama
|
| 171 |
+
'PR',// Puerto Rico
|
| 172 |
+
'BL',// Saint Barth�lemy
|
| 173 |
+
'KN',// Saint Kitts and Nevis
|
| 174 |
+
'LC',// Saint Lucia
|
| 175 |
+
'MF',// Saint Martin
|
| 176 |
+
'PM',// Saint Pierre and Miquelon
|
| 177 |
+
'VC',// Saint Vincent and the Grenadines
|
| 178 |
+
'TT',// Trinidad and Tobago
|
| 179 |
+
'TC',// Turks and Caicos Islands
|
| 180 |
+
'UM',// U.S. Minor Outlying Islands
|
| 181 |
+
'VI',// U.S. Virgin Islands
|
| 182 |
+
'US',// United States
|
| 183 |
+
);
|
| 184 |
+
}
|
| 185 |
+
|
| 186 |
+
public static function isAfrica() {
|
| 187 |
+
return
|
| 188 |
+
array(
|
| 189 |
+
'DZ',// Algeria
|
| 190 |
+
'AO',// Angola
|
| 191 |
+
'BJ',// Benin
|
| 192 |
+
'BW',// Botswana
|
| 193 |
+
'BF',// Burkina Faso
|
| 194 |
+
'BI',// Burundi
|
| 195 |
+
'CM',// Cameroon
|
| 196 |
+
'CV',// Cape Verde
|
| 197 |
+
'CF',// Central African Republic
|
| 198 |
+
'TD',// Chad
|
| 199 |
+
'KM',// Comoros
|
| 200 |
+
'CG',// Congo - Brazzaville
|
| 201 |
+
'CD',// Congo - Kinshasa
|
| 202 |
+
'CI',// C�te d�Ivoire
|
| 203 |
+
'DJ',// Djibouti
|
| 204 |
+
'EG',// Egypt
|
| 205 |
+
'GQ',// Equatorial Guinea
|
| 206 |
+
'ER',// Eritrea
|
| 207 |
+
'ET',// Ethiopia
|
| 208 |
+
'GA',// Gabon
|
| 209 |
+
'GM',// Gambia
|
| 210 |
+
'GH',// Ghana
|
| 211 |
+
'GN',// Guinea
|
| 212 |
+
'GW',// Guinea-Bissau
|
| 213 |
+
'KE',// Kenya
|
| 214 |
+
'LS',// Lesotho
|
| 215 |
+
'LR',// Liberia
|
| 216 |
+
'LY',// Libya
|
| 217 |
+
'MG',// Madagascar
|
| 218 |
+
'MW',// Malawi
|
| 219 |
+
'ML',// Mali
|
| 220 |
+
'MR',// Mauritania
|
| 221 |
+
'MU',// Mauritius
|
| 222 |
+
'YT',// Mayotte
|
| 223 |
+
'MA',// Morocco
|
| 224 |
+
'MZ',// Mozambique
|
| 225 |
+
'NA',// Namibia
|
| 226 |
+
'NE',// Niger
|
| 227 |
+
'NG',// Nigeria
|
| 228 |
+
'RW',// Rwanda
|
| 229 |
+
'RE',// R�union
|
| 230 |
+
'SH',// Saint Helena
|
| 231 |
+
'ST',// S�o Tom� and Pr�ncipe
|
| 232 |
+
'SN',// Senegal
|
| 233 |
+
'SC',// Seychelles
|
| 234 |
+
'SL',// Sierra Leone
|
| 235 |
+
'SO',// Somalia
|
| 236 |
+
'ZA',// South Africa
|
| 237 |
+
'SD',// Sudan
|
| 238 |
+
'SZ',// Swaziland
|
| 239 |
+
'TZ',// Tanzania
|
| 240 |
+
'TG',// Togo
|
| 241 |
+
'TN',// Tunisia
|
| 242 |
+
'UG',// Uganda
|
| 243 |
+
'ZM',// Zambia
|
| 244 |
+
'ZW',// Zimbabwe
|
| 245 |
+
);
|
| 246 |
+
}
|
| 247 |
+
|
| 248 |
+
public static function isSouthAmerica() {
|
| 249 |
+
return
|
| 250 |
+
array(
|
| 251 |
+
'AR',// Argentina
|
| 252 |
+
'BO',// Bolivia
|
| 253 |
+
'BR',// Brazil
|
| 254 |
+
'CL',// Chile
|
| 255 |
+
'CO',// Colombia
|
| 256 |
+
'EC',// Ecuador
|
| 257 |
+
'FK',// Falkland Islands
|
| 258 |
+
'GF',// French Guiana
|
| 259 |
+
'GY',// Guyana
|
| 260 |
+
'PY',// Paraguay
|
| 261 |
+
'PE',// Peru
|
| 262 |
+
'GS',// South Georgia and the South Sandwich Islands
|
| 263 |
+
'SR',// Suriname
|
| 264 |
+
'UY',// Uruguay
|
| 265 |
+
'VE',// Venezuela
|
| 266 |
+
);
|
| 267 |
+
}
|
| 268 |
+
|
| 269 |
+
public static function isAsia() {
|
| 270 |
+
return
|
| 271 |
+
array(
|
| 272 |
+
'AF',// Afghanistan
|
| 273 |
+
'AM',// Armenia
|
| 274 |
+
'AZ',// Azerbaijan
|
| 275 |
+
'BH',// Bahrain
|
| 276 |
+
'BD',// Bangladesh
|
| 277 |
+
'BT',// Bhutan
|
| 278 |
+
'IO',// British Indian Ocean Territory
|
| 279 |
+
'BN',// Brunei
|
| 280 |
+
'KH',// Cambodia
|
| 281 |
+
'CN',// China
|
| 282 |
+
'CX',// Christmas Island
|
| 283 |
+
'CC',// Cocos [Keeling] Islands
|
| 284 |
+
'CY',// Cyprus
|
| 285 |
+
'TL',// Timor-Leste
|
| 286 |
+
'GE',// Georgia
|
| 287 |
+
'HK',// Hong Kong SAR China
|
| 288 |
+
'IN',// India
|
| 289 |
+
'ID',// Indonesia
|
| 290 |
+
'IR',// Iran
|
| 291 |
+
'IQ',// Iraq
|
| 292 |
+
'IL',// Israel
|
| 293 |
+
'JP',// Japan
|
| 294 |
+
'JO',// Jordan
|
| 295 |
+
'KZ',// Kazakhstan
|
| 296 |
+
'KW',// Kuwait
|
| 297 |
+
'KG',// Kyrgyzstan
|
| 298 |
+
'LA',// Laos
|
| 299 |
+
'LB',// Lebanon
|
| 300 |
+
'MO',// Macau SAR China
|
| 301 |
+
'MY',// Malaysia
|
| 302 |
+
'MV',// Maldives
|
| 303 |
+
'MN',// Mongolia
|
| 304 |
+
'MM',// Myanmar [Burma]
|
| 305 |
+
'NP',// Nepal
|
| 306 |
+
'KP',// North Korea
|
| 307 |
+
'OM',// Oman
|
| 308 |
+
'PK',// Pakistan
|
| 309 |
+
'PS',// Palestinian Territories
|
| 310 |
+
'PH',// Philippines
|
| 311 |
+
'QA',// Qatar
|
| 312 |
+
'SA',// Saudi Arabia
|
| 313 |
+
'SG',// Singapore
|
| 314 |
+
'KR',// South Korea
|
| 315 |
+
'LK',// Sri Lanka
|
| 316 |
+
'SY',// Syria
|
| 317 |
+
'TW',// Taiwan
|
| 318 |
+
'TJ',// Tajikistan
|
| 319 |
+
'TH',// Thailand
|
| 320 |
+
'TR',// Turkey
|
| 321 |
+
'TM',// Turkmenistan
|
| 322 |
+
'AE',// United Arab Emirates
|
| 323 |
+
'UZ',// Uzbekistan
|
| 324 |
+
'VN',// Vietnam
|
| 325 |
+
'YE',// Yemen
|
| 326 |
+
);
|
| 327 |
+
}
|
| 328 |
+
|
| 329 |
+
public static function isAntarctica() {
|
| 330 |
+
return
|
| 331 |
+
array(
|
| 332 |
+
'AQ',// Antarctica
|
| 333 |
+
'BV',// Bouvet Island
|
| 334 |
+
'HM',// Heard Island and McDonald Islands
|
| 335 |
+
'TF',// French Southern Territories
|
| 336 |
+
);
|
| 337 |
+
}
|
| 338 |
+
|
| 339 |
+
public static function isOceania() {
|
| 340 |
+
return
|
| 341 |
+
array(
|
| 342 |
+
'AS',// American Samoa
|
| 343 |
+
'AU',// Australia
|
| 344 |
+
'CK',// Cook Islands
|
| 345 |
+
'FJ',// Fiji
|
| 346 |
+
'PF',// French Polynesia
|
| 347 |
+
'GU',// Guam
|
| 348 |
+
'KI',// Kiribati
|
| 349 |
+
'MH',// Marshall Islands
|
| 350 |
+
'FM',// Micronesia
|
| 351 |
+
'NR',// Nauru
|
| 352 |
+
'NC',// New Caledonia
|
| 353 |
+
'NZ',// New Zealand
|
| 354 |
+
'NU',// Niue
|
| 355 |
+
'NF',// Norfolk Island
|
| 356 |
+
'MP',// Northern Mariana Islands
|
| 357 |
+
'PW',// Palau
|
| 358 |
+
'PG',// Papua New Guinea
|
| 359 |
+
'PN',// Pitcairn Islands
|
| 360 |
+
'WS',// Samoa
|
| 361 |
+
'SB',// Solomon Islands
|
| 362 |
+
'TK',// Tokelau
|
| 363 |
+
'TO',// Tonga
|
| 364 |
+
'TV',// Tuvalu
|
| 365 |
+
'VU',// Vanuatu
|
| 366 |
+
'WF',// Wallis and Futuna
|
| 367 |
+
);
|
| 368 |
+
}
|
| 369 |
+
|
| 370 |
+
}
|
| 371 |
+
?>
|
app/code/community/Productiveminds/Core/Helper/Data.php
ADDED
|
@@ -0,0 +1,158 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
|
| 3 |
+
/**
|
| 4 |
+
* A Magento module by ProductiveMinds
|
| 5 |
+
*
|
| 6 |
+
* NOTICE OF LICENSE
|
| 7 |
+
*
|
| 8 |
+
* This code is the work and copyright of Productive Minds Ltd, A UK registered company.
|
| 9 |
+
* The copyright owner prohibit any fom of distribution of this code
|
| 10 |
+
*
|
| 11 |
+
* DISCLAIMER
|
| 12 |
+
*
|
| 13 |
+
* You are strongly advised to backup ALL your server files and database before installing and/or configuring
|
| 14 |
+
* this Magento module. ProductiveMinds will not take any form of responsibility for any adverse effects that
|
| 15 |
+
* may be cause directly or indirectly by using this software. As a usual practice with Software deployment,
|
| 16 |
+
* the copyright owner recommended that you first install this software on a test server verify its appropriateness
|
| 17 |
+
* before finally deploying it to a live server.
|
| 18 |
+
*
|
| 19 |
+
* @category Productiveminds
|
| 20 |
+
* @package Productiveminds_Sitesecurity
|
| 21 |
+
* @copyright Copyright (c) 2010 - 2015 Productive Minds Ltd (http://www.productiveminds.com)
|
| 22 |
+
* @license http://www.productiveminds.com/license/license.txt
|
| 23 |
+
* @author ProductiveMinds <info@productiveminds.com>
|
| 24 |
+
*/
|
| 25 |
+
|
| 26 |
+
|
| 27 |
+
class Productiveminds_Core_Helper_Data extends Mage_Core_Helper_Abstract {
|
| 28 |
+
|
| 29 |
+
private $systemInfo = '<table rules="all" border=1 frame="void">';
|
| 30 |
+
|
| 31 |
+
public function isModuleActive($moduleName = null,$enabledLocation=null)
|
| 32 |
+
{
|
| 33 |
+
|
| 34 |
+
if ($moduleName === null) {
|
| 35 |
+
$moduleName = $this->_getModuleName();
|
| 36 |
+
}
|
| 37 |
+
|
| 38 |
+
if (Mage::getConfig()->getNode('modules/'.$moduleName) &&
|
| 39 |
+
Mage::getStoreConfig('productivemindscore_sectns/productivemindscore_grps/enabled', Mage::app()->getStore())
|
| 40 |
+
) {
|
| 41 |
+
return true;
|
| 42 |
+
} else {
|
| 43 |
+
return false;
|
| 44 |
+
}
|
| 45 |
+
return false;
|
| 46 |
+
}
|
| 47 |
+
|
| 48 |
+
// return long from a readable IP address
|
| 49 |
+
public function getIp2long($ip='') {
|
| 50 |
+
// first check IP address is valid
|
| 51 |
+
if(filter_var($ip, FILTER_VALIDATE_IP)) {
|
| 52 |
+
$ip = trim($ip);
|
| 53 |
+
return ip2long($ip);
|
| 54 |
+
}
|
| 55 |
+
return 'invalid IP address';
|
| 56 |
+
}
|
| 57 |
+
|
| 58 |
+
// return a human readable IP address from long
|
| 59 |
+
public function getLong2ip($ip=0) {
|
| 60 |
+
return long2ip(trim($ip));
|
| 61 |
+
}
|
| 62 |
+
|
| 63 |
+
public function systemInfo()
|
| 64 |
+
{
|
| 65 |
+
$this->mageConfig();
|
| 66 |
+
$this->systemConfigs();
|
| 67 |
+
$this->phpExts();
|
| 68 |
+
$this->otherPromindsExts();
|
| 69 |
+
|
| 70 |
+
return $this->getCollatedInfo();
|
| 71 |
+
}
|
| 72 |
+
|
| 73 |
+
private function mageConfig() {
|
| 74 |
+
$this->addTableRow("Magento Details");
|
| 75 |
+
|
| 76 |
+
$this->addTableRow('Version', self::getInstalledMagentoVersion());
|
| 77 |
+
|
| 78 |
+
$compilerConfig = '../includes/config.php';
|
| 79 |
+
if (file_exists($compilerConfig)) {
|
| 80 |
+
include $compilerConfig;
|
| 81 |
+
}
|
| 82 |
+
|
| 83 |
+
$this->addTableRow('Compilation', defined('COMPILER_INCLUDE_PATH') ? 'Enabled' : 'Disabled');
|
| 84 |
+
|
| 85 |
+
$this->addTableRow('Domain', $_SERVER ["HTTP_HOST"]);
|
| 86 |
+
}
|
| 87 |
+
|
| 88 |
+
private function otherPromindsExts() {
|
| 89 |
+
$this->addTableRow("Other ProductiveMinds Extensions");
|
| 90 |
+
|
| 91 |
+
$modules = ( array )Mage::getConfig()->getNode('modules')->children();
|
| 92 |
+
foreach ($modules as $key => $value) {
|
| 93 |
+
if (strpos($key, 'Productiveminds_', 0) !== false) {
|
| 94 |
+
$this->addTableRow("{$key} (v {$value->version})", "{$value->active} ({$value->codePool})");
|
| 95 |
+
}
|
| 96 |
+
}
|
| 97 |
+
}
|
| 98 |
+
|
| 99 |
+
private function systemConfigs() {
|
| 100 |
+
$this->addTableRow("Server and PhP Configs");
|
| 101 |
+
$this->addTableRow('PHP version', phpversion());
|
| 102 |
+
$ini = array(
|
| 103 |
+
'safe_mode',
|
| 104 |
+
'memory_limit',
|
| 105 |
+
'realpath_cache_ttl',
|
| 106 |
+
'allow_url_fopen'
|
| 107 |
+
);
|
| 108 |
+
foreach ($ini as $i) {
|
| 109 |
+
$val = ini_get($i);
|
| 110 |
+
$val = empty ($val) ? 'off' : $val;
|
| 111 |
+
$this->addTableRow($i, $val);
|
| 112 |
+
}
|
| 113 |
+
}
|
| 114 |
+
|
| 115 |
+
private function phpExts() {
|
| 116 |
+
$this->addTableRow("Magento Required Extensions");
|
| 117 |
+
$extensions = array(
|
| 118 |
+
'curl',
|
| 119 |
+
'dom',
|
| 120 |
+
'gd',
|
| 121 |
+
'hash',
|
| 122 |
+
'iconv',
|
| 123 |
+
'mcrypt',
|
| 124 |
+
'pcre',
|
| 125 |
+
'pdo',
|
| 126 |
+
'pdo_mysql',
|
| 127 |
+
'simplexml'
|
| 128 |
+
);
|
| 129 |
+
foreach ($extensions as $extension)
|
| 130 |
+
$this->addTableRow($extension, extension_loaded($extension));
|
| 131 |
+
}
|
| 132 |
+
|
| 133 |
+
private function addTableRow($column1, $column2 = "") {
|
| 134 |
+
if ($column2 === "") {
|
| 135 |
+
$this->systemInfo .= "<tr><td colspan='2'> </td></tr> <tr><td colspan='2'><strong>{$column1}</strong></td></tr>";
|
| 136 |
+
} else {
|
| 137 |
+
$this->systemInfo .= "<tr><td>{$column1}</td><td>{$column2}</td></tr>";
|
| 138 |
+
}
|
| 139 |
+
}
|
| 140 |
+
|
| 141 |
+
private function getCollatedInfo() {
|
| 142 |
+
return ($this->systemInfo .= "<tr><td colspan='2'> </td></tr></table>");
|
| 143 |
+
}
|
| 144 |
+
|
| 145 |
+
public function getInstalledMagentoVersion()
|
| 146 |
+
{
|
| 147 |
+
$version = Mage::getVersion();
|
| 148 |
+
if (!Mage::getConfig()->getModuleConfig('Enterprise_Enterprise')) {
|
| 149 |
+
return $version;
|
| 150 |
+
}
|
| 151 |
+
$info = explode('.', $version);
|
| 152 |
+
$info[1] -= 5;
|
| 153 |
+
$version = implode('.', $info);
|
| 154 |
+
return $version;
|
| 155 |
+
}
|
| 156 |
+
|
| 157 |
+
}
|
| 158 |
+
?>
|
app/code/community/Productiveminds/Core/Model/Email.php
ADDED
|
@@ -0,0 +1,39 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
|
| 3 |
+
class Productiveminds_Core_Model_Email {
|
| 4 |
+
|
| 5 |
+
const PROMINDS_EMAIL = 'support@productiveminds.com';
|
| 6 |
+
const PROMINDS_NAME = 'Prominds Support';
|
| 7 |
+
|
| 8 |
+
public function sendMail($subject, $useremail, $username, $emailBody, $attachments)
|
| 9 |
+
{
|
| 10 |
+
$mail = new Zend_Mail ();
|
| 11 |
+
|
| 12 |
+
$mail->setBodyHtml($emailBody, "UTF-8");
|
| 13 |
+
$mail->setFrom($useremail, $username);
|
| 14 |
+
$mail->addTo(self::PROMINDS_EMAIL, self::PROMINDS_NAME);
|
| 15 |
+
$mail->setSubject($subject);
|
| 16 |
+
|
| 17 |
+
for ($i = 0; $i < count($attachments['name']); $i++) {
|
| 18 |
+
$tmpFilePath = $attachments['tmp_name'] [$i];
|
| 19 |
+
if ($tmpFilePath != "") {
|
| 20 |
+
$newFilePath = "./media/downloadable/" . $attachments['name'] [$i];
|
| 21 |
+
if (move_uploaded_file($tmpFilePath, $newFilePath)) {
|
| 22 |
+
$fileName = $attachments['name'] [$i];
|
| 23 |
+
$attachedItem = new Zend_Mime_Part (file_get_contents($newFilePath));
|
| 24 |
+
$attachedItem->disposition = Zend_Mime::DISPOSITION_INLINE;
|
| 25 |
+
$attachedItem->encoding = Zend_Mime::ENCODING_BASE64;
|
| 26 |
+
$attachedItem->filename = $fileName;
|
| 27 |
+
$mail->addAttachment($attachedItem);
|
| 28 |
+
}
|
| 29 |
+
}
|
| 30 |
+
}
|
| 31 |
+
|
| 32 |
+
try {
|
| 33 |
+
$mail->send();
|
| 34 |
+
Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('productivemindscore')->__('Your ticket was successfully sent - you will be in touch shortly, Many thanks.'));
|
| 35 |
+
} catch (Exception $ex) {
|
| 36 |
+
Mage::getSingleton('core/session')->addError(Mage::helper('productivemindscore')->__($ex->getMessage()));
|
| 37 |
+
}
|
| 38 |
+
}
|
| 39 |
+
}
|
app/code/community/Productiveminds/Core/Model/System/Config/Source/Typeofissue.php
ADDED
|
@@ -0,0 +1,33 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
class Productiveminds_Core_Model_System_Config_Source_Typeofissue {
|
| 3 |
+
|
| 4 |
+
public function toOptionArray()
|
| 5 |
+
{
|
| 6 |
+
$types = array(
|
| 7 |
+
array(
|
| 8 |
+
'value' => false,
|
| 9 |
+
'label' => "Choose a type"
|
| 10 |
+
),
|
| 11 |
+
array(
|
| 12 |
+
'value' => "NewFeature",
|
| 13 |
+
'label' => "Request a New or Custom Feature"
|
| 14 |
+
)
|
| 15 |
+
);
|
| 16 |
+
|
| 17 |
+
$extensions = ( array )Mage::getConfig()->getNode('modules')->children();
|
| 18 |
+
$promindsExtensions = array();
|
| 19 |
+
|
| 20 |
+
foreach ($extensions as $key => $value)
|
| 21 |
+
if (strpos($key, 'Productiveminds_', 0) !== false && $key != 'Productiveminds_Core')
|
| 22 |
+
$promindsExtensions [] = array(
|
| 23 |
+
'value' => $key,
|
| 24 |
+
'label' => $key
|
| 25 |
+
);
|
| 26 |
+
$types [] = array(
|
| 27 |
+
'value' => $promindsExtensions,
|
| 28 |
+
'label' => 'Productiveminds Extensions'
|
| 29 |
+
);
|
| 30 |
+
|
| 31 |
+
return $types;
|
| 32 |
+
}
|
| 33 |
+
}
|
app/code/community/Productiveminds/Core/controllers/Adminhtml/IndexController.php
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
|
| 3 |
+
class Productiveminds_Core_Adminhtml_IndexController extends Mage_Adminhtml_Controller_Action
|
| 4 |
+
{
|
| 5 |
+
|
| 6 |
+
protected function _initAction() {
|
| 7 |
+
$this->loadLayout()->_setActiveMenu('productiveminds');
|
| 8 |
+
$this->_title('Productiveminds Core');
|
| 9 |
+
return $this;
|
| 10 |
+
}
|
| 11 |
+
|
| 12 |
+
protected function _isAllowed() {
|
| 13 |
+
return true;
|
| 14 |
+
}
|
| 15 |
+
|
| 16 |
+
public function indexAction() {
|
| 17 |
+
$this->loadLayout();
|
| 18 |
+
$this->_initAction();
|
| 19 |
+
$this->renderLayout();
|
| 20 |
+
}
|
| 21 |
+
|
| 22 |
+
}
|
app/code/community/Productiveminds/Core/controllers/Adminhtml/SupportController.php
ADDED
|
@@ -0,0 +1,54 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
class Productiveminds_Core_Adminhtml_SupportController extends Mage_Adminhtml_Controller_Action
|
| 3 |
+
{
|
| 4 |
+
protected function _initAction() {
|
| 5 |
+
$this->loadLayout()
|
| 6 |
+
->_setActiveMenu('productiveminds')
|
| 7 |
+
->_title($this->__('Productiveminds Support'));
|
| 8 |
+
|
| 9 |
+
$this->_addBreadcrumb(Mage::helper('productivemindscore')->__('Productiveminds Support'),
|
| 10 |
+
Mage::helper('productivemindscore')->__('Productiveminds Support'));
|
| 11 |
+
|
| 12 |
+
return $this;
|
| 13 |
+
}
|
| 14 |
+
|
| 15 |
+
protected function _isAllowed() {
|
| 16 |
+
return true;
|
| 17 |
+
}
|
| 18 |
+
|
| 19 |
+
|
| 20 |
+
public function indexAction()
|
| 21 |
+
{
|
| 22 |
+
$this->loadLayout()
|
| 23 |
+
->_setActiveMenu('productiveminds')
|
| 24 |
+
->_title($this->__('Productiveminds Support'));
|
| 25 |
+
|
| 26 |
+
$this->_addBreadcrumb(Mage::helper('productivemindscore')->__('Productiveminds Support'),
|
| 27 |
+
Mage::helper('productivemindscore')->__('Productiveminds Support'));
|
| 28 |
+
$this->renderLayout();
|
| 29 |
+
}
|
| 30 |
+
|
| 31 |
+
public function newAction()
|
| 32 |
+
{
|
| 33 |
+
$this->loadLayout();
|
| 34 |
+
$this->_initAction();
|
| 35 |
+
$this->_title('Create new Ticket');
|
| 36 |
+
$this->getLayout()->getBlock('head')->setCanLoadExtJs(true);
|
| 37 |
+
$this->_addContent($this->getLayout()->createBlock('productivemindscore/adminhtml_support_edit'))
|
| 38 |
+
->_addLeft($this->getLayout()->createBlock('productivemindscore/adminhtml_support_edit_tabs'));
|
| 39 |
+
$this->renderLayout();
|
| 40 |
+
}
|
| 41 |
+
|
| 42 |
+
public function saveAction()
|
| 43 |
+
{
|
| 44 |
+
$subject = 'Customer ticket for: '.$this->getRequest()->getParam('typeofissue', false);
|
| 45 |
+
$message = $this->getRequest()->getParam('message', false);
|
| 46 |
+
$systeminfo = $this->getRequest()->getParam('systeminfo', false);
|
| 47 |
+
$username = $this->getRequest()->getParam('username', false);
|
| 48 |
+
$useremail = $this->getRequest()->getParam('useremail', false);
|
| 49 |
+
$emailBody = "<p>{$subject}</p> <p>{$message}</p> <p>{$systeminfo}</p> <br/> <p>Productiveminds Support</p><br/><br/>";
|
| 50 |
+
|
| 51 |
+
Mage::getModel('productivemindscore/email')->sendMail($subject, $useremail, $username, $emailBody, $_FILES['attachments']);
|
| 52 |
+
$this->getResponse()->setRedirect($this->getUrl("*/*/"));
|
| 53 |
+
}
|
| 54 |
+
}
|
app/code/community/Productiveminds/Core/etc/adminhtml.xml
ADDED
|
@@ -0,0 +1,67 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0" encoding="UTF-8"?>
|
| 2 |
+
<config>
|
| 3 |
+
<menu>
|
| 4 |
+
<productiveminds translate="title" module="productivemindscore">
|
| 5 |
+
<title>Productiveminds</title>
|
| 6 |
+
<sort_order>90</sort_order>
|
| 7 |
+
<depends>
|
| 8 |
+
<module>Productiveminds_Core</module>
|
| 9 |
+
</depends>
|
| 10 |
+
<children>
|
| 11 |
+
<productivemindscore module="productivemindscore">
|
| 12 |
+
<title>Core</title>
|
| 13 |
+
<sort_order>10</sort_order>
|
| 14 |
+
<children>
|
| 15 |
+
<support translate="title" module="productivemindscore">
|
| 16 |
+
<title>Create a Support Ticket</title>
|
| 17 |
+
<sort_order>10</sort_order>
|
| 18 |
+
<action>productivemindscore_admin/adminhtml_support/new</action>
|
| 19 |
+
</support>
|
| 20 |
+
<settings translate="title" module="productivemindscore">
|
| 21 |
+
<title>Settings and Contact Info</title>
|
| 22 |
+
<sort_order>20</sort_order>
|
| 23 |
+
<action>adminhtml/system_config/edit/section/productivemindscore_sectns</action>
|
| 24 |
+
</settings>
|
| 25 |
+
</children>
|
| 26 |
+
</productivemindscore>
|
| 27 |
+
</children>
|
| 28 |
+
</productiveminds>
|
| 29 |
+
</menu>
|
| 30 |
+
<acl>
|
| 31 |
+
<resources>
|
| 32 |
+
<admin>
|
| 33 |
+
<children>
|
| 34 |
+
<productiveminds translate="title" module="productivemindscore">
|
| 35 |
+
<title>Productiveminds</title>
|
| 36 |
+
<sort_order>80</sort_order>
|
| 37 |
+
<children>
|
| 38 |
+
<productivemindscore module="productivemindscore">
|
| 39 |
+
<title>Core</title>
|
| 40 |
+
<sort_order>10</sort_order>
|
| 41 |
+
<children>
|
| 42 |
+
<support translate="title">
|
| 43 |
+
<title>Create a Support Ticket</title>
|
| 44 |
+
</support>
|
| 45 |
+
<settings translate="title">
|
| 46 |
+
<title>Settings and Contact Info</title>
|
| 47 |
+
</settings>
|
| 48 |
+
</children>
|
| 49 |
+
</productivemindscore>
|
| 50 |
+
</children>
|
| 51 |
+
</productiveminds>
|
| 52 |
+
<system>
|
| 53 |
+
<children>
|
| 54 |
+
<config>
|
| 55 |
+
<children>
|
| 56 |
+
<productivemindscore_sectns translate="title" module="productivemindscore">
|
| 57 |
+
<title>Productiveminds Core</title>
|
| 58 |
+
</productivemindscore_sectns>
|
| 59 |
+
</children>
|
| 60 |
+
</config>
|
| 61 |
+
</children>
|
| 62 |
+
</system>
|
| 63 |
+
</children>
|
| 64 |
+
</admin>
|
| 65 |
+
</resources>
|
| 66 |
+
</acl>
|
| 67 |
+
</config>
|
app/code/community/Productiveminds/Core/etc/config.xml
ADDED
|
@@ -0,0 +1,54 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0" encoding="UTF-8"?>
|
| 2 |
+
<config>
|
| 3 |
+
<modules>
|
| 4 |
+
<Productiveminds_Core>
|
| 5 |
+
<version>0.2.6</version>
|
| 6 |
+
</Productiveminds_Core>
|
| 7 |
+
</modules>
|
| 8 |
+
<adminhtml>
|
| 9 |
+
<layout>
|
| 10 |
+
<updates>
|
| 11 |
+
<productivemindscore>
|
| 12 |
+
<file>productiveminds/core.xml</file>
|
| 13 |
+
</productivemindscore>
|
| 14 |
+
</updates>
|
| 15 |
+
</layout>
|
| 16 |
+
</adminhtml>
|
| 17 |
+
<admin>
|
| 18 |
+
<routers>
|
| 19 |
+
<productivemindscore_admin>
|
| 20 |
+
<use>admin</use>
|
| 21 |
+
<args>
|
| 22 |
+
<module>Productiveminds_Core</module>
|
| 23 |
+
<frontName>productivemindscore_admin</frontName>
|
| 24 |
+
</args>
|
| 25 |
+
</productivemindscore_admin>
|
| 26 |
+
</routers>
|
| 27 |
+
</admin>
|
| 28 |
+
<global>
|
| 29 |
+
<helpers>
|
| 30 |
+
<productivemindscore>
|
| 31 |
+
<class>Productiveminds_Core_Helper</class>
|
| 32 |
+
</productivemindscore>
|
| 33 |
+
</helpers>
|
| 34 |
+
<blocks>
|
| 35 |
+
<productivemindscore>
|
| 36 |
+
<class>Productiveminds_Core_Block</class>
|
| 37 |
+
</productivemindscore>
|
| 38 |
+
</blocks>
|
| 39 |
+
<models>
|
| 40 |
+
<productivemindscore>
|
| 41 |
+
<class>Productiveminds_Core_Model</class>
|
| 42 |
+
</productivemindscore>
|
| 43 |
+
</models>
|
| 44 |
+
</global>
|
| 45 |
+
<default>
|
| 46 |
+
<productivemindscore_sectns>
|
| 47 |
+
<contactus>
|
| 48 |
+
<text>
|
| 49 |
+
<![CDATA[For all enquiries about our modules, feel free to <a href='http://www.productiveminds.com/contacts' onclick='window.open(this.href); return false;'>contact us here</a>.]]>
|
| 50 |
+
</text>
|
| 51 |
+
</contactus>
|
| 52 |
+
</productivemindscore_sectns>
|
| 53 |
+
</default>
|
| 54 |
+
</config>
|
app/code/community/Productiveminds/Core/etc/system.xml
ADDED
|
@@ -0,0 +1,42 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0" encoding="UTF-8"?>
|
| 2 |
+
<config>
|
| 3 |
+
<tabs>
|
| 4 |
+
<productive_minds translate="label" module="productivemindscore">
|
| 5 |
+
<label>Productiveminds-Modules</label>
|
| 6 |
+
<sort_order>188</sort_order>
|
| 7 |
+
</productive_minds>
|
| 8 |
+
</tabs>
|
| 9 |
+
<sections>
|
| 10 |
+
<productivemindscore_sectns translate="label" module="productivemindscore">
|
| 11 |
+
<label>Productiveminds Core</label>
|
| 12 |
+
<tab>productive_minds</tab>
|
| 13 |
+
<frontend_type>text</frontend_type>
|
| 14 |
+
<sort_order>10</sort_order>
|
| 15 |
+
<show_in_default>1</show_in_default>
|
| 16 |
+
<show_in_website>1</show_in_website>
|
| 17 |
+
<show_in_store>1</show_in_store>
|
| 18 |
+
<groups>
|
| 19 |
+
<contactus translate="label" module="productivemindscore">
|
| 20 |
+
<label>Productiveminds Contact Information</label>
|
| 21 |
+
<frontend_type>text</frontend_type>
|
| 22 |
+
<frontend_model>productivemindscore/adminhtml_system_config_form_fieldset_contactus</frontend_model>
|
| 23 |
+
<sort_order>10</sort_order>
|
| 24 |
+
<show_in_default>1</show_in_default>
|
| 25 |
+
<show_in_website>1</show_in_website>
|
| 26 |
+
<show_in_store>1</show_in_store>
|
| 27 |
+
<expanded>1</expanded>
|
| 28 |
+
</contactus>
|
| 29 |
+
<extensions translate="label" module="productivemindscore">
|
| 30 |
+
<label>Installed Productiveminds Extensions</label>
|
| 31 |
+
<frontend_type>text</frontend_type>
|
| 32 |
+
<frontend_model>productivemindscore/adminhtml_system_config_form_fieldset_promindsextensions_item</frontend_model>
|
| 33 |
+
<sort_order>20</sort_order>
|
| 34 |
+
<show_in_default>1</show_in_default>
|
| 35 |
+
<show_in_website>0</show_in_website>
|
| 36 |
+
<show_in_store>0</show_in_store>
|
| 37 |
+
<expanded>1</expanded>
|
| 38 |
+
</extensions>
|
| 39 |
+
</groups>
|
| 40 |
+
</productivemindscore_sectns>
|
| 41 |
+
</sections>
|
| 42 |
+
</config>
|
app/code/local/Productiveminds/Contactus/Block/Activate.php
ADDED
|
@@ -0,0 +1,49 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Magento
|
| 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 |
+
* 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 Mage
|
| 22 |
+
* @package Mage_Core
|
| 23 |
+
* @copyright Copyright (c) 2012 Magento Inc. (http://www.magentocommerce.com)
|
| 24 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 25 |
+
*/
|
| 26 |
+
|
| 27 |
+
/**
|
| 28 |
+
* Messages block
|
| 29 |
+
*
|
| 30 |
+
* @category Mage
|
| 31 |
+
* @package Mage_Core
|
| 32 |
+
* @author Magento Core Team <core@magentocommerce.com>
|
| 33 |
+
*/
|
| 34 |
+
class Productiveminds_Contactus_Block_Activate extends Mage_Core_Block_Template
|
| 35 |
+
{
|
| 36 |
+
public function activateMessage() {
|
| 37 |
+
$activateMessage = Mage::getSingleton('core/session', array('name' => 'frontend'))->getActivateMessage();
|
| 38 |
+
Mage::getSingleton('core/session', array('name' => 'frontend'))->unsActivateMessage('');
|
| 39 |
+
|
| 40 |
+
return $activateMessage;
|
| 41 |
+
}
|
| 42 |
+
|
| 43 |
+
public function useFormKey() {
|
| 44 |
+
if (version_compare(Mage::helper('productivemindscore')->getInstalledMagentoVersion(), '1.8.0.0') >= 0) {
|
| 45 |
+
return true;
|
| 46 |
+
}
|
| 47 |
+
return false;
|
| 48 |
+
}
|
| 49 |
+
}
|
app/code/local/Productiveminds/Contactus/Helper/Data.php
ADDED
|
@@ -0,0 +1,48 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Magento
|
| 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@magento.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.magento.com for more information.
|
| 20 |
+
*
|
| 21 |
+
* @category Mage
|
| 22 |
+
* @package Mage_Admin
|
| 23 |
+
* @copyright Copyright (c) 2006-2015 X.commerce, Inc. (http://www.magento.com)
|
| 24 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 25 |
+
*/
|
| 26 |
+
|
| 27 |
+
class Productiveminds_Contactus_Helper_Data extends Mage_Core_Helper_Abstract
|
| 28 |
+
{
|
| 29 |
+
|
| 30 |
+
public function isModuleActive($moduleName = null,$enabledLocation=null)
|
| 31 |
+
{
|
| 32 |
+
|
| 33 |
+
if ($moduleName === null) {
|
| 34 |
+
$moduleName = $this->_getModuleName();
|
| 35 |
+
}
|
| 36 |
+
|
| 37 |
+
if (Mage::getConfig()->getNode('modules/'.$moduleName) &&
|
| 38 |
+
Mage::getStoreConfig('contactus_sectns/contactus_grps/enabled', Mage::app()->getStore())
|
| 39 |
+
) {
|
| 40 |
+
return true;
|
| 41 |
+
} else {
|
| 42 |
+
return false;
|
| 43 |
+
}
|
| 44 |
+
return false;
|
| 45 |
+
}
|
| 46 |
+
|
| 47 |
+
}
|
| 48 |
+
?>
|
app/code/local/Productiveminds/Contactus/controllers/IndexController.php
ADDED
|
@@ -0,0 +1,157 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Magento
|
| 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@magento.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.magento.com for more information.
|
| 20 |
+
*
|
| 21 |
+
* @category Mage
|
| 22 |
+
* @package Mage_Admin
|
| 23 |
+
* @copyright Copyright (c) 2006-2015 X.commerce, Inc. (http://www.magento.com)
|
| 24 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 25 |
+
*/
|
| 26 |
+
|
| 27 |
+
require_once 'Mage/Contacts/controllers/IndexController.php';
|
| 28 |
+
class Productiveminds_Contactus_IndexController extends Mage_Contacts_IndexController
|
| 29 |
+
{
|
| 30 |
+
|
| 31 |
+
const XML_PATH_ENABLED = 'contactus_sectns/contactus_grps/enabled';
|
| 32 |
+
const XML_PATH_EMAIL_RECIPIENT = 'contactus_sectns/contactus_grps/email_recipient';
|
| 33 |
+
const XML_PATH_EMAIL_SENDER = 'contactus_sectns/contactus_grps/email_sender';
|
| 34 |
+
const XML_PATH_EMAIL_TEMPLATE = 'contactus_sectns/contactus_grps/email_template';
|
| 35 |
+
|
| 36 |
+
public function preDispatch() {
|
| 37 |
+
parent::preDispatch();
|
| 38 |
+
if( !Mage::getStoreConfigFlag(self::XML_PATH_ENABLED, Mage::app()->getStore()) ) {
|
| 39 |
+
//$this->norouteAction();
|
| 40 |
+
Mage::getSingleton('customer/session')->addError(Mage::helper('contacts')->__('The Productiveminds Contact us module is disabled. Please enable it (in admin) to continue'));
|
| 41 |
+
}
|
| 42 |
+
}
|
| 43 |
+
|
| 44 |
+
public function indexAction() {
|
| 45 |
+
$this->loadLayout();
|
| 46 |
+
|
| 47 |
+
$currentModule = $this->getRequest()->getModuleName();
|
| 48 |
+
if($currentModule == 'contacts') {
|
| 49 |
+
$this->getLayout()->getBlock('contactsForm')->setFormAction(Mage::getUrl('*/*/post'));
|
| 50 |
+
} else if($currentModule == 'contactus') {
|
| 51 |
+
$this->getLayout()->getBlock('contactusForm')->setFormAction(Mage::getUrl('*/*/post'));
|
| 52 |
+
}
|
| 53 |
+
$this->_initLayoutMessages('customer/session');
|
| 54 |
+
$this->_initLayoutMessages('catalog/session');
|
| 55 |
+
$this->renderLayout();
|
| 56 |
+
}
|
| 57 |
+
|
| 58 |
+
public function postAction() {
|
| 59 |
+
$post = $this->getRequest()->getPost();
|
| 60 |
+
if ( $post ) {
|
| 61 |
+
|
| 62 |
+
$is_not_spam = false;
|
| 63 |
+
if(empty($post['city']) || $post['city'] == '') {
|
| 64 |
+
$is_not_spam = true;
|
| 65 |
+
}
|
| 66 |
+
// Added by Sola: Now check if user fills the unrequired field
|
| 67 |
+
if($is_not_spam) {
|
| 68 |
+
$translate = Mage::getSingleton('core/translate');
|
| 69 |
+
/* @var $translate Mage_Core_Model_Translate */
|
| 70 |
+
$translate->setTranslateInline(false);
|
| 71 |
+
try {
|
| 72 |
+
$postObject = new Varien_Object();
|
| 73 |
+
$postObject->setData($post);
|
| 74 |
+
|
| 75 |
+
$error = false;
|
| 76 |
+
|
| 77 |
+
if (!Zend_Validate::is(trim($post['name']) , 'NotEmpty')) {
|
| 78 |
+
$error = true;
|
| 79 |
+
}
|
| 80 |
+
|
| 81 |
+
if (!Zend_Validate::is(trim($post['comment']) , 'NotEmpty')) {
|
| 82 |
+
$error = true;
|
| 83 |
+
}
|
| 84 |
+
|
| 85 |
+
if (!Zend_Validate::is(trim($post['email']), 'EmailAddress')) {
|
| 86 |
+
$error = true;
|
| 87 |
+
}
|
| 88 |
+
|
| 89 |
+
if (Zend_Validate::is(trim($post['hideit']), 'NotEmpty')) {
|
| 90 |
+
$error = true;
|
| 91 |
+
}
|
| 92 |
+
|
| 93 |
+
if ($error) {
|
| 94 |
+
throw new Exception();
|
| 95 |
+
}
|
| 96 |
+
|
| 97 |
+
if (version_compare(Mage::helper('productivemindscore')->getInstalledMagentoVersion(), '1.8.0.0') >= 0) {
|
| 98 |
+
if (!$this->_validateFormKey()) {
|
| 99 |
+
Mage::getSingleton('customer/session')->addError(Mage::helper('contacts')->__('Please refresh the page - invalid security form key.'));
|
| 100 |
+
$this->_redirect('*/*/');
|
| 101 |
+
return;
|
| 102 |
+
}
|
| 103 |
+
}
|
| 104 |
+
|
| 105 |
+
$mailTemplate = Mage::getModel('core/email_template');
|
| 106 |
+
|
| 107 |
+
$store = Mage::app()->getStore();
|
| 108 |
+
$senderEmailId = Mage::getStoreConfig(self::XML_PATH_EMAIL_SENDER, $store);
|
| 109 |
+
$recipientEmailId = Mage::getStoreConfig(self::XML_PATH_EMAIL_RECIPIENT, $store);
|
| 110 |
+
$emailTemplate = Mage::getStoreConfig(self::XML_PATH_EMAIL_TEMPLATE, $store);
|
| 111 |
+
|
| 112 |
+
if (empty($recipientEmailId) || $recipientEmailId == '') {
|
| 113 |
+
Mage::getSingleton('customer/session')->addError(Mage::helper('contacts')->__('Email address is missing - see module configuration in Magento admin.'));
|
| 114 |
+
$this->_redirect('*/*/');
|
| 115 |
+
return;
|
| 116 |
+
}
|
| 117 |
+
|
| 118 |
+
if (empty($emailTemplate) || $emailTemplate == '') {
|
| 119 |
+
Mage::getSingleton('customer/session')->addError(Mage::helper('contacts')->__('Email template is missing - see module configuration in Magento admin.'));
|
| 120 |
+
$this->_redirect('*/*/');
|
| 121 |
+
return;
|
| 122 |
+
}
|
| 123 |
+
|
| 124 |
+
$recipientEmailId = str_replace(' ', '', $recipientEmailId);
|
| 125 |
+
$recipientEmailId = explode(',', $recipientEmailId);
|
| 126 |
+
|
| 127 |
+
$mailTemplate->setDesignConfig(array('area' => 'frontend'))
|
| 128 |
+
->setReplyTo($post['email'])
|
| 129 |
+
->sendTransactional($emailTemplate, $senderEmailId, $recipientEmailId, null, array('data' => $postObject)
|
| 130 |
+
);
|
| 131 |
+
|
| 132 |
+
if (!$mailTemplate->getSentSuccess()) {
|
| 133 |
+
throw new Exception();
|
| 134 |
+
}
|
| 135 |
+
|
| 136 |
+
$translate->setTranslateInline(true);
|
| 137 |
+
|
| 138 |
+
$confirmationMessage = Mage::getStoreConfig('contactus_sectns/contactus_grps/confirmation_message', $store);
|
| 139 |
+
Mage::getSingleton('customer/session')->addSuccess(Mage::helper('contacts')->__($confirmationMessage));
|
| 140 |
+
$this->_redirect('*/*/');
|
| 141 |
+
return;
|
| 142 |
+
|
| 143 |
+
} catch (Exception $e) {
|
| 144 |
+
$translate->setTranslateInline(true);
|
| 145 |
+
Mage::getSingleton('customer/session')->addError(Mage::helper('contacts')->__('Unable to submit your request. Please, try again later'));
|
| 146 |
+
$this->_redirect('*/*/');
|
| 147 |
+
return;
|
| 148 |
+
}
|
| 149 |
+
} else {
|
| 150 |
+
$this->_redirect('*/*/');
|
| 151 |
+
}
|
| 152 |
+
|
| 153 |
+
} else {
|
| 154 |
+
$this->_redirect('*/*/');
|
| 155 |
+
}
|
| 156 |
+
}
|
| 157 |
+
}
|
app/code/local/Productiveminds/Contactus/etc/adminhtml.xml
ADDED
|
@@ -0,0 +1,39 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0" encoding="UTF-8"?>
|
| 2 |
+
<config>
|
| 3 |
+
<menu>
|
| 4 |
+
<productiveminds translate="title" module="contactus">
|
| 5 |
+
<children>
|
| 6 |
+
<contactus module="contactus">
|
| 7 |
+
<title>Contact us</title>
|
| 8 |
+
<sort_order>50</sort_order>
|
| 9 |
+
<children>
|
| 10 |
+
<settings translate="title" module="contactus">
|
| 11 |
+
<title>Settings</title>
|
| 12 |
+
<sort_order>10</sort_order>
|
| 13 |
+
<action>adminhtml/system_config/edit/section/contactus_sectns</action>
|
| 14 |
+
</settings>
|
| 15 |
+
</children>
|
| 16 |
+
</contactus>
|
| 17 |
+
</children>
|
| 18 |
+
</productiveminds>
|
| 19 |
+
</menu>
|
| 20 |
+
<acl>
|
| 21 |
+
<resources>
|
| 22 |
+
<admin>
|
| 23 |
+
<children>
|
| 24 |
+
<system>
|
| 25 |
+
<children>
|
| 26 |
+
<config>
|
| 27 |
+
<children>
|
| 28 |
+
<contactus_sectns translate="title" module="contactus">
|
| 29 |
+
<title>Productiveminds Contactus</title>
|
| 30 |
+
</contactus_sectns>
|
| 31 |
+
</children>
|
| 32 |
+
</config>
|
| 33 |
+
</children>
|
| 34 |
+
</system>
|
| 35 |
+
</children>
|
| 36 |
+
</admin>
|
| 37 |
+
</resources>
|
| 38 |
+
</acl>
|
| 39 |
+
</config>
|
app/code/local/Productiveminds/Contactus/etc/config.xml
ADDED
|
@@ -0,0 +1,65 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0" encoding="UTF-8"?>
|
| 2 |
+
<config>
|
| 3 |
+
<modules>
|
| 4 |
+
<Productiveminds_Contactus>
|
| 5 |
+
<version>0.1.4</version>
|
| 6 |
+
</Productiveminds_Contactus>
|
| 7 |
+
</modules>
|
| 8 |
+
<frontend>
|
| 9 |
+
<layout>
|
| 10 |
+
<updates>
|
| 11 |
+
<contactus>
|
| 12 |
+
<file>productiveminds/contactus.xml</file>
|
| 13 |
+
</contactus>
|
| 14 |
+
</updates>
|
| 15 |
+
</layout>
|
| 16 |
+
<routers>
|
| 17 |
+
<contactus>
|
| 18 |
+
<use>standard</use>
|
| 19 |
+
<args>
|
| 20 |
+
<module>Productiveminds_Contactus</module>
|
| 21 |
+
<frontName>contactus</frontName>
|
| 22 |
+
</args>
|
| 23 |
+
</contactus>
|
| 24 |
+
</routers>
|
| 25 |
+
</frontend>
|
| 26 |
+
<global>
|
| 27 |
+
<models>
|
| 28 |
+
<contactus>
|
| 29 |
+
<class>Productiveminds_Contactus_Model</class>
|
| 30 |
+
</contactus>
|
| 31 |
+
</models>
|
| 32 |
+
<blocks>
|
| 33 |
+
<contactus>
|
| 34 |
+
<class>Productiveminds_Contactus_Block</class>
|
| 35 |
+
</contactus>
|
| 36 |
+
</blocks>
|
| 37 |
+
<helpers>
|
| 38 |
+
<contactus>
|
| 39 |
+
<class>Productiveminds_Contactus_Helper</class>
|
| 40 |
+
</contactus>
|
| 41 |
+
</helpers>
|
| 42 |
+
<template>
|
| 43 |
+
<email>
|
| 44 |
+
<contactus_sectns_contactus_grps_email_template translate="label" module="contactus">
|
| 45 |
+
<label>ProductiveMinds Contactus Email Template</label>
|
| 46 |
+
<file>productiveminds/contactus.html</file>
|
| 47 |
+
<type>text</type>
|
| 48 |
+
</contactus_sectns_contactus_grps_email_template>
|
| 49 |
+
</email>
|
| 50 |
+
</template>
|
| 51 |
+
</global>
|
| 52 |
+
<default>
|
| 53 |
+
<contactus_sectns>
|
| 54 |
+
<contactus_grps>
|
| 55 |
+
<enabled>1</enabled>
|
| 56 |
+
<confirmation_message>Your inquiry was submitted and will be responded to as soon as possible. Thank you for contacting us.</confirmation_message>
|
| 57 |
+
</contactus_grps>
|
| 58 |
+
<overlay_properties>
|
| 59 |
+
<title>Contact Us</title>
|
| 60 |
+
<width>480</width>
|
| 61 |
+
<height>480</height>
|
| 62 |
+
</overlay_properties>
|
| 63 |
+
</contactus_sectns>
|
| 64 |
+
</default>
|
| 65 |
+
</config>
|
app/code/local/Productiveminds/Contactus/etc/system.xml
ADDED
|
@@ -0,0 +1,117 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0" encoding="UTF-8"?>
|
| 2 |
+
<config>
|
| 3 |
+
<sections>
|
| 4 |
+
<contactus_sectns translate="label" module="contactus">
|
| 5 |
+
<label>Productiveminds Contact Us</label>
|
| 6 |
+
<tab>productive_minds</tab>
|
| 7 |
+
<frontend_type>text</frontend_type>
|
| 8 |
+
<sort_order>50</sort_order>
|
| 9 |
+
<show_in_default>1</show_in_default>
|
| 10 |
+
<show_in_website>1</show_in_website>
|
| 11 |
+
<show_in_store>1</show_in_store>
|
| 12 |
+
<groups>
|
| 13 |
+
<contactus_grps translate="label">
|
| 14 |
+
<label>Productiveminds Contact Us</label>
|
| 15 |
+
<frontend_type>text</frontend_type>
|
| 16 |
+
<sort_order>10</sort_order>
|
| 17 |
+
<show_in_default>1</show_in_default>
|
| 18 |
+
<show_in_website>1</show_in_website>
|
| 19 |
+
<show_in_store>1</show_in_store>
|
| 20 |
+
<fields>
|
| 21 |
+
<enabled>
|
| 22 |
+
<label>Enabled</label>
|
| 23 |
+
<frontend_type>select</frontend_type>
|
| 24 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
| 25 |
+
<sort_order>10</sort_order>
|
| 26 |
+
<show_in_default>1</show_in_default>
|
| 27 |
+
<show_in_website>1</show_in_website>
|
| 28 |
+
<show_in_store>1</show_in_store>
|
| 29 |
+
</enabled>
|
| 30 |
+
<confirmation_message>
|
| 31 |
+
<label>Confirmation Message</label>
|
| 32 |
+
<frontend_type>textarea</frontend_type>
|
| 33 |
+
<sort_order>30</sort_order>
|
| 34 |
+
<show_in_default>1</show_in_default>
|
| 35 |
+
<show_in_website>1</show_in_website>
|
| 36 |
+
<show_in_store>1</show_in_store>
|
| 37 |
+
<comment>
|
| 38 |
+
<![CDATA[The confirmation message.]]>
|
| 39 |
+
</comment>
|
| 40 |
+
</confirmation_message>
|
| 41 |
+
<email_recipient translate="label comment">
|
| 42 |
+
<label>Email Recipient(s)</label>
|
| 43 |
+
<comment><![CDATA[Separate multiple with a comma ',' - e.g: one@example.com, two@example.com]]></comment>
|
| 44 |
+
<frontend_type>text</frontend_type>
|
| 45 |
+
<sort_order>60</sort_order>
|
| 46 |
+
<show_in_default>1</show_in_default>
|
| 47 |
+
<show_in_website>1</show_in_website>
|
| 48 |
+
<show_in_store>1</show_in_store>
|
| 49 |
+
</email_recipient>
|
| 50 |
+
<email_template translate="label">
|
| 51 |
+
<label>Email Template</label>
|
| 52 |
+
<frontend_type>select</frontend_type>
|
| 53 |
+
<source_model>adminhtml/system_config_source_email_template</source_model>
|
| 54 |
+
<sort_order>70</sort_order>
|
| 55 |
+
<show_in_default>1</show_in_default>
|
| 56 |
+
<show_in_website>1</show_in_website>
|
| 57 |
+
<show_in_store>1</show_in_store>
|
| 58 |
+
</email_template>
|
| 59 |
+
<email_sender translate="label">
|
| 60 |
+
<label>Email Sender</label>
|
| 61 |
+
<frontend_type>select</frontend_type>
|
| 62 |
+
<source_model>adminhtml/system_config_source_email_identity</source_model>
|
| 63 |
+
<sort_order>80</sort_order>
|
| 64 |
+
<show_in_default>1</show_in_default>
|
| 65 |
+
<show_in_website>1</show_in_website>
|
| 66 |
+
<show_in_store>1</show_in_store>
|
| 67 |
+
</email_sender>
|
| 68 |
+
</fields>
|
| 69 |
+
</contactus_grps>
|
| 70 |
+
<overlay_properties translate="label">
|
| 71 |
+
<label>Overlay Properties</label>
|
| 72 |
+
<frontend_type>text</frontend_type>
|
| 73 |
+
<sort_order>20</sort_order>
|
| 74 |
+
<show_in_default>1</show_in_default>
|
| 75 |
+
<show_in_website>1</show_in_website>
|
| 76 |
+
<show_in_store>1</show_in_store>
|
| 77 |
+
<expanded>1</expanded>
|
| 78 |
+
<fields>
|
| 79 |
+
<title>
|
| 80 |
+
<label>Overlay Title</label>
|
| 81 |
+
<frontend_type>text</frontend_type>
|
| 82 |
+
<sort_order>20</sort_order>
|
| 83 |
+
<show_in_default>1</show_in_default>
|
| 84 |
+
<show_in_website>1</show_in_website>
|
| 85 |
+
<show_in_store>1</show_in_store>
|
| 86 |
+
<comment>
|
| 87 |
+
<![CDATA[Title for the overlay.]]>
|
| 88 |
+
</comment>
|
| 89 |
+
</title>
|
| 90 |
+
<width>
|
| 91 |
+
<label>Overlay Width</label>
|
| 92 |
+
<frontend_type>text</frontend_type>
|
| 93 |
+
<sort_order>30</sort_order>
|
| 94 |
+
<show_in_default>1</show_in_default>
|
| 95 |
+
<show_in_website>1</show_in_website>
|
| 96 |
+
<show_in_store>1</show_in_store>
|
| 97 |
+
<comment>
|
| 98 |
+
<![CDATA[Width for the overlay.]]>
|
| 99 |
+
</comment>
|
| 100 |
+
</width>
|
| 101 |
+
<height>
|
| 102 |
+
<label>Overlay Height</label>
|
| 103 |
+
<frontend_type>text</frontend_type>
|
| 104 |
+
<sort_order>40</sort_order>
|
| 105 |
+
<show_in_default>1</show_in_default>
|
| 106 |
+
<show_in_website>1</show_in_website>
|
| 107 |
+
<show_in_store>1</show_in_store>
|
| 108 |
+
<comment>
|
| 109 |
+
<![CDATA[Height for the overlay.]]>
|
| 110 |
+
</comment>
|
| 111 |
+
</height>
|
| 112 |
+
</fields>
|
| 113 |
+
</overlay_properties>
|
| 114 |
+
</groups>
|
| 115 |
+
</contactus_sectns>
|
| 116 |
+
</sections>
|
| 117 |
+
</config>
|
app/design/adminhtml/default/default/layout/productiveminds/core.xml
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0" encoding="UTF-8"?>
|
| 2 |
+
<layout>
|
| 3 |
+
<default/>
|
| 4 |
+
<productivemindscore_admin_adminhtml_support_new>
|
| 5 |
+
<reference name="messages">
|
| 6 |
+
<action method="addNotice" translate="message">
|
| 7 |
+
<message>
|
| 8 |
+
The support ticket will be sent to the ProductiveMinds support - support@productiveminds.com.
|
| 9 |
+
Please provide detailed information to help us understand the problems you are experiencing or the request.
|
| 10 |
+
This email will enclose your system configurations such as Magento details and application server -
|
| 11 |
+
these details will help speed up our diagnosis of your system, hence a quick response.
|
| 12 |
+
</message>
|
| 13 |
+
</action>
|
| 14 |
+
</reference>
|
| 15 |
+
</productivemindscore_admin_adminhtml_support_new>
|
| 16 |
+
</layout>
|
app/design/frontend/base/default/layout/productiveminds/contactus.xml
ADDED
|
@@ -0,0 +1,55 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<!--
|
| 3 |
+
/**
|
| 4 |
+
* Magento
|
| 5 |
+
*
|
| 6 |
+
* NOTICE OF LICENSE
|
| 7 |
+
*
|
| 8 |
+
* This source file is subject to the Academic Free License (AFL 3.0)
|
| 9 |
+
* that is bundled with this package in the file LICENSE_AFL.txt.
|
| 10 |
+
* It is also available through the world-wide-web at this URL:
|
| 11 |
+
* http://opensource.org/licenses/afl-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 |
+
* DISCLAIMER
|
| 17 |
+
*
|
| 18 |
+
* Do not edit or add to this file if you wish to upgrade Magento to newer
|
| 19 |
+
* versions in the future. If you wish to customize Magento for your
|
| 20 |
+
* needs please refer to http://www.magentocommerce.com for more information.
|
| 21 |
+
*
|
| 22 |
+
* @category design
|
| 23 |
+
* @package base_default
|
| 24 |
+
* @copyright Copyright (c) 2012 Magento Inc. (http://www.magentocommerce.com)
|
| 25 |
+
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
| 26 |
+
*/
|
| 27 |
+
-->
|
| 28 |
+
<layout version="0.1.0">
|
| 29 |
+
<default>
|
| 30 |
+
<reference name="head">
|
| 31 |
+
<action method="addJs"><script>prototype/window.js</script></action>
|
| 32 |
+
<action method="addCss"><name>productiveminds/contactus/css/contactus.css</name></action>
|
| 33 |
+
</reference>
|
| 34 |
+
<reference name="header">
|
| 35 |
+
<block type="core/template" name="productiveminds_contactus" template="productiveminds/contactus/contactus.phtml"/>
|
| 36 |
+
</reference>
|
| 37 |
+
<reference name="footer">
|
| 38 |
+
<block type="core/template" name="contactusLink" template="productiveminds/contactus/link.phtml"/>
|
| 39 |
+
</reference>
|
| 40 |
+
</default>
|
| 41 |
+
<contactus_index_index translate="label">
|
| 42 |
+
<label>Contact Us Form</label>
|
| 43 |
+
<reference name="root">
|
| 44 |
+
<action method="setTemplate"><template>productiveminds/contactus/overlay.phtml</template></action>
|
| 45 |
+
<action method="setHeaderTitle" translate="title" module="contactus"><title>Contact Us</title></action>
|
| 46 |
+
</reference>
|
| 47 |
+
<reference name="head">
|
| 48 |
+
<action method="addCss"><name>productiveminds/contactus/css/overlay.css</name></action>
|
| 49 |
+
<action method="setTitle" translate="title" module="contactus"><title>Contact Us</title></action>
|
| 50 |
+
</reference>
|
| 51 |
+
<reference name="content">
|
| 52 |
+
<block type="contactus/activate" name="contactusForm" template="productiveminds/contactus/form.phtml"/>
|
| 53 |
+
</reference>
|
| 54 |
+
</contactus_index_index>
|
| 55 |
+
</layout>
|
app/design/frontend/base/default/template/productiveminds/contactus/contactus-live.phtml
ADDED
|
@@ -0,0 +1,71 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 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
|
| 22 |
+
* @package base_default
|
| 23 |
+
* @copyright Copyright (c) 2012 Magento Inc. (http://www.magentocommerce.com)
|
| 24 |
+
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
| 25 |
+
*/
|
| 26 |
+
?>
|
| 27 |
+
<div class="header-content">
|
| 28 |
+
<div class="lefted">
|
| 29 |
+
<?php
|
| 30 |
+
$store = Mage::app()->getStore();
|
| 31 |
+
$urlToShow = $this->getUrl('').'contactus/';
|
| 32 |
+
$title = Mage::getStoreConfig('contactus_sectns/overlay_properties/title', $store);
|
| 33 |
+
$width = Mage::getStoreConfig('contactus_sectns/overlay_properties/width', $store);
|
| 34 |
+
$height = Mage::getStoreConfig('contactus_sectns/overlay_properties/height', $store);
|
| 35 |
+
?>
|
| 36 |
+
<a style="color:#fff; font-weight:600;" id="contactusLink" href="#" onclick="contactusOverlay('<?php echo $urlToShow;?>')">Contact Us</a>
|
| 37 |
+
</div>
|
| 38 |
+
</div>
|
| 39 |
+
<script type="text/javascript">
|
| 40 |
+
//<![CDATA[
|
| 41 |
+
function contactusOverlay(urlToShow) {
|
| 42 |
+
contactusPopup = new Window({
|
| 43 |
+
id:'contactusConfirm_window',
|
| 44 |
+
className: 'contactus',
|
| 45 |
+
url: urlToShow,
|
| 46 |
+
width: '<?php echo $width;?>',
|
| 47 |
+
height: '<?php echo $height;?>',
|
| 48 |
+
title: '<?php echo $title;?>',
|
| 49 |
+
minimizable: false,
|
| 50 |
+
maximizable: false,
|
| 51 |
+
hideEffect:Element.hide,
|
| 52 |
+
showEffect:Element.show,
|
| 53 |
+
showEffectOptions: {
|
| 54 |
+
duration: 0.7
|
| 55 |
+
},
|
| 56 |
+
hideEffectOptions:{
|
| 57 |
+
duration: 0.7
|
| 58 |
+
},
|
| 59 |
+
destroyOnClose: true
|
| 60 |
+
});
|
| 61 |
+
contactusPopup.setZIndex(888888);
|
| 62 |
+
contactusPopup.showCenter(true);
|
| 63 |
+
contactusPopup.setDestroyOnClose(true);
|
| 64 |
+
}
|
| 65 |
+
|
| 66 |
+
function closePopup() {
|
| 67 |
+
Windows.close('contactusConfirm_window');
|
| 68 |
+
}
|
| 69 |
+
|
| 70 |
+
//]]>
|
| 71 |
+
</script>
|
app/design/frontend/base/default/template/productiveminds/contactus/contactus.phtml
ADDED
|
@@ -0,0 +1,72 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 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
|
| 22 |
+
* @package base_default
|
| 23 |
+
* @copyright Copyright (c) 2012 Magento Inc. (http://www.magentocommerce.com)
|
| 24 |
+
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
| 25 |
+
*/
|
| 26 |
+
?>
|
| 27 |
+
<div class="header-content">
|
| 28 |
+
<div class="lefted">
|
| 29 |
+
<?php
|
| 30 |
+
$store = Mage::app()->getStore();
|
| 31 |
+
$urlToShow = $this->getUrl('').'contactus/';
|
| 32 |
+
$title = Mage::getStoreConfig('contactus_sectns/overlay_properties/title', $store);
|
| 33 |
+
$width = Mage::getStoreConfig('contactus_sectns/overlay_properties/width', $store);
|
| 34 |
+
$height = Mage::getStoreConfig('contactus_sectns/overlay_properties/height', $store);
|
| 35 |
+
?>
|
| 36 |
+
<a style="color:#fff; font-weight:600;" id="contactusLink" href="#" onclick="contactusOverlay('<?php echo $urlToShow;?>')">Contact Us (extension)</a>
|
| 37 |
+
</div>
|
| 38 |
+
<div class="lefted eighty_left_margin">
|
| 39 |
+
<a class="button" href="http://www.productiveminds.com/multistore-contact-page-on-an-overlay.html">Download Multistore Contactus FREE Now</a>
|
| 40 |
+
</div>
|
| 41 |
+
</div>
|
| 42 |
+
<script type="text/javascript">
|
| 43 |
+
//<![CDATA[
|
| 44 |
+
function contactusOverlay(urlToShow) {
|
| 45 |
+
contactusPopup = new Window({
|
| 46 |
+
id:'contactusConfirm_window',
|
| 47 |
+
className: 'contactus',
|
| 48 |
+
url: urlToShow,
|
| 49 |
+
width: '<?php echo $width;?>',
|
| 50 |
+
height: '<?php echo $height;?>',
|
| 51 |
+
title: '<?php echo $title;?>',
|
| 52 |
+
minimizable: false,
|
| 53 |
+
maximizable: false,
|
| 54 |
+
hideEffect:Element.hide,
|
| 55 |
+
showEffect:Element.show,
|
| 56 |
+
showEffectOptions: {
|
| 57 |
+
duration: 0.7
|
| 58 |
+
},
|
| 59 |
+
hideEffectOptions:{
|
| 60 |
+
duration: 0.7
|
| 61 |
+
},
|
| 62 |
+
destroyOnClose: true
|
| 63 |
+
});
|
| 64 |
+
contactusPopup.setZIndex(888888);
|
| 65 |
+
contactusPopup.showCenter(true);
|
| 66 |
+
}
|
| 67 |
+
|
| 68 |
+
function closePopup() {
|
| 69 |
+
Windows.close('contactusConfirm_window');
|
| 70 |
+
}
|
| 71 |
+
//]]>
|
| 72 |
+
</script>
|
app/design/frontend/base/default/template/productiveminds/contactus/form.phtml
ADDED
|
@@ -0,0 +1,99 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Magento
|
| 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@magento.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.magento.com for more information.
|
| 20 |
+
*
|
| 21 |
+
* @category Mage
|
| 22 |
+
* @package Mage_Admin
|
| 23 |
+
* @copyright Copyright (c) 2006-2015 X.commerce, Inc. (http://www.magento.com)
|
| 24 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 25 |
+
*/
|
| 26 |
+
?>
|
| 27 |
+
<div class="contactus_container">
|
| 28 |
+
|
| 29 |
+
<div id="messages_product_view"><?php echo $this->getMessagesBlock()->getGroupedHtml() ?></div>
|
| 30 |
+
|
| 31 |
+
<div class="page-title">
|
| 32 |
+
<h1><?php echo Mage::helper('contactus')->__('Contact Us') ?></h1>
|
| 33 |
+
</div>
|
| 34 |
+
<form action="<?php echo $this->getFormAction(); ?>" id="contactusForm" method="post">
|
| 35 |
+
<?php
|
| 36 |
+
if($this->useFormKey()) {
|
| 37 |
+
echo $this->getBlockHtml('formkey');
|
| 38 |
+
}
|
| 39 |
+
?>
|
| 40 |
+
<div class="fieldset">
|
| 41 |
+
<ul class="form-list">
|
| 42 |
+
<li>
|
| 43 |
+
<div class="input-box input-box-left">
|
| 44 |
+
<input placeholder="Name" onfocus="this.placeholder=''" onblur="this.placeholder='Name'" name="name" id="name" title="<?php echo Mage::helper('contactus')->__('Name') ?>" value="<?php echo $this->htmlEscape($this->helper('contacts')->getUserName()) ?>" class="input-text required-entry" type="text" />
|
| 45 |
+
</div>
|
| 46 |
+
</li>
|
| 47 |
+
<li>
|
| 48 |
+
<div class="input-box input-box-left">
|
| 49 |
+
<input placeholder="Email" onfocus="this.placeholder=''" onblur="this.placeholder='Email'" name="email" id="email" title="<?php echo Mage::helper('contactus')->__('Email') ?>" value="<?php echo $this->htmlEscape($this->helper('contacts')->getUserEmail()) ?>" class="input-text required-entry validate-email" type="text" />
|
| 50 |
+
</div>
|
| 51 |
+
</li>
|
| 52 |
+
<li>
|
| 53 |
+
<div class="input-box input-box-left">
|
| 54 |
+
<input placeholder="Telephone" onfocus="this.placeholder=''" onblur="this.placeholder='Telephone'" name="telephone" id="telephone" title="<?php echo Mage::helper('contactus')->__('Telephone') ?>" value="" class="input-text" type="text" />
|
| 55 |
+
</div>
|
| 56 |
+
</li>
|
| 57 |
+
<li>
|
| 58 |
+
<div class="input-box input-box-left">
|
| 59 |
+
<textarea placeholder="Comment" onfocus="this.placeholder=''" onblur="this.placeholder='Comment'" name="comment" id="comment" title="<?php echo Mage::helper('contactus')->__('Comment') ?>" class="required-entry input-text" cols="5" rows="3"></textarea>
|
| 60 |
+
</div>
|
| 61 |
+
</li>
|
| 62 |
+
</ul>
|
| 63 |
+
</div>
|
| 64 |
+
<div>
|
| 65 |
+
<input type="text" name="hideit" id="hideit" value="" style="display:none !important;" />
|
| 66 |
+
<button id="submitButton" type="submit" title="<?php echo Mage::helper('contactus')->__('Submit') ?>" class="button"><span><span><?php echo Mage::helper('contactus')->__('Submit') ?></span></span></button>
|
| 67 |
+
</div>
|
| 68 |
+
<div class="topofstoreinfo">
|
| 69 |
+
<?php
|
| 70 |
+
$store_phone = Mage::getStoreConfig('general/store_information/phone', Mage::app()->getStore());
|
| 71 |
+
$store_address = Mage::getStoreConfig('general/store_information/address', Mage::app()->getStore());
|
| 72 |
+
$store_email = Mage::getStoreConfig('trans_email/ident_general/email', Mage::app()->getStore());
|
| 73 |
+
?>
|
| 74 |
+
<?php if( $store_phone && $store_phone != '' && !empty($store_phone) ) { ?>
|
| 75 |
+
<div class="new-item"><strong>Phone: </strong> <?php echo $store_phone; ?></div>
|
| 76 |
+
<?php } ?>
|
| 77 |
+
|
| 78 |
+
<div class="new-item"><strong>Email: </strong> <?php echo $store_email; ?></div>
|
| 79 |
+
|
| 80 |
+
<?php if( $store_address && $store_address != '' && !empty($store_address) ) { ?>
|
| 81 |
+
<div class="new-item"><strong>Store address: </strong> <div><?php echo $store_address; ?></div></div>
|
| 82 |
+
<?php } ?>
|
| 83 |
+
</div>
|
| 84 |
+
|
| 85 |
+
<!-- BEGIN: hidden field added to tackle robotic form submissions -->
|
| 86 |
+
<div style="display: none; height: 0">
|
| 87 |
+
<div>
|
| 88 |
+
<input type="text" style="width:4px" name="city" id="ro_nammy" value="" />
|
| 89 |
+
</div>
|
| 90 |
+
</div>
|
| 91 |
+
<!-- END: hidden field added to tackle robotic form submissions -->
|
| 92 |
+
</form>
|
| 93 |
+
<script type="text/javascript">
|
| 94 |
+
//<![CDATA[
|
| 95 |
+
var contactusForm = new VarienForm('contactusForm', true);
|
| 96 |
+
document.getElementById("submitButton").focus();
|
| 97 |
+
//]]>
|
| 98 |
+
</script>
|
| 99 |
+
</div>
|
app/design/frontend/base/default/template/productiveminds/contactus/link.phtml
ADDED
|
@@ -0,0 +1,41 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
|
| 2 |
+
<?php
|
| 3 |
+
$store = Mage::app()->getStore();
|
| 4 |
+
$urlToShow = $this->getUrl('').'contactus/';
|
| 5 |
+
$title = Mage::getStoreConfig('contactus_sectns/overlay_properties/title', $store);
|
| 6 |
+
$width = Mage::getStoreConfig('contactus_sectns/overlay_properties/width', $store);
|
| 7 |
+
$height = Mage::getStoreConfig('contactus_sectns/overlay_properties/height', $store);
|
| 8 |
+
?>
|
| 9 |
+
<a style="color:#900; font-weight:600;" id="contactusLink" href="#" onclick="contactusOverlayLink('<?php echo $urlToShow;?>')">Contact Us (by ProductiveMinds)</a>
|
| 10 |
+
|
| 11 |
+
<script type="text/javascript">
|
| 12 |
+
//<![CDATA[
|
| 13 |
+
function contactusOverlayLink(urlToShow) {
|
| 14 |
+
contactusPopup = new Window({
|
| 15 |
+
id:'contactusConfirm_window',
|
| 16 |
+
className: 'contactus',
|
| 17 |
+
url: urlToShow,
|
| 18 |
+
width: '<?php echo $width;?>',
|
| 19 |
+
height: '<?php echo $height;?>',
|
| 20 |
+
title: '<?php echo $title;?>',
|
| 21 |
+
minimizable: false,
|
| 22 |
+
maximizable: false,
|
| 23 |
+
hideEffect:Element.hide,
|
| 24 |
+
showEffect:Element.show,
|
| 25 |
+
showEffectOptions: {
|
| 26 |
+
duration: 0.7
|
| 27 |
+
},
|
| 28 |
+
hideEffectOptions:{
|
| 29 |
+
duration: 0.7
|
| 30 |
+
},
|
| 31 |
+
destroyOnClose: true
|
| 32 |
+
});
|
| 33 |
+
contactusPopup.setZIndex(888888);
|
| 34 |
+
contactusPopup.showCenter(true);
|
| 35 |
+
}
|
| 36 |
+
|
| 37 |
+
function closePopup() {
|
| 38 |
+
Windows.close('contactusConfirm_window');
|
| 39 |
+
}
|
| 40 |
+
//]]>
|
| 41 |
+
</script>
|
app/design/frontend/base/default/template/productiveminds/contactus/overlay.phtml
ADDED
|
@@ -0,0 +1,46 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 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
|
| 22 |
+
* @package base_default
|
| 23 |
+
* @copyright Copyright (c) 2012 Magento Inc. (http://www.magentocommerce.com)
|
| 24 |
+
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
| 25 |
+
*/
|
| 26 |
+
?>
|
| 27 |
+
<?php
|
| 28 |
+
/**
|
| 29 |
+
* Template for Mage_Page_Block_Html
|
| 30 |
+
*/
|
| 31 |
+
?>
|
| 32 |
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
| 33 |
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?php echo $this->getLang() ?>" lang="<?php echo $this->getLang() ?>">
|
| 34 |
+
<head>
|
| 35 |
+
<?php echo $this->getChildHtml('head') ?>
|
| 36 |
+
</head>
|
| 37 |
+
<body class="page-switch-confirm" <?php echo $this->getBodyClass()?$this->getBodyClass():'' ?>">
|
| 38 |
+
<div>
|
| 39 |
+
<?php echo $this->getChildHtml('after_body_start') ?>
|
| 40 |
+
<?php echo $this->getChildHtml('global_messages') ?>
|
| 41 |
+
<?php echo $this->getChildHtml('content') ?>
|
| 42 |
+
<?php echo $this->getChildHtml('before_body_end') ?>
|
| 43 |
+
<?php echo $this->getAbsoluteFooter() ?>
|
| 44 |
+
</div>
|
| 45 |
+
</body>
|
| 46 |
+
</html>
|
app/etc/modules/Productiveminds_Contactus.xml
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<config>
|
| 3 |
+
<modules>
|
| 4 |
+
<Productiveminds_Contactus>
|
| 5 |
+
<active>true</active>
|
| 6 |
+
<codePool>local</codePool>
|
| 7 |
+
</Productiveminds_Contactus>
|
| 8 |
+
</modules>
|
| 9 |
+
</config>
|
app/etc/modules/Productiveminds_Core.xml
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0" encoding="UTF-8"?>
|
| 2 |
+
<config>
|
| 3 |
+
<modules>
|
| 4 |
+
<Productiveminds_Core>
|
| 5 |
+
<active>true</active>
|
| 6 |
+
<codePool>community</codePool>
|
| 7 |
+
</Productiveminds_Core>
|
| 8 |
+
</modules>
|
| 9 |
+
</config>
|
app/locale/en_US/template/email/productiveminds/contactus.html
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<!--@subject {{var store.getFrontendName()}}: Contact Us @-->
|
| 2 |
+
|
| 3 |
+
Please find below a message submitted at, {{var store.getFrontendName()}}.
|
| 4 |
+
|
| 5 |
+
Full Name: {{var data.name}}
|
| 6 |
+
|
| 7 |
+
Email: {{var data.email}}
|
| 8 |
+
|
| 9 |
+
Phone Number: {{var data.telephone}}
|
| 10 |
+
|
| 11 |
+
Comment: {{var data.comment}}
|
| 12 |
+
|
| 13 |
+
This email is generated by the ProductiveMinds Contact Us, an extension for Magento.
|
| 14 |
+
|
| 15 |
+
======================================================
|
| 16 |
+
End of email.
|
package.xml
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<package>
|
| 3 |
+
<name>Productiveminds_Contactus</name>
|
| 4 |
+
<version>0.1.6</version>
|
| 5 |
+
<stability>stable</stability>
|
| 6 |
+
<license>OSL</license>
|
| 7 |
+
<channel>community</channel>
|
| 8 |
+
<extends/>
|
| 9 |
+
<summary>The extension opens up the standard Magento contact us page as an overlay, which gives your customers the ability to leave a message without browsing away from their current page.</summary>
|
| 10 |
+
<description>The extension opens up the standard Magento contact us page as an overlay, which gives your customers the ability to leave a message without browsing away from their current page.</description>
|
| 11 |
+
<notes>The extension opens up the standard Magento contact us page as an overlay, which gives your customers the ability to leave a message without browsing away from their current page.</notes>
|
| 12 |
+
<authors><author><name>Productiveminds</name><user>productiveminds</user><email>info@productiveminds.com</email></author></authors>
|
| 13 |
+
<date>2015-11-14</date>
|
| 14 |
+
<time>07:29:06</time>
|
| 15 |
+
<contents><target name="magelocal"><dir name="Productiveminds"><dir name="Contactus"><dir name="Block"><file name="Activate.php" hash="7c4581206899f535962791d74ee30072"/></dir><dir name="Helper"><file name="Data.php" hash="9e6dbf9a28777ddc6bf9fce577fbf340"/></dir><dir name="controllers"><file name="IndexController.php" hash="b0242aa30c941fd391fc434677b4a68b"/></dir><dir name="etc"><file name="adminhtml.xml" hash="8c0ae4497ff2d77fe61a9a9e5109617f"/><file name="config.xml" hash="586ccfce03b825c783f2df77754864d8"/><file name="system.xml" hash="b2ec8ab467742743568ffdec6d6aa1e7"/></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Productiveminds_Contactus.xml" hash="74be9c01285e18a758a16730ac6d54ed"/><file name="Productiveminds_Core.xml" hash="e187891e5f1d5b7a8ccbee065ac65c71"/></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="template"><dir name="productiveminds"><dir name="contactus"><file name="contactus-live.phtml" hash="b4280bd19f8f5e747cde66bc68c7a31f"/><file name="contactus.phtml" hash="164ff4c729d1dc48c5b00be1d1d8ab49"/><file name="form.phtml" hash="e8a38c7169f2b3329f93c6eef215f1f8"/><file name="link.phtml" hash="b5232fd1d9555e864b8c9b6fe4289c98"/><file name="overlay.phtml" hash="dd36fc85c65bd30e6a848a5be7ab5d0b"/></dir></dir></dir><dir name="layout"><dir name="productiveminds"><file name="contactus.xml" hash="4aa87f0b33d16df44e5cf383b3fddb8f"/></dir></dir></dir></dir></dir><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><dir name="productiveminds"><file name="core.xml" hash="2c94277f988a76a5c22946c1b8fe3f20"/></dir></dir></dir></dir></dir></target><target name="magelocale"><dir name="en_US"><dir name="template"><dir name="email"><dir name="productiveminds"><file name="contactus.html" hash="f8c3e3aed41396162f76c9251b051553"/></dir></dir></dir></dir></target><target name="mageskin"><dir name="frontend"><dir name="base"><dir name="default"><dir name="productiveminds"><dir name="contactus"><dir name="css"><file name="contactus.css" hash="cda730e1c56909ec926eeeed53741c8a"/><file name="overlay.css" hash="e3f39a062752003aead4ba88826e311b"/></dir><dir name="images"><file name="btn_bg.gif" hash="37c51a4d48a92da9648dcd3ca011039f"/><file name="content_bg.gif" hash="21278ea0da2d4256f4ced96b6080ba2e"/><file name="window_close.png" hash="3af14f053f360bf31f8ba2df73ec7f1e"/></dir></dir></dir></dir></dir></dir></target><target name="magecommunity"><dir name="Productiveminds"><dir name="Core"><dir name="Block"><dir name="Adminhtml"><dir name="Renderer"><file name="Attachedfiles.php" hash="0983db648802fc4df55b52cecfa4a268"/></dir><dir name="Support"><dir name="Edit"><file name="Form.php" hash="4824bbe691fca695ed5c47448bf6b1f3"/><dir name="Tab"><file name="Form.php" hash="36b509e8d93e47196da2d3e9980382fc"/><file name="Options.php" hash="16d38bff80a954983124d1731d618249"/></dir><file name="Tabs.php" hash="e2136f21462d8e396003741f351045ea"/></dir><file name="Edit.php" hash="6e7a25c9319cf002db49ec454005a8ea"/></dir><dir name="System"><dir name="Config"><dir name="Form"><dir name="Fieldset"><file name="Contactus.php" hash="67234576b89996fcf2a9d8b06d601baa"/><dir name="Promindsextensions"><file name="Item.php" hash="7c06f0367c41abe5fd0b18a175008344"/></dir></dir></dir></dir></dir></dir><file name=".DS_Store" hash="0047fe0bc161a58c6088a4e959de43a4"/></dir><dir name="Helper"><file name="Countrycat.php" hash="2d352bed3e1f9722044cf56d4d27c343"/><file name="Data.php" hash="497d793d8a25a3a34b3f4c3002f41e91"/></dir><dir name="Model"><file name="Email.php" hash="951b97048703ca5315a007e8c9e62c15"/><dir name="System"><dir name="Config"><dir name="Source"><file name="Typeofissue.php" hash="8195c567345f997dea60020d50ab4f66"/></dir></dir></dir></dir><dir name="controllers"><dir name="Adminhtml"><file name="IndexController.php" hash="69487036587a296a1dbe5fe745adf34f"/><file name="SupportController.php" hash="983b88b4f68d9867a9da63f49bc334ec"/></dir></dir><dir name="etc"><file name="adminhtml.xml" hash="2c8b5a3875905f97acfa08b73bece3dc"/><file name="config.xml" hash="e2228735e76519fdb2511dcc798f5001"/><file name="system.xml" hash="07ac2509bc9f2edd377c5b4bc591b506"/></dir><file name=".DS_Store" hash="3d15c499ef015dbcf750d9bbfc126aa0"/></dir></dir></target></contents>
|
| 16 |
+
<compatible/>
|
| 17 |
+
<dependencies><required><php><min>5.2.0</min><max>5.6.0</max></php></required></dependencies>
|
| 18 |
+
</package>
|
skin/frontend/base/default/productiveminds/contactus/css/contactus.css
ADDED
|
@@ -0,0 +1,318 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
|
| 2 |
+
.header-contactus {
|
| 3 |
+
width: 100%;
|
| 4 |
+
background: #36454f;
|
| 5 |
+
}
|
| 6 |
+
.header-contactus .header {
|
| 7 |
+
padding: 0;
|
| 8 |
+
height: 40px;
|
| 9 |
+
color: #fff;
|
| 10 |
+
width: 950px;
|
| 11 |
+
margin: 0 auto;
|
| 12 |
+
text-align: left;
|
| 13 |
+
}
|
| 14 |
+
.header-contactus .header-content {
|
| 15 |
+
padding: 10px 0px;
|
| 16 |
+
}
|
| 17 |
+
|
| 18 |
+
.header-contactus .header-content img.arrow {
|
| 19 |
+
margin: 4px 0 0 4px;
|
| 20 |
+
}
|
| 21 |
+
|
| 22 |
+
.header-contactus .header .header-content a.button {
|
| 23 |
+
color: #fff;
|
| 24 |
+
height: 19px;
|
| 25 |
+
padding: 0 8px;
|
| 26 |
+
display: block;
|
| 27 |
+
text-align: center;
|
| 28 |
+
white-space: nowrap;
|
| 29 |
+
border: 1px solid #de5400;
|
| 30 |
+
background: none repeat scroll 0 0 #f18200;
|
| 31 |
+
font: bold 12px/19px Arial,Helvetica,sans-serif;
|
| 32 |
+
}
|
| 33 |
+
.header-contactus .header .header-content a.button:hover {
|
| 34 |
+
color: #f18200;
|
| 35 |
+
text-decoration: none;
|
| 36 |
+
background: none repeat scroll 0 0 #fff;
|
| 37 |
+
}
|
| 38 |
+
|
| 39 |
+
.header-content .currency-text {
|
| 40 |
+
}
|
| 41 |
+
.header-content img {
|
| 42 |
+
margin: 1px 5px 0px 0px;
|
| 43 |
+
}
|
| 44 |
+
.header-content a {
|
| 45 |
+
color: #fff;
|
| 46 |
+
font-weight: 600;
|
| 47 |
+
text-decoration: none;
|
| 48 |
+
}
|
| 49 |
+
.header-content a:hover {
|
| 50 |
+
color: #999;
|
| 51 |
+
text-decoration: underline;
|
| 52 |
+
}
|
| 53 |
+
|
| 54 |
+
.lefted {
|
| 55 |
+
float: left;
|
| 56 |
+
}
|
| 57 |
+
|
| 58 |
+
.righted {
|
| 59 |
+
float: right;
|
| 60 |
+
}
|
| 61 |
+
|
| 62 |
+
.eighty_left_margin {
|
| 63 |
+
margin-left: 80px !important;
|
| 64 |
+
}
|
| 65 |
+
|
| 66 |
+
|
| 67 |
+
.overlay_dialog {
|
| 68 |
+
background: #36454f;
|
| 69 |
+
filter:alpha(opacity=50);
|
| 70 |
+
-moz-opacity: 0.5;
|
| 71 |
+
opacity: 0.5;
|
| 72 |
+
}
|
| 73 |
+
|
| 74 |
+
.overlay___invisible__ {
|
| 75 |
+
background: #fff;
|
| 76 |
+
filter:alpha(opacity=0);
|
| 77 |
+
-moz-opacity: 0;
|
| 78 |
+
opacity: 0;
|
| 79 |
+
}
|
| 80 |
+
|
| 81 |
+
.top_draggable, .bottom_draggable {
|
| 82 |
+
cursor:move;
|
| 83 |
+
}
|
| 84 |
+
|
| 85 |
+
.status_bar {
|
| 86 |
+
font-size:12px;
|
| 87 |
+
}
|
| 88 |
+
.status_bar input{
|
| 89 |
+
font-size:12px;
|
| 90 |
+
}
|
| 91 |
+
|
| 92 |
+
.wired_frame {
|
| 93 |
+
display: block;
|
| 94 |
+
position: absolute;
|
| 95 |
+
border: 1px #36454f dashed;
|
| 96 |
+
}
|
| 97 |
+
|
| 98 |
+
.dialog {
|
| 99 |
+
display: block;
|
| 100 |
+
position: absolute;
|
| 101 |
+
border: none;
|
| 102 |
+
}
|
| 103 |
+
.dialog .bot { display: none; }
|
| 104 |
+
|
| 105 |
+
.dialog table.table_window {
|
| 106 |
+
border-collapse: collapse;
|
| 107 |
+
border-spacing: 0;
|
| 108 |
+
width: 100%;
|
| 109 |
+
margin: 0px;
|
| 110 |
+
padding:0px;
|
| 111 |
+
}
|
| 112 |
+
|
| 113 |
+
.dialog table.table_window td , .dialog table.table_window th {
|
| 114 |
+
padding: 0;
|
| 115 |
+
}
|
| 116 |
+
|
| 117 |
+
.dialog .title_window {
|
| 118 |
+
-moz-user-select:none;
|
| 119 |
+
}
|
| 120 |
+
.overlay_contactus {
|
| 121 |
+
opacity:.5;
|
| 122 |
+
-moz-opacity:.5;
|
| 123 |
+
-webkit-opacity:.5;
|
| 124 |
+
background-color:#36454f;
|
| 125 |
+
filter:alpha(opacity=60);
|
| 126 |
+
}
|
| 127 |
+
|
| 128 |
+
.top.table_window { border-bottom: none; background: transparent; }
|
| 129 |
+
|
| 130 |
+
#contactusConfirm_window {
|
| 131 |
+
}
|
| 132 |
+
#contactusConfirm_window_row1,
|
| 133 |
+
#contactusConfirm_window_row2,
|
| 134 |
+
#contactusConfirm_window_row3 {
|
| 135 |
+
}
|
| 136 |
+
|
| 137 |
+
#contactusConfirm_window_row1 {
|
| 138 |
+
padding-left: 10px;
|
| 139 |
+
}
|
| 140 |
+
|
| 141 |
+
#contactusConfirm_window_row2 {
|
| 142 |
+
}
|
| 143 |
+
|
| 144 |
+
.contactus_n {
|
| 145 |
+
|
| 146 |
+
}
|
| 147 |
+
|
| 148 |
+
#contactusConfirm_window_row3,
|
| 149 |
+
.contactus_w,
|
| 150 |
+
.contactus_e,
|
| 151 |
+
.contactus_s,
|
| 152 |
+
.contactus_sw,
|
| 153 |
+
.contactus_se,
|
| 154 |
+
.contactus_sizer,
|
| 155 |
+
.contactus_minimize,
|
| 156 |
+
.contactus_maximize {
|
| 157 |
+
display: none;
|
| 158 |
+
}
|
| 159 |
+
|
| 160 |
+
.contactus_close {
|
| 161 |
+
top: 15px;
|
| 162 |
+
right: 7px;
|
| 163 |
+
width: 16px;
|
| 164 |
+
height: 16px;
|
| 165 |
+
position:absolute;
|
| 166 |
+
cursor:pointer;
|
| 167 |
+
z-index:1000;
|
| 168 |
+
background:url(../images/window_close.png) no-repeat 0 0;
|
| 169 |
+
}
|
| 170 |
+
.contactus_title {
|
| 171 |
+
float: left;
|
| 172 |
+
width: 100%;
|
| 173 |
+
color: #fff;
|
| 174 |
+
background: #36454f;
|
| 175 |
+
padding: 5px 0px 5px 10px;
|
| 176 |
+
text-align: left;
|
| 177 |
+
font-size: 16px;
|
| 178 |
+
font-weight: 600;
|
| 179 |
+
border: 5px solid #36454f !important;
|
| 180 |
+
border-bottom: none;
|
| 181 |
+
}
|
| 182 |
+
#contactusConfirm_window_content {
|
| 183 |
+
border: 10px solid #36454f ;
|
| 184 |
+
border-top: none !important;
|
| 185 |
+
}
|
| 186 |
+
.contactus_content {
|
| 187 |
+
overflow:auto;
|
| 188 |
+
font-size:12px;
|
| 189 |
+
}
|
| 190 |
+
.contactus_container {
|
| 191 |
+
min-width: 360px !important;
|
| 192 |
+
padding: 5px;
|
| 193 |
+
}
|
| 194 |
+
.contactus_container .fields,
|
| 195 |
+
.contactus_container .fieldset,
|
| 196 |
+
.contactus_container .page-title {
|
| 197 |
+
width: 100%;
|
| 198 |
+
}
|
| 199 |
+
.contactus_container .page-title {
|
| 200 |
+
border: none;
|
| 201 |
+
margin: 0px 0px 10px 0px;
|
| 202 |
+
}
|
| 203 |
+
|
| 204 |
+
.contactus_container h1 {
|
| 205 |
+
margin: 0px;
|
| 206 |
+
}
|
| 207 |
+
|
| 208 |
+
.contactus_container .fields,
|
| 209 |
+
.contactus_container .fieldset {
|
| 210 |
+
margin: 0;
|
| 211 |
+
padding: 0px;
|
| 212 |
+
}
|
| 213 |
+
.contactus_container .fieldset {
|
| 214 |
+
padding: 0px;
|
| 215 |
+
}
|
| 216 |
+
.contactus_container .form-list li {
|
| 217 |
+
margin: 0 0 10px;
|
| 218 |
+
}
|
| 219 |
+
.contactus_container select,
|
| 220 |
+
.contactus_container textarea,
|
| 221 |
+
.contactus_container input.input-text,
|
| 222 |
+
.contactus_container .form-list select,
|
| 223 |
+
.contactus_container .form-list li.wide select,
|
| 224 |
+
.contactus_container .form-list input.input-text {
|
| 225 |
+
box-sizing: border-box;
|
| 226 |
+
font-size: 12px;
|
| 227 |
+
padding: 10px;
|
| 228 |
+
width: 100%;
|
| 229 |
+
}
|
| 230 |
+
.contactus_container .form-list input,
|
| 231 |
+
.contactus_container .form-list select,
|
| 232 |
+
.contactus_container .form-list textarea,
|
| 233 |
+
.contactus_container .form-list .input-box,
|
| 234 |
+
.contactus_container .form-list li.wide .input-box {
|
| 235 |
+
width: 100% !important;
|
| 236 |
+
box-shadow: 0 0 0 0 !important;
|
| 237 |
+
}
|
| 238 |
+
.contactus_container textarea,
|
| 239 |
+
.contactus_container input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]):not([type="file"]):not([type="image"]) {
|
| 240 |
+
background: none repeat scroll 0 0 #fff;
|
| 241 |
+
border: 1px solid #bbb;
|
| 242 |
+
border-radius: 1px;
|
| 243 |
+
color: #2f2f2f !important;
|
| 244 |
+
font-family: inherit;
|
| 245 |
+
font-size: 12px;
|
| 246 |
+
line-height: 120%;
|
| 247 |
+
max-width: 100%;
|
| 248 |
+
outline: 0 none;
|
| 249 |
+
padding: 7px;
|
| 250 |
+
}
|
| 251 |
+
.contactus_container .form-list select {
|
| 252 |
+
padding: 5px;
|
| 253 |
+
height: 36px;
|
| 254 |
+
}
|
| 255 |
+
.contactus_container .form-list select option {
|
| 256 |
+
padding: 5px;
|
| 257 |
+
border-bottom: 1px dotted #999;
|
| 258 |
+
}
|
| 259 |
+
.contactus_container .button-set {
|
| 260 |
+
margin: 0 !important;
|
| 261 |
+
}
|
| 262 |
+
|
| 263 |
+
.contactus_container .buttons-set {
|
| 264 |
+
width: 300px;
|
| 265 |
+
margin: 20px 0 0 0;
|
| 266 |
+
}
|
| 267 |
+
|
| 268 |
+
.form-list label {
|
| 269 |
+
color: #36454f;
|
| 270 |
+
}
|
| 271 |
+
.contactus_container button.button,
|
| 272 |
+
.contactus_container button.button:hover {
|
| 273 |
+
padding: 5px 0 !important;
|
| 274 |
+
background: transparent !important;
|
| 275 |
+
}
|
| 276 |
+
.contactus_container button.button span {
|
| 277 |
+
height: auto;
|
| 278 |
+
color: #f6f6f6;
|
| 279 |
+
display: block;
|
| 280 |
+
font-size: 13px;
|
| 281 |
+
font-weight: 300;
|
| 282 |
+
padding: 5px 10px;
|
| 283 |
+
text-align: center;
|
| 284 |
+
border-radius: 1px;
|
| 285 |
+
white-space: nowrap;
|
| 286 |
+
border: medium none;
|
| 287 |
+
background: none repeat scroll 0 0 #36454f;
|
| 288 |
+
}
|
| 289 |
+
.contactus_container .contactus_container button.button span {
|
| 290 |
+
color: #fff;
|
| 291 |
+
display: block;
|
| 292 |
+
font-size: 14px;
|
| 293 |
+
font-weight: 400;
|
| 294 |
+
padding: 4px 12px;
|
| 295 |
+
background: #36454f;
|
| 296 |
+
border-radius: 1px !important;
|
| 297 |
+
}
|
| 298 |
+
.contactus_container .input-box-left,
|
| 299 |
+
.contactus_container .input-box-right {
|
| 300 |
+
float: left;
|
| 301 |
+
}
|
| 302 |
+
.contactus_container .input-box-right {
|
| 303 |
+
margin-left: 10px;
|
| 304 |
+
}
|
| 305 |
+
.contactus_container .fieldset {
|
| 306 |
+
border: transparent !important;
|
| 307 |
+
background: none !important;
|
| 308 |
+
}
|
| 309 |
+
.topofstoreinfo {
|
| 310 |
+
padding-top: 5px;
|
| 311 |
+
margin-top: 20px !important;
|
| 312 |
+
border-top: 1px solid #bbb;
|
| 313 |
+
}
|
| 314 |
+
.topofstoreinfo .new-item {
|
| 315 |
+
margin-top: 5px;
|
| 316 |
+
}
|
| 317 |
+
/* FOR IE */
|
| 318 |
+
* html .contactus_close { background-image:none; filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../images/window_close.png", sizingMethod="crop"); }
|
skin/frontend/base/default/productiveminds/contactus/css/overlay.css
ADDED
|
@@ -0,0 +1,51 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
|
| 2 |
+
.page-switch-confirm {
|
| 3 |
+
padding: 10px;
|
| 4 |
+
text-align:left;
|
| 5 |
+
background:#fff !important;
|
| 6 |
+
}
|
| 7 |
+
|
| 8 |
+
.storesSwitching {
|
| 9 |
+
text-align: left;
|
| 10 |
+
}
|
| 11 |
+
|
| 12 |
+
.header-currency-overlay {
|
| 13 |
+
|
| 14 |
+
}
|
| 15 |
+
|
| 16 |
+
.header-currency-overlay img {
|
| 17 |
+
margin: 1px 3px 0px 0px;
|
| 18 |
+
}
|
| 19 |
+
|
| 20 |
+
.header-currency-overlay li.current {
|
| 21 |
+
color: #000;
|
| 22 |
+
width: 300px;
|
| 23 |
+
display: block;
|
| 24 |
+
padding: 8px 0;
|
| 25 |
+
font-weight: 600;
|
| 26 |
+
border-bottom: 1px dotted #bbb;
|
| 27 |
+
}
|
| 28 |
+
.header-currency-overlay li.current div.message-top,
|
| 29 |
+
.header-currency-overlay li.current div.message-bottom {
|
| 30 |
+
color: #000;
|
| 31 |
+
font-size: 12px;
|
| 32 |
+
font-weight: normal;
|
| 33 |
+
padding-bottom: 10px;
|
| 34 |
+
}
|
| 35 |
+
.header-currency-overlay li.current div.message-bottom {
|
| 36 |
+
padding: 15px 0 5px 0;
|
| 37 |
+
}
|
| 38 |
+
.header-currency-overlay li a {
|
| 39 |
+
color: #006ac3;
|
| 40 |
+
width: 300px;
|
| 41 |
+
display: block;
|
| 42 |
+
padding: 8px 0;
|
| 43 |
+
font-weight: 600;
|
| 44 |
+
text-decoration: none;
|
| 45 |
+
border-bottom: 1px dotted #bbb;
|
| 46 |
+
}
|
| 47 |
+
.header-currency-overlay li a:hover {
|
| 48 |
+
color: #000;
|
| 49 |
+
background: #f0f0f0;
|
| 50 |
+
}
|
| 51 |
+
|
skin/frontend/base/default/productiveminds/contactus/images/btn_bg.gif
ADDED
|
Binary file
|
skin/frontend/base/default/productiveminds/contactus/images/content_bg.gif
ADDED
|
Binary file
|
skin/frontend/base/default/productiveminds/contactus/images/window_close.png
ADDED
|
Binary file
|
