Advertisement:

Author Topic: Birthday Post v0.12.1 Beta (Now RC2 Compatible!)  (Read 94317 times)

Offline Suki

  • Carthago delenda est
  • Lead Developer
  • SMF Super Hero
  • *
  • Posts: 16,115
  • Oh, wouldn't it be great if I *was* crazy?
    • MissAllSunday on GitHub
    • SMF mods
Birthday Post v0.12.1 Beta (Now RC2 Compatible!)
« on: July 31, 2009, 11:49:30 PM »
Birthday Posts v0.12.1 Beta

Warning!
As this mod is a beta, it is strongly suggested that you make a forum backup before installing to prevent any data loss.

Author: JBlaze
Co-Author: Arantor
Current Version: 0.12 Beta
Compatibility: SMF 2.0 RC2
Link to Mod | Comments | Donate                           
Homepage: JBlaze Development
Type: New Feature
Updates: Birthday Posts Updates
Languages:



Features
 Fully customizable via Admin -> Modifications -> Birthday Posts
 Makes a new post when a birthday is detected.
 Option to send a notification PM.
 Available features:
     Custom subject and message
     Choose what member should make the post
     Choose what board to make the post in
     Choose whether or not to update the post count of the poster
     Runs as a Scheduled Task
     Choose whether to post a new topic per user or reuse an existing topic
     Choose whether to post all the day's birthdays in a single post
     Choose whether to send a notice via PM to user
     Choose whether users must have been online in the previous x days to receive a post
     Choose whether users have been part of the community for a period of time before a birthday post
     Can choose whether or not to post birthday posts for banned users



Installation
Any previous versions of this mod MUST be uninstalled BEFORE installing this version.

Simply install the package to install on the SMF Default Core Theme ONLY.

If your theme has its own versions of the language files Modifications.english.php and/or Modifications.english-utf8.php, OR if your using a language other than those supported (listed above) by the mod then you will need to copy the language strings into each custom version of those files.

Useful Links
Manual Installation Of Mods
How Do I Modify Files?



