Oh no! Where's the JavaScript?
Your Web browser does not have JavaScript enabled or does not support JavaScript. Please enable JavaScript on your Web browser to properly view this Web site, or upgrade to a Web browser that does support JavaScript.
Sign In
Not a member yet? Click here to register.

Suspected Bugs and Errors - 8

If you suspect you have found a bug or a code error post here.
3,991 posts | Last Activity on 18-02-2020 08:50 by RobiNN
RobiNN
Re: Deprecated: Unparenthesized `a ? b : c ? d : e` on search.php Upgrade your system to latest.... It's already fixed
E
Re: Deprecated: Unparenthesized `a ? b : c ? d : e` on search.php Deprecated: Unparenthesized `a ? b : c ? d : e` is deprecated. Use either `(a ? b : c) ? d : e` or `a ? b : (c ? d : e)` in ... search.php on line 273

Line 273:
Code
$memory_limit = !isnum($memory_limit) ? 8 * 1024 * 1024 : $memory_limit < 8 * 1024 * 1024 ? 8 * 1024 * 1024 : $memory_limit;

Oleg
Oleg 01-01-2020 16:45, 2 months ago
Re: Error updating database Now it adds parameters to the database, but displays another error:

Query Error: ALTER DATABASE gallants_fusion CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
Stack Trace: #0 /public_html/includes/db_handlers/pdo_functions_include.php(43): PDOStatement->execute() #1 /public_html/administration/upgrade.php(62): dbquery('ALTER DATABASE ...') #2 {main}
Error Nature: SQLSTATE[HY000]: General error: 2014 Cannot execute queries while other unbuffered queries are active. Consider using PDOStatement::fetchAll(). Alternatively, if your code is only ever going to run against mysql, you may enable query buffering by setting the PDO::MYSQL_ATTR_USE_BUFFERED_QUERY attribute.
RobiNN
RobiNN 01-01-2020 13:19, 2 months ago
Re: Error updating database Fixed https://github.com/php-fusion/PHP-Fusion/commit/55c822feabfed685e6efe30b4fbb1174c660346f
Oleg
Oleg 01-01-2020 09:21, 2 months ago
Re: Error updating database Good day! An error occurred while updating from 8.00.21 to 8.00.22

Query Error: INSERT INTO fusionda132_settingssettings (settings_name, settings_value) VALUES ('number_delimiter', '.')
Stack Trace: #0 /public_html/includes/db_handlers/pdo_functions_include.php(42): PDO->prepare('INSERT INTO fus...') #1 /public_html/administration/upgrade.php(50): dbquery('INSERT INTO fus...') #2 {main}
Error Nature: SQLSTATE[42S02]: Base table or view not found: 1146 Table 'gallants_fusion.fusionda132_settingssettings' doesn't exist
douwe_yntema
douwe_yntema 03-12-2019 13:42, 3 months ago
Re: Panel restriction Ok thanks, that worked for me.
Falk
Falk 02-12-2019 23:10, 3 months ago
Re: Panel restriction yeah it was rewritten so it can use Permalinks. Usually there are no vars enabled on home but you can try add the panel with a wildcard restriction, like /home*
douwe_yntema
douwe_yntema 02-12-2019 21:40, 3 months ago
Re: Panel restriction Panel Inclusion in PHP-Fusion is not working good.

I have a center panel, wich is included on page /home.php.
On home.php, the page is beeing called as home.php?rowstart=6

On PHP-Fusion 7.02.07 this is working ok, with this code in themse/templates/panels.php line 63:

Code
      || ($p_data['panel_restriction'] == 1 && (!in_array(TRUE_PHP_SELF.(FUSION_QUERY ? "?".FUSION_QUERY : ""), $url_arr) && !in_array(TRUE_PHP_SELF, $url_arr)))
         || ($p_data['panel_restriction'] == 0 && (in_array(TRUE_PHP_SELF.(FUSION_QUERY ? "?".FUSION_QUERY : ""), $url_arr) || in_array(TRUE_PHP_SELF, $url_arr))))
            





on PHP-Fusion 8.0.21 the same is written as:

