// Create constant name
$constantName = sprintf("SURFBAR_URL_STATUS_%s", strtoupper($status));
- // Set default translated status
- $statusTranslated = '!'.$constantName.'!';
-
- // Is the constant there?
- if (defined($constantName)) {
- // Then get it's value
- $statusTranslated = constant($constantName);
- } // END - if
+ // Get message
+ $statusTranslated = getMessage($constantName);
// Return result
return $statusTranslated;
$OUT = ''; $SW = 2;
while ($content = SQL_FETCHARRAY($result)) {
// "Translate" some data
- $content['status'] = constant(sprintf("SURFBAR_URL_STATUS_%s", $content['status']));
- $content['action'] = constant(sprintf("MEMBER_SURFBAR_ACTION_%s_SUBMIT", $content['action']));
+ $content['status'] = translateSurfbarUrlStatus($content['status']);
+ $content['action'] = getMessage(sprintf("MEMBER_SURFBAR_ACTION_%s_SUBMIT", $content['action']));
// New status set?
if (!is_null($content['new_status'])) {
// Translate it
- $content['new_status'] = constant(sprintf("SURFBAR_URL_STATUS_%s", $content['new_status']));
+ $content['new_status'] = translateSurfbarUrlStatus($content['new_status']);
} else {
// "Do nothing" status
- $content['new_status'] = SURFBAR_URL_STATUS_NONE;
+ $content['new_status'] = getMessage('SURFBAR_URL_STATUS_NONE');
}
// Add color
<div align="center">
<form accept-charset="utf-8" action="{?URL?}/modules.php?module=admin&what=add_surfbar_url" method="post">
-<div class="admin_table dashed" style="width:600px;margin-top:10px;">
- <div class="admin_title bottom2" style="padding-top:5px;padding-bottom:5px;">
+<div class="admin_table dashed">
+ <div class="admin_title bottom2">
<strong>URL in Surfbar hinzufügen:</strong>
</div>
- <div class="admin_input" style="padding-top:5px;padding-bottom:5px;" align="center">
+ <div class="admin_input" align="center">
URL eingeben: <input type="text" name="url" size="20" maxlength="255" value="http://" />
</div>
- <div class="admin_input" style="padding-top:5px;padding-bottom:5px;" align="center">
+ <div class="admin_input" align="center">
Maximale Einblendung: <input type="text" name="limit" size="5" maxlength="20" value="0" /><br />
<span class="admin_note">(0 = Unbegrenzt)</span>
</div>
- <div class="admin_input" style="padding-top:5px;padding-bottom:5px;" align="center">
+ <div class="admin_input" align="center">
Reloadsperre: $content[reload]
<span class="admin_note">(0 = Standarteinstellungen)</span>
</div>
- <div align="center" class="footer top2" style="padding-top:3px;padding-bottom:3px;">
+ <div align="center" class="admin_footer top2">
<input type="reset" class="admin_reset" value="{--CLEAR_FORM--}" />
<input type="submit" class="admin_submit" name="add" value="{--ADMIN_SURFBAR_ADD_URL--}" />
</div>