note 108795 added to function.eval
| From: | wifipc at yahoo dot com | Date: | Fri, 25 May 2012 03:20:18 +0000 |
| Subject: | note 108795 added to function.eval | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-188216@lists.php.net to get a copy of this message | ||
Hi there, guys can you HELP me with this problem?
***Here is my PROBLEM***
It is about the status (1,0) of schoolyear. 1 is on/activate, 0 is off/inactivate.
So in my form i have combo box of school year, and button 'Set Activate', inside the
school year combobox, the option are 1999-2000, 2001-2002, 2003-2004 and the rest of the year.
this is my form(imagine):
Select SY: ((combobox))
Set activate <<--(button)
If im going to choose the 2001-2002 in the combobox, then i will select/click the button 'Set
Activate'. Then in my database tblschoolyear, i have 'schoolid', 'syear1',
'syear2', 'date', 'activestatus'.
this is my tblschoolyear in the database(imagine):
-----------------------------------------------------------
schoolid | syear1|syear2 |date |activestatus
-----------------------------------------------------------
3 |1999 |2000 |2012-05-06 20:13:03 |0
8 |2001 |2002 |2012-05-06 20:13:03 |0
2 |2003 |2004 |2012-05-06 20:13:03 |0
So the column of 2001-2002, the active status is default '0', it will be turn to
'1' because i activate the 2001-2002.
||***it will be like this***||
-----------------------------------------------------------
schoolid | syear1|syear2 |date |activestatus
-----------------------------------------------------------
3 |1999 |2000 |2012-05-06 20:13:03 |0
8 |2001 |2002 |2012-05-06 20:13:03 |1
2 |2003 |2004 |2012-05-06 20:13:03 |0
And then if i select again to activate the school year 2003-2004, in the database 'active
status', will be turn to 1. and 2001-2002, will be 0 again.
||***it will be like this***||
-----------------------------------------------------------
schoolid | syear1|syear2 |date |activestatus
-----------------------------------------------------------
3 |1999 |2000 |2012-05-06 20:13:03 |0
8 |2001 |2002 |2012-05-06 20:13:03 |0
2 |2003 |2004 |2012-05-06 20:13:03 |1
Same thing happen if i will goin to choose again in the school year. Can you please help me with my
problem? thanks so much in advance for the response :) takecare
----
Server IP: 69.147.83.197
Probable Submitter: 121.96.51.66
----
Manual Page -- http://www.php.net/manual/en/function.eval.php
Edit -- https://master.php.net/note/edit/108795
Del: integrated -- https://master.php.net/note/delete/108795/integrated
Del: useless -- https://master.php.net/note/delete/108795/useless
Del: bad code -- https://master.php.net/note/delete/108795/bad+code
Del: spam -- https://master.php.net/note/delete/108795/spam
Del: non-english -- https://master.php.net/note/delete/108795/non-english
Del: in docs -- https://master.php.net/note/delete/108795/in+docs
Del: other reasons-- https://master.php.net/note/delete/108795
Reject -- https://master.php.net/note/reject/108795
Search -- https://master.php.net/manage/user-notes.php