summaryrefslogtreecommitdiffstats
path: root/lib/class
diff options
context:
space:
mode:
authorPaul Arthur <flowerysong00@yahoo.com>2012-03-31 17:01:04 -0400
committerPaul Arthur <paul.arthur@flowerysong.com>2012-04-12 21:13:29 -0400
commitf65076b93d91fe9718cf9bef37638d64290b9f28 (patch)
tree40fbc65baffab34971d8c7b685ef9c99e0f4014f /lib/class
parent15457b16f17a141fa76a3b9882892362b601787c (diff)
downloadampache-f65076b93d91fe9718cf9bef37638d64290b9f28.tar.gz
ampache-f65076b93d91fe9718cf9bef37638d64290b9f28.tar.bz2
ampache-f65076b93d91fe9718cf9bef37638d64290b9f28.zip
Switch from _() to T_()
Even if we move away from php-gettext in the future, it's easy to write a quick T_() as a simple wrapper; it's not so easy to rewrite PHP to allow redeclaration of a function.
Diffstat (limited to 'lib/class')
-rw-r--r--lib/class/access.class.php36
-rw-r--r--lib/class/album.class.php6
-rw-r--r--lib/class/ampacherss.class.php12
-rw-r--r--lib/class/api.class.php16
-rw-r--r--lib/class/art.class.php2
-rw-r--r--lib/class/artist.class.php6
-rw-r--r--lib/class/browse.class.php30
-rw-r--r--lib/class/catalog.class.php70
-rw-r--r--lib/class/config.class.php2
-rw-r--r--lib/class/democratic.class.php14
-rw-r--r--lib/class/flag.class.php14
-rw-r--r--lib/class/localplay.class.php8
-rw-r--r--lib/class/playlist_object.abstract.php2
-rw-r--r--lib/class/query.class.php2
-rw-r--r--lib/class/radio.class.php12
-rw-r--r--lib/class/random.class.php8
-rw-r--r--lib/class/registration.class.php6
-rw-r--r--lib/class/search.class.php92
-rw-r--r--lib/class/update.class.php4
-rw-r--r--lib/class/user.class.php10
-rw-r--r--lib/class/video.class.php2
21 files changed, 177 insertions, 177 deletions
diff --git a/lib/class/access.class.php b/lib/class/access.class.php
index d2227701..578ba32b 100644
--- a/lib/class/access.class.php
+++ b/lib/class/access.class.php
@@ -160,17 +160,17 @@ class Access {
$end = @inet_pton($data['end']);
if (!$start AND $data['start'] != '0.0.0.0' AND $data['start'] != '::') {
- Error::add('start',_('Invalid IPv4 / IPv6 Address Entered'));
+ Error::add('start', T_('Invalid IPv4 / IPv6 Address Entered'));
return false;
}
if (!$end) {
- Error::add('end',_('Invalid IPv4 / IPv6 Address Entered'));
+ Error::add('end', T_('Invalid IPv4 / IPv6 Address Entered'));
return false;
}
if (strlen(bin2hex($start)) != strlen(bin2hex($end))) {
- Error::add('start',_('IP Address Version Mismatch'));
- Error::add('end',_('IP Address Version Mismatch'));
+ Error::add('start', T_('IP Address Version Mismatch'));
+ Error::add('end', T_('IP Address Version Mismatch'));
return false;
}
@@ -207,24 +207,24 @@ class Access {
$end = @inet_pton($data['end']);
if (!$start AND $data['start'] != '0.0.0.0' AND $data['start'] != '::') {
- Error::add('start',_('Invalid IPv4 / IPv6 Address Entered'));
+ Error::add('start', T_('Invalid IPv4 / IPv6 Address Entered'));
return false;
}
if (!$end) {
- Error::add('end',_('Invalid IPv4 / IPv6 Address Entered'));
+ Error::add('end', T_('Invalid IPv4 / IPv6 Address Entered'));
return false;
}
if (strlen(bin2hex($start)) != strlen(bin2hex($end))) {
- Error::add('start',_('IP Address Version Mismatch'));
- Error::add('end',_('IP Address Version Mismatch'));
+ Error::add('start', T_('IP Address Version Mismatch'));
+ Error::add('end', T_('IP Address Version Mismatch'));
return false;
}
// Check existing ACL's to make sure we're not duplicating values here
if (self::exists($data)) {
debug_event('ACL Create','Error: An ACL equal to the created one does already exist. Not adding another one: ' . $data['start'] . ' - ' . $data['end'],'1');
- Error::add('general',_('Duplicate ACL defined'));
+ Error::add('general', T_('Duplicate ACL defined'));
return false;
}
@@ -482,16 +482,16 @@ class Access {
public function get_level_name() {
if ($this->level >= '75') {
- return _('All');
+ return T_('All');
}
if ($this->level == '5') {
- return _('View');
+ return T_('View');
}
if ($this->level == '25') {
- return _('Read');
+ return T_('Read');
}
if ($this->level == '50') {
- return _('Read/Write');
+ return T_('Read/Write');
}
} // get_level_name
@@ -502,7 +502,7 @@ class Access {
*/
public function get_user_name() {
- if ($this->user == '-1') { return _('All'); }
+ if ($this->user == '-1') { return T_('All'); }
$user = new User($this->user);
return $user->fullname . " (" . $user->username . ")";
@@ -518,17 +518,17 @@ class Access {
switch ($this->type) {
case 'xml-rpc':
case 'rpc':
- return _('API/RPC');
+ return T_('API/RPC');
break;
case 'network':
- return _('Local Network Definition');
+ return T_('Local Network Definition');
break;
case 'interface':
- return _('Web Interface');
+ return T_('Web Interface');
break;
case 'stream':
default:
- return _('Stream Access');
+ return T_('Stream Access');
break;
} // end switch
diff --git a/lib/class/album.class.php b/lib/class/album.class.php
index dbf0b18e..1c4aa301 100644
--- a/lib/class/album.class.php
+++ b/lib/class/album.class.php
@@ -246,7 +246,7 @@ class Album extends database_object {
$this->f_name_link = "<a href=\"$web_path/albums.php?action=show&amp;album=" . scrub_out($this->id) . "\" title=\"" . scrub_out($this->full_name) . "\">" . scrub_out($this->f_name);
// If we've got a disk append it
if ($this->disk) {
- $this->f_name_link .= " <span class=\"discnb disc" .$this->disk. "\">[" . _('Disk') . " " . $this->disk . "]</span>";
+ $this->f_name_link .= " <span class=\"discnb disc" .$this->disk. "\">[" . T_('Disk') . " " . $this->disk . "]</span>";
}
$this->f_name_link .="</a>";
@@ -260,8 +260,8 @@ class Album extends database_object {
$this->f_artist = $artist;
}
else {
- $this->f_artist_link = "<span title=\"$this->artist_count " . _('Artists') . "\">" . _('Various') . "</span>";
- $this->f_artist = _('Various');
+ $this->f_artist_link = "<span title=\"$this->artist_count " . T_('Artists') . "\">" . T_('Various') . "</span>";
+ $this->f_artist = T_('Various');
$this->f_artist_name = $this->f_artist;
}
diff --git a/lib/class/ampacherss.class.php b/lib/class/ampacherss.class.php
index 681ae98f..b971b1fb 100644
--- a/lib/class/ampacherss.class.php
+++ b/lib/class/ampacherss.class.php
@@ -80,10 +80,10 @@ class AmpacheRSS {
*/
public function get_title() {
- $titles = array('now_playing'=>_('Now Playing'),
- 'recently_played'=>_('Recently Played'),
- 'latest_album'=>_('Newest Albums'),
- 'latest_artist'=>_('Newest Artists'));
+ $titles = array('now_playing' => T_('Now Playing'),
+ 'recently_played' => T_('Recently Played'),
+ 'latest_album' => T_('Newest Albums'),
+ 'latest_artist' => T_('Newest Artists'));
return scrub_out(Config::get('site_title')) . ' - ' . $titles[$this->type];
@@ -126,7 +126,7 @@ class AmpacheRSS {
// Default to now playing
$type = self::validate_type($type);
- $string = '<a href="' . Config::get('web_path') . '/rss.php?type=' . $type . '">' . get_user_icon('feed',_('RSS Feed')) . '</a>';
+ $string = '<a href="' . Config::get('web_path') . '/rss.php?type=' . $type . '">' . get_user_icon('feed', T_('RSS Feed')) . '</a>';
return $string;
@@ -185,7 +185,7 @@ class AmpacheRSS {
//FIXME: The time stuff should be centralized, it's currently in two places, lame
- $time_unit = array('',_('seconds ago'),_('minutes ago'),_('hours ago'),_('days ago'),_('weeks ago'),_('months ago'),_('years ago'));
+ $time_unit = array('', T_('seconds ago'), T_('minutes ago'), T_('hours ago'), T_('days ago'), T_('weeks ago'), T_('months ago'), T_('years ago'));
$data = Song::get_recently_played();
$results = array();
diff --git a/lib/class/api.class.php b/lib/class/api.class.php
index 61b071f6..ff7e2cb3 100644
--- a/lib/class/api.class.php
+++ b/lib/class/api.class.php
@@ -132,7 +132,7 @@ class Api {
if (intval($version) < self::$version) {
debug_event('API', 'Login Failed: version too old', 1);
- Error::add('api', _('Login Failed: version too old'));
+ Error::add('api', T_('Login Failed: version too old'));
return false;
}
@@ -140,7 +140,7 @@ class Api {
if (($timestamp < (time() - 1800)) ||
($timestamp > (time() + 1800))) {
debug_event('API', 'Login Failed: timestamp out of range', 1);
- Error::add('api', _('Login Failed: timestamp out of range'));
+ Error::add('api', T_('Login Failed: timestamp out of range'));
return false;
}
@@ -169,7 +169,7 @@ class Api {
if (!$row['password']) {
debug_event('API', 'Unable to find user with userid of ' . $user_id, 1);
- Error::add('api', _('Invalid Username/Password'));
+ Error::add('api', T_('Invalid Username/Password'));
return false;
}
@@ -232,7 +232,7 @@ class Api {
} // end while
debug_event('API','Login Failed, unable to match passphrase','1');
- xmlData::error('401',_('Error Invalid Handshake - ') . _('Invalid Username/Password'));
+ xmlData::error('401', T_('Error Invalid Handshake - ') . T_('Invalid Username/Password'));
} // handshake
@@ -659,7 +659,7 @@ class Api {
break;
default:
// They are doing it wrong
- echo xmlData::error('405',_('Invalid Request'));
+ echo xmlData::error('405', T_('Invalid Request'));
break;
} // end switch on command
@@ -680,7 +680,7 @@ class Api {
$type = 'song';
$media = new $type($input['oid']);
if (!$media->id) {
- echo xmlData::error('400',_('Media Object Invalid or Not Specified'));
+ echo xmlData::error('400', T_('Media Object Invalid or Not Specified'));
break;
}
$democratic->vote(array(array('song',$media->id)));
@@ -693,7 +693,7 @@ class Api {
$type = 'song';
$media = new $type($input['oid']);
if (!$media->id) {
- echo xmlData::error('400',_('Media Object Invalid or Not Specified'));
+ echo xmlData::error('400', T_('Media Object Invalid or Not Specified'));
}
$uid = $democratic->get_uid_from_object_id($media->id,$type);
@@ -715,7 +715,7 @@ class Api {
echo xmlData::keyed_array($xml_array);
break;
default:
- echo xmlData::error('405',_('Invalid Request'));
+ echo xmlData::error('405', T_('Invalid Request'));
break;
} // switch on method
diff --git a/lib/class/art.class.php b/lib/class/art.class.php
index 647e5163..ad8023ca 100644
--- a/lib/class/art.class.php
+++ b/lib/class/art.class.php
@@ -1000,7 +1000,7 @@ class Art extends database_object {
$handle = opendir($dir);
if (!$handle) {
- Error::add('general',_('Error: Unable to open') . ' ' . $dir);
+ Error::add('general', T_('Error: Unable to open') . ' ' . $dir);
debug_event('folder_art', "Error: Unable to open $dir for album art read", 2);
continue;
}
diff --git a/lib/class/artist.class.php b/lib/class/artist.class.php
index 583cab8c..78459e24 100644
--- a/lib/class/artist.class.php
+++ b/lib/class/artist.class.php
@@ -376,7 +376,7 @@ class Artist extends database_object {
// check for fault
if ($client->fault) {
debug_event("lyrics", "Can't get lyrics", "1");
- return $results = "<h2>" . _('Fault') . "</h2>" . print_r($result);
+ return $results = "<h2>" . T_('Fault') . "</h2>" . print_r($result);
}
else {
// check for errors
@@ -384,12 +384,12 @@ class Artist extends database_object {
if ($err) {
debug_event("lyrics", "Getting error: $err", "1");
- return $results = "<h2>" . _('Error') . "</h2>" . $err;
+ return $results = "<h2>" . T_('Error') . "</h2>" . $err;
}
else {
// if returned "Not found" do not add
if($result['lyrics'] == "Not found") {
- $sorry = _('Sorry Lyrics Not Found.');
+ $sorry = T_('Sorry Lyrics Not Found.');
return $sorry;
}
else {
diff --git a/lib/class/browse.class.php b/lib/class/browse.class.php
index 83eb2d27..89cf5933 100644
--- a/lib/class/browse.class.php
+++ b/lib/class/browse.class.php
@@ -137,84 +137,84 @@ class Browse extends Query {
// Switch on the type of browsing we're doing
switch ($type) {
case 'song':
- show_box_top(_('Songs') . $match, $class);
+ show_box_top(T_('Songs') . $match, $class);
Song::build_cache($object_ids);
require_once Config::get('prefix') . '/templates/show_songs.inc.php';
show_box_bottom();
break;
case 'album':
- show_box_top(_('Albums') . $match, $class);
+ show_box_top(T_('Albums') . $match, $class);
Album::build_cache($object_ids,'extra');
require_once Config::get('prefix') . '/templates/show_albums.inc.php';
show_box_bottom();
break;
case 'user':
- show_box_top(_('Manage Users') . $match, $class);
+ show_box_top(T_('Manage Users') . $match, $class);
require_once Config::get('prefix') . '/templates/show_users.inc.php';
show_box_bottom();
break;
case 'artist':
- show_box_top(_('Artists') . $match, $class);
+ show_box_top(T_('Artists') . $match, $class);
Artist::build_cache($object_ids,'extra');
require_once Config::get('prefix') . '/templates/show_artists.inc.php';
show_box_bottom();
break;
case 'live_stream':
require_once Config::get('prefix') . '/templates/show_live_stream.inc.php';
- show_box_top(_('Radio Stations') . $match, $class);
+ show_box_top(T_('Radio Stations') . $match, $class);
require_once Config::get('prefix') . '/templates/show_live_streams.inc.php';
show_box_bottom();
break;
case 'playlist':
Playlist::build_cache($object_ids);
- show_box_top(_('Playlists') . $match, $class);
+ show_box_top(T_('Playlists') . $match, $class);
require_once Config::get('prefix') . '/templates/show_playlists.inc.php';
show_box_bottom();
break;
case 'playlist_song':
- show_box_top(_('Playlist Songs') . $match,$class);
+ show_box_top(T_('Playlist Songs') . $match,$class);
require_once Config::get('prefix') . '/templates/show_playlist_songs.inc.php';
show_box_bottom();
break;
case 'playlist_localplay':
- show_box_top(_('Current Playlist'));
+ show_box_top(T_('Current Playlist'));
require_once Config::get('prefix') . '/templates/show_localplay_playlist.inc.php';
show_box_bottom();
break;
case 'smartplaylist':
- show_box_top(_('Smart Playlists') . $match, $class);
+ show_box_top(T_('Smart Playlists') . $match, $class);
require_once Config::get('prefix') . '/templates/show_smartplaylists.inc.php';
show_box_bottom();
break;
case 'catalog':
- show_box_top(_('Catalogs'), $class);
+ show_box_top(T_('Catalogs'), $class);
require_once Config::get('prefix') . '/templates/show_catalogs.inc.php';
show_box_bottom();
break;
case 'shoutbox':
- show_box_top(_('Shoutbox Records'),$class);
+ show_box_top(T_('Shoutbox Records'),$class);
require_once Config::get('prefix') . '/templates/show_manage_shoutbox.inc.php';
show_box_bottom();
break;
case 'flagged':
- show_box_top(_('Flagged Records'),$class);
+ show_box_top(T_('Flagged Records'),$class);
require_once Config::get('prefix') . '/templates/show_flagged.inc.php';
show_box_bottom();
break;
case 'tag':
Tag::build_cache($tags);
- show_box_top(_('Tag Cloud'),$class);
+ show_box_top(T_('Tag Cloud'),$class);
require_once Config::get('prefix') . '/templates/show_tagcloud.inc.php';
show_box_bottom();
break;
case 'video':
Video::build_cache($object_ids);
- show_box_top(_('Videos'),$class);
+ show_box_top(T_('Videos'),$class);
require_once Config::get('prefix') . '/templates/show_videos.inc.php';
show_box_bottom();
break;
case 'democratic':
- show_box_top(_('Democratic Playlist'),$class);
+ show_box_top(T_('Democratic Playlist'),$class);
require_once Config::get('prefix') . '/templates/show_democratic_playlist.inc.php';
show_box_bottom();
default:
diff --git a/lib/class/catalog.class.php b/lib/class/catalog.class.php
index 52073202..0de562d2 100644
--- a/lib/class/catalog.class.php
+++ b/lib/class/catalog.class.php
@@ -170,9 +170,9 @@ class Catalog extends database_object {
$this->f_name = truncate_with_ellipsis($this->name,Config::get('ellipse_threshold_title'));
$this->f_name_link = '<a href="' . Config::get('web_path') . '/admin/catalog.php?action=show_customize_catalog&catalog_id=' . $this->id . '" title="' . scrub_out($this->name) . '">' . scrub_out($this->f_name) . '</a>';
$this->f_path = truncate_with_ellipsis($this->path,Config::get('ellipse_threshold_title'));
- $this->f_update = $this->last_update ? date('d/m/Y h:i',$this->last_update) : _('Never');
- $this->f_add = $this->last_add ? date('d/m/Y h:i',$this->last_add) : _('Never');
- $this->f_clean = $this->last_clean ? date('d/m/Y h:i',$this->last_clean) : _('Never');
+ $this->f_update = $this->last_update ? date('d/m/Y h:i',$this->last_update) : T_('Never');
+ $this->f_add = $this->last_add ? date('d/m/Y h:i',$this->last_add) : T_('Never');
+ $this->f_clean = $this->last_clean ? date('d/m/Y h:i',$this->last_clean) : T_('Never');
} // format
@@ -276,7 +276,7 @@ class Catalog extends database_object {
// Make sure the path is readable/exists
if (!is_readable($data['path']) AND $data['type'] == 'local') {
- Error::add('general', sprintf(_('Error: %s is not readable or does not exist'), scrub_out($data['path'])));
+ Error::add('general', sprintf(T_('Error: %s is not readable or does not exist'), scrub_out($data['path'])));
return false;
}
@@ -285,7 +285,7 @@ class Catalog extends database_object {
$db_results = Dba::read($sql);
if (Dba::num_rows($db_results)) {
- Error::add('general', sprintf(_('Error: Catalog with %s already exists'), $path));
+ Error::add('general', sprintf(T_('Error: Catalog with %s already exists'), $path));
return false;
}
@@ -312,7 +312,7 @@ class Catalog extends database_object {
$insert_id = Dba::insert_id();
if (!$insert_id) {
- Error::add('general', _('Catalog Insert Failed check debug logs'));
+ Error::add('general', T_('Catalog Insert Failed check debug logs'));
debug_event('catalog','SQL Failed:' . $sql,'3');
return false;
}
@@ -330,7 +330,7 @@ class Catalog extends database_object {
public function run_add($options) {
if ($this->catalog_type == 'remote') {
- show_box_top(_('Running Remote Sync') . '. . .');
+ show_box_top(T_('Running Remote Sync') . '. . .');
$this->get_remote_catalog($type=0);
show_box_bottom();
return true;
@@ -496,14 +496,14 @@ class Catalog extends database_object {
if (!is_resource($handle)) {
debug_event('read', "Unable to open $path", 5,'ampache-catalog');
- Error::add('catalog_add', sprintf(_('Error: Unable to open %s'), $path));
+ Error::add('catalog_add', sprintf(T_('Error: Unable to open %s'), $path));
return false;
}
/* Change the dir so is_dir works correctly */
if (!chdir($path)) {
debug_event('read', "Unable to chdir $path", 2,'ampache-catalog');
- Error::add('catalog_add', sprintf(_('Error: Unable to change to directory %s'), $path));
+ Error::add('catalog_add', sprintf(T_('Error: Unable to change to directory %s'), $path));
return false;
}
@@ -549,7 +549,7 @@ class Catalog extends database_object {
/* Change the dir so is_dir works correctly */
if (!chdir($path)) {
debug_event('read',"Unable to chdir $path",'2','ampache-catalog');
- Error::add('catalog_add', sprintf(_('Error: Unable to change to directory %s'), $path));
+ Error::add('catalog_add', sprintf(T_('Error: Unable to change to directory %s'), $path));
}
/* Skip to the next file */
@@ -586,14 +586,14 @@ class Catalog extends database_object {
if (!$file_size) {
debug_event('read',"Unable to get filesize for $full_file",'2','ampache-catalog');
/* HINT: FullFile */
- Error::add('catalog_add', sprintf(_('Error: Unable to get filesize for %s'), $full_file));
+ Error::add('catalog_add', sprintf(T_('Error: Unable to get filesize for %s'), $full_file));
} // file_size check
if (!is_readable($full_file)) {
// not readable, warn user
debug_event('read',"$full_file is not readable by ampache",'2','ampache-catalog');
/* HINT: FullFile */
- Error::add('catalog_add', sprintf(_('%s is not readable by ampache'), $full_file));
+ Error::add('catalog_add', sprintf(T_('%s is not readable by ampache'), $full_file));
continue;
}
@@ -602,7 +602,7 @@ class Catalog extends database_object {
if (strcmp($full_file,iconv(Config::get('site_charset'),Config::get('site_charset'),$full_file)) != '0') {
debug_event('read',$full_file . ' has non-' . Config::get('site_charset') . ' characters and can not be indexed, converted filename:' . iconv(Config::get('site_charset'),Config::get('site_charset'),$full_file),'1');
/* HINT: FullFile */
- Error::add('catalog_add', sprintf(_('%s does not match site charset'), $full_file));
+ Error::add('catalog_add', sprintf(T_('%s does not match site charset'), $full_file));
continue;
}
} // end if iconv
@@ -1079,14 +1079,14 @@ class Catalog extends database_object {
if ($info['change']) {
$file = scrub_out($song->file);
echo "<dl>\n\t<dd>";
- echo "<strong>$file " . _('Updated') . "</strong>\n";
+ echo "<strong>$file " . T_('Updated') . "</strong>\n";
echo $info['text'];
echo "\t</dd>\n</dl><hr align=\"left\" width=\"50%\" />";
flush();
} // if change
else {
echo"<dl>\n\t<dd>";
- echo "<strong>" . scrub_out($song->file) . "</strong><br />" . _('No Update Needed') . "\n";
+ echo "<strong>" . scrub_out($song->file) . "</strong><br />" . T_('No Update Needed') . "\n";
echo "\t</dd>\n</dl><hr align=\"left\" width=\"50%\" />";
flush();
}
@@ -1221,7 +1221,7 @@ class Catalog extends database_object {
public function add_to_catalog() {
if ($this->catalog_type == 'remote') {
- show_box_top(_('Running Remote Update') . '. . .');
+ show_box_top(T_('Running Remote Update') . '. . .');
$this->get_remote_catalog($type=0);
show_box_bottom();
return true;
@@ -1248,7 +1248,7 @@ class Catalog extends database_object {
if ($this->import_m3u($full_file)) {
$file = basename($full_file);
if ($verbose) {
- echo "&nbsp;&nbsp;&nbsp;" . _('Added Playlist From') . " $file . . . .<br />\n";
+ echo "&nbsp;&nbsp;&nbsp;" . T_('Added Playlist From') . " $file . . . .<br />\n";
flush();
}
} // end if import worked
@@ -1277,8 +1277,8 @@ class Catalog extends database_object {
}
show_box_top();
- echo "\n<br />" . _('Catalog Update Finished') . "... " . _('Total Time') . " [" . date("i:s",$time_diff) . "] " .
- _('Total Songs') . " [" . $this->count . "] " . _('Songs Per Seconds') . " [" . $song_per_sec . "]<br /><br />";
+ echo "\n<br />" . T_('Catalog Update Finished') . "... " . T_('Total Time') . " [" . date("i:s",$time_diff) . "] " .
+ T_('Total Songs') . " [" . $this->count . "] " . T_('Songs Per Seconds') . " [" . $song_per_sec . "]<br /><br />";
show_box_bottom();
} // add_to_catalog
@@ -1301,7 +1301,7 @@ class Catalog extends database_object {
if ($remote_handle->state() != 'CONNECTED') {
debug_event('APICLIENT','Error Unable to make API client ready','1');
- Error::add('general',_('Error Connecting to Remote Server'));
+ Error::add('general', T_('Error Connecting to Remote Server'));
Error::display('general');
return false;
}
@@ -1310,7 +1310,7 @@ class Catalog extends database_object {
$remote_catalog_info = $remote_handle->info();
// Tell em what we've found johnny!
- printf(_('%u remote catalog(s) found (%u songs)'),$remote_catalog_info['catalogs'],$remote_catalog_info['songs']);
+ printf(T_('%u remote catalog(s) found (%u songs)'),$remote_catalog_info['catalogs'],$remote_catalog_info['songs']);
flush();
// Hardcoded for now
@@ -1334,14 +1334,14 @@ class Catalog extends database_object {
foreach ($songs as $data) {
if (!$this->insert_remote_song($data['song'])) {
debug_event('REMOTE_INSERT','Remote Insert failed, see previous log messages -' . $data['song']['self']['id'],'1');
- Error::add('general',_('Unable to Insert Song - %s'),$data['song']['title']);
+ Error::add('general', T_('Unable to Insert Song - %s'),$data['song']['title']);
Error::display('general');
flush();
}
} // end foreach
} // end while
- echo "<p>" . _('Completed updating remote catalog(s)') . ".</p><hr />\n";
+ echo "<p>" . T_('Completed updating remote catalog(s)') . ".</p><hr />\n";
flush();
// Update the last update value
@@ -1384,7 +1384,7 @@ class Catalog extends database_object {
// mount points fail
if ($this->catalog_type == 'local' && !is_readable($this->path)) {
debug_event('catalog', 'Catalog path:' . $this->path . ' unreadable, clean failed', 1);
- Error::add('general',_('Catalog Root unreadable, stopping clean'));
+ Error::add('general', T_('Catalog Root unreadable, stopping clean'));
Error::display('general');
return false;
}
@@ -1408,7 +1408,7 @@ class Catalog extends database_object {
// Never remove everything; it might be a dead mount
if ($dead_count >= $total) {
debug_event('catalog', 'All files would be removed. Doing nothing.', 1);
- Error::add('general', _('All files would be removed. Doing nothing'));
+ Error::add('general', T_('All files would be removed. Doing nothing'));
continue;
}
if ($dead_count) {
@@ -1462,7 +1462,7 @@ class Catalog extends database_object {
$file_info = filesize($results['file']);
if (!file_exists($results['file']) || $file_info < 1) {
debug_event('clean', 'File not found or empty: ' . $results['file'], 5, 'ampache-catalog');
- Error::add('general', sprintf(_('Error File Not Found or 0 Bytes: %s'), $results['file']));
+ Error::add('general', sprintf(T_('Error File Not Found or 0 Bytes: %s'), $results['file']));
// Store it in an array we'll delete it later...
@@ -1479,7 +1479,7 @@ class Catalog extends database_object {
if ($file_info == false) {
/* Add Error */
- Error::add('general', sprintf(_('Error Remote File Not Found or 0 Bytes: %s'), $results['file']));
+ Error::add('general', sprintf(T_('Error Remote File Not Found or 0 Bytes: %s'), $results['file']));
// Store it in an array we'll delete it later...
@@ -1696,7 +1696,7 @@ class Catalog extends database_object {
show_box_top();
echo '<strong>';
- printf(_('Catalog Verify Done. %d of %d files updated.'), $total_updated, $number);
+ printf(T_('Catalog Verify Done. %d of %d files updated.'), $total_updated, $number);
echo "</strong><br />\n";
show_box_bottom();
ob_flush();
@@ -1737,7 +1737,7 @@ class Catalog extends database_object {
}
if (!is_readable($row['file'])) {
- Error::add('general', sprintf(_('%s does not exist or is not readable'), $row['file']));
+ Error::add('general', sprintf(T_('%s does not exist or is not readable'), $row['file']));
debug_event('read', $row['file'] . ' does not exist or is not readable', 5,'ampache-catalog');
continue;
}
@@ -1835,7 +1835,7 @@ class Catalog extends database_object {
/* Ohh no the artist has lost it's mojo! */
if (!$artist) {
- $artist = _('Unknown (Orphaned)');
+ $artist = T_('Unknown (Orphaned)');
}
// Remove the prefix so we can sort it correctly
@@ -1890,7 +1890,7 @@ class Catalog extends database_object {
$sql = "UPDATE `artist` SET `mbid`='$mbid' WHERE `id`='$artist_id'";
$db_results = Dba::write($sql);
if (!$db_results) {
- Error::add('general', sprintf(_('Updating Artist: %s'), $artist));
+ Error::add('general', sprintf(T_('Updating Artist: %s'), $artist));
}
}
}
@@ -1911,7 +1911,7 @@ class Catalog extends database_object {
$artist_id = Dba::insert_id();
if (!$db_results) {
- Error::add('general', sprintf(_('Inserting Artist: %s'), $artist));
+ Error::add('general', sprintf(T_('Inserting Artist: %s'), $artist));
}
} // not found
@@ -1943,7 +1943,7 @@ class Catalog extends database_object {
/* Ohh no the album has lost its mojo */
if (!$album) {
- $album = _('Unknown (Orphaned)');
+ $album = T_('Unknown (Orphaned)');
unset($album_year, $album_disk);
}
@@ -2091,7 +2091,7 @@ class Catalog extends database_object {
if (!$db_results) {
debug_event('insert',"Unable to insert $file -- $sql" . Dba::error(),'5','ampache-catalog');
- Error::add('catalog_add', sprintf(_('SQL Error Adding %s'), $file));
+ Error::add('catalog_add', sprintf(T_('SQL Error Adding %s'), $file));
}
$song_id = Dba::insert_id();
@@ -2314,7 +2314,7 @@ class Catalog extends database_object {
$playlist_id = Playlist::create($name,'public');
if (!$playlist_id) {
- $reason = _('Playlist creation error.');
+ $reason = T_('Playlist creation error.');
return false;
}
diff --git a/lib/class/config.class.php b/lib/class/config.class.php
index 78745be8..8ad7189e 100644
--- a/lib/class/config.class.php
+++ b/lib/class/config.class.php
@@ -110,7 +110,7 @@ class Config {
if (isset(self::$_global[$name]) && !$clobber) {
debug_event('Config', "Tried to overwrite existing key $name without setting clobber", 5);
- Error::add('Config Global', sprintf(_('Trying to clobber \'%s\' without setting clobber'), $name));
+ Error::add('Config Global', sprintf(T_('Trying to clobber \'%s\' without setting clobber'), $name));
return false;
}
diff --git a/lib/class/democratic.class.php b/lib/class/democratic.class.php
index a0ea01a5..71699960 100644
--- a/lib/class/democratic.class.php
+++ b/lib/class/democratic.class.php
@@ -150,24 +150,24 @@ class Democratic extends tmpPlaylist {
*/
public function format() {
- $this->f_cooldown = $this->cooldown . ' ' . _('minutes');
- $this->f_primary = $this->primary ? _('Primary') : '';
+ $this->f_cooldown = $this->cooldown . ' ' . T_('minutes');
+ $this->f_primary = $this->primary ? T_('Primary') : '';
switch ($this->level) {
case '5':
- $this->f_level = _('Guest');
+ $this->f_level = T_('Guest');
break;
case '25':
- $this->f_level = _('User');
+ $this->f_level = T_('User');
break;
case '50':
- $this->f_level = _('Content Manager');
+ $this->f_level = T_('Content Manager');
break;
case '75':
- $this->f_level = _('Catalog Manager');
+ $this->f_level = T_('Catalog Manager');
break;
case '100':
- $this->f_level = _('Admin');
+ $this->f_level = T_('Admin');
break;
}
diff --git a/lib/class/flag.class.php b/lib/class/flag.class.php
index b3791dbd..bbb3f4a0 100644
--- a/lib/class/flag.class.php
+++ b/lib/class/flag.class.php
@@ -322,8 +322,8 @@ class Flag extends database_object {
*/
public function print_status() {
- if ($this->approved) { echo _('Approved'); }
- else { echo _('Pending'); }
+ if ($this->approved) { echo T_('Approved'); }
+ else { echo T_('Pending'); }
} // print_status
@@ -335,19 +335,19 @@ class Flag extends database_object {
switch ($this->flag) {
case 'delete':
- $name = _('Delete');
+ $name = T_('Delete');
break;
case 'retag':
- $name = _('Re-Tag');
+ $name = T_('Re-Tag');
break;
case 'reencode':
- $name = _('Re-encode');
+ $name = T_('Re-encode');
break;
case 'other':
- $name = _('Other');
+ $name = T_('Other');
break;
default:
- $name = _('Unknown');
+ $name = T_('Unknown');
break;
} // end switch
diff --git a/lib/class/localplay.class.php b/lib/class/localplay.class.php
index ef03b1c3..cebc5bff 100644
--- a/lib/class/localplay.class.php
+++ b/lib/class/localplay.class.php
@@ -653,16 +653,16 @@ class Localplay {
switch ($state) {
case 'play':
- return _('Now Playing');
+ return T_('Now Playing');
break;
case 'stop':
- return _('Stopped');
+ return T_('Stopped');
break;
case 'pause':
- return _('Paused');
+ return T_('Paused');
break;
default:
- return _('Unknown');
+ return T_('Unknown');
break;
} // switch on state
diff --git a/lib/class/playlist_object.abstract.php b/lib/class/playlist_object.abstract.php
index def7b3f2..fd9b0147 100644
--- a/lib/class/playlist_object.abstract.php
+++ b/lib/class/playlist_object.abstract.php
@@ -39,7 +39,7 @@ abstract class playlist_object extends database_object {
public function format() {
$this->f_name = truncate_with_ellipsis($this->name,Config::get('ellipse_threshold_title'));
- $this->f_type = ($this->type == 'private') ? get_user_icon('lock',_('Private')) : '';
+ $this->f_type = ($this->type == 'private') ? get_user_icon('lock', T_('Private')) : '';
$client = new User($this->user);
diff --git a/lib/class/query.class.php b/lib/class/query.class.php
index 49a978af..1dffd35b 100644
--- a/lib/class/query.class.php
+++ b/lib/class/query.class.php
@@ -79,7 +79,7 @@ class Query {
return true;
}
- Error::add('browse', _('Browse not found or expired, try reloading the page'));
+ Error::add('browse', T_('Browse not found or expired, try reloading the page'));
return false;
}
diff --git a/lib/class/radio.class.php b/lib/class/radio.class.php
index 46743614..d4be4f76 100644
--- a/lib/class/radio.class.php
+++ b/lib/class/radio.class.php
@@ -92,11 +92,11 @@ class Radio extends database_object implements media {
// Verify the incoming data
if (!$data['id']) {
- Error::add('general', _('Missing ID'));
+ Error::add('general', T_('Missing ID'));
}
if (!$data['name']) {
- Error::add('general', _('Name Required'));
+ Error::add('general', T_('Name Required'));
}
$allowed_array = array('https','http','mms','mmsh','mmsu','mmst','rtsp');
@@ -104,7 +104,7 @@ class Radio extends database_object implements media {
$elements = explode(":",$data['url']);
if (!in_array($elements['0'],$allowed_array)) {
- Error::add('general', _('Invalid URL must be mms:// , https:// or http://'));
+ Error::add('general', T_('Invalid URL must be mms:// , https:// or http://'));
}
if (Error::occurred()) {
@@ -136,7 +136,7 @@ class Radio extends database_object implements media {
// Make sure we've got a name
if (!strlen($data['name'])) {
- Error::add('name', _('Name Required'));
+ Error::add('name', T_('Name Required'));
}
$allowed_array = array('https','http','mms','mmsh','mmsu','mmst','rtsp');
@@ -144,13 +144,13 @@ class Radio extends database_object implements media {
$elements = explode(":",$data['url']);
if (!in_array($elements['0'],$allowed_array)) {
- Error::add('url', _('Invalid URL must be http:// or https://'));
+ Error::add('url', T_('Invalid URL must be http:// or https://'));
}
// Make sure it's a real catalog
$catalog = new Catalog($data['catalog']);
if (!$catalog->name) {
- Error::add('catalog', _('Invalid Catalog'));
+ Error::add('catalog', T_('Invalid Catalog'));
}
if (Error::occurred()) { return false; }
diff --git a/lib/class/random.class.php b/lib/class/random.class.php
index ef6c3037..5dc8b47b 100644
--- a/lib/class/random.class.php
+++ b/lib/class/random.class.php
@@ -368,16 +368,16 @@ class Random implements media {
switch ($type) {
case 'album':
- return _('Related Album');
+ return T_('Related Album');
break;
case 'genre':
- return _('Related Genre');
+ return T_('Related Genre');
break;
case 'artist':
- return _('Related Artist');
+ return T_('Related Artist');
break;
default:
- return _('Pure Random');
+ return T_('Pure Random');
break;
} // end switch
diff --git a/lib/class/registration.class.php b/lib/class/registration.class.php
index 6175b016..bfc49d4b 100644
--- a/lib/class/registration.class.php
+++ b/lib/class/registration.class.php
@@ -59,9 +59,9 @@ class Registration {
// We are the system
$mailer->set_default_sender();
- $mailer->subject = sprintf(_("New User Registration at %s"), Config::get('site_title'));
+ $mailer->subject = sprintf(T_("New User Registration at %s"), Config::get('site_title'));
- $mailer->message = sprintf(_("Thank you for registering\n\n
+ $mailer->message = sprintf(T_("Thank you for registering\n\n
Please keep this e-mail for your records. Your account information is as follows:
----------------------
Username: %s
@@ -82,7 +82,7 @@ Thank you for registering
// Check to see if the admin should be notified
if (Config::get('admin_notify_reg')) {
- $mailer->message = sprintf(_("A new user has registered
+ $mailer->message = sprintf(T_("A new user has registered
The following values were entered.
Username: %s
diff --git a/lib/class/search.class.php b/lib/class/search.class.php
index fc860ed9..eaa45a97 100644
--- a/lib/class/search.class.php
+++ b/lib/class/search.class.php
@@ -53,55 +53,55 @@ class Search extends playlist_object {
$this->basetypes['numeric'][] = array(
'name' => 'gte',
- 'description' => _('is greater than or equal to'),
+ 'description' => T_('is greater than or equal to'),
'sql' => '>='
);
$this->basetypes['numeric'][] = array(
'name' => 'lte',
- 'description' => _('is less than or equal to'),
+ 'description' => T_('is less than or equal to'),
'sql' => '<='
);
$this->basetypes['numeric'][] = array(
'name' => 'equal',
- 'description' => _('is'),
+ 'description' => T_('is'),
'sql' => '<=>'
);
$this->basetypes['numeric'][] = array(
'name' => 'ne',
- 'description' => _('is not'),
+ 'description' => T_('is not'),
'sql' => '<>'
);
$this->basetypes['numeric'][] = array(
'name' => 'gt',
- 'description' => _('is greater than'),
+ 'description' => T_('is greater than'),
'sql' => '>'
);
$this->basetypes['numeric'][] = array(
'name' => 'lt',
- 'description' => _('is less than'),
+ 'description' => T_('is less than'),
'sql' => '<'
);
$this->basetypes['boolean'][] = array(
'name' => 'true',
- 'description' => _('is true')
+ 'description' => T_('is true')
);
$this->basetypes['boolean'][] = array(
'name' => 'false',
- 'description' => _('is false')
+ 'description' => T_('is false')
);
$this->basetypes['text'][] = array(
'name' => 'contain',
- 'description' => _('contains'),
+ 'description' => T_('contains'),
'sql' => 'LIKE',
'preg_match' => array('/^/','/$/'),
'preg_replace' => array('%', '%')
@@ -109,7 +109,7 @@ class Search extends playlist_object {
$this->basetypes['text'][] = array(
'name' => 'notcontain',
- 'description' => _('does not contain'),
+ 'description' => T_('does not contain'),
'sql' => 'NOT LIKE',
'preg_match' => array('/^/','/$/'),
'preg_replace' => array('%', '%')
@@ -117,7 +117,7 @@ class Search extends playlist_object {
$this->basetypes['text'][] = array(
'name' => 'start',
- 'description' => _('starts with'),
+ 'description' => T_('starts with'),
'sql' => 'LIKE',
'preg_match' => '/$/',
'preg_replace' => '%'
@@ -125,7 +125,7 @@ class Search extends playlist_object {
$this->basetypes['text'][] = array(
'name' => 'end',
- 'description' => _('ends with'),
+ 'description' => T_('ends with'),
'sql' => 'LIKE',
'preg_match' => '/^/',
'preg_replace' => '%'
@@ -133,58 +133,58 @@ class Search extends playlist_object {
$this->basetypes['text'][] = array(
'name' => 'equal',
- 'description' => _('is'),
+ 'description' => T_('is'),
'sql' => '='
);
$this->basetypes['text'][] = array(
'name' => 'sounds',
- 'description' => _('sounds like'),
+ 'description' => T_('sounds like'),
'sql' => 'SOUNDS LIKE'
);
$this->basetypes['text'][] = array(
'name' => 'notsounds',
- 'description' => _('does not sound like'),
+ 'description' => T_('does not sound like'),
'sql' => 'NOT SOUNDS LIKE'
);
$this->basetypes['boolean_numeric'][] = array(
'name' => 'equal',
- 'description' => _('is'),
+ 'description' => T_('is'),
'sql' => '<=>'
);
$this->basetypes['boolean_numeric'][] = array(
'name' => 'ne',
- 'description' => _('is not'),
+ 'description' => T_('is not'),
'sql' => '<>'
);
$this->basetypes['boolean_subsearch'][] = array(
'name' => 'equal',
- 'description' => _('is'),
+ 'description' => T_('is'),
'sql' => ''
);
$this->basetypes['boolean_subsearch'][] = array(
'name' => 'ne',
- 'description' => _('is not'),
+ 'description' => T_('is not'),
'sql' => 'NOT'
);
$this->basetypes['date'][] = array(
'name' => 'lt',
- 'description' => _('before'),
+ 'description' => T_('before'),
'sql' => '>'
);
$this->basetypes['date'][] = array(
'name' => 'gt',
- 'description' => _('after'),
+ 'description' => T_('after'),
'sql' => '>'
);
@@ -192,35 +192,35 @@ class Search extends playlist_object {
case 'song':
$this->types[] = array(
'name' => 'anywhere',
- 'label' => _('Any searchable text'),
+ 'label' => T_('Any searchable text'),
'type' => 'text',
'widget' => array('input', 'text')
);
$this->types[] = array(
'name' => 'title',
- 'label' => _('Title'),
+ 'label' => T_('Title'),
'type' => 'text',
'widget' => array('input', 'text')
);
$this->types[] = array(
'name' => 'album',
- 'label' => _('Album'),
+ 'label' => T_('Album'),
'type' => 'text',
'widget' => array('input', 'text')
);
$this->types[] = array(
'name' => 'artist',
- 'label' => _('Artist'),
+ 'label' => T_('Artist'),
'type' => 'text',
'widget' => array('input', 'text')
);
$this->types[] = array(
'name' => 'comment',
- 'label' => _('Comment'),
+ 'label' => T_('Comment'),
'type' => 'text',
'widget' => array('input', 'text')
);
@@ -228,28 +228,28 @@ class Search extends playlist_object {
$this->types[] = array(
'name' => 'tag',
- 'label' => _('Tag'),
+ 'label' => T_('Tag'),
'type' => 'text',
'widget' => array('input', 'text')
);
$this->types[] = array(
'name' => 'file',
- 'label' => _('Filename'),
+ 'label' => T_('Filename'),
'type' => 'text',
'widget' => array('input', 'text')
);
$this->types[] = array(
'name' => 'year',
- 'label' => _('Year'),
+ 'label' => T_('Year'),
'type' => 'numeric',
'widget' => array('input', 'text')
);
$this->types[] = array(
'name' => 'time',
- 'label' => _('Length (in minutes)'),
+ 'label' => T_('Length (in minutes)'),
'type' => 'numeric',
'widget' => array('input', 'text')
);
@@ -257,7 +257,7 @@ class Search extends playlist_object {
if (Config::get('ratings')) {
$this->types[] = array(
'name' => 'rating',
- 'label' => _('Rating'),
+ 'label' => T_('Rating'),
'type' => 'numeric',
'widget' => array(
'select',
@@ -274,7 +274,7 @@ class Search extends playlist_object {
$this->types[] = array(
'name' => 'bitrate',
- 'label' => _('Bitrate'),
+ 'label' => T_('Bitrate'),
'type' => 'numeric',
'widget' => array(
'select',
@@ -299,21 +299,21 @@ class Search extends playlist_object {
$this->types[] = array(
'name' => 'played',
- 'label' => _('Played'),
+ 'label' => T_('Played'),
'type' => 'boolean',
'widget' => array('input', 'hidden')
);
$this->types[] = array(
'name' => 'added',
- 'label' => _('Added'),
+ 'label' => T_('Added'),
'type' => 'date',
'widget' => array('input', 'text')
);
$this->types[] = array(
'name' => 'updated',
- 'label' => _('Updated'),
+ 'label' => T_('Updated'),
'type' => 'date',
'widget' => array('input', 'text')
);
@@ -326,7 +326,7 @@ class Search extends playlist_object {
}
$this->types[] = array(
'name' => 'catalog',
- 'label' => _('Catalog'),
+ 'label' => T_('Catalog'),
'type' => 'boolean_numeric',
'widget' => array('select', $catalogs)
);
@@ -339,7 +339,7 @@ class Search extends playlist_object {
}
$this->types[] = array(
'name' => 'playlist',
- 'label' => _('Playlist'),
+ 'label' => T_('Playlist'),
'type' => 'boolean_numeric',
'widget' => array('select', $playlists)
);
@@ -352,7 +352,7 @@ class Search extends playlist_object {
}
$this->types[] = array(
'name' => 'smartplaylist',
- 'label' => _('Smart Playlist'),
+ 'label' => T_('Smart Playlist'),
'type' => 'boolean_subsearch',
'widget' => array('select', $playlists)
);
@@ -360,14 +360,14 @@ class Search extends playlist_object {
case 'album':
$this->types[] = array(
'name' => 'title',
- 'label' => _('Title'),
+ 'label' => T_('Title'),
'type' => 'text',
'widget' => array('input', 'text')
);
$this->types[] = array(
'name' => 'year',
- 'label' => _('Year'),
+ 'label' => T_('Year'),
'type' => 'numeric',
'widget' => array('input', 'text')
);
@@ -375,7 +375,7 @@ class Search extends playlist_object {
if (Config::get('ratings')) {
$this->types[] = array(
'name' => 'rating',
- 'label' => _('Rating'),
+ 'label' => T_('Rating'),
'type' => 'numeric',
'widget' => array(
'select',
@@ -398,7 +398,7 @@ class Search extends playlist_object {
}
$this->types[] = array(
'name' => 'catalog',
- 'label' => _('Catalog'),
+ 'label' => T_('Catalog'),
'type' => 'boolean_numeric',
'widget' => array('select', $catalogs)
);
@@ -406,7 +406,7 @@ class Search extends playlist_object {
$this->types[] = array(
'name' => 'tag',
- 'label' => _('Tag'),
+ 'label' => T_('Tag'),
'type' => 'text',
'widget' => array('input', 'text')
);
@@ -414,7 +414,7 @@ class Search extends playlist_object {
case 'video':
$this->types[] = array(
'name' => 'filename',
- 'label' => _('Filename'),
+ 'label' => T_('Filename'),
'type' => 'text',
'widget' => array('input', 'text')
);
@@ -422,13 +422,13 @@ class Search extends playlist_object {
case 'artist':
$this->types[] = array(
'name' => 'name',
- 'label' => _('Name'),
+ 'label' => T_('Name'),
'type' => 'text',
'widget' => array('input', 'text')
);
$this->types[] = array(
'name' => 'tag',
- 'label' => _('Tag'),
+ 'label' => T_('Tag'),
'type' => 'text',
'widget' => array('input', 'text')
);
diff --git a/lib/class/update.class.php b/lib/class/update.class.php
index c1a6c3fb..3401436b 100644
--- a/lib/class/update.class.php
+++ b/lib/class/update.class.php
@@ -417,7 +417,7 @@ class Update {
if (!$update_needed) {
if (!defined('CLI')) { echo '<p align="center">'; }
- echo _('No updates needed.');
+ echo T_('No updates needed.');
if (!defined('CLI')) {
echo '[<a href="', Config::get('web_path'), '">Return</a>]</p>';
}
@@ -446,7 +446,7 @@ class Update {
/* Verify that there are no plugins installed
//FIXME: provide a link to remove all plugins, otherwise this could turn into a catch 22
if (!$self::plugins_installed()) {
- $GLOBALS['error']->add_error('general',_('Plugins detected, please remove all Plugins and try again'));
+ $GLOBALS['error']->add_error('general', T_('Plugins detected, please remove all Plugins and try again'));
return false;
} */
diff --git a/lib/class/user.class.php b/lib/class/user.class.php
index 4b283d62..09000600 100644
--- a/lib/class/user.class.php
+++ b/lib/class/user.class.php
@@ -408,11 +408,11 @@ class User extends database_object {
public function update($data) {
if (empty($data['username'])) {
- Error::add('username',_('Error Username Required'));
+ Error::add('username', T_('Error Username Required'));
}
if ($data['password1'] != $data['password2'] AND !empty($data['password1'])) {
- Error::add('password',_("Error Passwords don't match"));
+ Error::add('password', T_("Error Passwords don't match"));
}
if (Error::occurred()) {
@@ -696,11 +696,11 @@ class User extends database_object {
public function format() {
/* If they have a last seen date */
- if (!$this->last_seen) { $this->f_last_seen = _('Never'); }
+ if (!$this->last_seen) { $this->f_last_seen = T_('Never'); }
else { $this->f_last_seen = date("m\/d\/Y - H:i",$this->last_seen); }
/* If they have a create date */
- if (!$this->create_date) { $this->f_create_date = _('Unknown'); }
+ if (!$this->create_date) { $this->f_create_date = T_('Unknown'); }
else { $this->f_create_date = date("m\/d\/Y - H:i",$this->create_date); }
// Base link
@@ -722,7 +722,7 @@ class User extends database_object {
$this->ip_history = inet_ntop($data['0']['ip']);
}
else {
- $this->ip_history = _('Not Enough Data');
+ $this->ip_history = T_('Not Enough Data');
}
} // format_user
diff --git a/lib/class/video.class.php b/lib/class/video.class.php
index 5051fa97..22bafa19 100644
--- a/lib/class/video.class.php
+++ b/lib/class/video.class.php
@@ -91,7 +91,7 @@ class Video extends database_object implements media {
$this->f_codec = $this->video_codec . ' / ' . $this->audio_codec;
$this->f_resolution = $this->resolution_x . 'x' . $this->resolution_y;
$this->f_tags = '';
- $this->f_length = floor($this->time/60) . ' ' . _('minutes');
+ $this->f_length = floor($this->time/60) . ' ' . T_('minutes');
} // format