Jump to content

Hide billing address fields using product id


Abhicool

Recommended Posts

Hello,

I have tried to remove billing address custom fields based on product ids. As I have some free products which I don't want the user to fill the address, pin code, phone number and etc. As I know if I keep them to "hidden" and change all the values to "NA" but that's not the feasible solution. What I'm trying to do is hiding fields based on the total amount due, as the free product has "0" amount and if anything more than will show the fields. But I'm not able to get the desired result. Please help me

{if $LANG.ordertotalduetoday eq "0"}

 <div class="form-group-noconflict">
                                                        <label for="inputState" class="col-lg-4 col-sm-3 control-label">{$LANG.clientareastate}</label>
                                                        <div class="col-sm-6">
                                                            <input class="form-control" type="hidden" name="state" id="inputState" placeholder="{$LANG.orderForm.state}" value="NA"{if $loggedin} readonly="readonly"{/if}>
                                                        </div>
                                                    </div>

{else $LANG.ordertotalduetoday > "0"}

 <div class="form-group-noconflict">
                                                        <label for="inputState" class="col-lg-4 col-sm-3 control-label">{$LANG.clientareastate}</label>
                                                        <div class="col-sm-6">
                                                            <input class="form-control" type="text" name="state" id="inputState" placeholder="{$LANG.orderForm.state}" value="{$clientsdetails.state}"{if $loggedin} readonly="readonly"{/if}>
                                                        </div>
                                                    </div>


	{/if}



 

Link to comment
Share on other sites

  • 2 weeks later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated