mailjet

Mailjet Non-Nested Loop Failing

风流意气都作罢 提交于 2021-01-29 20:30:41
问题 My test email for a Mailjet Template keeps failing in a for loop I am using. Unlike other Mailjet Loop questions on stack overflow, my loops are not nested, and my array is not empty. The following code keeps failing In my template, I have two template blocks (for the for and endfor) surrounding a text block. Like below: {{var:FirstName:""}} {% for month in var:MonthList %} {{month.Name:""}} {{month.Count:""}} {% endfor %} I keep getting: ERenderError: expression parsing error ## Unknown

Send emails via mailjet without backend

不想你离开。 提交于 2020-02-07 17:15:20
问题 It would be awesome if I could just send emails via mailjet from the frontend without the need of a backend. The only implementations on their page are for backend systems. But shouldn`t it in theory be possible to use mailjet without a backend? Sending emails through mailjet should be nothing more than just some post request, don't they? If so, why is there no JS implementation? 回答1: Disclaimer: Mailjet's employee here. As long as you don't expose your credentials to the public , you can

Integrating Mailjet API v3 wrapper as Codeigniter library

隐身守侯 提交于 2019-12-17 06:19:18
问题 How can I integrate the Mailjet API PHP wrapper into my Codeigniter installation as a library? Is it as simple as placing the contents of the repository into application/libraries/Mailjet and then creating a Mailjet.php file in application/libraries which initializes Mailjet like shown below? require 'Mailjet/vendor/autoload.php'; use \Mailjet\Resources; $mj = new \Mailjet\Client(getenv('MJ_APIKEY_PUBLIC'), getenv('MJ_APIKEY_PRIVATE')); Please let me know if I'm on the right track. Thanks.

Mailjet Vars blank array throws error

这一生的挚爱 提交于 2019-12-13 00:06:09
问题 $array = [ "low_price_low_stock_goods" => [] ] In my mailjet template {% for item in var:low_price_low_stock_goods %} <tr> <td>{{ item.good_name }}</td> <td>{{ item.value }}</td> <td>{{ item.count }}</td> </tr> {% endfor %} error is now No value for "var:low_price_low_stock_goods" 回答1: As I answered you on Github Ricky: it's a known issue on Mailjet's templating language side, sorry for that. To avoid it, just pass a valid object in the API call for the low_price_low_stock_goods value . This

How can i delete a contact from a list with the mailjet api and php? [closed]

故事扮演 提交于 2019-12-11 22:58:53
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 5 years ago . I use mailjet api to send newsletter, but i don't know how delete a contact from a list. Please help me. 回答1: I'm a developer evangelist here at Mailjet. The relation between a contactlist and a contact is represented through the listrecipient entity. You can learn more about this in our guide, here: To remove a

Mailjet: Adding email to list does not work

旧时模样 提交于 2019-12-11 03:55:00
问题 I have started to use Mailjet to store the subscription emails using a form. The library I used for this task is "https://github.com/mailjet/mailjet-apiv3-php-simple" include("php-mailjet-v3-simple.class.php"); $apiKey = "xxx"; $secretKey = "yyy"; $mj = new Mailjet($apiKey, $secretKey); $contact_params = array("method" => "POST", "Email" => "abc@gmail.com"); $contact = $mj->contact($contact_params); $add_params = array( "method" => "POST", "ListID" => "11223344", "IsActive" => "True" );

How to get Contact ID in Mailjet v3 PHP wrapper?

感情迁移 提交于 2019-12-10 13:59:46
问题 I have used the Mailjet api to store submitted emails in a Mailjet list. This worked properly when there was the Mailjet 0.1 version API (then there wasn't any PHP wrapper but was easy to use with their examples), but when they changed the API to version 3 their PHP wrapper does not return any contact ID when adding a new contact to a contact list. I have raised a similar question earlier how to get Mailjet to work but now this issue arose with the new version 3. Again here is the corrected

How can I send an email with attachement using the API MailJet in iOS programmatically?

别等时光非礼了梦想. 提交于 2019-12-08 07:27:08
问题 FIRST ERROR I use this code but I don't know how to use the api Mailjet in iOS ? Where to put the API key private, the public etc... I check the github mailjet, the doc mailJet about the API without success. NSData *data = [NSData dataWithContentsOfFile:filePath]; NSLog(@"File Size: %lu",(unsigned long)[data length]); //set up request NSMutableURLRequest *request= [[NSMutableURLRequest alloc] init]; [request setURL:[NSURL URLWithString:@"https://api.mailjet.com/v3/send"]]; [request

MailJet nested loops

无人久伴 提交于 2019-12-08 03:33:26
问题 we are building our emails with mailJet which works fine so far. Our current problem is, that we would like to have a loop within a loop within a loop (so nested loops) the first loop works fine, and also the second inner loop is working fine, but the third one isn't working anymore: {% for trip in var:trips %} {{trip.id}} {% for tripSegment in trip.tripSegments %} {% for tripBreak in tripSegment.breaks %} {{tripBreak.duration}} {% endfor %} {% endfor %} Distance: {{trip.totalDistance}} km {%

MailJet nested loops

ⅰ亾dé卋堺 提交于 2019-12-07 00:19:34
we are building our emails with mailJet which works fine so far. Our current problem is, that we would like to have a loop within a loop within a loop (so nested loops) the first loop works fine, and also the second inner loop is working fine, but the third one isn't working anymore: {% for trip in var:trips %} {{trip.id}} {% for tripSegment in trip.tripSegments %} {% for tripBreak in tripSegment.breaks %} {{tripBreak.duration}} {% endfor %} {% endfor %} Distance: {{trip.totalDistance}} km {% endfor %} This is in our template. If I remove the inner loop with the breaks, everything is fine. If