Creating a port to Drupal 6 Info & Questions
| Project: | Inline Registration |
| Version: | 5.x-1.x-dev |
| Component: | Code |
| Category: | task |
| Priority: | normal |
| Assigned: | himerus |
| Status: | closed |
I've just this week come across 2 projects (one client, and one personal) where this module would be very useful.
I am no longer using Drupal 5 unless a client forces me to, so I need this module to work on Drupal 6.
I've used the Deadwood module to do a "Quick fix" upgrade to 6, and it's currently "working" in it's most basic format.
I need to update the mail functionality, as the automated system emails for registration aren't working.
I will also be adding in a configuration page with at least for now, node type options, which will allow users to select node types, which are allowable for the inline_registration functionality.
With the current functionality I have in Drupal 6, and I don't know if it's the side effect of the upgrade from 5.x, or intended functionality, however, I must turn on permissions for anonymous users to create content of the specified node types I want to use.
I'd like to see it so that I can set in the normal Drupal permissions that only an Authenticated user can post to the content types I want to use, but STILL display the inline_registration, and node form to anonymous users in those cases.
So my question is if that was the original way? Did anonymous content posting have to be enabled for it to work and make the node form page visible?
Either way, I'm working on a version for the 2 sites I need it for, and will share back here when ready. Depending on the interest of the current developer, I'd consider maintaining this project going forward. (I would only support Drupal 6 moving forward)
Any information would be appreciated as I tackle this conversion, and feature upgrades to make it a bit more friendly.