Support
Please use the modification thread for support with this modification.
(Please don't ask me to do the edits for you)



Changelog
Legend:
! = Bugfix
- = Removed
+ = New Feature
o = Update
> = New Language
^ = Initial/New Release

Code: [Select]
1/1/10 - v.0.12.1 Beta
! Fixed throwing posts for all users without dates on 1st January (sorry, stupid bug)
! Fixed installer not always creating new column

12/28/09 - v0.12 Beta (the "Arantor had fun" build)
! Fixed smileys not being recognized; smileys are enabled on all new birthday posts now
! Fixed typo in English/English British regarding an apostrophe
! Fixed hard-coded text string to reuse existing language string
! Fixed extra menu item in Security menu
! Fixed undefined index bp_settings_title
! Fixed PM support entirely :)
! Fixed {link} support for PMs to link back to posts
+ Added {forumname} for PM templates, as well as default PM templates
+ Added protection for duplicating posts; checks for minimum 2 days between posting for a given user
+ Must be active within last days support
+ Minimum time registered on forum support
+ Post to existing topic (must be in the listed board!!)
+ Post all birthdays together (in a comma list, {membername} becomes "person1, person2, person3")
+ Uninstall also tidies up scheduled task run log (since the items never get displayed, they're just phantom data)
+ Made posting/sending to banned users optional (default off)
o Fixed indentation in the main area
o Fixed up installer to use proper installer semantics (db_insert, <database>)
o Removed unneeded $member_name variable when {membername} literal string would be more appropriate
> English-British support added
- License notes removed from installer script (old URL etc). Any reuse/license questions, please direct to [url=http://www.simplemachines.org/community/index.php?topic=328059.0]the mod's thread[/url].
- Removed Turkish translation as needs retranslating for extra features

NB: Future versions probably should split Turkish into separate UTF-8 and ISO-8859-9 (?) files.

10/19/09 - v0.11.2 Beta
! Fixed undefined error for $txt['bp_settings_title']
! Fixed problem with not sending PM's or making posts
> Russian translation added

10/15/09 - v0.11.1 Beta
! Fixed parse error on install.php
! Fixed bug in package-info.xml

10/14/09 - v0.11 Beta
! Fixed sendPM error
! Fixed database errors
o Rewrote messy code
+ Added support for SMF 2.0 RC2

8/05/09 - v0.10.1 Beta, v0.10.2 Beta
! Fixed parse error when running scheduled task
> New language: Turkish

7/27/09 - v0.10 Beta
! Small bug fixed in query.
+ Added feature to send notification via PM.

7/25/09 - v0.9.1 Beta
! Fixed a small bug in ScheduledTasks.php
o Updated settings.

7/24/09 - v0.9 Beta
^ Initial release.
« Last Edit: February 08, 2012, 05:57:35 PM by Suki »
Disclaimer: unless otherwise stated, all my posts are personal and does not represent any views or opinions held by Simple Machines.

Making tough decisions, so you don't have to.

Offline LHW

  • Jr. Member
  • **
  • Posts: 311
  • Gender: Male
  • I am The Lord thy Warlock.
    • The Crystal Fortress
Re: Birthday Post
« Reply #1 on: August 01, 2009, 01:05:32 AM »
Does this create a new thread/topic for each birthday post?  If so, it would be nice to have the additional option of posting this in an already established "birthday thread/topic."

Other than that, this looks sweet, and will be great for absentminded Admins.  ;)  LOL


Offline JBlaze

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 12,178
  • Gender: Male
    • jason.p.clemons on Facebook
    • jasonclemons on GitHub
    • jasonclemons1 on LinkedIn
    • @fragicide on Twitter
    • clemons.io
Re: Birthday Post
« Reply #2 on: August 01, 2009, 01:24:02 AM »
Does this create a new thread/topic for each birthday post?  If so, it would be nice to have the additional option of posting this in an already established "birthday thread/topic."

Other than that, this looks sweet, and will be great for absentminded Admins.  ;)  LOL

That's not a bad idea.

I may add that it the coming update which will add notification PM's/emails along with a link to the topic.
Jason Clemons
Former Team Member 2009 - 2012

Offline chrishicks

  • Full Member
  • ***
  • Posts: 517
  • Gender: Male
    • RejectsRestStop
Re: Birthday Post
« Reply #3 on: August 01, 2009, 01:46:45 AM »
Please tell us 1.1.x users we will eventually get this. "please, please, please"  :)

Offline JBlaze

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 12,178
  • Gender: Male
    • jason.p.clemons on Facebook
    • jasonclemons on GitHub
    • jasonclemons1 on LinkedIn
    • @fragicide on Twitter
    • clemons.io
Re: Birthday Post
« Reply #4 on: August 01, 2009, 01:48:21 AM »
Please tell us 1.1.x users we will eventually get this. "please, please, please"  :)

No unfortunately. This mod makes use of 2.0's Scheduled Tasks function. I would have to write a cron script for it to work on 1.1.x
Jason Clemons
Former Team Member 2009 - 2012

Offline alex30

  • Full Member
  • ***
  • Posts: 605
  • Gender: Male
Re: Birthday Post
« Reply #5 on: August 01, 2009, 06:45:34 AM »
JBlaze if you could please write that cron script, many 1.1. x users will use your mod.

Thanks.

Offline Eclipse16V

  • Sophist Member
  • *****
  • Posts: 1,070
  • Gender: Male
  • Tornado Map
    • Eclipse16V on Facebook
    • @Eclipse16V on Twitter
    • SID Giessen
Re: Birthday Post
« Reply #6 on: August 04, 2009, 12:22:27 AM »
Hi,
nice Mod but I have a problem with it.
The mod doesn´t makes birthday postings on my board.
When I do it manuell, it works. The Scheduled Tasks function doesen´t work.
Now i see that all the user who has yesterday birthday, it makes the post yesterday at 11.00 pm.
In Scheduled Tasks is it on 01.00 am.

