Skip to content

Instantly share code, notes, and snippets.

@SheriSmith
Created November 26, 2015 00:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save SheriSmith/532a0c7ba03ddfb44271 to your computer and use it in GitHub Desktop.
Save SheriSmith/532a0c7ba03ddfb44271 to your computer and use it in GitHub Desktop.
<?php $_streetValidationClass = $this->helper('customer/address')->getAttributeValidationClass('street'); ?>
<li class="wide">
<label for="shipping:street1" class="required"><em>*</em><?php echo $this->__('Address') ?></label>
<div class="input-box">
<input type="text" title="<?php echo $this->__('Street Address') ?>" name="shipping[street][]" id="shipping:street1" value="<?php echo $this->escapeHtml($this->getAddress()->getStreet(1)) ?>" class="input-text validate-for-pobox <?php echo $_streetValidationClass ?>" onchange="shipping.setSameAsBilling(false);" />
</div>
</li>
<?php $_streetValidationClass = trim(str_replace('required-entry', '', $_streetValidationClass)); ?>
<?php for ($_i = 2, $_n = $this->helper('customer/address')->getStreetLines(); $_i <= $_n; $_i++): ?>
<li class="wide">
<div class="input-box">
<input type="text" title="<?php echo $this->__('Street Address %s', $_i) ?>" name="shipping[street][]" id="shipping:street<?php echo $_i ?>" value="<?php echo $this->escapeHtml($this->getAddress()->getStreet($_i)) ?>" class="input-text validate-for-pobox <?php echo $_streetValidationClass ?>" onchange="shipping.setSameAsBilling(false);" />
</div>
</li>
<?php endfor; ?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment