Good morning!
Generally ElkArte send E-Mails. All went well!
But...the attempt send out newsletter (admin;area=news;sa=mailingsend) failed. Return in a blank page.
At the moment no access to server, therefor not in greater detail. Sorry.
Regards
NetFlag
Thanks NetFlag!
It's a missing require.
In sources/admin/ManageNews.controller.php:
// Get the smelly people - note we respect the id_member range as it gives us a quicker query.
require_once(SUBSDIR . '/News.subs.php');
ETA Fixed locally, will push "soon". ;)
And again, codefix in a great pace. You knows ElkArtes stuff. Neat!
But there is still a bug there... lol
https://github.com/emanuele45/Dialogo/commit/255a2a18cb2e51bce9070828158bedef065cfba6
And while I was there, I added also an intermediate page when the news letter is finished to inform of the successful sending:
https://github.com/emanuele45/Dialogo/commit/f74a51143cd617c2e5e9ae727aa396d225b05d0f
technically I think there is a sort of bug that there is no indication that the newsletter was sent to 0 members (in case nobody fits into the conditions), it should be fixed as well.
I can do what I want, loading bar stops at 8,33%. Only the administrator (uid1) receives the mail. :(
Ohhh.. right there were more things:
https://github.com/emanuele45/Dialogo/commit/e00baaab921e71f3b397bf208337d388c63d6fd1
https://github.com/emanuele45/Dialogo/commit/3c21ebf92309ccdf65ae087d96357589786bdf85
Now Im confused. This is my sources/Subs.php Line
3125 till
3169.
// Output the declared Javascript variables.
if (!empty($context['javascript_vars']) && !$do_defered)
{
echo '
<script><!-- // --><![CDATA[';
$output = array();
foreach ($context['javascript_vars'] as $key => $value)
$output[] = $key . ' = ' . $value;
echo '
var ' . implode(",\n\t\t\t", $output) . ';';
echo '
// ]]></script>';
}
// Inline JavaScript - Actually useful some times!
if (!empty($context['javascript_inline']))
{
if (!empty($context['javascript_inline']['defer']) && $do_defered)
{
echo '
<script><!-- // --><![CDATA[';
foreach ($context['javascript_inline']['defer'] as $js_code)
echo $js_code;
echo '
// ]]></script>';
}
if (!empty($context['javascript_inline']['standard']) && !$do_defered)
{
echo '
<script><!-- // --><![CDATA[';
foreach ($context['javascript_inline']['standard'] as $js_code)
echo $js_code;
echo '
// ]]></script>';
}
}
}
No match to yours
here on Github. (https://github.com/emanuele45/Dialogo/commit/3c21ebf92309ccdf65ae087d96357589786bdf85)
Then probably you are using a version of few days ago and the code is still the old one, then the other one should be enough. ;)
Ah, I was not yet clear about the package get updates. So its me to upgrade my installation.
Have to test a little bit more on weekend.
Thank you Emanuele!
Starting from the beta up to now, we didn't change anything on the database, so it is enough to just grab the package and replace the files in order to be up-to-date! :)
Now everything is on the current state here. Test send out newsletter. Elk says all went well:
It is not. Actually still only members of the group Administrator get mails.
Edit:
New evidence. Delivery only fails if user still has
no primary membergroup.
/me marks this topic unread...
...also failed is user in additional group. :'(
Try this, in admin/ManageNews.controller.php:
// Some functions we will need
require_once(SUBSDIR . '/Mail.subs.php');
Use the comment too because there are two instances of the require_once and only the one with the comment is the important one in that case.
And just after it add:
require_once(SUBSDIR . '/News.subs.php');
Unfortunately not. All groups, expect my new "Newsletter" (2 Members inside) , uncheckt. Nevertheless no one recieved email. That's Greek to me.
Try the one attached.
Replace the one in sources/admin/
ETA: also, secondary groups are not considered at all... should they?
ETA2: attachment removed
Sourcefile can not be read. Tried 5 times. 5 minutes later i get it.
Brood...for my logical understanding, yes. Otherwise for me it is very irritating.
Edit:
Unfortunately, the attached file does not work. Same as before.
Can you check the error log to see if there is anything there that could be related?
Nothing in there. Strange....
Can someone else reproduce this?
Additional groups are included.
Can you try for debugging the one attached?
When the process is finished it will show you a message with a code block, can you copy and paste the content of the block here?
Sorry for all the downloads on that file, that was me testing to find out why it was doing that ... Figured it out :)
Members to include see attachment. (3 Members)
This is the result:
members_collected: 1
members_sent: 1
completed
Found it!!
It was a bug introduced last summer in SMF , these two changes should fix it:
https://github.com/emanuele45/Dialogo/commit/304e22dd368c6386428c1b65583a4da593a32215
Sorry, no success message. :(
Groups to receive: Newsletter (2 Member)
Only one receive the mail.
Groups to receive: Newbie (3 Member in)
Only two of them receive the mail.
Groups to receive: All checked (3 Member overall)
Only two receive the mail.
Big thanks for your tireless assignment!!
I found some other bugs around and a mostly duplicated function, now is a bit late, I'll try to fix everything tomorrow... :(
NetFlag, just to be 100% sure, are all the three members activated?
If you go to the member list (the public one at ?action=memberlist) do you see the three of them?
I'm asking because there was a bug that was counting non-active members too, but apart from that I can't reproduce the issue... :-\
All members are activated and visible in public meberlist.
New upload overall files from current available Github:
https://github.com/elkarte/Elkarte
Patch included:
https://github.com/emanuele45/Dialogo/commit/304e22dd368c6386428c1b65583a4da593a32215
Apparently I'm the only one had the problem. No one else??
Compared with SMF there is a missing variable called $normalGroups. Cant find another approach.
I have installed an test SMF too. No problems with send out newsletter.
/me php != php
ElkArtes' Code is much different to mybb. For me some difficulties to read it.
Still learning...
Okay, let's try to reproduce the thing on a similar system.
You have a clean install, right?
3 users: one admin and two in a group "newsletter"? (Is it a normal group? Something special about it in terms of settings?)
Other "special" settings? (Dunno, deny permissions on, or post-based groups permissions? Things like that.)
No special settings. The group "Newsletter" is additionel, inherit from "normal members".
One admin.
The other two are members in "normal menbers" and "Newsletter". The goal is to send emails only to members of group "Newsletter".
The problem, only one of them recieve.
Can you try with the attached sources dir? ???
From this morning till now I test with this mail problems. I found it. Mea culpa that I need this long time to figured it out.
The only reasen to this problem was a wrong emailadress for one of my member. Goof!
Now I can say ElkArte works.
Im so sorry. I did not expect to wrong emailadress.
I asked myself:
Why is this not written in errorlog?
Answer:
The mailadress exists. A noninvolved get spamed by me. oh, my goodness....
/me could kick himself.
It really does sadden me that you emanuele have unnecessary work with me.
lol
It happens! ;D
No problem, the first bug was absolutely legitimate! And while debugging the non-bug I found and fixed several other things (and hopefully improved a tiny bit a nasty function).
Well then, time to merge!
Glad to read the whole has actually something good. Thank you for your understanding.
@ALL
Have a nice weekend, merry Christmas and a happy new year!
/me away from keyboard from 12.21,2013 till 01.07,2014 8)
/me is a bit late for NetFlag's merry Christmas (he is already away... :()
Oh well, happy 2014 NetFlag and all!