[RC] Digests 3.2.11

A place for Extension Authors to post and receive feedback on Extensions still in development. No Extensions within this forum should be used within a live environment!
Anti-Spam Guide
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

IMPORTANT: Extensions Development rules

IMPORTANT FOR NEEDED EVENTS!!!
If you need an event for your extension please read this for the steps to follow to request the event(s)
LCSF082
Registered User
Posts: 9
Joined: Sat Dec 08, 2018 12:51 pm

Re: [RC] Digests 3.2.10

Post by LCSF082 » Sat Dec 15, 2018 8:35 pm

It's not working that way for me. Presently I only have 2 accounts. The admin account and 1 user account (obviously different email accounts). I logged in to admin and created a new topic and the user account received a notification of the new topic immediately. After that notification, I did not log out of the admin account, nor visit the forum from the user account. I then created another new test topic and the user email account received an immediate notification of the new topic. I also created a new topic in a different forum that the user account was not subscribed to and the user email did not get any notifications.

I do know that this works if I can get the settings correct as I regularly participate in another phpbb based forum that works in the manner I expect.

Thanks for your assistance.

User avatar
MarkDHamill
Registered User
Posts: 3582
Joined: Fri Aug 02, 2002 12:36 am
Location: Florence, MA USA
Contact:

Re: [RC] Digests 3.2.10

Post by MarkDHamill » Sat Dec 15, 2018 8:55 pm

I think you should be posting this question on notifications in one of the support forums. This is a topic for the digest extension only.
Get the latest versions of my Digests and Smartfeed mods and extensions.
Need phpBB services or a phpBB consultant? I offer most phpBB services.

LCSF082
Registered User
Posts: 9
Joined: Sat Dec 08, 2018 12:51 pm

Re: [RC] Digests 3.2.10

Post by LCSF082 » Sat Dec 15, 2018 9:04 pm

OK, I think I found the problem. It was discussed on this thread: viewtopic.php?t=2429516
Apparently phpbb does not keep track of whether or not the user has been notified by email, just whether or not they have been notified by notifications. I disabled email notification in the user account UCP and created a new topic from the admin account and - presto - no email. I suppose the user could mark specific topics or forums to be notified by email if they consider those topics/forums urgent.
I have not yet found how to set the default notification options for a new user upon registration, but I'll keep looking.
Thanks

LCSF082
Registered User
Posts: 9
Joined: Sat Dec 08, 2018 12:51 pm

Re: [RC] Digests 3.2.10

Post by LCSF082 » Wed Dec 19, 2018 1:34 pm

The link at https://www.phpbb.com/customise/db/exte ... ension/faq to the FAQ provided in the Read Me file does not work.

Do you have an updated link? I am looking for information regarding setting up a system cron task so that the digests are automatically sent out. Presently they only seem to be sent out after I wake up phpbb by logging in to the admin account.

Thanks

User avatar
MarkDHamill
Registered User
Posts: 3582
Joined: Fri Aug 02, 2002 12:36 am
Location: Florence, MA USA
Contact:

Re: [RC] Digests 3.2.10

Post by MarkDHamill » Wed Dec 19, 2018 1:37 pm

The link will appear when the extension is approved. However, it's mostly a cut and paste of the content on the first post of this topic.
Get the latest versions of my Digests and Smartfeed mods and extensions.
Need phpBB services or a phpBB consultant? I offer most phpBB services.

User avatar
MarkDHamill
Registered User
Posts: 3582
Joined: Fri Aug 02, 2002 12:36 am
Location: Florence, MA USA
Contact:

Re: [RC] Digests 3.2.10

Post by MarkDHamill » Sun Dec 23, 2018 5:56 pm

canonknipser wrote:
Mon Dec 10, 2018 3:17 pm
colinshead wrote:
Mon Dec 10, 2018 1:22 pm
the Digests extension to grab the files, and create plain old .jpg's or similar from them, store them somewhere and link them into the Digest e-mails !!
No need to create any "Plain old .jpg's or similar", because the files are already there. phpBB just stores them under a unique random file name in the files-folder. You can grab the storage systems filename from the attachment table (the attachment-id is in the file.php-parameter id, the file name on the storage system is in physical_filename). If there is a thumbnail-file for images (thumbnail = 1), you can use the physical filename prepended by a string thumb_ to link the smaller image. The mime-type for the file you can grab from column mimetype to determine if you have a image (img-link) or a different sort of file (standard-a-link). The path for linking attachments directly is http://example.org/files (example.org is your boards address)
I've been doing some testing to see if this is possible. It doesn't appear to be. The resulting HTML look something like this:

