Move the IBM example module from 4.7.x to 5.x?

verbal - December 7, 2006 - 12:48

I have been trying for a few days now to move the IBM example module ( http://www-128.ibm.com/developerworks/ibm/library/i-osource6/ ) to drupal 5 beta 2. I was able to follow the article very well and understand how the module works, but upgrading it to 5.x is proving to be a bit more difficult. I read the article a while back about how one guy upgraded tagedelic to 5.x, but he touched on only a few of the updates that I need to move the example module to 5.x. I have also read the list of changes from 4.7.x to 5.x but its a little bit over my head. My goal is to move the module to 5.x and then write a book entry on this site to help other's move it to 5.x so they can see how that article would have looked in 5.x instead of 4.7.x because the article was very good at explained things well but it was all explained in 4.7.x, which is quickly becoming outdated. Would anyone like to help? Or if someone is feeling nice, convert it to 5.x and then I can look at what was changed and I'll write the book entry?

Thanks,
-Steve

Updating announcement module to 5.x

louisw - December 11, 2006 - 15:53

One of the biggest changes moving from 4.7 to 5.x is the use of the .info file. If you add this file (announcement.info) to the announcement module directory things should work. The contents of the file should be something like:

name         = Announcement
description = Represents an announcement on the IBC web site
package     = IBC - core

hope that helps,
louie

Updates to the form api also

verbal - December 12, 2006 - 00:56

Updates to the form api also need to be applied. And there a few changes to settings and things being moved into the hook_menu stuff. I kinda know what needs to happen, but i've never updated a module before so I was just looking for someone who wanted to help me, but judging by your e-mail you are going to update the article to 5.x sometime anyway, so I'll take a crack at it and look at how you updated it when you finish updating the article.

Thanks,

-Steve

Source code of IBM Announcement module for Drupal 5.x

rodolphe - June 19, 2007 - 18:00

Louis, Steve,

Has any of you been able to tweak the code to make it work under Drupal 5.x? I'd really appreciate getting it. I have tried to change some hooks but it still doesn't work.

Cheers,

R

4.7 version?

heuristik - February 9, 2007 - 04:56

Just out of curiosity, has anyone built the module who is willing to make it available as a 4.7 module?

Excellent, extensive &

coupet - February 23, 2007 - 03:32

Excellent, extensive & detailed tutorial and highly recommend!

Looking forward to Port 5.0

----
Darly

Has anyone tried the Coder module?

NancyDru - June 19, 2007 - 21:56

It will analyze a module and tell you what to do to upgrade it.

Nancy W.
Drupal Cookbook (for New Drupallers)
Adding Hidden Design or How To notes in your database

Coder review of Announcement module

rodolphe - June 20, 2007 - 06:31

Unfortunately it doesn't detect any anomaly for upgrading to 5.x.

Pardon the bump here, but

TheGorf - May 4, 2008 - 04:54

Pardon the bump here, but has any work been done on this module to port it to 5.x or 6.x? This is SUCH a useful module but I am now running on 5.x and can't use it. Perhaps I am missing something. I saw that the IBM link talked about upcoming changes when Drupal 5 was in beta, but then never say any port work done. I'm very new to module development so I am tinkering with building my own version of this, but the 4.x worked so nicely and exactly like I wanted that it would be nice to see it ported.

Thoughts?

Done

NancyDru - May 5, 2008 - 01:46

http://drupal.org/project/announcements

@verbal: your offer to do documentation would be most welcome.

Donations to underwrite this will be accepted, contact me for a Paypal address.

Nancy Dru (formerly Nancy W. until I got married to Drupal)

Well I just tried to install

TheGorf - May 5, 2008 - 21:24

Well I just tried to install it on my 5.7 Drupal, and it doesn't do anything. It says it installed it correctly, but the administration page doesn't come up (isn't listed on the Admin page), and the database changes don't get made. The first thing I noticed is that all the hook_ calls in the .module file and the functions in the .install doc are all "announcement_" but (and correct me if I'm wrong) doesn't Drupal reference a module by the name of it's install directory? The install directory in the download package is "announcements" <- note the trailing "s". However even if I alter the directory name, I still get the same response.

Should I report this as a bug?

Lastly there are some things that I can change in the module to help clean it up as some of the comments and what not are IBM centric. If this help is wanted, how do I go about submitting new versions of the code?

I fixed it already

NancyDru - May 6, 2008 - 00:23

I created it as the "announcement" module, but it turns out there was already a module by that name. So I renamed it to "announcements" but forgot that ll the internal function names had to be changed. I have done that now.

But, by all means, create issues - it is a contributed module now.

Nancy Dru (formerly Nancy W. until I got married to Drupal)

 
 

Drupal is a registered trademark of Dries Buytaert.