Commit b6b35b468caad174a9d14b572c3e652267cbf1f8
1 parent
fcbd5c55
KTS-673
"The search algorithm needs some work" Updated. Internationalisation Committed By: Conrad Vermeulen Reviewed By: Kevin Fourie git-svn-id: https://kt-dms.svn.sourceforge.net/svnroot/kt-dms/trunk@7281 c91229c3-7414-0410-bfa2-8a42b809f60b
Showing
1 changed file
with
5 additions
and
5 deletions
search2/search/search.inc.php
| ... | ... | @@ -252,7 +252,7 @@ class SearchHelper |
| 252 | 252 | |
| 253 | 253 | if (!Permission::userHasFolderReadPermission($folder)) |
| 254 | 254 | { |
| 255 | - return new PEAR_Error('no permission to read folder'); | |
| 255 | + return new PEAR_Error(_kt('no permission to read folder')); | |
| 256 | 256 | } |
| 257 | 257 | |
| 258 | 258 | $sql = "SELECT id, name FROM folders WHERE parent_id=$folderID ORDER BY name"; |
| ... | ... | @@ -304,7 +304,7 @@ class SearchHelper |
| 304 | 304 | } |
| 305 | 305 | if (count($rs) == 0) |
| 306 | 306 | { |
| 307 | - return new PEAR_Error('Fieldset was not found'); | |
| 307 | + return new PEAR_Error(_kt('Fieldset was not found')); | |
| 308 | 308 | } |
| 309 | 309 | |
| 310 | 310 | $result=array(); |
| ... | ... | @@ -450,7 +450,7 @@ function parseExpression($expr_str) |
| 450 | 450 | { |
| 451 | 451 | $use_internal=true; |
| 452 | 452 | $expr_str=getExpressionLocalityString($expr_str, $lexer->offset, 20); |
| 453 | - throw new Exception("Parsing problem near '$lexer->value' in '$expr_str' of expression."); | |
| 453 | + throw new Exception(sprintf(_kt("Parsing problem near '%s' in '%s' of expression."),$lexer->value,$expr_str)); | |
| 454 | 454 | } |
| 455 | 455 | } |
| 456 | 456 | |
| ... | ... | @@ -461,7 +461,7 @@ function parseExpression($expr_str) |
| 461 | 461 | { |
| 462 | 462 | $use_internal=true; |
| 463 | 463 | $expr_str=getExpressionLocalityString($expr_str, $lexer->offset, 20); |
| 464 | - throw new Exception("There is a problem parsing the expression '$expr_str'"); | |
| 464 | + throw new Exception(sprintf(_kt("There is a problem parsing the expression '%s'"),$expr_str)); | |
| 465 | 465 | } |
| 466 | 466 | |
| 467 | 467 | } |
| ... | ... | @@ -476,7 +476,7 @@ function parseExpression($expr_str) |
| 476 | 476 | throw $e; |
| 477 | 477 | } |
| 478 | 478 | $expr_str=getExpressionLocalityString($expr_str, $lexer->offset, 20); |
| 479 | - throw new Exception("Parsing problem near '$lexer->value' of expression '$expr_str'."); | |
| 479 | + throw new Exception(sprintf(_kt("Parsing problem near '%s' of expression '%s'."), $lexer->value, $expr_str)); | |
| 480 | 480 | } |
| 481 | 481 | |
| 482 | 482 | return $parser->getExprResult(); | ... | ... |