SV: [Catalyst] CC::FormBuilder woes - I don't get it
Hi, I had the same problem a few months ago and was advised to change the stash_name from the default. So I have the following: __PACKAGE__-config( name ='YourApplicationName', 'Controller::FormBuilder' = { method_name = 'form', attr_name = 'Form', obj_name = 'form', stash_name = 'fb', } . }; Then in the template: [% fb.field.fieldname.field %] I haven't figured out why I had to change this name but try. Regards Peter Sørensen/University of Southern Denmark/mail: [EMAIL PROTECTED] -Oprindelig meddelelse- Fra: Piet Ruyssinck [mailto:[EMAIL PROTECTED] Sendt: 12. april 2008 21:30 Til: catalyst@lists.scsys.co.uk Emne: [Catalyst] CC::FormBuilder woes - I don't get it My problem with FormBuilder and Template Toolkit : [% form.render %] works [% FOREACH f IN form.fields %] [% f.label %] [% f.field %] [% END %] works y. [% form.field.fieldname.field %] does not work The same problem was signaled a year ago under de subject CC::Formbuilder woes. A solution was posted : Actually, it _was_ a stash issue, but all down to my misuse of it! Once I used the correct term for it (default = formbuilder), or over-rode it with the Controller::FormBuilder config entry stash_name = something_else, it worked fine. Thanks for the pointer. My problem : I just don't get it. the default for stash_name is formbuilder. Does this mean that [% formbuilder.field.fieldname.field %] ought to work ? It doesn't. Or else, what should I override it with ? with 'form' ? No luck either. Maybe someone more knowledgeable than me might be able to help me. -- Piet Ruyssinck ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/ ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
RE: [Catalyst] Problem storing session data
Thanks for the suggestion. I tried but this does not solve my problem. I'm a little uncertain on where to set theese values. I've done this: _PACKAGE__-config-{session = { storage = '/tmp/session'.$$, cache_size = '10m', page_size = '256k', expires = 3600 }; I can see that I get a /tmp/session- file when starting. Still I also have the default /tmp/share--xx file so which is used? Somehow the problem is that the session is'nt restored. If the output I save is fairly small debug shows: [debug] Found sessionid c23. in cookie [debug] Restored session c23. If output is to big the sessionid suddenly does'nt get restored. Debug shows: [debug] Found sessionid c23. in cookie but the Restore is missing. I don't know where to look for a solution to this problem. Any hints? Regards Peter -Oprindelig meddelelse- Fra: Bill Moseley [mailto:[EMAIL PROTECTED] Sendt: 31. marts 2008 16:04 Til: The elegant MVC web framework Emne: Re: [Catalyst] Problem storing session data On Mon, Mar 31, 2008 at 09:07:02AM +0200, Peter Sørensen wrote: use Catalyst qw/-Debug ConfigLoader Static::Simple Session Session::State::Cookie Session::Store::FastMmap FastMmap::Cache/; I don't think that specifying C::P::FastMmap::Cache is required any more as Cache::FastMmap was updated to work with Catalyst. This is working when output is fairly small but if I use a bigger TimeFrame and generate a far bigger output table it fails. I have tried to increase the cache_size like: __PACKAGE__-config-{session = { cache_size = '10m', This changes nothing. So now my question: I think you want to increase page_size. http://search.cpan.org/~robm/Cache-FastMmap-1.25/FastMmap.pm#PAGE_SIZE_AND_KEY/VALUE_LIMITS One consequence of this is that you cannot store values larger than a page in the cache at all. Attempting to store values larger than a page size will fail (the set() function will return false). -- Bill Moseley [EMAIL PROTECTED] ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/ ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
[Catalyst] Problem storing session data
Hi, I use session to store output between calls and have some serious problem with this. I still fairly new to Catalyst. I have the following defined use Catalyst qw/-Debug ConfigLoader Static::Simple Session Session::State::Cookie Session::Store::FastMmap FastMmap::Cache/; I store output from an array in one controller method like: ( I have a module which returns a ref to an array with output ) my $search = new SearchLog( SearchInfo = $searchInfo, SearchPath = ' some path', TimeFrame = { timefrom = , $timeto = } }; $tableout = $search-processRegex(...) In short it takes a generated Regex and use this to extract information from the logfile. This operation is time consuming and I want to save the output generated. $c-session-{tableout} = $tableout; and restore this in another controller method like: $tableout = $c-session-{tableout}; This is working when output is fairly small but if I use a bigger TimeFrame and generate a far bigger output table it fails. I have tried to increase the cache_size like: __PACKAGE__-config-{session = { storage = '/tmp/session'.$$, cache_size = '10m', expires = 3600 } }; This changes nothing. So now my question: I this the right way to store internmediate output or should I use a different approach? If right - does anyone know why I have this problem? Regards and thanks Peter Sorensen/University of Southern Denmark/mail: [EMAIL PROTECTED] Med venlig hilsen Peter Sørensen Vid.medarb., IT-service Tlf.6550 2858 Fax 6550 2860 Email [EMAIL PROTECTED] Web http://intern.sdu.dk/it-service/ansatte/ps-238/ Adr.Campusvej 55, 5230 Odense M SYDDANSK UNIVERSITET ___ Campusvej 55 * 5230 * Odense M * Tlf. 6550 1000 * www.sdu.dk ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
[Catalyst] Create tables on the fly using DBIC
Hi, Using Catalyst, DBIC and TT. I need to create tables on the fly depending on the input I get. Need them to save data for further processing. It this possible with DBIC or do I need any additional extensions? Regards Peter Sorensen/University of Southern Denmark/mail: [EMAIL PROTECTED] ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
[Catalyst] File-browser functionality
Hi, I'm using catalyst and TT to develop a system, where it is possible to search in system logfiles based on predefined regex. I need a way to BROWSE on the server filesystem. I can use the directory plugin in TT but before trying this I would ask if any other solutions are around. Regards Peter Sorensen/University of Southern Denmark/mail: [EMAIL PROTECTED] ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
RE: [Catalyst] Dumb questionagain: nowCatalyst::Controller::FormBuilder
what I meant was: name: location_edit method: post title: Location fields: CHANHE HERE --- locationname: insteadof name name: Location name type: text size: 60 required: 1 descr: name: Location description type: textarea rows: 4 cols: 60 Regards Peter ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
RE: [Catalyst] Dumb question again: nowCatalyst::Controller::FormBuilder
Maybe FormBuilder don't like: .. fields: name: name: Location name .. You use name as both field and object name. Just a guess. Regards Peter Sorensen/University of Southern Denmark/mail: [EMAIL PROTECTED] -Oprindelig meddelelse- Fra: Alex Povolotsky [mailto:[EMAIL PROTECTED] Sendt: 24. februar 2008 00:25 Til: The elegant MVC web framework Emne: [Catalyst] Dumb question again: nowCatalyst::Controller::FormBuilder [info] *** Request 1 (1.000/s) [43248] [Sun Feb 24 02:05:17 2008] *** [debug] GET request for location/add from 89.222.147.9 [debug] Path is location/add [debug] Form (location/edit): Looking for config file location/edit.fb [debug] Form (location/edit): Found form config /usr/local/traffic/Traffic2/root/forms/location/edit.fb [error] Caught exception in Traffic2::C::Location-add Can't use string (location_edit) as a HASH ref while strict refs in use at /usr/local/lib/perl5/site_perl/5.8.8/CGI/FormBuilder/Source/File.pm line 150. [info] Request took 0.014863s (67.281/s) CGI::FormBulder, running on that file, yields no error File is simple name: location_edit method: post title: Location fields: name: name: Location name type: text size: 60 required: 1 descr: name: Location description type: textarea rows: 4 cols: 60 What has I done wrong?... Alex. ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/ ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
RE: [Catalyst] Doing work inside the DBIx::Class model
He meant result_source: http://cpan.uwinnipeg.ca/htdocs/DBIx-Class/DBIx/Class/ResultSet.html#result_source But this is not all and it is something that begs for a FAQ entry - I always forget how to do it. The important thing is how to add new methods to the ResultSet: package ArchivedBooks; use base qw/DBIx::Class/; __PACKAGE__-table('books_archive'); __PACKAGE__-source_name('Books'); __PACKAGE__-resultset_class('ArchivedBooks::ResultSet'); package ArchivedBooks::ResultSet; use strict; use warnings; use base qw( DBIx::Class::ResultSet ); sub advanced_search { my ( $self, $params, $attrs ) = @_; $self now is a ResultSet - so you can use methods on it. .. I have a similar problem want - to add some custom methods to the model. I've read your references but still - I can't get this thing to work. I have generated the model using Catalyst and get the following layout: LogParser.pm LogParser | |Components.pm |Connectinfo.pm |Logtype.pm and if I take a look into Components it looks like: package LogParser::Schema::LogParserDB::Components; use strict; use warnings; use base 'DBIx::Class'; __PACKAGE__-load_components(Core); __PACKAGE__-table(components); __PACKAGE__-add_columns( id, { data_type = INT, default_value = undef, is_nullable = 0, size = 11 }, component, { data_type = VARCHAR, default_value = , is_nullable = 0, size = 32 }, regex, { data_type = TEXT, default_value = , is_nullable = 0, size = 65535 }, nvars, { data_type = INT, default_value = 1, is_nullable = 0, size = 10 }, varnames, { data_type = VARCHAR, default_value = , is_nullable = 0, size = 64 }, ); __PACKAGE__-set_primary_key(id); # Created by DBIx::Class::Schema::Loader v0.04004 @ 2008-02-12 17:08:38 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:gkSc31rRGpYHxL8tAAd/kw # You can replace this text with custom content, and it will be preserved on regeneration 1; As I understand I have to add to above: __PACKAGE__-source_name('SomeName'); __PACKAGE__-resultset_class('Components::ResultSet'); LogParser::Schema::LogParserDB::Components;ame and create a new package with: package LogParser::Schema::LogParserDB::Components::ResultSet; use strict; use warnings; use base qw( DBIx::Class::ResultSet ); sub advanced_search { my ( $self, $params, $attrs ) = @_; } 1; So I created Components/ResultSet.pm with this content. But it fails with : Couldn't instantiate component LogParser::Model::LogParserDB, Cannot load schema class 'LogParser::Schema::LogParserDB': Can't locate object method source_name via package LogParser::Schema::LogParserDB::Components::ResultSet at /usr/lib/perl5/site_perl/5.8.5/DBIx/Class/Schema.pm line 301. I tried to remove the line: __PACKAGE__-source_name('SomeName'); but still same problem. As I read the docs the meaning of this is to use another name than the default name so why use it??? Regards Peter Sorensen/University of Southern Denmark/mail: [EMAIL PROTECTED] ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
[Catalyst] Question on parameter passing
Hi, Using Catalyst, TT and FormBuilder I have a question concerning parameter passing. I have an action lists/editlist which display a form based on a TT template. In this form the user can modify several field and hit the SUBMIT button to update theese fields. sub editlist : Local Form { my ($self, $c) = @_; my $data = $c-req-params; my $form = $self-form-new(debug = 0); my $listmembers = $c-model('CatalystModelName::ListsAlias') -find({'listname' = $data-{listname} } ); # populate the fields $form-field(name = 'date', value = $listmembers-date); $form-field(name = 'reason', value = $listmembers-reason); $form-field(name = 'by', value = $listmembers-created_by); $form-field(name = 'listname', value = $data-{listname}); # Make information available for the template my @membersarray = split( ,$listmembers-destination); my @popdesc = $listmembers-population_desc; $c-stash-{listname} = $data-{listname}; $c-stash-{members} = [EMAIL PROTECTED]; $c-stash-{popdesc} = [EMAIL PROTECTED]; $c-stash-{created_by} = $listmembers-created_by; $c-stash-{template} = 'editlist.tt2'; } The SUBMIT call a new action lists/savemembers where the update according to a database is done. The savemembers don't output anything just processing data. I would like it to stay in the same form after data are processed. I have tried several ways make the nessacary information available to this: use the stash ( does'nt work and is probably not the right way to deal with this. Tried to pass the listname. Thought that this information would be available to another process in the controller) use hidden form fields: works but there must be a cleaner way to do this. How do I deal with this in a proper way using catalyst? And how do I process the data and leave the form unchanged? Regards and thanks Peter Sorensen/University of Southern Denmark/mail: [EMAIL PROTECTED] ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
[Catalyst] Advice on form submission
Hi, I'm using Catalyst with FormBuilder and TT I need an advice on how to handle multiple SUBMIT buttons on one form. I have a method: sub index : Local Form { .. This creates my main form with multiple SUBMITS like UPDATE DELETE ADD SUBSCRIBER } What would be the most elegant solution to deal with this according to Catalyst. I would prefer to have separate actions like: sub delete : Local Form { . sub update : Local Form { . Regards Peter Sorensen/university of Southern Denmark / e-mail: [EMAIL PROTECTED] ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
RE: [Catalyst] Catalyst, TT and using new filter
Thanks that worked. Below just FYI. In the meantime I found, that the problem was related to my minor knowledge to TT. The reason I wanted to trim the output was, that the code: tdtextarea [% FOREACH line IN subscribers %] [% line | undent %] [% END %] /textarea/td produces NL in the textarea field. I changed this to: tdtextarea [%- FOREACH line IN subscribers -%] [%- line | trim -%] [% END -%] /textarea/td and got rid of the NL. I was'nt aware of this. regards Peter --- easy filters: package myApp::View::TT; use strict; use base 'Catalyst::View::TT'; __PACKAGE__-config( { CATALYST_VAR = 'catalyst', ... FILTERS = { yesno = sub { $_[0] ? 'yes' : 'no'; }, onoff = sub { $_[0] ? 'on' : 'off'; }, }, }, ); 1; Peter Sørensen schrieb: Hi, I am Using catalyst, TT and formbuilder. I am struggling with output in a textarea field and would like to install a new filter to TT to be used like: tdtextarea [% FOREACH line IN subscribers %] [% line | undent %] [% END %] /textarea/td I have tried the standard trim filter but this does not give the expected result. I found a post facing the problem, where Andy Wardley suggested a undent filter and supplied code for this. My problem is where to put this code so that TT will recognize this filter according to Catalyst. Do I need to install this as a new Plugin in TT? Regards Peter Sorensen/University of Southern Denmark/E-mail: [EMAIL PROTECTED] Med venlig hilsen Peter Sørensen Vid.medarb., IT-service Tlf.6550 2858 Fax 6550 2860 Email [EMAIL PROTECTED] Web http://intern.sdu.dk/it-service/ansatte/ps-238/ Adr.Campusvej 55, 5230 Odense M SYDDANSK UNIVERSITET ___ Campusvej 55 * 5230 * Odense M * Tlf. 6550 1000 * www.sdu.dk -Oprindelig meddelelse- Fra: Gavin Henry [mailto:[EMAIL PROTECTED] Sendt: 4. februar 2008 11:50 Til: catalyst@lists.scsys.co.uk Emne: [Catalyst] Catalyst and Web Services? Hi All, If you want to provide access over SSL with auth, i.e. for example a desktop app posting and retrieving info from/to a Catalyst app what's the best way? REST or SOAP? I want the same users that normalling login via a web browser and get a cookie to be able to login via a light wee desktop app or some such? Would you create a new interface/access point on the Cat site and use REST or SOAP? All new to me, so excuse the dumb questions. Thanks. ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/ ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/ -- Mit freundlichen Grüßen Felix Antonius Wilhelm Ostmann -- Websuche Search Technology GmbH Co. KG Martinistraße 3 - D-49080 Osnabrück - Germany Tel.: +49 541 40666-0 - Fax:+49 541 40666-22 Email: [EMAIL PROTECTED] - Website: www.websuche.de -- AG Osnabrück - HRA 200252 - Ust-Ident: DE814737310 Komplementärin: Websuche Search Technology Verwaltungs GmbH - AG Osnabrück - HRB 200359 Geschäftsführer: Diplom Kaufmann Martin Steinkamp -- ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/ ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
[Catalyst] Advice on form submission
Hi, I'm using Catalyst with FormBuilder and TT I need an advice on how to handle multiple SUBMIT buttons on one form. I have a method: sub index : Local Form { .. This creates my main form with multiple SUBMITS like UPDATE DELETE ADD SUBSCRIBER } What would be the most elegant solution to deal with this according to Catalyst. I would prefer to have separate actions like: sub delete : Local Form { . sub update : Local Form { . Regards Peter Sorensen/university of Southern Denmark / e-mail: [EMAIL PROTECTED] ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
[Catalyst] Catalyst, TT and using new filter
Hi, I am Using catalyst, TT and formbuilder. I am struggling with output in a textarea field and would like to install a new filter to TT to be used like: tdtextarea [% FOREACH line IN subscribers %] [% line | undent %] [% END %] /textarea/td I have tried the standard trim filter but this does not give the expected result. I found a post facing the problem, where Andy Wardley suggested a undent filter and supplied code for this. My problem is where to put this code so that TT will recognize this filter according to Catalyst. Do I need to install this as a new Plugin in TT? Regards Peter Sorensen/University of Southern Denmark/E-mail: [EMAIL PROTECTED] Med venlig hilsen Peter Sørensen Vid.medarb., IT-service Tlf.6550 2858 Fax 6550 2860 Email [EMAIL PROTECTED] Web http://intern.sdu.dk/it-service/ansatte/ps-238/ Adr.Campusvej 55, 5230 Odense M SYDDANSK UNIVERSITET ___ Campusvej 55 * 5230 * Odense M * Tlf. 6550 1000 * www.sdu.dk -Oprindelig meddelelse- Fra: Gavin Henry [mailto:[EMAIL PROTECTED] Sendt: 4. februar 2008 11:50 Til: catalyst@lists.scsys.co.uk Emne: [Catalyst] Catalyst and Web Services? Hi All, If you want to provide access over SSL with auth, i.e. for example a desktop app posting and retrieving info from/to a Catalyst app what's the best way? REST or SOAP? I want the same users that normalling login via a web browser and get a cookie to be able to login via a light wee desktop app or some such? Would you create a new interface/access point on the Cat site and use REST or SOAP? All new to me, so excuse the dumb questions. Thanks. ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/ ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
SV: SV: [Catalyst] Problem with TT view and form.field
I am aware of that but the formbuilder lists is down so I hoped someone in here could sheed some light on the problem. Regards Peter Sorensen/Universirt of Southern Denmark/email: [EMAIL PROTECTED] -Oprindelig meddelelse- Fra: Matt S Trout [mailto:[EMAIL PROTECTED] Sendt: 21. januar 2008 11:19 Til: The elegant MVC web framework Emne: Re: SV: [Catalyst] Problem with TT view and form.field On Fri, Jan 18, 2008 at 08:05:37AM +0100, Peter Sørensen wrote: Hi Jason, Thanks for looking into the problem. I have tried your suggested syntax but still no output. I can access the information with: form.field.3.label where 3 is the index in the array but this is not what I want. I want to be able to address the content using the name of the field. Have you considered trying the formbuilder mailing list? Your problem doesn't seem particularly Catalyst-specific so maybe they'll be able to help better than we can ... -- Matt S Trout Need help with your Catalyst or DBIx::Class project? Technical Directorhttp://www.shadowcat.co.uk/catalyst/ Shadowcat Systems Ltd. Want a managed development or deployment platform? http://chainsawblues.vox.com/http://www.shadowcat.co.uk/servers/ ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/ ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
[Catalyst] Problem with TT view and form.field
Hi, I am trying to get hold of the Template Toolkit views. If I make a .tt2 file like [% form.render %] all form fields are showing up - OK. Now I want do my own layout and as I understood the DOCS all fields are saved in a hash field or array fields. All my fields are defined in a .fb file If I do: [% FOREACH field IN form.fields %] tr td[% field.label %]/td td[% field.name %]/td td[% field.field %]/td /tr [% END %] The output is OK but as I understood the docs it should also be possible to access this directly. [% fields %] - List of fields [% field %] - Hash of fields (for lookup by name) Lets say I have a field named firstname then it should be possible to do: [% form.fields.firstname.label %] BUT NOTHING SHOWS UP. I have tried to create a testhash in the controller like: my %testhash; $testhash{firstname} = myname; $c-stash-{testhash} = \%testhash; and I have no problem using: [% testhash.firstname %] in the .tt2 file What am i missing or what have I overlooked?? Regards Peter Sørensen/University of Southern Denmark/email: [EMAIL PROTECTED] ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
[Catalyst] Documentation on DBIx Class
Hi, I've been using perls for years and when dealing with web - CGI and DBI. Now I've come across Catalyst and DBIx. This is fantastic. Now I can get back to the code I've written and actually understand what I wrote 2 weeks back :-) I need some advice on where to look for documentation specially the DBIx Class and which methods I can use in here along with Catalyst. I've already ordered the Catalyst book but until this arrive any hints? Regards Peter Sørensen/University of Southern Denmark/Email: [EMAIL PROTECTED] ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
SV: [Catalyst] Template render problem (plugin error) - Hops-0.05application
Thanks, I downloaded the suggested and installed with perl Makefile.PL, I got a lot of prereq from CPAN but when trying to run the application i get following error: no file specified at /usr/lib/perl5/site.Catalyst/Plugin/Authentication/Store(Htpasswd/Backend.pm As I can see the wiab.conf contains path_to__(auth.txt) and it is probably this is it missing or?? Regard Peter -Oprindelig meddelelse- Fra: Kieren Diment [mailto:[EMAIL PROTECTED] Sendt: 21. december 2007 13:00 Til: The elegant MVC web framework Emne: Re: [Catalyst] Template render problem (plugin error) - Hops-0.05application On 21 Dec 2007, at 22:39, Peter Sørensen wrote: Hi, I am new to Catalyst. I have just installed it and got my first very simple application to work. (Catalyst 5.7012 , perl 5.8.5) Now I'm trying to learn by example, and have downloaded the Hops-0.05 application and got this working - I thought. But when accessing it from my browser I get the following error: Where's Hops from? It sounds to me like it might be very old. I suggest having a look in the catalyst examples dir in svn for something more up to date: svn checkout http://dev.catalyst.perl.org/repos/Catalyst/trunk/examples/ Or for something (that I wrote) which is thoroughly documented and n00b friendly (but not the best sw design work in the world - adequate, not great) http://code.google.com/p/websiteinabox/ ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/[EMAIL PROTECTED]/ Dev site: http://dev.catalyst.perl.org/ ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/[EMAIL PROTECTED]/ Dev site: http://dev.catalyst.perl.org/
SV: [Catalyst] Template render problem (plugin error) - Hops-0.05application
Thanks, This solved the problem with the Hops application. Regards Peter -Oprindelig meddelelse- Fra: Moritz Onken [mailto:[EMAIL PROTECTED] Sendt: 21. december 2007 13:58 Til: The elegant MVC web framework Emne: Re: [Catalyst] Template render problem (plugin error) - Hops-0.05application try installing Template::Plugin::Class Am 21.12.2007 um 12:39 schrieb Peter Sørensen: Hi, I am new to Catalyst. I have just installed it and got my first very simple application to work. (Catalyst 5.7012 , perl 5.8.5) Now I'm trying to learn by example, and have downloaded the Hops-0.05 application and got this working - I thought. But when accessing it from my browser I get the following error: .. [debug] Rendering template list [error] Could'nt render template plugin error - Class: plugin not found .. Obviously I'm missing something. Could someone shed some light on this and point me in the right direction? Maybee howto get more debug output or other ways to track down the problem. Regards and thanks Peter ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/[EMAIL PROTECTED]/ Dev site: http://dev.catalyst.perl.org/ ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/[EMAIL PROTECTED]/ Dev site: http://dev.catalyst.perl.org/ ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/[EMAIL PROTECTED]/ Dev site: http://dev.catalyst.perl.org/