21.12.2022 Views

python_para_desenvolvedores_2ed

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

MVC 191

</py-for>

</table>

<br />

<input type="submit" value=" salvar " />

</form>

<br />

[ <a href="/">voltar</a> ]

<py-include="footer.html">

Modelo “mod.html” (página de formulário para alteração de registros):

<py-include="header.html">

<form

action="/?op=mod&ident=<py-eval="unicode(res['id'])">"

method="post">

<table border="0">

<py-for="coluna in colunas">

<tr><th>

<py-eval="coluna">

</th><td>

<input type="text" size="30" name="<py-eval="coluna">"

value="<py-eval="unicode(res[coluna])">" />

</td></tr>

</py-for>

</table>

<br />

<input type="submit" value=" salvar " />

</form>

<br />

[ <a href="/">voltar</a> ]

<py-include="footer.html">

Modelo “rem.html” (página que pede confirmação para remoção de

registros):

<py-include="header.html">

<table border="1">

<tr>

<py-for="coluna in colunas">

<th><py-eval="coluna"></th>

</py-for>

</tr>

<tr>

<py-for="coluna in colunas">

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!