May 5, 200421 yr I want to be able to edit each record's status (active or inactive) from a found list. What happens is if I find more than 1 record (say I do a search on last name "Smith") then the bottom record is always edited regardless of which one I choose. I've looked at this and can't see where the problem lies. Any suggestions? <FORM name="f" METHOD="POST" ACTION="FMPro"> <INPUT TYPE="hidden" NAME="-db" VALUE="Student.fp5"> <INPUT TYPE="hidden" NAME="-lay" VALUE="StudentMain"> <INPUT TYPE="hidden" NAME="-format" VALUE="UpdateComplete.html"> <INPUT TYPE="hidden" NAME="-error" VALUE="Error.html"> <Table><TR> [FMP-Record] <td>[FMP-Field: L_name]</td> <td>[FMP-Field: F_name]</td> <td>[FMP-Field: SSN]</td> <td>[FMP-Field: Status]</td> <td><input type="hidden" name="-RecID" value="[FMP-CurrentRecID]"> <input type="radio" name="Status" value="Active" >Active <input type="radio" name="Status" value="Inactive">Inactive <input type="submit" name="-edit" value="Submit Edit"></td> </tr> [/FMP-Record] </table> </FORM>
May 6, 200421 yr Author Thanks Garry. Really don't want to edit multiple ones, just want to edit the one I choose from the list: Name Status Edit Status (radio buttons) Jo Smith Active Active Inactive Click here to Change (this is a button) Al Smith Inactive Active Inactive Click here to Change Su Smith Active Active Inactive Click here to Change Does that make sense?
May 6, 200421 yr You need to put the input buttons into a FMP-IF statement Here is an example I used which is on a record edit page (using Recid=CurrentRecID) <input type="radio" name="publish" value="yes"[fmp-if:publish.eq.yes]checked[/fmp-if]> Publish my lesson </font></p> <p><font size="2"> <input name="publish" type="radio" value="no" [fmp-if:publish.eq.no]checked[/fmp-if]> Not Ready for Publishing <br>
May 10, 200421 yr Try this: <FORM name="f" METHOD="POST" ACTION="FMPro"> <INPUT TYPE="hidden" NAME="-db" VALUE="Student.fp5"> <INPUT TYPE="hidden" NAME="-lay" VALUE="StudentMain"> <INPUT TYPE="hidden" NAME="-format" VALUE="UpdateComplete.html"> <INPUT TYPE="hidden" NAME="-error" VALUE="Error.html"> <input type="hidden" name="-RecID" value=""> <input type="hidden" name="-edit" value=""> <Table><TR> [FMP-Record] <td>[FMP-Field: L_name]</td> <td>[FMP-Field: F_name]</td> <td>[FMP-Field: SSN]</td> <td>[FMP-Field: Status]</td> <td> <input type="radio" name="Status" value="Active" >Active <input type="radio" name="Status" value="Inactive">Inactive <a href="#" onclick="document.f.elements['-RecID'].value='[FMP-CurrentRecID]';document.f.submit();">Click here to Change</a> </td> </tr> [/FMP-Record] </table> </FORM> This is the basis for submitting the change. However, the "Status" field and the method for using Radio Buttons need to be dealt with yet. (This leads to what theBloke has written.) Good Luck. Garry
Create an account or sign in to comment