I have a conditional statement set on the url,I tested both the IF and ELSE and it does work with a simple document.write. However, I am trying to output Php i the conditional but it just always outputs the else statement, Php is not my strongest language:
<script type="text/javascript">
if(
window.location.href=="mywebsite.com"
)
{
document.write('<label for="qty"><?php echo $this->__("Qty:") ?></label><input type="text" name="qty" id="qty" maxlength="12" value="<?php echo $this->getProductDefaultQty() * 1 ?>" title="<?php echo $this->__("Qty") ?>" class="input-text qty" />')
}else{
document.write('<label for="qty"><?php echo $this->__(' ') ?></label>
<input type="hidden" name="qty" id="qty" maxlength="12" value="<?php echo $this->getMinimalQty($_product) ?>" title="<?php echo $this->__("Qty") ?>" class="input-text qty" />')
}
</script>