New wordpress posts

Actually there is. See https://kb.mailwizz.com/articles/embed-xml-rss-feeds-into-your-campaign/
Check the following params:

days-backinteger – the number of days to look back for posts. Optional.
no-item-actionstring – what action to take when no items are found in the feed. Valid values: postpone-campaign(postpones the campaign till next day). Optional.
send-only-unique-items – string – if we should only send unique items. if no items are found, then no-item-action is applied. Valid values: (yes or no). Optional.
 
Actually there is. See https://kb.mailwizz.com/articles/embed-xml-rss-feeds-into-your-campaign/
Check the following params:

days-backinteger – the number of days to look back for posts. Optional.
no-item-actionstring – what action to take when no items are found in the feed. Valid values: postpone-campaign(postpones the campaign till next day). Optional.
send-only-unique-items – string – if we should only send unique items. if no items are found, then no-item-action is applied. Valid values: (yes or no). Optional.
Because sending it out whenever there is a new post in the feed is such a common use case, I think the KB article should be expanded with a better explanation for how those optional parameters behave when they are set and not set, and what the default value is for each parameter.

> offset – integer – the number of items you want to skip loading. Optional.

What's the default value? 0? If I want to send the latest, should I omit this parameter?

> days-back – integer – the number of days to look back for posts. Optional.

What's the default value? Unlimited, which means if this is not set, the feed will return some items and that will make no-item-action moot? Should this be set to the frequency of the recurring campaign if I want the latest post since the last run? Does it also mean I should set the campaign to run no more frequently than once a day because otherwise the next run will find the same item again?

> no-item-action – string – what action to take when no items are found in the feed. Valid values: postpone-campaign(postpones the campaign till next day). Optional.

What does the campaign do when this is not set and the feed has no item within 'days-back'? Does 'postpone-campaign' postpone it literally till the next day or till the next run according to the campaign's recurring schedule?

> send-only-unique-items – string – if we should only send unique items. if no items are found, then no-item-action is applied. Valid values: (yes or no). Optional.

What's the default value for this, 'yes' or 'no'? If send-only-unique-items is set to yes but no-item-action is omitted, what does the campaign do? Does send-only-unique-items='yes' always require no-item-action='postpone-campaign'? How is an item seen as unique? By the title, the link, title + pub date, the GUID, or ...?

Again, if I want to send only the latest post, do I need:

days-back='1' no-item-action='postpone-campaign' send-only-unique-items='yes'

or

days-back='1' no-item-action='postpone-campaign'

or

no-item-action='postpone-campaign' send-only-unique-items='yes'

assuming I set the campaign to run once per day?

What if I want to run the campaign hourly and send one out as soon as it sees a new post but otherwise not send?
 
Last edited:
I could really use this for some of my clients.
Has there been any further development in terms of providing a more detailed setup documentation?
 
Hi @twisted1919,

Im setting up this feature, and have a question.

The article says: In order to take advantage of this feature, when you create a campaign, you will have to enable the feature.

I can not find where to enable this feature during campaign creation, can you guide me?

Thank you!
 
From what I understand, this system here is to embed some tags INSIDE the emails being sent out.
Is there a way to make it work LIKE THIS?
Also, if we want to just make it to broadcast and send out a campaign automatically whenever we publish a new article, where do we write this HTML
 
Is there a way to make it work LIKE THIS?
That's the exact way we reference here, and in that article.

Also, if we want to just make it to broadcast and send out a campaign automatically whenever we publish a new article, where do we write this HTML
The tags go into your email body. And based on the attributes you use in the tags, your campaign can be postponed from sending until there are new feed items. You may want to combine that with a recurring campaign so it always sends when new posts are added to your wordpress app.
 
Why should it go into the email body? What if that email is deleted?
I was thinking it will be set up somewhere either the mailwizz installation or WordPress installation, with the tags and all.
Ok, Can you give me a simplified html tag that will do what I desire?
 
Why should it go into the email body? What if that email is deleted?
I don't know what you are asking TBH. I mean that goes in your email template body, which does not get deleted.
Can you give me a simplified html tag that will do what I desire?
That's the way to do it, which is presented above. Please take a step back and check the info we presented, it's all there and it's very simple as well. Try it, and if you get stuck, we're here to help.
 
That's the way to do it, which is presented above. Please take a step back and check the info we presented, it's all there and it's very simple as well. Try it, and if you get stuck, we're here to help.
I am not just stock, I dont even know how to start this, LoL
 
Not sure if I should start a new topic. But since @twisted1919 said he'd be here to help, let's try!
I managed to make the recommended html code to work. I had to insert a code snippet inside wordpress to show the post featured image.

The problem I have is with the style, the link to the post is the blank square you see on the left, and the image itself has no link.
1 copy.jpg

This is the code I inserted in the functions.php
Code:
function featuredtoRSS($content) {
global $post;
if ( has_post_thumbnail( $post->ID ) ){
$content = '<div>' . get_the_post_thumbnail( $post->ID, 'medium', array( 'style' => 'margin-bottom: 15px;' ) ) . '</div>' . $content;
}
return $content;
}
 
add_filter('the_excerpt_rss', 'featuredtoRSS');
add_filter('the_content_feed', 'featuredtoRSS');

If anyone has a solution for this, I'd be very grateful :D

Update: when I try with CNN feed I don't get any image at all.
1661402594043.png

I don't think is a hotlink protection issue since I tried deactivating mine and nothing shows.
 
Last edited:
Back
Top