Sorry for my bad english
I worked with:
SMF 2 in German

Shop:
SID Giessen

Offline akbora

  • Sr. Member
  • ****
  • Posts: 960
    • Anında Tepki
Re: Birthday Post
« Reply #7 on: August 04, 2009, 04:54:55 AM »
I want to show under 'Name of the poster.' >>>  'Adminstrator'' or other thing... No 'Guest'
SMF 2.0.13
Default Theme
Utf8 Turkish
---------------

Offline JBlaze

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 12,178
  • Gender: Male
    • jason.p.clemons on Facebook
    • jasonclemons on GitHub
    • jasonclemons1 on LinkedIn
    • @fragicide on Twitter
    • clemons.io
Re: Birthday Post
« Reply #8 on: August 05, 2009, 12:49:57 AM »
Updated.

7/27/09 - v0.10 Beta
! Small bug fixed in query.
+ Added feature to send notification via PM.


To upgrade from 0.9 Beta or 0.9.1 Beta, simply install the new package and it will run the upgrade.
Jason Clemons
Former Team Member 2009 - 2012

Offline Groundhog

  • Jr. Member
  • **
  • Posts: 116
    • Hope Centre Burundi
Re: Birthday Post
« Reply #9 on: August 05, 2009, 03:40:37 AM »
Hi JBlaze. Thanks for this mod.

The mod installed perfectly and without problems. However when I try to test by running the scheduled tasks manually I receive this error message?

Code: [Select]
Parse error: syntax error, unexpected T_STRING in /home/******/public_html/home/Sources/ScheduledTasks.php on line 2292
I'm running "SMF Version 2.0 RC1". Any idea what the problem might be?

Many Thanks

Offline edi67

  • SMF Hero
  • ******
  • Posts: 1,532
  • Gender: Male
  • Italian Supporter
    • CrazyZone
Re: Birthday Post
« Reply #10 on: August 05, 2009, 07:15:51 AM »
let me try thx
CrazyZone - My SMF Forum


From the difficult the hardening of the man you can see

Offline JBlaze

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 12,178
  • Gender: Male
    • jason.p.clemons on Facebook
    • jasonclemons on GitHub
    • jasonclemons1 on LinkedIn
    • @fragicide on Twitter
    • clemons.io
Re: Birthday Post
« Reply #11 on: August 05, 2009, 10:14:19 AM »
Hi JBlaze. Thanks for this mod.

The mod installed perfectly and without problems. However when I try to test by running the scheduled tasks manually I receive this error message?

Code: [Select]
Parse error: syntax error, unexpected T_STRING in /home/******/public_html/home/Sources/ScheduledTasks.php on line 2292
I'm running "SMF Version 2.0 RC1". Any idea what the problem might be?

Many Thanks

Hmm... that's odd. I'll get to fixing it right now. Thanks :)
Jason Clemons
Former Team Member 2009 - 2012

Offline Groundhog

  • Jr. Member
  • **
  • Posts: 116
    • Hope Centre Burundi
Re: Birthday Post
« Reply #12 on: August 05, 2009, 10:22:20 AM »
Thanks JBlaze

I have other mods that probably change the "ScheduledTasks.php". Would it help if I give you a copy of my 'ScheduledTasks.php' file?

Offline JBlaze

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 12,178
  • Gender: Male
    • jason.p.clemons on Facebook
    • jasonclemons on GitHub
    • jasonclemons1 on LinkedIn
    • @fragicide on Twitter
    • clemons.io
Re: Birthday Post
« Reply #13 on: August 05, 2009, 10:23:49 AM »
Sure if you don't mind :)
Jason Clemons
Former Team Member 2009 - 2012

Offline Groundhog

  • Jr. Member
  • **
  • Posts: 116
    • Hope Centre Burundi
