Unable to see emoji on page description and text content

Bug #1895259 reported by Heena Agheda
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mahara
20.10
Fix Released
Medium
Heena Agheda

Bug Description

- exact version of Mahara - 20.04 - master branch
- operating system - Ubuntu 18.04.5 LTS
- database - MySQL 5.7

Emoji's are turning into '?' while adding them on 'Page description' of Page.

Also When you add the New Block -> Content type -> Text - in 'Block content' adding emoji removes all content of the block. Its stored in database but because its converted into '?', content of serialized not matching with content length.

Revision history for this message
Heena Agheda (hdagheda) wrote :

I have changed table collation and field character set:

ALTER TABLE block_instance CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
ALTER TABLE block_instance modify configdata text charset utf8mb4;

ALTER TABLE view CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
ALTER TABLE view modify description text charset utf8mb4;

Also change line:1751 in /htdocs/lib/dml.php
$db->_Execute("SET NAMES utf8mb4 COLLATE utf8mb4_unicode_ci");

Revision history for this message
Kristina Hoeppner (kris-hoeppner) wrote :

Page descriptions in Mahara 20.10 do not have a visual editor any more and thus emojis won't be displayed as such there. Therefore, it is only an issue for content in pages that has been created via TinyMCE.

Changed in mahara:
status: New → Confirmed
importance: Undecided → Medium
milestone: none → 20.10.0
Revision history for this message
Mahara Bot (dev-mahara) wrote : A patch has been submitted for review

Patch for "20.04_STABLE" branch: https://reviews.mahara.org/11265

Revision history for this message
Mahara Bot (dev-mahara) wrote :

Patch for "master" branch: https://reviews.mahara.org/11270

Changed in mahara:
status: Confirmed → In Progress
assignee: nobody → Heena Agheda (hdagheda)
Changed in mahara:
milestone: 20.10.0 → 20.10rc2
Revision history for this message
Mahara Bot (dev-mahara) wrote : A change has been merged

Reviewed: https://reviews.mahara.org/11270
Committed: https://git.mahara.org/mahara/mahara/commit/d08118ad7ec695dd22dcc279c33493ebfbf9891d
Submitter: Cecilia Vela Gurovic (<email address hidden>)
Branch: master

commit d08118ad7ec695dd22dcc279c33493ebfbf9891d
Author: Heena Agheda <email address hidden>
Date: Mon Sep 14 12:27:34 2020 +1000

Bug 1895259: Set collation to store emoji

also update entrycontent in import_entry_requests to be able to import
the views with emojis

Change-Id: I0012dd215b488ce93313051f2bfe9f5f524433e2

Changed in mahara:
status: In Progress → Fix Committed
Revision history for this message
Mahara Bot (dev-mahara) wrote : A patch has been submitted for review

Patch for "20.10_STABLE" branch: https://reviews.mahara.org/11322

Revision history for this message
Mahara Bot (dev-mahara) wrote : A change has been merged

Reviewed: https://reviews.mahara.org/11322
Committed: https://git.mahara.org/mahara/mahara/commit/f2b5bc24a64aceffa821adcbb27690768cf2a7c0
Submitter: Cecilia Vela Gurovic (<email address hidden>)
Branch: 20.10_STABLE

commit f2b5bc24a64aceffa821adcbb27690768cf2a7c0
Author: Heena Agheda <email address hidden>
Date: Mon Sep 14 12:27:34 2020 +1000

Bug 1895259: Set collation to store emoji

also update entrycontent in import_entry_requests to be able to import
the views with emojis

Change-Id: I0012dd215b488ce93313051f2bfe9f5f524433e2

Robert Lyon (robertl-9)
no longer affects: mahara/21.04
no longer affects: mahara
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.