[Jifty-commit] r3362 - jifty/trunk/plugins/CodePress/lib/Jifty/Plugin

jifty-commit at lists.jifty.org jifty-commit at lists.jifty.org
Tue Jun 5 18:03:05 EDT 2007


Author: dpavlin
Date: Tue Jun  5 18:03:04 2007
New Revision: 3362

Modified:
   jifty/trunk/plugins/CodePress/lib/Jifty/Plugin/CodePress.pm

Log:
simplify example to just view modification

Modified: jifty/trunk/plugins/CodePress/lib/Jifty/Plugin/CodePress.pm
==============================================================================
--- jifty/trunk/plugins/CodePress/lib/Jifty/Plugin/CodePress.pm	(original)
+++ jifty/trunk/plugins/CodePress/lib/Jifty/Plugin/CodePress.pm	Tue Jun  5 18:03:04 2007
@@ -19,17 +19,13 @@
   Plugins:
     - CodePress: {}
 
-In your Model instead of 
-
-  render_as 'teaxterea';
-
-use
-
-  render_as 'Jifty::Plugin::CodePress::Textarea';
-
 In your View do something like:
 
-
+  $action->form_field( 'source',
+	cols => 80, rows => 25,
+	language => 'perl',
+	render_as => 'Jifty::Plugin::CodePress::Textarea',
+  );
 
   Jifty->web->submit( 
 	label   => _("Save"), 
@@ -41,7 +37,12 @@
 
 or if you are using L<Template::Declare>
 
-  render_param( $action => 'source', cols => 80, rows => 25, language => 'perl' );
+  render_param(
+  	$action => 'source',
+	cols => 80, rows => 25,
+	language => 'perl',
+	render_as => 'Jifty::Plugin::CodePress::Textarea',
+  );
 
   form_submit(
 	label => _("Save"),


More information about the Jifty-commit mailing list