- This topic has 10 replies, 2 voices, and was last updated 3 years, 8 months ago by Tom.
August 2, 2017 at 8:45 pm #358881Adriane
If we set up “sections” on a page and put content in them, and then add content that includes Hawaiian characters like ā and ʻ that are UTF8 but not latin1, the entire content of the page disappears and a message says there are no sections.
Is there a database table or some other config that needs to be changed for this to work? Regular posts and WordPress pages work fine, and the wp_posts table columns are all set to UTF8.GP Premium 1.3.1August 2, 2017 at 11:51 pm #358922TomLead DeveloperLead Developer
I just tested it by copying and pasting those characters: https://www.screencast.com/t/aDJvILZiiR
And here’s what I see on the front end: https://www.screencast.com/t/o7dyPG87Uk4A
Do you have any other servers/hosting you can test on?August 3, 2017 at 1:40 am #358961Adriane
Yes, there are two other hosts with almost identical installations, including GeneratePress, and they work. But I don’t know which database tables (or other configuration) is different. Which database tables does “sections” use, other than wp_posts?August 3, 2017 at 10:11 am #359202TomLead DeveloperLead DeveloperAugust 3, 2017 at 2:07 pm #359365Adriane
Changing the meta_key and meta_value columns to UTF8 collation solved the problem with not being able to use Hawaiian characters on pages using “sections” (probably would have been enough to change meta_value).
We have another problem with sections that started a few days ago and is probably not related to the collation/character set problem: only the first section shows up on the page when there are multiple sections defined (in Edit Page). This used to work (when not including Hawaiian characters). It is possible there was an auto-update of GeneratePress in the past week. Is this a known problem, and is there a work-around?August 3, 2017 at 2:12 pm #359369Adriane
This is in the error log and may be related:
Thu Aug 03 17:00:48.466398 2017] [:error] [pid 2026] [client 188.8.131.52:60329] PHP Warning: Invalid argument supplied for foreach() in /home/sierracl/public_html/mauisierraclub.org/wp-content/plugins/gp-premium/sections/functions/templates/template.php on line 43, referer: https://mauisierraclub.org/wp-admin/post.php?post=1774&action=edit&revision=2075
[Thu Aug 03 17:00:48.466368 2017] [:error] [pid 2026] [client 184.108.40.206:60329] PHP Warning: Illegal string offset ‘sections’ in /home/sierracl/public_html/mauisierraclub.org/wp-content/plugins/gp-premium/sections/functions/templates/template.php on line 43, referer: https://mauisierraclub.org/wp-admin/post.php?post=1774&action=edit&revision=2075August 3, 2017 at 2:56 pm #359400TomLead DeveloperLead Developer
Hmm, no auto-updates.
What about when you create a new page? Same issue?
Those error_log values basically mean that there’s supposed to be sections, but they’re not there.
Any db changes? Search/replace in the db maybe?August 3, 2017 at 3:27 pm #359415Adriane
The only changes I made to the DB were to change the collation from latin1 to utf8 on the text columns of wp_posts and wp_post_meta.
I created a new page now and added three sections. Only the first is visible:
All three sections are visible in Edit Page for that page.August 3, 2017 at 4:07 pm #359427TomLead DeveloperLead DeveloperAugust 3, 2017 at 5:03 pm #359454Adriane
That solved the problem! Thanks!
Now I have to find out why that CSS is there to begin with.August 3, 2017 at 5:04 pm #359455
- You must be logged in to reply to this topic.