#1
Hi Jake-
Great to hear you can help with the upgrade. The node type setting would be very helpful to some, I'm sure.
It is intended that you must turn on permissions for anonymous users to create content for the desired node types. In Drupal 5 I was unable to figure an easy way around this, and it suited my purposes. Perhaps with Drupal 6's hook_menu_alter() it is possible to alter the access for the /node/add/nodetype menu item.
Are you comfortable with rolling patches and/or CVS? I'll happily add you as a maintainer to the project if you'd like.
-Matt
#2
Hey Matt,
Thanks for responding quickly. I spent several hours playing with this last night. My first implementation of this in Drupal 6 is on my new corporate site, where users would only be allowed to create a single node type. (quote).
I did some basic testing with the access permissions, and read about 20 different pages on Drupal regarding the inability of modules to use something like hook_access() to control a node types permission to a node that module didn't create. It appears impossible until D7, where they are looking at an option in hook_nodeapi() which "should" allow other modules to manipulate the access control of another modules node type.
I played around with it a ton, just as I wanted it to be allowed so that the site admin "could" disallow anonymous users to post a content type, but IF the node type was selected as an inline registration node, it would override this setting. I think this makes the most sense going forward, because if an admin has to set anon permissions to post the content type, and then later turns off the inline registration module, AND forgets to disallow anon users the permission, then the content type(s) are wide open to spam. It DOES currently work the way it is, but I think for usability, and user convenience, this makes the most sense.
I did test it out on my D6 install, and it DOES NOT allow anon users to actually post the content type, which is good, and is a solution for now. Possibly just making it very clear that if they uninstall the module, they MUST check the access permissions to anonymous users.
I think in D7, it will be possible to rewrite the core so it observes proper access permissions, and ONLY overrides the settings if it is a node type that is defined in the inline_registration settings.
In my D6 version, I currently am correctly selecting node types available for this feature, AND included a simple weight widget to move the registration form up or down in the node form based on one of the easy requests I saw in the issue queue.
I really like this module, and would for sure not mind making commits on the D6 version and D7 moving forward. I've got a couple I've published here, ShareThis & PingThis. Both are quite simple, and the only ones I've been able to make publicly available so far. I've written tons of custom modules for clients that are either for private clients, or that wouldn't apply to the Drupal community.
I think there's a lot of room to expand the features in the D6+ versions, but this is a GREAT feature that I'm starting to need more and more on sites.
I'd like to also see in my feature list the ability to possibly toggle the register and login forms from this module. So it would load both in the node.
I like how it currently validates on the node submit, but maybe, based on my external client's needs, I may figure out a way to submit either that login or registration form that is at the top of the node form via AJAX, and then update the node page, without the login/reg form, and update with proper user data.
Then also another feature that would really be needed for widespread usage would be the ability to save nodes as non-published if administrator approval was required on nodes, then setting an action to once a user has confirmed their registration, this module would publish any non-published nodes of the content types defined in the settings for this user.
Just a few points for thought, and where my current needs may take some of the features...
#3
I'm willing to help with this, as I would like to use this module too for D6. Let me know if there's anything I can do to help.
#4
@himerus: Yes, I think you are probably right about the direction, in terms of making it compatible with multiple node types, as well as making it work better for anonymous users. I've granted you CVS access to the project so please go ahead and create the 6.x release if you like. I think then it would be good to try to port back the functionality improvements to the 5.x version as well.
@vkareh: You could look into some of the other issues in the queue if you like! It sounds like himerus has the 6.x port ready to go already!
#5
I've been way behind on the personal project where this is coming to use for me.
I do have that "working" version installed... the main issue is all the mail functions need to be rewritten for D6, but I just haven't had time to dig into that yet.
I will try to take a few hours this week to come back to the site I'm using this one, and finish up a "dirty" version to use as the 6.x-dev version here.
Once that's done, we can start working on additional features to move forward with for D6, and D7 as that becomes available. (I'm just working on my first D7 test install, and want to have a couple of my modules ready to publishing to that soon as it's available)
Thanks for the help, and responses.
@vkareh - Once I have the D6 version uploaded, and you can install a copy on a test site, along with others hopefully, we can determine, and line out some additional issues/needs for the queue, and figure out a path of how to tackle them, and get it to optimum performance asap.
#6
Hi Matt and the rest...
I ported your code to 6.6, and corrected a couple of things, if you want me to maintain it, let me know, in case anyone else want the code I'll attach to this comment, review, and if you find any mistake, tell me...
List of main corrections:
- in validation, the check if the username exists is redundant, it's checked in user module.
- in submit, I deciphered how to do for not repeating the code of 'user_register_submit'
Thank you for your module, it was what I was looking for...
Juan Arias
PD. I reduced the module to the minimum expression, feel free to modify/readd the license and readme
#7
Ok, I'm inspired...
added Mavimo functionality (thank's!), and did some cleaning...
Greetings,
Juan Arias
#8
#7 works for me.
Thank you, Hwanger!
#9
je je...
you're wellcome...
if you think of new functionality, I'm using the module so I could consider implementing, just contact me
Greetings!
Juan Arias
#10
I'm using the 5.0 version of this module on my site which is D 5.13. [Please excuse the front page right now, I am working through some block problems] It is truly remarkable and one of the gems of drupal as far as I'm concerned.
Just to clarify, if and when I convert my site to Drupal 6.0 I should use the latest attachment in #7. Also what is Mavimo functionality??
Thanks
#11
works for me!
#12
#7 works good, but dont work with content_profile user registration ((
#13
Hmmm, I also did a port with more admin options, so I'll mark it back as needs review. Perhaps the two can be merged? Hwanga's is much cleaner, whereas I did a straight copy of the D5 module and added a needed admin feature to choose which content types to expose the form on.
In answer to OFF (#12 above) content_profile is HORRIBLE to get this working for. I will need to do this at some point, but it won't be easy. Don't hold your breath. =(
Ps - no info file in my patch - please either use the one in Hwanga's zip or make your own.
#14
Status didn't change?!
#15
I downloaded the inline_registration-5.x-1.x-dev.tar.gz from the project page and here's the output from the patch:
@greg.harvey: Could you please give further instructions or a zip of your copy?
#16
Strange. Unless the dev snapshot has been updated in the last three or four days you're using the same version as me. It's a straight patch generated by SVN, like I always do. Don't know what I can do to "fix" it. I'll zip the files tomorrow.
#17
subscribe
#18
Simple 6.x dev version has been released
#19
Sadly it is not working at all, as we have a version change now, I have started this following thread: Issue 425136. Please continue the conversation there so that when new users search for the Drupal 6.x version issues they'll find them more easily! Thanks!
#20
@panatlantica The readme.txt file has been updated per your issue. Marking as fixed.
#21
Automatically closed -- issue fixed for 2 weeks with no activity.