I delete the javascript code in the navbar vb form
onsubmit="md5hash(vb_login_password, vb_login_md5password, vb_login_md5password_utf, 0)"
And change the path on the action to:
action="../drupal/drupalvb/login" method="post" accept-charset="UTF-8"
When I press the submit buttom a get a blank page, I'm missing something?
Thanks in advance
| Comment | File | Size | Author |
|---|---|---|---|
| #11 | drupalvb-HEAD.drupalvb-login.patch | 1.98 KB | sun |
| #10 | drupalvb-HEAD.drupalvb-login.patch | 1.92 KB | sun |
| #9 | drupal-vb-380658-2.patch | 4.39 KB | crashtest_ |
| #7 | drupal-vb-380658.patch | 5.2 KB | crashtest_ |
Comments
Comment #1
thehong commentedI have same pb.
Look at drupalvb_login() function here, look like the author did not update the document:
We need also change the username field's name to "name", and password field to "pass".
Andy
Comment #2
thehong commentedI get this error after submit (modified) VB login form:
Andy
Comment #3
sunInstead of looking at the code, you could have looked at the latest changes:
http://cvs.drupal.org/viewvc.py/drupal/contributions/modules/drupalvb/CH...
This file is also linked from the project page as "Read complete log of changes".
To fix the fatal error, update to the latest development snapshot.
Comment #4
RAFA3L commentedThanks!
I notice that the version 6.x.2.x-dev need a little change, the function user_login_validate() now don't exist in Drupal 6, this must be user_authenticate(). Line 491 in drupalvb.module
And need to add a hiden field "destination" to redirect the login from vb. This is in navbar style.
Now I'm trying to show the error message when the login fail, form_get_errors() always return empty.
Comment #5
sunPatch?
Comment #6
RAFA3L commentedSorry, but I'm not familiarized creating patches, I'm trying create it with diff but for now don't look like the anothers I saw here.
The change is in line 492 on drupalvb.module:
user_login_validate($_REQUEST['form_id'], $_REQUEST);
to
user_authenticate($_REQUEST);
Now, I would like redirect to the drupal login page when the login fails and show the error message. Actually I can redirect to the index forum if the login is ok.
Comment #7
crashtest_ commentedOk, I have gotten this to work, changing the VB login form in template navbar to look like this:
And changing the FORUMHOME template in VB to look like:
Then, I needed to figure out the changes to the Drupal authentication. This part probably needs some work, because I don't believe I am validating well enough, so some review of this patch would be good. Also, an entire function (drupalvb_auth) that is called by the drupalvb_user_login had been removed, so I put it back. If there was a reason for the removal, perhaps there could be a way to not call that function?
I am a themer by trade, so it is very likely that my code still needs work, so please take a look. It is all working on my implementation though, so maybe I am close!
Comment #8
sunglobal $user is not required here.
Please only change lines that need to be changed. Also, change your editor configuration to use spaces instead of tabs.
I have no idea why this function is added here.
Comment #9
crashtest_ commentedThanks for the review, and the pointers!
I have cleaned up the code and patched again. Looks a lot more straightforward now. Also, yes, for some reason I had not checked the "Use spaces" even though I had told my editor how many spaces I wanted to use instead of tabs ;)
I have left in the function drupalvb_auth() because it is called from function drupalvb_login(). As I mentioned before, I am not sure how to do it without that function. Any ideas there?
Comment #10
sunI think what you want is simply this.
Comment #11
sunUsing $_POST instead of $_REQUEST. Can anyone confirm whether this patch works?
Comment #12
sunThanks for reporting, reviewing, and testing! Committed to 6.x.
A new development snapshot will be available within the next 12 hours. This improvement will be available in the next official release.