Last active
May 23, 2016 15:41
-
-
Save St0iK/b0f49ca6d2aac162b69046dc680695ab to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /** | |
| * Magento | |
| * | |
| * NOTICE OF LICENSE | |
| * | |
| * This source file is subject to the Academic Free License (AFL 3.0) | |
| * that is bundled with this package in the file LICENSE_AFL.txt. | |
| * It is also available through the world-wide-web at this URL: | |
| * http://opensource.org/licenses/afl-3.0.php | |
| * If you did not receive a copy of the license and are unable to | |
| * obtain it through the world-wide-web, please send an email | |
| * to [email protected] so we can send you a copy immediately. | |
| * | |
| * DISCLAIMER | |
| * | |
| * Do not edit or add to this file if you wish to upgrade Magento to newer | |
| * versions in the future. If you wish to customize Magento for your | |
| * needs please refer to http://www.magentocommerce.com for more information. | |
| * | |
| * @category design | |
| * @package base_default | |
| * @copyright Copyright (c) 2010 Magento Inc. (http://www.magentocommerce.com) | |
| * @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0) | |
| */ | |
| ?> | |
| <?php $_product = $this->getProduct() ?> | |
| <?php if($_product->isSaleable()): ?> | |
| <div class="add-to-cart"> | |
| <?php if(!$_product->isGrouped()): ?> | |
| <label for="qty"><?php echo $this->__('# of Licences') ?> <a href="/support" alt="<?php echo $this->__('Read Our FAQ') ?>" class="help show-desktop-license cboxElement"><?php echo $this->__('?'); ?></a></label> | |
| <?php | |
| $resource = Mage::getSingleton('core/resource'); | |
| $read= $resource->getConnection('core_read'); | |
| $licensepricingadminTable = $resource->getTableName('licensepricingadmin'); | |
| $select = $read->select()->from( $licensepricingadminTable, array('licensepricingadmin_id','title','content','to','from','status') )->where('status',1)->order('from ASC') ; | |
| $results = $read->fetchAll( $select ); | |
| ?> | |
| <div id="qty-formulas"> | |
| <?php foreach( $results as $license ) { ?> | |
| <span rel="<?php echo $license['content']; ?>" data-from="<?php echo $license['from']; ?>" data-to="<?php echo $license['to']; ?>"><?php echo $license['title']; ?></span> | |
| <?php } ?> | |
| </div> | |
| <input type="text" name="qty" id="qty" maxlength="12" value="5" title="<?php echo $this->__('Qty') ?>" class="input-text qty" /> | |
| <?php endif; ?> | |
| <?php echo $this->getChildHtml('', true, true) ?> | |
| </div> | |
| <div id="desktop_license" class="hide"> | |
| <?php echo $this->getLayout()->createBlock('cms/block')->setBlockId('cart_page_help')->toHtml() ?> | |
| </div> | |
| <?php endif; ?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment