eccen Posted April 7, 2008 Share Posted April 7, 2008 I am wondering if there is a way to assign a variable to a product custom field value. I am 'guessing' it can be done by something like {php}$ID = $_GET['ID']{/php} (assign value from url to $ID){assign var=$customfield.value value=$ID} I have been trying to figure this out for whole day but have not had any luck Hope someone can help me out. I am doing this in template/orderforms/cart/configureproduct.tpl. 0 Quote Link to comment Share on other sites More sharing options...
lesmith Posted April 7, 2008 Share Posted April 7, 2008 It can be done but without seeing excatly what you want its hard to exaplain. If you dont want to post item on site pm instead. If you can explain a bit more and I will help you. 0 Quote Link to comment Share on other sites More sharing options...
eccen Posted April 7, 2008 Author Share Posted April 7, 2008 Thank you for the help. Here is what I am trying to achieve. Customers will purchase an item at a url like below. whmcs/cart.php?a=add&pid=3&sid=$sid Here, $sid is a unique product number assigned from a script outside of WHMCS. I would like to pass this variable through the domain checker and ordering process. When the payment is complete, I want to have a database table value associated with $sid changed. (querying UPDATE product SET status='Active' WHERE sid='$sid') For better understanding, I am selling template websites and I want my customers to create 'draft' sites at no cost. These 'draft' sites will have product status as 'Draft' and will change to 'Active' upon purchase. Anyway, I was thinking I could do this using 'custom field' feature in WHMCS and apparently having trouble... Please let me know if you can give me some direction! 0 Quote Link to comment Share on other sites More sharing options...
eccen Posted April 8, 2008 Author Share Posted April 8, 2008 just to clarify, $sid above is not related to session 0 Quote Link to comment Share on other sites More sharing options...
moronhater Posted October 11, 2009 Share Posted October 11, 2009 I am having the same problem. If anyone can work this out, please reply. It's driving me crazy. Just want to assign the value to the custom field text box so it's already there. 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.