Code: Select all

<a href="http://127.0.0.1/phpbb/files/thumb_2_1294173054e11e14dc2e971eab09956f"><img src="http://127.0.0.1/phpbb/files/2_1294173054e11e14dc2e971eab09956f" alt="Not sure what this is" title="Not sure what this is"></a>
With no suffix to the file, the browser doesn't know how to render it. It could be an image but it could be a document or pretty much anything. At least Firefox won't bother to read the file and try to figure it out. More importantly, it's ambiguous to the email client.

If the <img> tag had some sort of attribute that allowed for the assertion of the MIME type, then perhaps. I don't see anything in the specification.
Get the latest versions of my Digests and Smartfeed mods and extensions.
Need phpBB services or a phpBB consultant? I offer most phpBB services.

User avatar
canonknipser
Registered User
Posts: 1758
Joined: Thu Sep 08, 2011 4:16 am
Location: Germany
Name: Frank Jakobs
Contact:

Re: [RC] Digests 3.2.10

Post by canonknipser » Sun Dec 23, 2018 10:55 pm

Right - so a way to handle this problem may be to copy the thumbnail file (or the image file) to a extensions specific store folder appending the proper extension according to the mime type - so something like

Code: Select all

<img src="http://127.0.0.1/phpbb/store/digest/files/thumb_2_1294173054e11e14dc2e971eab09956f.jpg" alt="Not sure what this is" title="Not sure what this is">
- no <a>-tag around the image.

Another way would be, as already discussed, including the image into the mail body, giving the file as binary data (base-64-encoded). When there are no thumbs, the mail will be quite big. There are a lot of examples how to do that, eg. https://stackoverflow.com/questions/387 ... -html-mail
Greetings, Frank
phpbb.de support team member
English is not my native language - no support via PM or mail
New arrival - Extensions and scripts for phpBB

User avatar
MarkDHamill
Registered User
Posts: 3582
Joined: Fri Aug 02, 2002 12:36 am
Location: Florence, MA USA
Contact:

Re: [RC] Digests 3.2.10

Post by MarkDHamill » Mon Dec 24, 2018 2:36 am

A future project, perhaps, for embedding photos. The <a> tag has a type attribute where you can specify the MIME type. But based on my testing it doesn't make the images appear.

Images are linked in HTML digests so they can be seen in a browser if desired.
Get the latest versions of my Digests and Smartfeed mods and extensions.
Need phpBB services or a phpBB consultant? I offer most phpBB services.

User avatar
MarkDHamill
Registered User
Posts: 3582
Joined: Fri Aug 02, 2002 12:36 am
Location: Florence, MA USA
Contact:

Digests 3.2.11 Released

Post by MarkDHamill » Wed Dec 26, 2018 12:47 am

Digests 3.2.11, "Merry Christmas Edition", is now available. See first post for the download link. Remember that the files are placed in the /ext/phpbbservices/digests folder. If updating, disable digests first. Then remove it from your tree, upload the new version and then enable.

Principally, this release addresses more concerns by the extension review team, but also fixes the big bug in 3.2.10 that would not create the /store/phpbbservices/digests folder correctly. This folder is used with the manual mailer and contains the digest in file form for inspection.

I may be nearing the end of this very long review process. The issues to be fixed were just a handful. However, given that it is a very large and complex extension as these things go, they tend to see new things and request more corrections. So we'll see.

Change log:

Bug fixes:
  • Fixed critical bug that did not provide the proper path for creating the /store/phpbbservices/digests folder
  • libxml internal errors are suppressed when digests contain tags the administrator wants removed
  • Embedded image text in HTML digests are wrapped inside a <div> to ensure the text appears below the Attachments text instead of next to it
Changes requested by the extension review team:
  • The Manual Mailer calls the mailer using a container object rather than instantiating a separate object
User interface:
  • HTML input fields of type number are right aligned and not as wide
  • Forms that contain checkboxes for forums now use the common HTML input name of forum[]. This allows them to be treated as arrays by PHP, simplifying the logic for subscribing and unsubscribing to individual forums.
