milstanyu
Member-
Posts
24 -
Joined
-
Last visited
About milstanyu

Recent Profile Visitors
The recent visitors block is disabled and is not being shown to other users.
milstanyu's Achievements
Junior Member (1/3)
0
Reputation
-
Hello, I would like to customize the existing mailchimpsubscribe.php hook and to add support for 2 mailing lists. So, when product #1 is purchased, user to be subscribed to the list #1, and when product #2 is purchased, user to be subscribed to the list #2. Original script is this: <?php function hook_mail_chimp_subscribe($vars) { // ******MailChimp API and List ID****** // Replace XXXX with your API key retrieved from http://admin.mailchimp.com/account/api/ $api_key = "APIKEY"; // Replace XXXX with your list Unique ID obtained by going to http://admin.mailchimp.com/lists/ and clicking on the Settings link for the list. Unique ID found a the bottom of the page $list_id = "LISTID"; // ******Additional Settings****** // Replace with your datacenter. Retrieved from dashboard URL eg. - https://us2.admin.mailchimp.com/ $datacenter = "us1"; // Set to true if you would like the user to confirm their subscription before being added to your list $doubleoptin = "false"; // Don't bother changing this unless you really, really....REALLY have to! $output = "php"; // ******New subscriber information****** $first_name = str_replace(" ", "%20", $vars['firstname']); $last_name = str_replace(" ", "%20", $vars['lastname']); $email = $vars['email']; $url = "http://$datacenter.api.mailchimp.com/1.3/?output=$output&method=listSubscribe&apikey=$api_key&id=$list_id&email_address=$email&merge_vars[FNAME]=$first_name&merge_vars[LNAME]=$last_name&double_optin=$doubleoptin"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $retval = curl_exec($ch); curl_close($ch); logActivity("Debugging: MailChimp Hook - URL: $url - Response: ".htmlentities($retval)); } add_hook("ClientAdd",1,"hook_mail_chimp_subscribe"); ?> I don't know how to access the purchased product ID. I tried to add this: $pid = $vars['params']['packageid']; if($pid==1) { $list_id = "LIST1ID"; $api_key = "API1KEY"; $datacenter = "us9"; }else{ $list_id = "LIST2ID"; $api_key = "API2KEY"; $datacenter = "us1"; } But it doesn't seems to work. How do I get "packageid" in the ClientAdd hook? Thanks
-
Currently the list of downloads is organized by "newest first" criterium. Is it possible to organize the list to show downloads from A-Z (alphabetically). In file /templates/portal/clientareaproductdetails.tpl, we have this <h3>{$LANG.downloadstitle}</h3> {foreach key=num item=download from=$downloads} <table width="100%" cellspacing="0" cellpadding="0" class="frame"> <tr> <td><table width="100%" border="0" cellpadding="10" cellspacing="0"> <tr> <td>{$download.type} <a href="{$download.link}">{$download.title}</a></td> </tr> </table></td> </tr> </table> {/foreach} We are using WHMCS 5.2.1.
-
Somebody sends code in the contact form
milstanyu replied to milstanyu's topic in General Discussion
When I decode the script, I can see he is trying to call script angel.php, but it's not available on my server. -
This is the second time somebody is trying to do something nasty to my website. In the support ticket form, he/she enters this code: What he/she is trying to do? Could this be dangerous? I am using version 4.5.2.
-
Accept Creditcards Outside North America
milstanyu replied to irishelite's question in Pre-Sales Questions
I am also interested for SWREG payment module. -
I am using WHMCS to sell downloadable goods. However, I have many clients (3-4% of them) who after successful purchase can't download. When I login with his account, I can download. Why is that so? Most of people can download normally.
-
Does it mean "it's not possible"? I said "to have ability to delete PENDING invoices, not PAID invoices". Also, if one uses payment processor, such as 2Checkout.com, WHMCS invoices are only pro-forma. Valid invoices are generated by 2checkout.com (or other payment provider).
-
Is it possible to allow clients to delete generated unpaid invoices themselves? This is the scenario. A client is trying to buy a service. Somehow, he failed to pay on payment provider website. Tomorrow he get back and create new order and pay successfully. However, the old order is still active and marked as unpaid. I must delete such orders/invoices manually. Anyway to allow clients to delete unpaid invoices themselves?
-
Yes, that it! Sorry, I hadn't notice that (my client also)... Thanks a lot!
-
I have created them as product add-ons. The product add-on options are present on the order form so user can buy add-on together with product. I am looking to allow customer to buy product's add-on AFTER buying the product without add-on (in example, he decided to buy it later).
-
OK, it's already setup like that. But I don't see that buyer can buy add-on separately after purchase of the main product. It's necessary administrator to assign add-on to the buyer's order manually and buyer to pay additional invoice after that. However, in the order form, buyer have option to chose product with or without the add-on himself.
-
Thank you for replying. I am looking to allow customers to buy product add-on for a product they already bought, not to upgrade from one product to another.
-
I have product that costs eg. $20. But with additional add-on, this products costs $40. That's one-time fees, no recurring charges. If user buys a product for normal price and later he decides to upgrade, is it possible? How should I set this up? I am using the latest WHMCS version.
-
floating box displaced after 4.4.1 upgrade
milstanyu replied to milstanyu's topic in Developer Corner
Doesn't work for me. I managed to center it as I described above, but it's static now. -
After the last upgrade 4.4.1, the floating box on order form (web20 template) has become displaced (gone about 200px to the right). I edited file /order/templates/jqueryfloat.js and changed line 31 to this.jqObj.css({ 'top':this.currentY ,'left':this.currentX}); Now it's perhaps placed correctly again, but it doesn't go up and down. You can see this in example here. Can you check this please?