Re: Birthday Post
« Reply #14 on: August 05, 2009, 10:45:29 AM »
Thanks JBlaze.

ScheduledTasks.php attached.


Offline JBlaze

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 12,178
  • Gender: Male
    • jason.p.clemons on Facebook
    • jasonclemons on GitHub
    • jasonclemons1 on LinkedIn
    • @fragicide on Twitter
    • clemons.io
Re: Birthday Post
« Reply #15 on: August 05, 2009, 11:24:53 AM »
Updated. As said before, simply install the new package. No need to worry about uninstalling first. Once upgraded, you can delete the old package.

8/05/09 - v0.10.1 Beta
! Fixed parse error when running scheduled task
Jason Clemons
Former Team Member 2009 - 2012

Offline timned88

  • Jr. Member
  • **
  • Posts: 363
    • The Magic in Pixels
Re: Birthday Post
« Reply #16 on: August 05, 2009, 12:48:24 PM »
every time i try to install this mod, i get the following area at the mod settings page in the forum admin...

// Modify Birthday Posts Settings function ModifyBirthdayPostsSettings($return_config = false) { global $txt, $scripturl, $context, $settings, $sc, $modSettings; // Options to configure $config_vars = array( $txt['birthday_admin_desc2'], array('int', 'birthday_board'), array('int', 'birthday_posterID'), array('text', 'birthday_posterName'), array('check', 'birthday_increase_post_count'), array('text', 'birthday_messageTitle'), array('large_text', 'birthday_message'), '', array('check', 'birthday_sendPM'), array('check', 'birthday_pmSameUser'), array('int', 'birthday_pmID'), array('text', 'birthday_pmUsername'), array('text', 'birthday_pmTitle'), array('large_text', 'birthday_pmBody'), ); if ($return_config) return $config_vars; $context['post_url'] = $scripturl . '?action=admin;area=modsettings;save;sa=birthday'; $context['settings_title'] = $txt['mods_cat_modifications_misc']; if (empty($config_vars)) { $context['settings_save_dont_show'] = true; $context['settings_message'] = '
' . $txt['modification_no_misc_settings'] . '
'; return prepareDBSettingContext($config_vars); } if (isset($_GET['save'])) { checkSession(); $save_vars = $config_vars; saveDBSettings($save_vars); redirectexit('action=admin;area=modsettings;sa=birthday'); } prepareDBSettingContext($config_vars); }

Fatal error: Call to undefined function ModifyBirthdayPostsSettings() in /home/themagic/public_html/forum/Sources/ManageSettings.php on line 220

Offline JBlaze

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 12,178
  • Gender: Male
    • jason.p.clemons on Facebook
    • jasonclemons on GitHub
    • jasonclemons1 on LinkedIn
    • @fragicide on Twitter
    • clemons.io
Re: Birthday Post
« Reply #17 on: August 05, 2009, 12:51:56 PM »
timned88, are you doing a manual install?
Jason Clemons
Former Team Member 2009 - 2012

Offline Özgür

  • SMF Hero
  • ******
  • Posts: 3,926
  • Gender: Male
  • Özgür | jQuery Lover
    • ozgurce on Facebook
    • @ozgurce on Twitter
    • Özgür Yalçın
Re: Birthday Post
« Reply #18 on: August 05, 2009, 01:00:27 PM »
Quote
Does this create a new thread/topic for each birthday post
Is this feature added ?
So Long

Offline JBlaze

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 12,178
  • Gender: Male
    • jason.p.clemons on Facebook
    • jasonclemons on GitHub
    • jasonclemons1 on LinkedIn
    • @fragicide on Twitter
    • clemons.io
Re: Birthday Post
« Reply #19 on: August 05, 2009, 01:06:49 PM »
Quote
Does this create a new thread/topic for each birthday post
Is this feature added ?

Yes, it creates a new topic for each birthday. If there are 4 birthdays on one day, it will create 4 posts.
Jason Clemons
Former Team Member 2009 - 2012