habe den Emotion Mod installiert.
Ich habe dazu mal ne Frage, er funktioniert super, aber beim auswählen stehen da nur die englischen Namen. Für mich nicht weiter das Problem, für andere User aber schon.
Hier ist mal der Code:
Code: Alles auswählen
//
// Pick an emotion
//
function emotion_select($default_emotion, $select_name = "emotion")
{
global $db;
$sql = "SELECT emotion_id, emotion_name
FROM " . EMOTIONS_TABLE . "
ORDER BY emotion_id";
if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, "Couldn't query themes table", "", __LINE__, __FILE__, $sql);
}
$emotion_select = '<select name="' . $select_name . '">';
while ( $row = $db->sql_fetchrow($result) )
{
$selected = ( $row['emotions_id'] == $default_emotion ) ? ' selected="selected"' : '';
$emotion_select .= '<option value="' . $row['emotion_id'] . '"' . $selected . '>' . $row['emotion_name'] . '</option>';
}
$emotion_select .= "</select>";
return $emotion_select;
}
Vielen Dank
~Borderline~