By Nelson Elliott on Thursday, 25 April 2013
Posted in General Issues
Replies 8
Likes 0
Views 817
Votes 0
How do I limit the length of an email notification? I'm specifically interested in the email sent for new blog posts.

I very quickly figured out how to do it once before, but this time around I have spent a few hours and not been able to replicate what I did before.

As an aside:
I tried this post, but despite showing up as an EasyBlog result in the Forum search, it says I don't have a subscription: http://stackideas.com/forums/can-i-limit-the-length-of-email-notifications.html
I know this is an old post, but what if you WANT the front page to be full length, but the email to be a teaser? Any idea how to do that?
·
Wednesday, 24 December 2014 07:30
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello Brian,

It is not possible unless you hack the code to do so.
·
Wednesday, 24 December 2014 10:30
·
0 Likes
·
0 Votes
·
0 Comments
·
I don't suppose you could point me to some code I could steal from another template file could you?
·
Wednesday, 24 December 2014 11:03
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello Brian,

There are two ways to do this; 1. You only truncate the email content manually using php substr which is very straightforward. 2. Modify the core file to handle the truncate. If you choose no.1, the file is here: ../components/com_easyblog/themes/default/email.blog.new.html.php. You can truncate the $blogIntro on line 73.
·
Wednesday, 24 December 2014 11:26
·
0 Likes
·
0 Votes
·
0 Comments
·
Yeah, I've already hacked the email template a bit to add a logo, load a google font and also load the large blog image, so I'll look at using truncate too. Thanks!
·
Wednesday, 24 December 2014 11:31
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello Brian,

Great, I'll assume you already know how to truncate it based on my reply above.
·
Wednesday, 24 December 2014 12:00
·
0 Likes
·
0 Votes
·
0 Comments
·
I'm not a programmer, but I've hacked a few bits of code from time to time. I'm sure I'll figure it out.

thanks!
·
Wednesday, 24 December 2014 12:06
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello Brian,

Great. You're welcome.
·
Wednesday, 24 December 2014 17:26
·
0 Likes
·
0 Votes
·
0 Comments
·
View Full Post