christopherm Posted July 9, 2013 Share Posted July 9, 2013 Hi folks, Really simple question, on the product page where a person selects a hosting package, how would I hide/remove the "(Free Domain)" next to the package names? Image: /http://i.imod.co.za/xwi2 Thank you 0 Quote Link to comment Share on other sites More sharing options...
DavidBee Posted July 9, 2013 Share Posted July 9, 2013 Are you looking to remove the ability to get a free domain or just the wording? 0 Quote Link to comment Share on other sites More sharing options...
christopherm Posted July 9, 2013 Author Share Posted July 9, 2013 Just the wording David 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted July 9, 2013 Share Posted July 9, 2013 Just the wording David unless one of the more experienced WHMCS users contradicts me, I think this is "semi" hard-coded. you can certainly remove the "Free Domain" bit as that is just in the language files... (remember to use overrides rather than editing your language file directly) - http://docs.whmcs.com/Language_Files#Overriding_Language_Strings $_LANG['orderfreedomainonly'] = "Free Domain"; but for me, this "Free Domain" text is only shown when an annual price is set - set any other price and it isn't shown (including monthly)... so i'm curious why it shows it for you using monthly and not me. unfortunately, what happens if you change the "Free Domain" text is that it still adds the opening and closing brackets - so you would see "$4.99 USD Monthly ()" - which I guess doesn't really help you. I thought adding a <br> before "Free Domain" in the language file may help, but it doesn't - it adds the opening bracket first and then adds "<br>Free Domain)"... I can't for the life of me find that opening bracket, so unless corrected, i'm going to assume it's hard-coded into one of the encrypted php files. you might like to try one of two things... either post a link to your site so we can view the code, or post the source code for your comparison table template page (removing your domain if you wish)... if you're using a custom template/order form, then it may be based on an older existing template and there may be an easy way to patch it to work... alternatively, drop a ticket to support and ask them about it - and then report back their answer (i'd be interested to know if i'm missing something!) I thought data feeds (http://docs.whmcs.com/Data_Feeds#Product_Pricing) might be an answer, and it's useful for getting one price, but not so much for a range of products. 0 Quote Link to comment Share on other sites More sharing options...
christopherm Posted July 9, 2013 Author Share Posted July 9, 2013 (edited) Hello again @brain! - you really are a huge use on this forum, thank you. I ended up widening the column divs to allow for the "(Free Domain)" to fit accordingly as when I looked at the PHP and templating I realised that it's not something that can really be removed per say as it falls into the variable being called. So, I'm going to stick with the solution for now as I'd prefer not to hack at code for obvious reasons. Again, thank you so much for your assistance today! PS. "You must spread some Reputation around before giving it to brian! again." ;-) Edited July 9, 2013 by christopherm update 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted July 10, 2013 Share Posted July 10, 2013 Hello again @brain! - you really are a huge use on this forum, thank you. I ended up widening the column divs to allow for the "(Free Domain)" to fit accordingly as when I looked at the PHP and templating I realised that it's not something that can really be removed per say as it falls into the variable being called. So, I'm going to stick with the solution for now as I'd prefer not to hack at code for obvious reasons. Again, thank you so much for your assistance today! PS. "You must spread some Reputation around before giving it to brian! again." ;-) i'm glad to have helped. working on the theory that either there must be a way to do this, or there is a bug in the templates and WHMCS should be made aware of it, I opened with a ticket with support about this issue last night. following their hints at where the answer may lie, I had a play and found how to remove the text - so for others reading the thread, I will post the solution... it turns out for a simple question, there is a relatively simple answer! now this may vary in the other order form templates, but for "Comparison", which your site seems to use (or at least be based on), you just need to change one line... {$product.pricing.monthly} becomes... {$product.pricing.monthly|replace:'(Free Domain)':''} it will likely be a very useful method for others wishing to change aspects of WHMCS too - i'm sure i'll use it again now I know the option exists! 0 Quote Link to comment Share on other sites More sharing options...
christopherm Posted July 10, 2013 Author Share Posted July 10, 2013 Hi @brian! Whilst I was playing around yesterday I found the {$product.pricing.monthly} call, but couldn't figure out how to manipulate it and that's why I went with the solution I did. That being said, I have tested your solution and it worked a charm! Thank you so much. 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.