Hi everybody, This error shows up when I upload some image (using xthread):
PHP Code:
Fatal error: Cannot use object of type xthreads_db_binary_value as array in E:\xampp\htdocs\mybb18beta3\inc\plugins\xthreads.php on line 762
|
i'm running mybb 1.8 beta 3 and xthread 1.6.3.
Thanks for finding that.
Try editing inc/plugins/xthreads.php, find:
PHP Code:
$md5hash = $xta['md5hash'];
if(isset($md5hash{15}) && !isset($md5hash{16})) {
$md5hash = bin2hex($md5hash);
} elseif(!isset($md5hash{31}) || isset($md5hash{32}))
$md5hash = '';
|
replace with
PHP Code:
$md5hash = $xta['md5hash'];
if(is_object($md5hash)) $md5hash = bin2hex($md5hash->__toString());
elseif(isset($md5hash{15}) && !isset($md5hash{16}))
$md5hash = bin2hex($md5hash);
elseif(!isset($md5hash{31}) || isset($md5hash{32}))
$md5hash = '';
|
See if that fixes it.
Thanks, it's working now.
But i have problem when upload a long filename.
Ex:
Code:
hhcb3pu5lGFcinfq3sc8Pi7v85Vb5KGRq6KrlDdcttCswplxmyJ005fPCdWsLYTI3XHV-zH2wKwKznko0pga6A.jpg
|
86 characters - working fine
Code:
hhcb3pu5lGFcinfq3sc8Pi7v85Vb5KGRq6KrlDdcttCwct6-FChLqGoSzh46AhUjnPy3Kea00_u9bAoMz82XVxwAcRMiTLOJbsfbbjtv-L0EmdHV3YTlr9SOpiKs_WKi.jpg
|
128 characters - Thumbnail not show up, it's say: Specified attachment not found.
[attachment=1011]
Max filename length is set to 120 characters. If you need more, you can change the width of the filename column in the xtattachments table.
MyBB sets the filename length to 120 characters in its attachments table, but I suppose there's no reason to follow that - I'll probably increase it to 255 characters.
Thanks for reporting.