At the time of modification and in PHP, the same as the change, it is necessary to pass the list page ID to be able to implement the modification, as follows:
It then reads all the information about the ID at the same time as the backend receives his pass-through ID:
Then we begin to write the post processing data problem, as follows:
<%include header.html%><Divclass= "wrapper Row-offcanvas row-offcanvas-left"> <!--Left side column contains the logo and sidebar - <%include Left. html%> <!--Right side column. Contains the NavBar and content of the page - <asideclass= "Right-side"> <!--Content Header (Page header) - < Sectionclass= "Content-header"> <H1>category Edit<Small>Classification</Small> </H1> <olclass= "breadcrumb"> <Li><ahref= "Index.html"><Iclass= "fa Fa-dashboard"></I>Management Center</a></Li> <Liclass= "category_list.html"><ahref= "Index.html">Classification</a></Li> <Liclass= "Active">Category Edit</Li> </ol> </ Section> <!--Main Content - < Sectionclass= "Content"> <Divclass= "Row"> <Divclass= "Col-md-12"> <Divclass= "box"> <formAction= "/admin/category/edit"Method= "POST"> <Divclass= "Box-header"> <H3class= "Box-title"></H3> <ahref= "/admin/category/"class= "btn btn-default pull-right">Category List</a> </Div><!--/.box-header - <Divclass= "Box-body"> <Divclass= "Form-group"> <label for= "InputTitle">Category headings</label> <inputtype= "title"placeholder= "title"ID= "InputTitle"name= "title"value= "<%= data.title%>"class= "Form-control"> </Div> <Divclass= "Form-group"> <label for= "Inputordernumber">Sort</label> <inputtype= "title"placeholder= "Sort"ID= "Inputordernumber"name= "Sort"value= "<%= data.sort%>"class= "Form-control"> </Div> <inputtype= "hidden"name= "id"value= "<%= data._id%>"> </Div><!--/.box-body - <Divclass= "Box-footer clearfix"> <Buttonclass= "Btn btn-primary"type= "Submit">Submit</Button> </Div><!--/.box-footer - </form> </Div><!--/.box - </Div><!--/.col - </Div><!--/.row - </ Section><!--/.content - <%include footer.html%>
And the modification is also by two can be completed, here in fact, and PHP is the same, the first to receive the ID, and then the edit page to traverse the ID data, and then is modified,
Kill lui lei Dog---node. js---22 project construction in Node+express+mongo Blog Item 7 data modification