After installing the Popup On Load module and configuring it as User 1. I didn't notice any issue, it was only when I tried to give another user access to administer the Popup On Load module that I noticed an issue. If you don't have full permissions to Text Formats you get the following message.
This field has been disabled because you do not have sufficient permissions to edit it.
After some looking around it appears that the Popup On Load module tries to set the Text Format when it loads. This causes a problem if no Text Format is set in the $popup_onload->format variable.
I have fixed this problem by adding a check for that variable.
if (!empty($popup_onload->format)) {
$form['body']['#format'] = $popup_onload->format;
}
I will submit a patch soon.
Comments
Comment #1
johnpicozziHere is the patch that I was talking about in the original issue. Added a check for the format variable in the admin.inc file.
Comment #2
steveoriolThe patch #1 :text-format-permission-issue-2447965-2.patch is empty...
Comment #3
johnpicozziWell that's strange... Here is one that works. Thanks for the heads up @steveoriol!!
Comment #4
johnpicozziComment #5
josebc commentedpatch in no3 didn't work for me, here is another one using filter_default_format() which handles permissions
Comment #7
ivnish