MarkEliasen Posted January 26, 2011 Share Posted January 26, 2011 Hi Everyone. Since I do not have any Smarty experience at all, I thought I would request some help in here. I have setup a trial hosting product, but I would like it so that your only able to choose a a free sub-domain with the trial account. I know (from asking Matt) that I need to edit the "/templates/orderforms/web20cart/configureproductdomain.tpl" (I use web20cart). I am just not sure how to check for a certain product and then only output sub-domain registration. Anyone got some hits or like to help me get started? Thank in advance for reading all this and getting this far Mark 0 Quote Link to comment Share on other sites More sharing options...
MarkEliasen Posted January 26, 2011 Author Share Posted January 26, 2011 I ran out of time (15 mins edit limit ) Here is how you do it! I will tell you how to do this with Web20cart template, but should be very easy to do with any of the others as well: 1). find whmcs/templates/orderforms/web20cart/configureproductdomain.tpl 2). go to line 12 and add this: {if $pid eq <your pid here>} <p><input type="radio" name="domainoption" value="subdomain" id="selsubdomain" onclick="document.getElementById('register').style.display='none';document.getElementById('transfer').style.display='none';document.getElementById('owndomain').style.display='none';document.getElementById('subdomain').style.display='';document.getElementById('incart').style.display='none'" /> <label for="selsubdomain">{$LANG.orderdomainoption4}</label></p> {else} 3). go to line 39. It should look like this: {/if} <br /> replace with this: {/if}{/if} <br /> Cheers 0 Quote Link to comment Share on other sites More sharing options...
Sitepearl Posted January 27, 2011 Share Posted January 27, 2011 I was going to start looking into this yesterday when I ran into some issues with email piping... thanks for the info. 0 Quote Link to comment Share on other sites More sharing options...
MarkEliasen Posted February 4, 2011 Author Share Posted February 4, 2011 No problem at all! 0 Quote Link to comment Share on other sites More sharing options...
dimtsef Posted February 9, 2012 Share Posted February 9, 2012 Hello, i try the above code and now i get white page when i ordering this product id i set:? 0 Quote Link to comment Share on other sites More sharing options...
dimtsef Posted February 9, 2012 Share Posted February 9, 2012 i try it on modern theme but also in Web20cart i am having the same issue 0 Quote Link to comment Share on other sites More sharing options...
maggot881 Posted February 4, 2013 Share Posted February 4, 2013 Hi i know this thread is a bit old but i have work this out for 4 Hours now and have the Solution so i will help others to the Trick For templates\orderforms\web20cart: On Line 12 BEFORE: {if $incartdomains} {if $pid = '12345'} 12345=YOUR ID <p><input type="radio" name="domainoption" value="subdomain" id="selsubdomain" onclick="document.getElementById('register').style.display='none';document.getElementById('transfer').style.display='none';document.getElementById('owndomain').style.display='none';document.getElementById('subdomain').style.display='';document.getElementById('incart').style.display='none'" /> <label for="selsubdomain">{$LANG.orderdomainoption4}</label></p> {else} and Double the last {/if} on Line 39 Done. For templates\orderforms\modern: On Line 12 BEFORE: {if $incartdomains} {if $pid = '12345'} 12345=YOUR ID <div class="option"> <label><input type="radio" name="domainoption" value="subdomain" id="selsubdomain" />{$LANG.cartsubdomainchoice|sprintf2:$companyname}</label> <div class="domainreginput" id="domainsubdomain"> http:// <input type="text" id="subdomainsld" size="30" value="{$sld}" /> <select id="subdomaintld">{foreach from=$subdomains key=subid item=subdomain}<option value="{$subid}">{$subdomain}</option>{/foreach}</select> <input type="submit" value="{$LANG.ordercontinuebutton}" /> </div> </div> {else} and Double the last {/if} on Line 71 Hope it would Hhelp someone. 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.