Hello Peeps 🙂
I've had the need to add another option in to one of my drop down boxes, everything seems to work ok, but now when I load a page with the NEW option I've added it does not display the correct DROP DOWN box that was INPUT in the form.
Before I changed it, the code that worked was this, this gave 2 options either PAID or PENDING
$fi[36]!='Received' ? $f36n='selected' : $f36y='selected';
$f[36]='<SELECT NAME="fi[36]"> <option '.$f36y.'>Received</option> <option '.$f36n.'>Pending</option></SELECT>';
I have added a new OPTION of WRITTEN OFF
$fi[36]!='Received' ? $f36n='selected' : $f36y='selected';
$f[36]='<SELECT NAME="fi[36]"> <option '.$f36y.'>Received</option> <option '.$f36w.'>Written Off</option> <option '.$f36n.'>Pending</option></SELECT>';
But when I load the form for any job that has been written off to edit it, the option selected is displayed as 'Pending' so I have to re-select the WRITTEN OFF value every time I go in to the form to edit it.
While this is ok to a point, and I know to do it. Other users in a hurry will probably just hit the 'send' button and the option will be saved as 'pending' thus the job will now be listed as 'pending'
When I edit the form, if the value is WRITTEN OFF, how do I make it put that value in as WRITTEN OFF instead of 'pending'
If the value is PENDING it works OK, if the value is PAID it works OK 🙂
I'm sure I'm missing something simple here! 😕