Hi,
This message always appear on the registration page:warning: preg_match() expects parameter 2 to be string, array given in /includes/bootstrap.inc on line 6
The upload picture system is enable during registration but when uploaded, there is no more picture and it is allways the default picture that is showing.
Comments
Comment #1
sbandyopadhyay commentedI had the same error, and crafted a potential solution. Using the devel module, I traced the error that I got as follows:
* warning: preg_match() expects parameter 2 to be string, array given in /includes/bootstrap.inc on line 670.
* preg_match
* file/line: /includes/bootstrap.inc: 670
* arguments: /^./us,
That second argument is an array, and as the error we're getting so handily notified us, it should be a string. Tracing back further, I found:
* drupal_attributes
* file/line: /includes/form.inc: 1433
* arguments:
The desired string ("multipart/form-data") is somehow being written in twice. I don't have the time to figure out how or why, but in the hopes that it would fix it, I commented out the line
$form['#attributes']['enctype'] = 'multipart/form-data';in reg_with_pic.module...And that fixed it!
This clearly may not be a universal solution. But it worked for me, so hopefully that will help.
Comment #2
eclypse commentedI've tried to comment these lines and it worked. So thanks a lot.
I searched in the code and It looks like it was the nodeprofile module that caused me this problem. By removing a nodeprofile form in the register page, it resolved the problem. And with that form enabled, I had to comment the lines that you've described above. So, problem of interraction between nodeprofile and this mobule.
Thank you for your contribution.
Comment #3
sbandyopadhyay commentedI can back that up-- I am running nodeprofile too. Looks like instead of commenting that out, maybe it could check to see if nodeprofile is activated and then act accordingly.
Comment #4
eclypse commentedComment #5
eclypse commentedComment #6
Anonymous (not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.