Closed (fixed)
Project:
Authorship Module
Version:
5.x-1.1
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Reporter:
Created:
14 Jun 2006 at 23:45 UTC
Updated:
25 Apr 2007 at 10:01 UTC
Jump to comment: Most recent file
Comments
Comment #1
AjK commentedGood point actually. I've just had a look over the API and it appears the "comments" module is less flexible than the "node" module. There's awful lot you can do with nodes but seems alot less you can do with comments.
I'm sure it's possible just I can't see it at a quick look.
I will look in more detail when I get time but if someone else reads this and can point me in the right direction then let me know please.
best regards
--AjK
Comment #2
StuartMackenzie commentedyeah just wanted to add a quick note to say yes it's a great module but unfortunately won't be any use unless it can be applied to comments also
Comment #3
AjK commentedThe API for "comments" doesn't extend the scope of modifying them in the same way that "nodes" do. So I'm afraid this isn't possible to do as a module but would need changes to comments.module which is a core module. That means a patch against core rather than a "free standing plugin" module.
So, I don't see this happening as I'm not going to create a core patch that needs maintenence each time comments.module is updated.
If I had the time I'd make a patch for comments.module that added enough API to do what's needed by modules and try and get that patch into core. But right now, I'm rather too busy on other projects to give it the attention it warrents.
best regards
--AjK
Comment #4
AjK commentedComment #5
magnusprime commentedThis seems like an issue with core that should be raised to development team. I agree that it would be much more friendly if it worked with comments as well.
Comment #6
lafo commentedDrupal 5 comment.module offers hooks for implementing the authorship functionality in comments. The attached patches will do the trick.
Patch both authorship.module and authorship.install and run the update script (!). Select update 2 for the Authorship module.
For fresh installations simply enable the patched module.
List of changes:
1. authorship.module:
a) authorship_form_alter(): authorship controls in the comment-form
b) authorship_form_alter(): authorship controls in the comment-admin-settings
c) authorship_comment(): implementation of hook_comment()
d) authorship_nodeapi(): INSERT is performed only when at least one of {$node->authorship, $node->profile_real_name} is specified. No point of storing empty rows.
2. authorship.install:
a) authorship_install(): updated DB structure
b) authorship_update_2(): to update previous installations of the Authorship module
c) authorship_uninstall(): implementation of hook_uninstall()
Comment #7
lafo commented...and the 2nd patch (see above)
(I was unable to attach both files to a single post)
Comment #8
AjK commented@lafo : I have added you to the CVS access for this module :)
Comment #9
lafo commentedThanks, I committed the updated files to the CVS.
Comment #10
AjK commentedHi, and thanks for the effort. Just a couple of things.
When you committed your patch your commit message was pretty verbose. Really, all you need do for a commit message is "#69091 by myself". The Drupal system picks up the #69091 as a d.o node number and links to it (this issue) and you can attribute the patch to, er, yourself! (as it's your work).
Also, after committing to CVS to fix an issue, don't forget to change the issue status to "fixed".
Also, I think your work was on the DRUPAL 5 branch (as it has better comment support). In that case you should also update the "Version" of this issue to reflect what branch you are "fixing". If you are happy with your work don't forget to add a CVS tag and do a release.
Thanks for your time on this module. I will leave CVS access enabled for you so you can continue to co-maintain it when ever you feel like it.
regards,
--Andy
Comment #11
(not verified) commented