![]() |
greggk author 10/29/2009 |
After reading some more on the forums I have tried two other options, both which failed. |
J
|
Jane 10/30/2009 |
Hi, <script>
|
![]() |
greggk author 10/30/2009 |
Thanks, I didn't think of doing it via javascript. That should be possible, I did do some additions before via javascript and they worked fine. However, was there anything wrong with my php code? Why it wouldn't work? |
![]() |
greggk author 10/30/2009 |
I got it to work. |
![]() |
greggk author 10/30/2009 |
Ok, I've answered a few of my own questions today, however could someone tell me why this one is not working? |
M
|
meirco 10/30/2009 |
Ok, I've answered a few of my own questions today, however could someone tell me why this one is not working? if (empty($values["receivedDate"])) { if ($values["receivedCK"] > 0) { $values["receivedDate"] = now(); } } I think I got the php code correct. It is supposed to check if the receivedDate is empty or not, and if it's empty, then it will add the current date, if it's not empty, it should leave it alone, but it's not leaving it alone. Every time it's edited, it's putting the new date in. I can't figure out why.
|
![]() |
greggk author 10/31/2009 |
I'm putting the code in the Edit events before record updated. |
J
|
Jane 11/2/2009 |
It's difficult to tell you what's happening without seeing actual files. |
![]() |
greggk author 11/2/2009 |
I did post the program and opened up a ticket, but I may have figured something out. |
J
|
Jane 11/3/2009 |
Hi, if ($oldvalues["receivedDate"] < 1) |
![]() |
greggk author 11/4/2009 |
Hi, readonly values are stored in the $oldvalues array only: if ($oldvalues["receivedDate"] < 1)
|