Other:
  • html_messenger class updated to override methods from a phpBB 3.2.5 version of /includes/functions_messenger.php instead of the 3.2.2 version
  • README contains link to Spanish language translation
Get the latest versions of my Digests and Smartfeed mods and extensions.
Need phpBB services or a phpBB consultant? I offer most phpBB services.

colinshead
Registered User
Posts: 51
Joined: Sun Mar 29, 2015 11:37 am

Re: [RC] Digests 3.2.11

Post by colinshead » Fri Dec 28, 2018 12:50 pm

Hi Mark,

Another question about system cron. I have a 15 minute curl cron set up as previously advised, this is working fine, and digest emails are being created at the correct times. I am not sure though whether the digest emails are actually sent promptly, I think until phpbb is woken up by user interaction the emails remain in the queue.

I have use of system cron turned off in ACP also as per the advice.

Is there any reason I should not also create a conventional phpbb system cron to wake up phpbb at say 5 minute intervals to make sure that the digest emails are promptly delivered? i.e. have two system cron tasks running.

All the best

Colin

User avatar
MarkDHamill
Registered User
Posts: 3582
Joined: Fri Aug 02, 2002 12:36 am
Location: Florence, MA USA
Contact:

Re: [RC] Digests 3.2.11

Post by MarkDHamill » Fri Dec 28, 2018 1:38 pm

I'm curious about your email package size. If it is set to 20, twenty items will get emailed in a batch. If could include digests but it might be notification emails too. In this case the next 20 in the queue should go out the next time your system cron is run, in fifteen minutes based on how you are set up.

System cron should only be turned off if you are not using CLI, for example, if you programmed a cron to use curl.
Get the latest versions of my Digests and Smartfeed mods and extensions.
Need phpBB services or a phpBB consultant? I offer most phpBB services.

colinshead
Registered User
Posts: 51
Joined: Sun Mar 29, 2015 11:37 am

Re: [RC] Digests 3.2.11

Post by colinshead » Fri Dec 28, 2018 2:11 pm

Hi Mark,

To solve notification email issues with a much earlier version of phpbb I have email package size set to 50000.

My board has been quiet over Christmas, and I have noticed my digest emails timed at 05:00 seem to arrive some hours later when a user such as myself has accessed the board.

The admin log though does indicate the digest email was created at 05:00, and the email when it arrives has an 05:00 time stamp.

I am curious whether the system from curl task dies actually trigger the email dispatch.

All the best

Colin

User avatar
MarkDHamill
Registered User
Posts: 3582
Joined: Fri Aug 02, 2002 12:36 am
Location: Florence, MA USA
Contact:

Re: [RC] Digests 3.2.11

Post by MarkDHamill » Fri Dec 28, 2018 2:16 pm

It sounds like your cron process is not working correctly. The testing process is in the first post. If the cron is not set up correctly, digests are sent when there is board traffic because that's how phpBB's cron process works. When using curl, you are essentially hitting the forum, pretending to be a human, to kick off phpBB's own cron.

You may want to set the email package size to 0. This removes the queue and sends emails one at a time, a somewhat slower approach. It assumes there are no quota issue with outgoing emails imposed by your web host.
Get the latest versions of my Digests and Smartfeed mods and extensions.
Need phpBB services or a phpBB consultant? I offer most phpBB services.

colinshead
Registered User
Posts: 51
Joined: Sun Mar 29, 2015 11:37 am

Re: [RC] Digests 3.2.11

Post by colinshead » Fri Dec 28, 2018 4:01 pm

Hi Mark

I have reset the email package size to 0, and will see how it goes.

I am sure that the curl system cron process is working OK, as the digest mails are now created at precise hourly intervals, whereas before I had set the cron task up the message creation time was totally dependent on a user accessing the forum, so that preceding digest e-mails were 'bunched' and all were created together.

I'll monitor the board for a few days to see how it behaves.

All the best and a very happy New Year.

All the best

Colin

kamaleon
Registered User
Posts: 436
Joined: Tue Sep 09, 2014 9:47 am
Location: Barcelona

Re: [RC] Digests 3.2.11

Post by kamaleon » Sun Dec 30, 2018 9:12 am

How can I check what day of the week a subscriber should get his digest?

Thanks

Post Reply

Return to “Extensions in Development”

Who is online

Users browsing this forum: Exabot, Forex Station, Gubkin, Holger, Mannix_, nou nou, SinusVonAlpha, Wormnest and 31 guests