[Catalyst-commits] r12135 -
trunk/examples/CatalystAdvent/root/2009/pen
alexn_org at dev.catalyst.perl.org
alexn_org at dev.catalyst.perl.org
Tue Dec 1 21:33:40 GMT 2009
Author: alexn_org
Date: 2009-12-01 21:33:39 +0000 (Tue, 01 Dec 2009)
New Revision: 12135
Modified:
trunk/examples/CatalystAdvent/root/2009/pen/formhandler.pod
Log:
removed css / modified form rendering
Modified: trunk/examples/CatalystAdvent/root/2009/pen/formhandler.pod
===================================================================
--- trunk/examples/CatalystAdvent/root/2009/pen/formhandler.pod 2009-12-01 21:31:04 UTC (rev 12134)
+++ trunk/examples/CatalystAdvent/root/2009/pen/formhandler.pod 2009-12-01 21:33:39 UTC (rev 12135)
@@ -275,46 +275,11 @@
[% IF item.article_id %]Editing "[% item.title %]"
[% ELSE %]Adding a new article[% END %]
</h1>
-
- [% form.render_start %]
-
- [% form.render_field('title') %]
- [% form.render_field('ts') %]
- [% form.render_field('content') %]
- [% form.render_field('tags') %]
-
- <div class="submit"><input type="submit" value="Save" /></div>
- [% form.render_end %]
- <style type="text/css">
- form fieldset {
- width: 450px;
- }
- form label {
- float: left;
- display: block;
- width: 150px;
- }
- form input, form textarea {
- width: 300px;
- }
- form #tags {
- height: 50px;
- }
- form .error_message {
- margin-left: 100px;
- color: red;
- font-style: italic;
- }
- form .submit {
- margin-top: 10px;
- text-align: right;
- }
- form .submit input {
- width: 100px;
- }
- </style>
+ [% IF info_msg %]<div class="info_msg">[% info_msg %]</div>[% END %]
+ [% form.render %]
+
OK, so we now have a form with automatic validation ...
=over
More information about the Catalyst-commits
mailing list