Page 1 of 1

Issues adding comments in DITA Map WebHelp Responsive with Feedback

Posted: Fri Aug 05, 2016 4:14 pm
by psosm
Hi,

when running the WebHelp Responsive with Feedback on my WebServer, I ran into two problems when trying to add a comment

The environment I am using is
OS: Windows 7 Professional 64bit
Apache 2.4
PHP 5.6.24
mysql 5.7


1. The very first try to add a comment on a topic or task page failed as there was an empty POST Parameter for 'comment'

changing line 79 of comment.php from

Code: Select all

$info["referedComment"] = (isset($_POST['comment']) ? $_POST['comment'] : 0);
to

Code: Select all

if (isset($_POST['comment']) && strlen( $_POST['comment']) > 0) {
$info["referedComment"] = $_POST['comment'] ;
} else {
$info["referedComment"] = 0;
}
fixed that issue.

The second one is inside Utils.php
line 429

Code: Select all

        return preg_replace('/<(.*?)>/ie', "'<' . preg_replace(array('/javascript:[^\"\']*/i', '/(" . implode('|',
$aDisabledAttributes) . ")[ \\t\\n]*=[ \\t\\n]*[\"\'][^\"\']*[\"\']/i', '/\s+/'), array('', '', ' '), stripslashes('\\1')) . '>'",
leads to an error message stating
preg_replace(): The /e modifier is deprecated, use preg_replace_callback

Re: Issues adding comments in DITA Map WebHelp Responsive with Feedback

Posted: Mon Aug 08, 2016 4:20 pm
by bogdan_cercelaru
Hello,
The very first try to add a comment on a topic or task page failed as there was an empty POST Parameter for 'comment'
I wasn't able to reproduce this but it will be good to check that the "$_POST['comment']" is not empty. This will be included in the next version of Oxygen (v18.1).
The second one is inside Utils.php
This is a known issue. It is already resolved and will be included in the next version of Oxygen (v18.1) so that the generated WebHelp will be compatible with PHP v7.

Regards,
Bogdan