Closed sjtufs closed 11 years ago
flourish 里使用的翻译方式和我上面所说的类似,你可以按照这个思路去看一看如何翻译 flourish 输出的信息。
收到
Date: Sun, 14 Oct 2012 22:27:02 -0700 From: notifications@github.com To: oj@noreply.github.com CC: sjtu_fs@outlook.com Subject: Re: [oj] 更改标点等 (#28)
flourish 里使用的翻译方式和我上面所说的类似,你可以按照这个思路去看一看如何翻译 flourish 输出的信息。
—
Reply to this email directly or view it on GitHub.
请去掉
app/.routes.php.swp
这个文件。翻译没有问题了,但为了方便支持多语言,需要做一些程序结构上的修改。
main.php
会在一开始载入init.php
,进而载入translate.php
。需要在translate.php
文件中,增加一个如下结构的函数:这样就可以在
app/controllers/DashboardController.php
这些文件里这样使用了:但是这样有一个问题,就是不能支持
"Data base directory {$data_base_dir} does not exist."
这样的句子。对于这样的句子,我们期望的使用方法如下:这可以通过使用 func_get_args 和 sprintf 等函数来实现。