-
Notifications
You must be signed in to change notification settings - Fork 0
/
helpers.php
40 lines (37 loc) · 1.11 KB
/
helpers.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
<?php
use Kiberzauras\Translator\Path;
use Kiberzauras\Translator\Translator;
if (!function_exists('_t')) {
/**
* @param string $string
* @param array|string $arguments
* @param string $domain
* @param string $locale
* @return string
* @author Rytis Grincevičius <[email protected]>
*/
function _t($string = '', $arguments = array(), $domain = 'default', $locale = '') {
return Translator::translate($string, $arguments, $domain, $locale);
}
}
if (!function_exists('translations_path')) {
/**
* @param string $path
* @return string
* @author Rytis Grincevičius <[email protected]>
*/
function translations_path($path = '') {
return Path::translations_path($path);
}
}
if (!function_exists('translation_path')) {
/**
* @param string $path
* @param string $locale Uses current locale if not set
* @return string
* @author Rytis Grincevičius <[email protected]>
*/
function translation_path($path = '', $locale = '') {
return Path::translation_path($path, $locale);
}
}