Level headings
Closed this issue · 9 comments
Hello everyone
Im trying to provide descriptive headings in the text editor so I
am using the format option for level heading: Header 2, Header 3, ....., and paragrah
My problem: In the visualization of the content, the Page Contents area don`t show correctly the html code (levels and paragrahps).
I atach the pictures to describe the error.
Thanks a lot for help me.
Image 2: Visualization Page Content area (Not Ok - it is my problem)
Which version of ATutor are you using?
Hello,
The version is: ATutor 2.2.2
XAMPP 5.6.33: Apache 2.4.29, MariaDB 10.1.30, PHP 5.6.33
The problem appears to be fixed in 2.2.3 (soon to be released), though the bug report is still open:
http://www.atutor.ca/atutor/mantis/view.php?id=5801
After making a backup copy of /include/lib/output.inc.php, I would suggest replacing it with a current copy from Github:
https://raw.githubusercontent.com/atutor/ATutor/master/include/lib/output.inc.php
Let me know if that works, so we can resolve the bug. thx
Hi.
It doesn’t work for me
If you have another suggestion I would really appreciate it
Cindy may be able to help with this. It seems to be a regular expression issue, which seems to be matching more than headings.
preg_match_all("/<(h[\d]+)[^>]*>(.*)<\/(\s*)\\1(\s*)>/i", $content, $found_headers, PREG_SET_ORDER);
ATutor/include/lib/output.inc.php
Line 1028 in c3b76d0
thanks Cindy.
Here's the fix:
preg_match_all("/<(h[\d]+)[^>]*>(.*?)<\/(\s*)\\1(\s*)>/i", $content, $found_headers, PREG_SET_ORDER);
Thanks a lot.
I tried it and worked perfectly!!!.
Good to hear.