.
*/
/**
* This is an example user_config.php file
* It shows you how to translate the application in your own language
* (here it's french)
*/
if (!class_exists('fotooManager'))
die('Just config');
/**
* User configuration
* You can set those constants to what you need
* Let them commented to get the defaults
*/
//define('BASE_DIR', dirname(__FILE__));
//define('CACHE_DIR', BASE_DIR . '/cache');
//define('BASE_URL', 'http://myserver.tld/pics/');
//define('SELF_URL', BASE_URL . 'gallery.php');
// Gallery title, change it to what you prefer
define('GALLERY_TITLE', 'My own photo gallery');
// Allow embedding of your pictures ?
define('ALLOW_EMBED', true);
// Generate a resized copy of images for small view (600x600), disabled by default
// WARNING GENERATING IMAGES IS REALLY SLOW AND IT MAY KILL YOU WEBSERVER!
// Generate all small images in directory update process (slow)
//define('GEN_SMALL', 1);
// Generate small image when an image is viewed (less slow)
define('GEN_SMALL', 2);
// If an image width or height is superior to this number, the gallery
// will not try to resize it
define('MAX_IMAGE_SIZE', 2048);
// Shortcut tags in album and pictures comments
// eg. if you type wp:Belgium in your comment tag, it will make a link to wikipedia
// You can add anything you want
$f->html_tags = array(
'wp:fr' => 'http://fr.wikipedia.org/wiki/KEYWORD',
'wp' => 'http://en.wikipedia.org/wiki/KEYWORD',
);
// Activation of custom-URLs (if you use RewriteRules for example)
function get_custom_url($type, $data = null)
{
if ($type == 'image')
{
return BASE_URL . 'image/' . $data;
}
elseif ($type == 'album')
{
return BASE_URL . 'album/' . $data;
}
elseif ($type == 'embed' || $type == 'slideshow')
{
return BASE_URL . $type . '/' . $data;
}
elseif ($type == 'embed_tag')
{
return BASE_URL . 'tag/embed/' . $data;
}
elseif ($type == 'slideshow_tag')
{
return BASE_URL . 'tag/slideshow/' . $data;
}
elseif ($type == 'embed_img')
{
return BASE_URL . 'r/' . $data;
}
elseif ($type == 'tag')
{
return BASE_URL . 'tag/' . $data;
}
elseif ($type == 'date')
{
return BASE_URL . 'date/' . $data;
}
elseif ($type == 'tags' || $type == 'timeline' || $type == 'feed')
{
return BASE_URL . $type;
}
}
// Strings translation
$french_strings = array(
'Pictures for %A %d %B %Y'
=> 'Photos prises le %A %d %B %Y',
'Pictures for %B %Y'
=> 'Photos prises en %B %Y',
'Pictures for %Y'
=> 'Photos prises en %Y',
'Pictures by date'
=> 'Photos par date',
'Pictures by tag'
=> 'Photos par mot-clé',
'Pictures in tag %TAG'
=> 'Photos pour le mot-clé %TAG',
'My Pictures'
=> 'Mes photos',
'By date'
=> 'Par date',
'By tags'
=> 'Par mot-clé',
'%B'
=> '%B',
'%A %d'
=> '%A %d',
'(%NB more pictures)'
=> '(%NB photos de plus)',
'Tags'
=> 'Mots-clés',
"Other tags related to '%TAG':"
=> "Autres mots-clés en rapport avec '%TAG' :",
'Download image at original size (%W x %H) - %SIZE KB'
=> "Télécharger l'image au format original (%W x %H) - %SIZE Ko",
'Comment:'
=> 'Commentaire :',
'Tags:'
=> 'Mots-clés :',
'Date:'
=> 'Date :',
'Embed:'
=> 'Intégrer dans un site :',
'Embed as image:'
=> 'Intégrer en image seule :',
'%A %d %B %Y at %H:%M'
=> '%A %d %B %Y à %H:%M',
'Updating database, please wait, more pictures will appear in a while...'
=> "Mise à jour de la base de données. "
. "Patientez, dans quelques instants d'autres images apparaîtront.",
'Updating'
=> 'Mise à jour',
'Update done.'
=> 'Mise à jour terminée.',
'Picture not found'
=> 'Photo non trouvée',
'Back to homepage'
=> "Retour à la page d'accueil",
'No picture found.'
=> "Aucune image n'a été trouvée.",
'No tag found.'
=> "Aucun mot-clé n'a été trouvé.",
'Previous'
=> "Photo précédente",
'Next'
=> "Photo suivante",
'Slideshow'
=> 'Diaporama',
'Pause'
=> 'Mettre en pause',
'Restart'
=> 'Reprendre',
'Back'
=> 'Retour',
'Photo details'
=> 'Détails de la photo',
'Camera maker:'
=> 'Fabricant de l\'appareil :',
'Camera model:'
=> 'Modèle de l\'appareil :',
'Exposure:'
=> 'Exposition :',
'Aperture:'
=> 'Ouverture :',
'ISO speed:'
=> 'Sensibilité ISO :',
'Flash:'
=> 'Flash :',
'On'
=> 'Activé',
'Off'
=> 'Désactivé',
'Focal length:'
=> 'Longueur focale :',
'Original resolution:'
=> 'Résolution originale :',
'%EXPOSURE seconds'
=> '%EXPOSURE secondes',
);
// Days of the week translations
$french_days = array(
'Monday' => 'lundi',
'Tuesday' => 'mardi',
'Wednesday' => 'mercredi',
'Thursday' => 'jeudi',
'Friday' => 'vendredi',
'Saturday' => 'samedi',
'Sunday' => 'dimanche',
);
// Months of the year translations
$french_months = array(
'January' => 'janvier',
'February' => 'février',
'March' => 'mars',
'April' => 'avril',
'May' => 'mai',
'June' => 'juin',
'July' => 'juillet',
'August' => 'août',
'September' => 'septembre',
'October' => 'octobre',
'November' => 'novembre',
'December' => 'décembre',
);
function __($str, $mode=false, $datas=false)
{
global $french_strings, $french_days, $french_months;
if (isset($french_strings[$str]))
$tr = $french_strings[$str];
else
$tr = $str;
if ($mode == 'TIME')
{
$tr = strftime($tr, $datas);
$tr = strtr($tr, $french_days);
$tr = strtr($tr, $french_months);
}
elseif ($mode == 'REPLACE')
{
foreach ($datas as $key => $value)
{
if (is_float($value))
$value = str_replace('.', ',', (string)$value);
$tr = str_replace($key, $value, $tr);
}
}
return $tr;
}
?>