PageRenderTime 50ms CodeModel.GetById 18ms RepoModel.GetById 0ms app.codeStats 0ms

/components/com_virtuemart/themes/default/templates/product_details/includes/addtocart_custom_attribute.tpl.php

https://bitbucket.org/dgough/annamaria-daneswood-25102012
PHP | 20 lines | 17 code | 1 blank | 2 comment | 2 complexity | 3548604871e9440fb856952f0c42cf54 MD5 | raw file
Possible License(s): GPL-2.0, LGPL-2.1
  1. <?php if( !defined( '_VALID_MOS' ) && !defined( '_JEXEC' ) ) die( 'Direct Access to '.basename(__FILE__).' is not allowed.' );
  2. foreach($attributes as $attribute) {
  3. foreach( $attribute as $attr => $val ) {
  4. // Using this we make all the variables available in the template
  5. // translated example: $this->set( 'product_name', $product_name );
  6. $this->set( $attr, $val );
  7. }
  8. ?>
  9. <div class="vmAttribChildDetail" style="float: left;width:30%;text-align:right;margin:3px;">
  10. <label for="<?php echo $attribute['titlevar'] ?>_field"><?php echo $attribute['title'] ?>
  11. </label>:
  12. </div>
  13. <div class="vmAttribChildDetail" style="float:left;width:60%;margin:3px;">
  14. <input type="text" class="inputboxattrib" id="<?php echo $attribute['titlevar'] ?>_field" size="30" name="<?php echo $attribute['titlevar'].$attribute['product_id'] ?>" />
  15. </div>
  16. <br style="clear: both;" />
  17. <input type="hidden" name="custom_attribute_fields[]" value="<?php echo $attribute['titlevar'].$attribute['product_id'] ?>" />
  18. <input type="hidden" name="custom_attribute_fields_check[<?php echo $attribute['titlevar'].$attribute['product_id'] ?>]" value="<?php echo md5($mosConfig_secret. $attribute['titlevar'].$attribute['product_id'] ) ?>" />
  19. <?php } ?>