Assorted Issues: Difference between revisions
From Joomla! Documentation
No edit summary |
No edit summary |
||
| (4 intermediate revisions by the same user not shown) | |||
| Line 1: | Line 1: | ||
<noinclude><languages /></noinclude> | <noinclude><languages /></noinclude> | ||
<translate> | <translate> | ||
== A Page Displays with No Styling == | == A Page Displays with No Styling == <!--T:1--> | ||
Possible cause: A gzip section in ''.htaccess'' is compressing the already-compressed CSS and JavaScript files.</translate> | Possible cause: A gzip section in ''.htaccess'' is compressing the already-compressed CSS and JavaScript files.</translate> | ||
<translate>See this section of the ''.htaccess'' file:</translate> | <translate><!--T:2--> See this section of the ''.htaccess'' file:</translate> | ||
<syntaxhighlight> | <syntaxhighlight> | ||
| Line 19: | Line 19: | ||
</syntaxhighlight> | </syntaxhighlight> | ||
<translate>If present, comment out or remove.</translate> | <translate><!--T:3--> If present, comment out or remove.</translate> | ||
<translate>== The List of Site Modules is Empty == | <translate>== The List of Site Modules is Empty == <!--T:4--> | ||
Possible cause: The MySQL sort buffer size may be too small.</translate> | Possible cause: The MySQL sort buffer size may be too small.</translate> | ||
<translate>Using phpMyAdmin, go to {{rarr|Home,Variables,Sort buffer size}}. | <translate><!--T:5--> | ||
Using phpMyAdmin, go to {{rarr|Home,Variables,Sort buffer size}}. | |||
<!--T:6--> | |||
It should be at least 256K and preferably 512K. On some shared hosting services, it may be set to 128K. Ask the hosting service to increase it.</translate> | It should be at least 256K and preferably 512K. On some shared hosting services, it may be set to 128K. Ask the hosting service to increase it.</translate> | ||
<translate>== Update Fails after Updating to 4.x == | <translate>== Update Fails after Updating to 4.x == <!--T:7--> | ||
Cause: an essential change to the Update procedure affecting a small number of users. | Cause: an essential change to the Update procedure affecting a small number of users. | ||
<!--T:8--> | |||
Look in ''.htaccess'' for this line:</translate> | Look in ''.htaccess'' for this line:</translate> | ||
| Line 36: | Line 39: | ||
RewriteRule ^administrator/components/com_joomlaupdate/restore\.php$ - [L]</syntaxhighlight> | RewriteRule ^administrator/components/com_joomlaupdate/restore\.php$ - [L]</syntaxhighlight> | ||
<translate>Change it to:</translate> | <translate><!--T:9--> Change it to:</translate> | ||
<syntaxhighlight> | <syntaxhighlight> | ||
RewriteRule ^administrator\/components\/com_joomlaupdate\/extract\.php$ - [L]</syntaxhighlight> | RewriteRule ^administrator\/components\/com_joomlaupdate\/extract\.php$ - [L]</syntaxhighlight> | ||
<translate>For further information see: | <translate><!--T:10--> | ||
For further information see: | |||
<!--T:11--> | |||
[https://www.joomla.org/announcements/release-news/5850-changes-to-update-process-that-you-need-to-be-aware-of.html Changes to Update Process that you need to be aware of]</translate> | [https://www.joomla.org/announcements/release-news/5850-changes-to-update-process-that-you-need-to-be-aware-of.html Changes to Update Process that you need to be aware of]</translate> | ||
<translate>== Articles Visible in Database and Frontend but Not Visible in Backend == | <translate>== Articles Visible in Database and Frontend but Not Visible in Backend == <!--T:12--> | ||
This occurs when articles are imported directly into the database, which worked fine in Joomla 3 but not in Joomla 4. One user's solution is as follows:</translate> | This occurs when articles are imported directly into the database, which worked fine in Joomla 3 but not in Joomla 4. One user's solution is as follows:</translate> | ||
<syntaxhighlight><translate> | <syntaxhighlight><translate> | ||
<!--T:13--> | |||
I imported articles directly in the database into the #__content table like I often did in Joomla 3. | I imported articles directly in the database into the #__content table like I often did in Joomla 3. | ||
However in Joomla 4 they were not visible. | However in Joomla 4 they were not visible. | ||
<!--T:14--> | |||
In Content > Categories, the category item counters counted the imported articles. | In Content > Categories, the category item counters counted the imported articles. | ||
But they were not visible in Content > Articles. | But they were not visible in Content > Articles. | ||
<!--T:15--> | |||
I solved it by creating the necessary references in the #__workflow_associations table for each imported article: | I solved it by creating the necessary references in the #__workflow_associations table for each imported article: | ||
item_id = article ID, stage_id = 1 and extension = com_content.article.</translate> | item_id = article ID, stage_id = 1 and extension = com_content.article.</translate> | ||
</syntaxhighlight> | </syntaxhighlight> | ||
<translate>With this from another user: | <translate><!--T:16--> | ||
With this from another user: | |||
<!--T:17--> | |||
This query should do it for you. Replace #__ with your own database prefix. | This query should do it for you. Replace #__ with your own database prefix. | ||
<!--T:18--> | |||
This query prevents duplicate items in the workflow associations table</translate> | This query prevents duplicate items in the workflow associations table</translate> | ||
| Line 71: | Line 82: | ||
</syntaxhighlight> | </syntaxhighlight> | ||
<translate>If, by analyzing the table #__workflow_associations | <translate><!--T:19--> If, by analyzing the table #__workflow_associations after the execution of the previous code, we find that the stage_id is 0 for all articles missing from the administration, then complete the process by executing the following query:</translate> | ||
<syntaxhighlight lang="sql"> | <syntaxhighlight lang="sql"> | ||
UPDATE `#__workflow_associations` SET `stage_id` = '1' WHERE `stage_id` = '0'; | UPDATE `#__workflow_associations` SET `stage_id` = '1' WHERE `stage_id` = '0'; | ||
</syntaxhighlight> | </syntaxhighlight> | ||
<noinclude> | |||
[[Category:Tips and tricks 4.x{{#translation:}}]] | |||
[[Category:Joomla!_4.x{{#translation:}}]] | |||
</noinclude> | |||
Latest revision as of 22:37, 26 May 2024
A Page Displays with No Styling
Possible cause: A gzip section in .htaccess is compressing the already-compressed CSS and JavaScript files.
See this section of the .htaccess file:
## These directives are only enabled if the Apache mod_headers module is enabled.
## This section will check if a .gz file exists and if so will stream it
## directly or fallback to gzip any asset on the fly
## If your site starts to look strange after enabling this, and you see
## ERR_CONTENT_DECODING_FAILED in your browser console network tab,
## then your server is already gzipping css and js files and you don't need this
## block enabled in your .htaccess
<IfModule mod_headers.c>
...
</IfModule>If present, comment out or remove.
The List of Site Modules is Empty
Possible cause: The MySQL sort buffer size may be too small.
Using phpMyAdmin, go to Home → Variables → Sort buffer size.
It should be at least 256K and preferably 512K. On some shared hosting services, it may be set to 128K. Ask the hosting service to increase it.
Update Fails after Updating to 4.x
Cause: an essential change to the Update procedure affecting a small number of users.
Look in .htaccess for this line:
RewriteRule ^administrator/components/com_joomlaupdate/restore\.php$ - [L]Change it to:
RewriteRule ^administrator\/components\/com_joomlaupdate\/extract\.php$ - [L]For further information see:
Changes to Update Process that you need to be aware of
Articles Visible in Database and Frontend but Not Visible in Backend
This occurs when articles are imported directly into the database, which worked fine in Joomla 3 but not in Joomla 4. One user's solution is as follows:
I imported articles directly in the database into the #__content table like I often did in Joomla 3.
However in Joomla 4 they were not visible.
In Content > Categories, the category item counters counted the imported articles.
But they were not visible in Content > Articles.
I solved it by creating the necessary references in the #__workflow_associations table for each imported article:
item_id = article ID, stage_id = 1 and extension = com_content.article.With this from another user:
This query should do it for you. Replace #__ with your own database prefix.
This query prevents duplicate items in the workflow associations table
INSERT INTO #__workflow_associations (item_id, stage_id, extension)
SELECT c.id as item_id, '1', 'com_content.article' FROM #__content AS c
WHERE NOT EXISTS (SELECT wa.item_id FROM #__workflow_associations AS wa WHERE wa.item_id = c.id);
If, by analyzing the table #__workflow_associations after the execution of the previous code, we find that the stage_id is 0 for all articles missing from the administration, then complete the process by executing the following query:
UPDATE `#__workflow_associations` SET `stage_id` = '1' WHERE `stage_id` = '0';