PDA

View Full Version : Mantis posting with national characters


zvasku
29-Apr-2010, 11:20 AM
Hello,

there are two problems when posting to Mantis with exception text with national characters. These lines must be corrected (add convert to UTF8):

(IsSuccessfulSend('view_all_bug_page.php', 'name="source_query_id"', ''))) then
begin
if ((IsSuccessfulSend('', '', 'bug_update_page.php?bug_id=')) and
(IsSuccessfulSend('', '', 'bug_update_advanced_page.php?bug_id='))) then
begin
SetRequest('bug_report_advanced_page.php', rmGET);
SendResult := SendRequest(Response, False);
if (SendResult) and
(IsSuccessfulSend('bug_report_advanced_page.php', 'name="file" type="file"', '')) then
begin
SetRequest('bug_report.php', rmBinaryPOST);
// Fields...
AddFieldValue('m_id');
AddFieldValue('project_id');
AddFieldByListTitle('handler_id', UTF8AssignTo);
AddFieldByListTitle('category', UTF8Category);
AddField('reproducibility', '10');
AddFieldByDefaultList('severity');
AddFieldByDefaultList('priority');
AddFieldValue('platform');
AddField('os', ACustomFields.Values['EL_OSType']);
AddField('os_build', ACustomFields.Values['EL_OSBuild']);
AddField('build', AVersion);
AddBugSummary('summary', AVersion, ABugType, ABugID); <----- Need to convert to UTF8
AddField('description', ABugText); <----- Need to convert to UTF8
AddField('steps_to_reproduce', UTF8StepsToReproduce);
AddField('additional_info', '');
AddField('view_state', '10');
AddFieldValue('report_stay');

// Mantis 1.1.5...
AddFieldValue('bug_report_token');

// Mantis 1.2.0
AddFieldByListTitle('category_id', UTF8Category);

See lines with <-----

Thanks
Zdenek

Alex
29-Apr-2010, 04:20 PM
Hi,

I believe that this problem is already fixed. Please, download 6.0.24 RC version from our area for registered customers: https://www.eurekalog.com/login.php

zvasku
30-Apr-2010, 07:45 AM
I can confirm 6.0.24 is ok.

Thanks
Zdenek

Alex
30-Apr-2010, 08:31 AM
Hi,

Thank you for the feedback!