Jump to content

configuredomains.tpl question


mtalley887

Recommended Posts

I am reconfiguring the configurdomains.tpl to add the code that is found here:

 

http://docs.whmcs.com/Enom_ID_Protection_Promo

 

and it works fine. But, I noticed something else with it that I want to discuss and that's about the check box settings. We offer free 'DNS Management and Email Forwarding' and from what I can see in the script is if those items are enabled in the domains/TLD setup in Admin then the boxes in the cart should be pre-checked, but they aren't. In the script it shows this:

 

{if $domain.dnsmanagement}<label><input type="checkbox" name="dnsmanagement[{$num}]"{if $domain.dnsmanagementselected} checked{/if} /> {$LANG.domaindnsmanagement} ({$domain.dnsmanagementprice})</label><br />{/if}

 

The way I read this is within the 'if' statement it looks to see if domain dns management is selected and if so then set the check box with a check in it. For me with us offering it for free I would want the box checked in the cart. Further looking into this I noticed that the id protect script had an extra statement in the 'if' tag

 

{if $domain.idprotectionselected || !$smarty.session.cart.firstpass} checked{/if}

 

If I add the smarty.session.cart.firstpass to the dnsmanagement then when you go to the cart the box is showing it checked and if you go to checkout it shows selected in the checkout section and if you go back and uncheck it then it doesn't show up in the checkout section. Appears to work fine. However, if you were to continue shopping and add a second domain none of the check boxes are checked on the second domain only on the first domain. But, if I change the smarty.session.cart.firstpass to smarty.session.cart.secondpass then all the added domains check boxes are checked including any additional domains add to the list. Since I haven't been able to find out if this is a real legit way of doing it I thought I would ask here if it is..?

 

Thanks

Link to comment
Share on other sites

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