moscontent::store failed - Joomla! Forum - community, help and support
it seems on servers, rules mysql stricter.
for instance, when insert jos_content user submit form, fields urls , attrib not part of query , don't have default value in table definition, hence error message: [urls doesn't have default value] when click submit.
i tried give fields default value in phpmyadmin, complained fields of type text/blob can't have default value. changed them text tinytext , solved that.
but that's not end of story.
the function in charge of saving content resides in /includes/database.php on line 541. [insertobject] generic function generates query values found in object. since insert, `id` empty. generated query looks like:
insert #__content (id, title, ... ) values ('','mytitle', ...)
this used work @ our previous service provider, parameters in mysql hosted now, doesn't work anymore.
it complains value '' out of range field `id`.
i solved abomination:
549 if ($table == '#__content' && $k == 'id' )
550 {continue;}
this prevents `id`from being put query, , there no error message , users can save content again.
if know better way solve problem, i'm listening.
in meantime, how did it.
i hope helps else...
sergio
for instance, when insert jos_content user submit form, fields urls , attrib not part of query , don't have default value in table definition, hence error message: [urls doesn't have default value] when click submit.
i tried give fields default value in phpmyadmin, complained fields of type text/blob can't have default value. changed them text tinytext , solved that.
but that's not end of story.
the function in charge of saving content resides in /includes/database.php on line 541. [insertobject] generic function generates query values found in object. since insert, `id` empty. generated query looks like:
insert #__content (id, title, ... ) values ('','mytitle', ...)
this used work @ our previous service provider, parameters in mysql hosted now, doesn't work anymore.
it complains value '' out of range field `id`.
i solved abomination:
549 if ($table == '#__content' && $k == 'id' )
550 {continue;}
this prevents `id`from being put query, , there no error message , users can save content again.
if know better way solve problem, i'm listening.
in meantime, how did it.
i hope helps else...
sergio
please remember search forum.
please turn strict mode off.
please turn strict mode off.
Comments
Post a Comment