strrev()
onlyHi,
That could be you should hit submit multiple times, as we already discovered.jackennils wrote: ↑Sat Jan 06, 2018 12:37 pm setting "Use Initial avatars" to No, does not remove the PIAs and does not make users avatarless again.
Care to expand, what exactly breaks? The URL is managed by phpBB, if the URL is not working a red X should display, isn't?
That's why I asked, I am thinking about providing a fallback indeed.jackennils wrote: ↑Sat Jan 06, 2018 10:34 pm Yes, if ui-avatars is not loading/blocked, the red X or similar (different for each browser) is displayed making the site look unprofessional. Maybe you can implement some sort of fallback?
Code: Select all
SQL ERROR [ mysqli ]
Duplicate entry 'threedi_pia_default_avatar' for key 'PRIMARY' [1062]
SQL
INSERT INTO phpbb_config (config_name, config_value, is_dynamic) VALUES ('threedi_pia_default_avatar', 1, 0)
BACKTRACE
FILE: (not given by php)
LINE: (not given by php)
CALL: msg_handler()
FILE: [ROOT]/phpbb/db/driver/driver.php
LINE: 996
CALL: trigger_error()
FILE: [ROOT]/phpbb/db/driver/mysqli.php
LINE: 193
CALL: phpbb\db\driver\driver->sql_error()
FILE: [ROOT]/phpbb/db/driver/factory.php
LINE: 329
CALL: phpbb\db\driver\mysqli->sql_query()
FILE: [ROOT]/phpbb/config/db.php
LINE: 161
CALL: phpbb\db\driver\factory->sql_query()
FILE: [ROOT]/phpbb/config/db.php
LINE: 122
CALL: phpbb\config\db->set_atomic()
FILE: [ROOT]/ext/threedi/pia/acp/pia_module.php
LINE: 53
CALL: phpbb\config\db->set()
FILE: [ROOT]/includes/functions_module.php
LINE: 676
CALL: threedi\pia\acp\pia_module->main()
FILE: [ROOT]/adm/index.php
LINE: 82
CALL: p_master->load_active()
The above line is perfectly fine IMHO, I can't reproduce your issue here..RomaamoR wrote: ↑Fri Jan 19, 2018 10:06 amCode: Select all
SQL ERROR [ mysqli ] Duplicate entry 'threedi_pia_default_avatar' for key 'PRIMARY' [1062] SQL INSERT INTO phpbb_config (config_name, config_value, is_dynamic) VALUES ('threedi_pia_default_avatar', 1, 0) BACKTRACE ... snip ... FILE: [ROOT]/ext/threedi/pia/acp/pia_module.php LINE: 53 CALL: phpbb\config\db->set() ... snip ..
Code: Select all
$config->set('threedi_pia_default_avatar', $request->variable('threedi_pia_default_avatar', (int) $config['threedi_pia_default_avatar']));
Code: Select all
if ($request->is_set_post('submit'))
{
if (!check_form_key('threedi/pia'))
{
trigger_error('FORM_INVALID', E_USER_WARNING);
}
if (!$config['allow_avatar_remote'])
{
$errors[] = $user->lang('PIA_REMOTE_CONFIG_INVALID');
/* Log the error. */
$phpbb_log->add('critical', $user->data['user_id'], $user->ip, 'PIA_LOG_REMOTE_CONFIG_INVALID');
}
/* No errors? Great, let's go. */
if (!count($errors))
{
$config->set('threedi_pia_default_avatar', $request->variable('threedi_pia_default_avatar', (int) config['threedi_pia_default_avatar']));
The above language (and many more) aren't into my level of comfort, I don't know what you are trying to tell me nor I have to investigate about that, IMHO.