I'm getting the following errors on my summary page (content/status-web-links)
Notice: Undefined index: emvideo_valid in theme_fbsmp_link_url() (line 642 of ../public_html/sites/all/modules/fbsmp/plugins/link.inc).
Notice: Undefined index: emaudio_valid in theme_fbsmp_link_url() (line 650 of ../public_html/sites/all/modules/fbsmp/plugins/link.inc).
Notice: Undefined index: emvideo_valid in theme_fbsmp_link_url() (line 654 of ../public_html/sites/all/modules/fbsmp/plugins/link.inc).
../public_html/sites/all/modules/fbsmp/plugins/link.inc).
Notice: Undefined index: emvideo_valid in theme_fbsmp_link_url() (line 674 of ../public_html/sites/all/modules/fbsmp/plugins/link.inc).
Does anyone know how to fix this?
Thanks
Sharon
Comment | File | Size | Author |
---|---|---|---|
#5 | undefined-indexes-1451030-5.patch | 940 bytes | thirdender |
Comments
Comment #1
emerham CreditAttribution: emerham commentedI'm getting it to
Comment #2
JohnnyW CreditAttribution: JohnnyW commentedMe too
Comment #3
thirdender CreditAttribution: thirdender commentedWe recently had this issue on our site. I was able to correct it by removing the offending Status and recreating it. It seems the statuses aren't always saved correctly, and then code tries to treat them as an image. Similar errors can be triggered by clicking the image upload button, cancelling, and then clicking the link upload button:
I'll post more information as I explore deeper.
Comment #4
thirdender CreditAttribution: thirdender commentedThe issue is caused when incomplete data is stored in the
fbsmp
database table. The data should be a serialized array of several different properties:Only the properties in bold are stored for the broken statuses.
Comment #5
thirdender CreditAttribution: thirdender commentedThis issue is caused when the user checks the "no thumbnail" checkbox when submitting a page link (URL). Lines 411-413 of link.inc copy values from the $form_state into the status data that will be saved, but only if the "no thumbnail" checkbox is unchecked.
Could someone familiar with the module clarify what the
emvideo_valid
,emaudio_valid
, andemfield_data
values should be? I dpm'ed the $form_state and they were actually undefined when I submitted the form.For now, setting these values to NULL before saving the status if "no thumbnail" is checked solves the issue. Any statuses saved before making this change could still be missing these values in the database and could cause the error when the status is viewed. You'll need to review which statuses are causing the issue and either manually fix the database values for those statuses or delete and repost the statuses.
Comment #6
mathankumarc CreditAttribution: mathankumarc commentedCommitted a fix for this recently.