Dotproject Calendar and Gantt chart garbled issues

Source: Internet
Author: User
Tags locale php file dotproject

I. Environment Windows 2003 xampplite_1.7.1 Dotproject_2_1_3.zip dotproject-zh-pack-2.1.1-by-hutuworm2.tar.gz
Second, calendar garbled problem open lib\pear\date\calc.php file

Around 1583 rows, function Getmonthnames () functions start with a line
SetLocale (lc_time, ' en ');
At the beginning of the 1608-line function getweekdays (), add a line
SetLocale (lc_time, ' en ');

Third, Gantt chart garbled problem

1, copy the%systemroot%\font directory under the Simhei.ttf to lib\fonts directory

2. Open \lib\jpgraph\src\jpg-config.inc

Find the following:

Define (' Base_font ', ' FreeSans ');

Define (' Custom_ttf_font_bold ', Base_font. ' Bold.ttf ');

Define (' Custom_ttf_font_italic ', Base_font. ' Oblique.ttf ');

Define (' Custom_ttf_font_bolditalic ', Base_font. ' Boldoblique.ttf ');
Modified to:

Define (' Base_font ', ' Simhei ');

Define (' Custom_ttf_font_bold ', Base_font. TTF ');

Define (' Custom_ttf_font_italic ', Base_font. TTF ');

Define (' Custom_ttf_font_bolditalic ', Base_font. TTF ');

3. Open modules\tasks\gantt.php

In about 370 rows

Comment out the following content

if ($locale _char_set== ' utf-8′&& function_exists (' Utf8_decode '))

{
$name = Utf8_decode ($name);

}

4. Open modules\projects\gantt.php

In about 214 rows

Comment and modify it as follows

/* IF ($locale _char_set== ' utf-8 ' && function_exists (' Utf8_decode ')) {$name = (Mb_strlen (Utf8_decode ($p [' Project_Name '])) > 25)? (Mb_substr (Utf8_decode ($p [' project_name ']), 0, 22). ' ... '): Utf8_decode ($p [' project_name ']); } else { *///while using charset different than UTF-8 we need not to use utf8_deocde $name = ((Mb_strlen ($p [' Projec T_name ']) > 25)? (Mb_substr ($p [' project_name '], 0, 22). ' ... '): $p [' project_name ']);  }

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.