Code
 || ($p_data['panel_restriction'] == 1 && (!in_array("/".PERMALINK_CURRENT_PATH, $url) && !in_array("/".PERMALINK_CURRENT_PATH, $url)))
 || ($p_data['panel_restriction'] == 0 && (in_array("/".PERMALINK_CURRENT_PATH, $url) || in_array("/".PERMALINK_CURRENT_PATH, $url)))) {



Now the panel is not included because of the ?rowstart=6 at the end of the url
Oleg
Oleg 27-10-2019 16:59, 4 months ago
Re: Bugs with multilingualism Good. After changing the code, the bugs disappeared like

In addition to what is described in this topic, links no longer disappear when you add another language. Prior to this, if the checkbox in the administrator part was checked in the second language (without removing the checkmark from the first), all links disappeared. And in phpmyadmin, new navigation links were displayed in two languages together, separated by commas.
Falk
Falk 23-10-2019 16:12, 4 months ago
Re: Bugs with multilingualism Yes now, I get it, must be secondary query that does not do mlang table.
Issued : https://github.com/php-fusion/PHP-Fusion/issues/2253
Oleg
Oleg 23-10-2019 08:42, 4 months ago
Re: Bugs with multilingualism I didn’t put it that accurately. I’ll try to explain even more accurately.

Links that are set to "navigation panel only" and "sub-header only" are displayed correctly in the same language. But precisely if you specify the "navigation panel and sub-header", then they are displayed in vertical navigation with 2 links in 2 languages.

Maybe now you will understand me.
Falk
Falk 23-10-2019 08:00, 4 months ago
Re: Bugs with multilingualism The links are what we called instanced, you add them under selected language. Very few areas in v8 is dual, like panels and custom pages can be displayed over an array of selected languages.
Add 1 link for a language you have selected in Admin, Switch language and that link should poof for the new language and you can add same link with a new locale for the new selected language.
If you for some reason have mixed links, remove the ones that are supposed to be for another language and re-add them carefully in the admin from you wanted language.
Oleg
Oleg 23-10-2019 06:27, 4 months ago
Re: Bugs with multilingualism On the first question, you misunderstood. The problem is that in two languages not only a link to articles is displayed, but also all links related to horizontal navigation; despite the fact that they should be displayed in only one language, the flag of which is indicated.

I would not want to go to v9 angry
RobiNN
RobiNN 22-10-2019 21:18, 4 months ago
Re: Bugs with multilingualism First issue, if you have link "Articles" you must add the same link also in another language with the same link options.

Second, known isssue.

If you want full multilang support try v9.
Oleg
Oleg 22-10-2019 21:09, 4 months ago
Re: Bugs with multilingualism On the test version, PHP-Fusion 8.0.22 found the following bugs:

With 2 languages installed, those links made in horizontal and vertical navigation are displayed regardless of the selected language. See screenshots:

d.radikal.ru/d40/1910/3a/5b72900542b7t.jpg

b.radikal.ru/b14/1910/cb/24efb8e66b1ft.jpg

Another bug with multilingualism in the admin theme "Venus"; leaves English in the menu on the left:

c.radikal.ru/c09/1910/24/277ee1da9dd9t.jpg

In themes, "AdminLTE" and "Ares" displays correctly:

c.radikal.ru/c13/1910/75/dd8016e4c531t.jpg
RobiNN
RobiNN 10-10-2019 12:45, 5 months ago
Re: Error in print.php https://github.com/php-fusion/PHP-Fus...ee/8.00.22
Oleg
Oleg 10-10-2019 12:33, 5 months ago
Re: Error in print.php

RobiNN wrote:

@RobiNN
- Update your system. This is already fixed


Version 8.00.21 is available for download on this site, which I installed. Is there a newer version??
RobiNN
RobiNN 10-10-2019 11:28, 5 months ago
Re: Error in print.php Update your system. This is already fixed
Oleg
Oleg 10-10-2019 10:15, 5 months ago
Re: Error in print.php Good day! There is an error in print.php:

Code

Query Error: SELECT ta.article_subject, ta.article_article, ta.article_breaks, article_datestamp, ta.article_visibility, tu.user_id, tu.user_name, tu.user_status FROM fusion_articles ta INNER JOIN fusion_article_cats tac ON ta.article_cat=tac.article_cat_id LEFT JOIN fusion_users tu ON ta.article_name=tu.user_id WHERE article_id='1' AND article_draft='0'

Stack Trace: #0 /site.ru/includes/db_handlers/pdo_functions_include.php(42): PDO->prepare('SELECT ta.artic...') #1 /site.ru/print.php(54): dbquery('SELECT ta.artic...') #2 {main}
Error Nature: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'ta.article_visibility' in 'field list'

helmuth
helmuth 20-09-2019 06:24, 5 months ago
Re: wrong sorting after upgrade in forum_threads_list_panel
Code
$result = dbquery(
 "SELECT   f.forum_id, f.forum_cat, f.forum_name, f.forum_description, f.forum_moderators, f.forum_lastpost, f.forum_postcount,
 f.forum_threadcount, f.forum_lastuser, f.forum_access, f2.forum_name AS forum_cat_name, f2.forum_description AS forum_cat_description,
 t.thread_id, t.thread_lastpost, t.thread_lastpostid, t.thread_subject, t.thread_postcount, t.thread_views, t.thread_lastuser, t.thread_poll,
 u.user_id, u.user_name, u.user_status, u.user_avatar
 FROM ".DB_FORUMS." f
 LEFT JOIN ".DB_FORUMS." f2 ON f.forum_cat = f2.forum_id
 LEFT JOIN ".DB_THREADS." t ON f.forum_id = t.forum_id AND f.forum_lastpost=t.thread_lastpost
 LEFT JOIN ".DB_USERS." u ON f.forum_lastuser = u.user_id
 ".(multilang_table("FO") ? "WHERE f2.forum_language='".LANGUAGE."' AND" : "WHERE")." ".groupaccess('f.forum_access')." AND f.forum_cat!='0' AND t.thread_lastpost >= ".$timeframe." AND t.thread_hidden='0'
 GROUP BY thread_id ORDER BY t.thread_lastpost DESC LIMIT ".$settings['numofthreads'].""
);



DESC entered into the last line ... did the trick :-)
You can view all discussion threads in this forum.
You can start a new discussion thread in this forum.
You cannot start on a poll in this forum.
You cannot upload attachments in this forum.
You can download attachments in this forum.