4images Forum & Community
4images Issues / Ausgaben => Installation, Update & Configuration => Topic started by: TIMT on May 08, 2006, 10:38:08 PM
-
Hi everybody
I have implemented the following code in memper_uploadform.html:
<td class="row1">
<select class="input name="image_medium" size="1">
<option value="Digitalaufnahme">unbekannt</option>
<option value="Digitalaufnahme">Digitalaufnahme</option>
<option value="Dia Kleinbild">Dia Kleinbild</option>
<option value="Dia Mittelformat">Dia Mittelformat</option>
<option value="Dia Grossformat">Dia Grossformat</option>
<option value="Negativ Kleinbild">Negativ Kleinbild</option>
<option value="Negativ Mittelformat">Negativ Mittelformat</option>
<option value="Negativ Grossformat">Negativ Grossformat</option>
</select>
I have implemented the following Code in db_field_definition.php
$additional_image_fields['image_medium'] = array($lang['image_medium'], "text", 0);
I created the filed image_medium in the table 4images_images and 4images_images_temp
Unfortunately the value entered by Dropdownlist is not be stored in the database.
So what did I wrong???
Thanks for helping me.
TIMT
-
What type is your new field? It should be either VARCHAR(XX) or TEXT
P.S. make sure you added the line in db_field_definitions.php not inside the comment ;)
-
when I replace the following code
<tr>
<td class="row1"><b>Originalmedium</b></td>
<td class="row1">
<select class="input name="image_medium" size="1">
<option value="Digitalaufnahme">unbekannt</option>
<option value="Digitalaufnahme">Digitalaufnahme</option>
<option value="Dia Kleinbild">Dia Kleinbild</option>
<option value="Dia Mittelformat">Dia Mittelformat</option>
<option value="Dia Grossformat">Dia Grossformat</option>
<option value="Negativ Kleinbild">Negativ Kleinbild</option>
<option value="Negativ Mittelformat">Negativ Mittelformat</option>
<option value="Negativ Grossformat">Negativ Grossformat</option>
</select>
</td>
</tr>
with this code:
<input type="text" name="image_medium" size="4" value="{image_medium}" class="inputjahr" />
it works. The value entered in the new field is stored in the database.
But I'd like this dropdownlist above. Something is wrong with the dropdownlist. Where in the dropdownlist is the field in the database defined? Ist that name=?
-
you are missing a quote:[qcode] <select class="input" name="image_medium" size="1">
[/qcode]
-
Thank you!!!! :D :oops:
-
Hi,
wie kann ich in ein Dropdown-Menü Text eingeben, welcher aber nicht gewählt werden kann? (als Überschriften um da eine gewisse Struktur reinzubekommen)
thx Achim
-
Look at this example here to "organise" your dropdown box
A group can be made with the help of the <optgroup> tag
<select name="subject">
<optgroup label="First Group">
<option>Option 1</option>
<option>Option 2</option>
<option>Option 3</option>
</optgroup>
<option disabled="disabled" value="">This is an option tag which can`t be selected</option>
<optgroup label="Another Group">
<option>Option 1</option>
<option>Option 2</option>
<option>Option 3</option>
</optgroup>
<option>this is just an normal option tag</option>
</select>
-
Perfekt, genau das habe ich gesucht!!! Viele Dank - Thank you :D