This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

Themabewertung:
  • 0 Bewertung(en) - 0 im Durchschnitt
  • 1
  • 2
  • 3
  • 4
  • 5
Uhrzeit addieren
#1
Hallo liebe Mitglieder,

ich benötige hier mal Hilfe.

Zur Zeit sieht es so aus:
<label for="pickup_from" class="ffs_red">Ihre Abholzeit zwischen</label><br />
	<select type="time" id="pickup_from" name="pickup_from"	class="ffs_time">
		<option name="pickup_from" class="ffs_opt-b" selected="selected">--:--</option>
		<option name="pickup_from" class="ffs_opt-b">10:00</option>
		<option name="pickup_from" class="ffs_opt-b">11:00</option>
		<option name="pickup_from" class="ffs_opt-b">12:00</option>
		<option name="pickup_from" class="ffs_opt-b">13:00</option>
		<option name="pickup_from" class="ffs_opt-b">14:00</option>
		<option name="pickup_from" class="ffs_opt-b">15:00</option>
		<option name="pickup_from" class="ffs_opt-b">16:00</option>
	</select>
	<label for="pickup_to" class="ffs_red">und</label>
	<select type="time" id="pickup_to" name="pickup_to"	class="ffs_time">
		<option name="pickup_to" class="ffs_opt-b" selected="selected">--:--</option>
		<option name="pickup_to" class="ffs_opt-b">11:00</option>
		<option name="pickup_to" class="ffs_opt-b">12:00</option>
		<option name="pickup_to" class="ffs_opt-b">13:00</option>
		<option name="pickup_to" class="ffs_opt-b">14:00</option>
		<option name="pickup_to" class="ffs_opt-b">15:00</option>
		<option name="pickup_to" class="ffs_opt-b">16:00</option>
		<option name="pickup_to" class="ffs_opt-b">17:00</option>
	</select>

Nun möchte ich gern den Bereich select "pickup_to" geändert haben in:
<input type="text" id="pickup_to" name="pickup_to" class="ffs_date" (Ausgabe: pickup_from + 1 Stunde)

Grund: Die Auswahl der Uhrzeit soll damit auf 1 Stunde beschränkt werden.
Javascript ist nicht mein Steckenpferd, ihr habt sicher eine einfache Idee.

Lieben Dank Mario
Zitieren
#2
Du meinst es so .
Wenn im ersten Feld 11 Uhr ausgewählt wurde,  darf im zweiten Feld nur noch 12 uhr stehen ?
Immer eine Stunde mehr ?
Da würde ich nicht rum rechnen

Als Lösung markieren Zitieren


Gehe zu:


Benutzer, die gerade dieses Thema anschauen: 1 Gast/Gäste