![]() |
|
#1
|
|||
|
|||
time Problemhi,
how i can get time which i selected from bis field on von field on the very next time when i clcik on save button for eg Von Bis 12:20 23:40 u can see from the url which i already posted if u clearly notice this link u will see the new line VOn showing time 13:03 instead of 23:40 as i used echo (date('H:i')) thats why im getting always system time thats why i asked any modification in php so that i can ge something like Von Bis 15:03 15 :03//new field user get once clcik on Save button 15:02 15:07 //this time may be from select or click on '>' button which acts as clock how to get 15:07 Bis time in Von field in new field once form submitted please modify the code as im newbie to PHP still any problem to understood server2.vitodesign.com or any other way of script will welcome if anybody sort out this problem will be appreciable thanks |
|
#2
|
|||
|
|||
|
Okay, lemme get this straight.
You want the value of "bis" to be the default selected value of "von" once submitted? If so, I've done very little. In your fillDD() function, you don't make use of the selected bit. So I changed it to accept time in 12:30 format, and then when if loops, if 12:30 comes up, it will be set as default. See attachment. I've not got PHP access at the mo, so you'll have to check my syntax. My changes are marked with ###. GF |
|
#3
|
|||
|
|||
|
awesome excellent,no doubt about it.........
is it possible that when user login first time he will get system time in von field as i seen u removed <option value="<?=date('H:i')?>"><? echo (date('H:i')); ?></option> from von field thats when i login i always see 0:00 in von field is it possible to get system but when i use this date('H:i') then same problem exists or is it possible to allow user to fill von time when he logins for first time anyway its appreciable thanks |
|
#4
|
|||
|
|||
|
Oh, yes.
Just replace that bit with an if statement checking if $von is set or not. So something like: PHP Code:
Presumably, when a user logs in first, the variable $HTTP_POST_VARS['bis'] certainly won't be set. So just check if it (or simply $bis) is set of not. You're welcome! Garth Farley |
|
#5
|
|||
|
|||
|
thanks for your feedback but still its not workign may be i misunderstood ur post i tried like this
<td nowrap align="center"> <select name="von"> <?if( isset($bis) ){//where shall i put this piece of code echo $bis; }else{ echo (date('H:i')); } ?> <? fillDD(0, 0, $bis); ?> </select> </td> thanks in advance |
|
#6
|
|||
|
|||
|
Almost there:
PHP Code:
See if that works GF |
|
#7
|
|||
|
|||
|
sorry unfortunately still its not working only change is instead of 0:00 now im getting system time i can give you the result im getting in form
first time i login i get time in von and bis field 10:30 10:30 //now i changed this into 10:55 so as new line on top of these time 10:55 11:00//upto this it works fine but when i close the browser and login as second time i get von time as system time instead of 11:00 in bis field hope it will be clear for u the result in form show like this when i login second time in same date,for more clear server2.vitodesign.com sys time 10:45 instead of systime it must be 11:00 10:55 11:00 10:30 10:55 thanks for understanding |
|
#8
|
|||
|
|||
|
Yup, you would like the "von" time to persist when you log out & in again.
If you look at the code, you see that $bis - what is set to be $von once submitted - is got from $HTTP_POST_VARS['bis']. When you log out, this value disappears, so it defaults back to system time. So the question is, how to get this value remembered? The best way, I think, would be to look at the information in the database. See which value of "bis" for today is greatest, and set it as the von in the form. BTW, your script isn't working at the mo. Insertion failed. GF |
|
#9
|
|||
|
|||
|
sorry once again i found one bug hope you will help me out
when i use this button <input type="button" name="now" size="1" value=">" onclick="insertTime();calculateIst()"> it will give me system time and it will show in bis field then i m not able to get this value in von field in new line 0:00 13:23 13:00 13:28 //initally it was 13:25 when i clcik on now buton then it display sysem time in bis field but in new line its not showing 13:28 13:28 13:23 another thing bis field time always show 5 min less than system due to $mins -= ($mins % 5); is it necessary to do that //this field is diff. between bis and von time <input size="1" type="text" value="00:00" name="ist" readonly></td>//i hadcoded value as 00:00 how i can get the actual change this field shows diff only when i change bis field onchange="calculateIst()" if possible just visit the link server2.vitodesign.com |
|
#10
|
|||
|
|||
|
hi,
sorry again for trouble still im getting trouble with time fields for von and bis 2 time fields 1. then i select time from BIS field and click on save then i get bis time in VON field its fine but when i click clock image on bis field to get system and click on save then i,m getting 0:00 i dont no why actually i already discussed this topic and i also get feedback but unfortunately my brain didnt digest this one----that when i chaneg time it works fine but what happen when PHP Code:
2.whn i login second time i m not getting the bis time in von time last entered for eg. Von Bis 13:21 14:30 // this si fine 13:20 13:21 but when i login im getting system time in Von field instead of 14:30 in Von field in same date i check in database but it only inserts and then select from database PHP Code:
please bear with this code as im new bie in this session kind of things anyone modify this code will really be appreciated or need full code i will send ,hope it is clear sorry for ur inconvenience thanks in advance arun |
Recent GIDBlog
NARMY by crystalattice
| Thread Tools | Search this Thread |
| Rate This Thread | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| problem with php5 cgi installation | fab13 | Apache Web Server Forum | 3 | 19-Nov-2003 09:11 |
| Display Size and maybe download time | BobbyDouglas | MySQL / PHP Forum | 5 | 08-Nov-2003 00:18 |
| Time Problem in Program | MrSmiley | C Programming Language | 1 | 03-Nov-2003 12:00 |
| unwanted scrollbar problem | kelly001 | Web Design Forum | 3 | 24-Oct-2003 10:44 |
| ambiguity in time field | zuzupus | MySQL / PHP Forum | 9 | 28-Jul-2003 08:40 |
Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The