html-template-users Mailing List for HTML::Template (Page 99)
Brought to you by:
samtregar
You can subscribe to this list here.
2002 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(42) |
Jul
(80) |
Aug
(77) |
Sep
(97) |
Oct
(65) |
Nov
(80) |
Dec
(39) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2003 |
Jan
(63) |
Feb
(47) |
Mar
(45) |
Apr
(63) |
May
(67) |
Jun
(51) |
Jul
(78) |
Aug
(37) |
Sep
(45) |
Oct
(59) |
Nov
(50) |
Dec
(70) |
2004 |
Jan
(23) |
Feb
(90) |
Mar
(37) |
Apr
(53) |
May
(111) |
Jun
(71) |
Jul
(35) |
Aug
(58) |
Sep
(35) |
Oct
(35) |
Nov
(35) |
Dec
(20) |
2005 |
Jan
(51) |
Feb
(19) |
Mar
(20) |
Apr
(8) |
May
(26) |
Jun
(14) |
Jul
(49) |
Aug
(24) |
Sep
(20) |
Oct
(49) |
Nov
(17) |
Dec
(53) |
2006 |
Jan
(12) |
Feb
(26) |
Mar
(45) |
Apr
(19) |
May
(19) |
Jun
(13) |
Jul
(11) |
Aug
(9) |
Sep
(10) |
Oct
(16) |
Nov
(17) |
Dec
(13) |
2007 |
Jan
(9) |
Feb
(12) |
Mar
(28) |
Apr
(33) |
May
(12) |
Jun
(12) |
Jul
(19) |
Aug
(4) |
Sep
(4) |
Oct
(5) |
Nov
(5) |
Dec
(13) |
2008 |
Jan
(6) |
Feb
(7) |
Mar
(14) |
Apr
(16) |
May
(3) |
Jun
(1) |
Jul
(12) |
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
(9) |
2009 |
Jan
(9) |
Feb
|
Mar
(10) |
Apr
(1) |
May
|
Jun
(6) |
Jul
(5) |
Aug
(3) |
Sep
(7) |
Oct
(1) |
Nov
(15) |
Dec
(1) |
2010 |
Jan
|
Feb
|
Mar
|
Apr
(9) |
May
|
Jun
|
Jul
(5) |
Aug
|
Sep
(2) |
Oct
|
Nov
|
Dec
|
2011 |
Jan
|
Feb
(3) |
Mar
|
Apr
(28) |
May
|
Jun
|
Jul
(3) |
Aug
(4) |
Sep
(3) |
Oct
|
Nov
(8) |
Dec
|
2012 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(2) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2013 |
Jan
(2) |
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2014 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2015 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(2) |
Dec
|
2016 |
Jan
|
Feb
(1) |
Mar
|
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(1) |
Dec
|
From: Jesse E. <je...@er...> - 2002-09-04 04:05:45
|
Hey All -- Kenny Smith writes: > If any piece of the MVC paradigm isn't being followed in an > application that > uses HTML::Template, it's only in the Model or the Controller, > which really > isn't in Mr. Tregar's scope. :) If I may add one thing to this: The goal of HTML::Template was *not* to be the "View" in Model-View-Controller. The goal of HTML::Template was actually to maximally separate application code from HTML code, and to provide an interface which was easier for non-programmer HTML designers to work with. If it so happens that the goal of separation of HTML from Perl is compatible with a particular approach to development (such as MVC), that is entirely coincidental. FWIW, IMHO, <TMPL_IF> enhances the separation of HTML from Perl code. Before <TMPL_IF> it would be necessary to have a <TMPL_VAR NAME="CONDITIONAL_OUTPUT_HERE">, which was much worse. I also believe that the decision to only provide Boolean operators (not relational: <, >, etc.) also enhances the separation of code from HTML. If you disagree, you can always create your own filter. Warmest regards, -Jesse- -- Jesse Erlbaum The Erlbaum Group je...@er... Phone: 212-684-6161 Fax: 212-684-6226 |
From: Kenny S. <ke...@jo...> - 2002-09-04 01:11:45
|
Hi Serg, > He show me a MANNINGish book Web Development with JavaServer Pages by DUANE K. FIELDS and > MARK A. KOLB where MVC have been discussed in chapter 8 Architecting JS= P applications (I'm sorry > for JSP offtopic, but it relates to subj) and I allow myself to cite pp. 212-213: > [cite] > The presentation layout tier is not concerned with how the informatio= n was obtained, or from where. Its > responsibilities lie only in displaying the information itself, while delegating any other activity up the > chain to other tiers. For example, in an application which involves submitting a search query through > a web form only the form itself and the corresponding results are the responsibility of the presenta-tion > layer. What happens in between, the processing of the request and the retreival of the results, is not. > [/cite] I completely agree, this is exactly what H::T does. Here is most of the citation with the word template stuck in: The template is not concerned w= ith how the information was obtained, or from where. *snip* For example, in a= n application which involves submitting a search query through a web form o= nly the form iteself and the corresponding results are the responsibility of = the template. What happens in between, the processing of the request and the retreival of the results, is not. Works perfectly. > [cite] > This tier (CONTROL - rem. by SV) is also responsible for making decisio= ns among multiple > presentations, when available. If a user=92s language, locale, or acces= s level dictates a different > presentation, this decision is made in the control layer. For example, = an administrator might > see all of the data from a database query, while an end user might see = an alternate, more > restrictive results page. > [/cite] I completely agree, my cgi script determines which of my many templates i= t is going to use... "responsible for making decisions among multiple presentations, when available." Either it chooses a completely seperate template, or it sets a boolean variable in the template data. If you have= a TMPL_IF in your template that is used to show form A or form B based on a TMPL_IF it isn't the view (H::T) that decides which to show... the controller and model (your cgi) provide the data to the template, so the = cgi is the one making the decision. The template is merely displaying the the given data based on the given data. If any piece of the MVC paradigm isn't being followed in an application t= hat uses HTML::Template, it's only in the Model or the Controller, which real= ly isn't in Mr. Tregar's scope. :) Kenny Smith JournalScape.com |
From: Mike C. <mi...@mi...> - 2002-09-04 00:51:31
|
I am getting started with HTML::Template and am looking for some advice on the best way to handle this. I want my home page to have a login form (username and password) if someone is not logged in, or a message "logged in as joe smith" and a logout link if they are logged in. What would be the cleanest way (in the MVC sense) to do this with H::T? I can have something like: <tmpl_if name=loginame> Logged in as <tmpl_var name=loginname><br> <a href='/logout'>Logout</a> <tmpl_else> <form action='/login'> <input type=text name=login> <input type=password name=password> </form> </tmpl_if> But this feels like putting the control out in the viewer to me. Is there a better way? Thanks, --Mike Carlton |
From: David W. <da...@wh...> - 2002-09-03 23:20:52
|
The Bricolage team would like to announce the release of Bricolage 1.4.0. This is the first new stable release of Bricolage since the release of version 1.2.3 in March, and the first major release since 1.2.0 in January. Bricolage is a full-featured, enterprise-class content management and publishing system. It offers a browser-based interface for ease-of use, a full-fledged templating system with complete programming language support for flexibility, and many other features (see below). It operates in an Apache/mod_perl environment, and uses the PostgreSQL RDBMS for its repository. For a complete list of the changes, See Bric::Changes at http://bricolage.cc/docs/Bric/Changes.html. Learn more about Bricolage and download it from the Bricolage home page, http://bricolage.cc/. Here's a sampling of the major new features in version 1.4.0: * An integrated SOAP (Simple Object Access Protocol) server, which offers a convenient interface for importing and exporting content, as well as for mass-publishing content. * Simplified installation via an included Makefile and related scripts that check for dependencies, build the database, and install all the required libraries, components, and programs. * Content distribution via FTP and SFTP, in addition to the existing file system copy methods. * System-wide customization of the URIs the Bricolage builds for content. * Improved tracking of the publish status of content, easing the identification of what needs to be published and what doesn't. * Search result paging. A new system-wide preference allows those manager screens that display a lot of objects to paginate those results over a series of pages. * Improved performance of the keyword system, the category system, the group system, the publishing system, and caching. * A new interface for managing media types (a.k.a., MIME types) so that Bricolage can better identify the types of media files it manages. * Support for Apache-SSL in addition to the existing support for mod_ssl. * Simplified configuration system, with support for manual configuration where desired. * System cloning. Bricolage installations can now be cloned, complete with all data stored in the RDBMS, and converted into a distribution tarball. This simplifies the creation of packages for installing customized copies of Bricolage. * The ability to use Bricolage with or without SSL support on arbitrary ports. * Support for Mac OS X. * Over 90 bug fixes. Enjoy! --The Bricolage Team -- David Wheeler AIM: dwTheory da...@wh... ICQ: 15726394 http://david.wheeler.net/ Yahoo!: dew7e Jabber: Th...@ja... |
From: Sam T. <sa...@tr...> - 2002-09-03 19:05:05
|
On Tue, 3 Sep 2002, SV wrote: > One of my friend say, when catch me programming tmpl file with <TMPL IF> statement: > "If you want your script complain with letter V in MVC paradigm, you should > include in your template only VAR and LOOP tags, becouse you should not transfer > Control rules to View". > > Any comments or emotions? It's a grey area. What exactly did your friend catch you doing? Constructing a giant rat's-nest of <tmpl_if>, <tmpl_unless> and <tmpl_else>? If so then he's got a case. However, when kept simple I don't think it necessarily violates reasonable MVC standards. -sam |
From: Kenny S. <ke...@jo...> - 2002-09-03 18:41:49
|
Hi Serg, This isn't a violation of MVC... The perl application decides which part of the application to go to (controller) and it constructs the data to be passed the template (model). The template decides how it wants to use that data (view), it can completely ignore it, or it can use it. If your friend is a Java programmer (perhaps Struts, where MVC is an essential part of the framework), ask him how exactly his JSP can do conditionals like <logic:equal> without the Model providing data to perform the comparison on. It's the same thing. The Model has to provide the data that the View uses to determine what to show. The View (in H::T) doesn't control the flow of the application, it merely takes the data given to it by the Model and presents it, which is exactly what it is supposed to do. Kenny Smith JournalScape.com > -----Original Message----- > From: htm...@li... > [mailto:htm...@li...]On Behalf Of SV > Sent: Tuesday, September 03, 2002 11:28 AM > To: htm...@li... > Subject: [htmltmpl] IF tag breaks V in MVC paradigm? > > > Hello All, > > One of my friend say, when catch me programming tmpl file with > <TMPL IF> statement: > "If you want your script complain with letter V in MVC paradigm, > you should > include in your template only VAR and LOOP tags, becouse you > should not transfer > Control rules to View". > > Any comments or emotions? > > -- > Best regards, > Serg Velikanov mailto:we...@vp... > > > > > ------------------------------------------------------- > This sf.net email is sponsored by: OSDN - Tired of that same old > cell phone? Get a new here for FREE! > https://www.inphonic.com/r.asp?r=sourceforge1&refcode1=vs3390 > _______________________________________________ > Html-template-users mailing list > Htm...@li... > https://lists.sourceforge.net/lists/listinfo/html-template-users > |
From: SV <we...@vp...> - 2002-09-03 18:29:05
|
Hello All, One of my friend say, when catch me programming tmpl file with <TMPL IF> statement: "If you want your script complain with letter V in MVC paradigm, you should include in your template only VAR and LOOP tags, becouse you should not transfer Control rules to View". Any comments or emotions? -- Best regards, Serg Velikanov mailto:we...@vp... |
From: Chris D. <Chr...@Ma...> - 2002-09-03 16:15:47
|
Will [sel...@ya...] wrote: > I am working on H::T loops. Right now I am looking to > pull info out of MySQL via Perl's DBI module, and then > stuff that data into HTML tables generated by H::T. [...] > Does anyone have any good advice on how to get through > this? If you do a search in the mailing list archives for words like "fetchrow" you'll see a plethora of examples and suggestions. Chris -- Chris Davies, Manheim Online Tel. 0113 393-2004 Fax. 0870 444-0482. Mobile 07778 199069 |
From: Benjamin <ben...@nu...> - 2002-09-03 16:04:14
|
Hi, > I know that to use H::T loops feature, I'll have to > (if I have this right) sort of "nest" a hash in an > array, but I am not sure of how to create the hash in > a way H::T will be able to work with it. > DBI supports a number of different method calls, like > fetchrow_hashref and others, but I am not sure if > these would work. The easiest way is to call $tbl_ary_ref = $sth->fetchall_arrayref( {} ); which returns an array ref, that contains hashrefs. I use this method frequentl, although the DBI docs state: Because of the extra work fetchrow_hashref and Perl have to perform, it is not as efficient as fetchrow_arrayref or fetchrow_array Hope this helps Benjamin |
From: Will <sel...@ya...> - 2002-09-03 15:23:10
|
Greets Folks, I am working on H::T loops. Right now I am looking to pull info out of MySQL via Perl's DBI module, and then stuff that data into HTML tables generated by H::T. I know that to use H::T loops feature, I'll have to (if I have this right) sort of "nest" a hash in an array, but I am not sure of how to create the hash in a way H::T will be able to work with it. DBI supports a number of different method calls, like fetchrow_hashref and others, but I am not sure if these would work. Does anyone have any good advice on how to get through this? Thanks, Will __________________________________________________ Do You Yahoo!? Yahoo! Finance - Get real-time stock quotes http://finance.yahoo.com |
From: Sam T. <sa...@tr...> - 2002-09-02 21:54:33
|
On Mon, 2 Sep 2002, Joachim Kohlhammer wrote: > It seems like the TMPL_INCLUDE is evaluated before the other code is run > through. Is this correct? Yes. The <tmpl_include> works like a #include in C - it reads in the file as soon as it is reached by the parser. The upside is that this means you could have the start of a <tmpl_loop> inside a header.tmpl and the </tmpl_loop> inside a footer.tmpl. The downside is that you can't recursively include a template inside itself. -sam |
From: Joachim K. <joa...@gm...> - 2002-09-02 20:22:31
|
Hi all, I have a question regarding TMPL_INCLUDE. At the moment I am writing new templates for BINS (http://bins.sautret.org), which uses HTML::Template. It features a Album Tree which is at the moment created in the Perlscript. You can see a example at http://album.sautret.org/tree.html. I want to move the creation of this tree in a template. The following came to mind: treeloop.html: <li> <TMPL_VAR NAME="ALBUM_NAME"> <TMPL_IF NAME="HAS_SUBALBUM"> <ul> <TMPL_LOOP NAME="SUBALBUM"> <TMPL_INCLUDE NAME="treeloop.html"> </TMPL_LOOP> </ul> </TMPL_IF> </li> But this doesn't work, it gives me the message HTML::Template->new() : likely recursive includes - parsed 10 files deep and giving up (set max_includes higher to allow deeper recursion). at /usr/share/perl5/HTML/Template.pm line 2108. The version of HTML::Template is 2.5. It seems like the TMPL_INCLUDE is evaluated before the other code is run through. Is this correct? If yes, is there a way to control recursion using IF's and LOOP's? If no, where is my mistake? Thanks for your help, Joachim |
From: Brian P. <br...@th...> - 2002-09-02 05:20:35
|
I've been playing around with the latest version of Dreamweaver and it seems to have a lot of support for templates. The syntax between HTML::Template and Dreamweaver's templates are a bit different, but nothing that a filter function couldn't handle. I'll post my latest version of the filter function that will transform Dreamweaver templates to HTML::Templates once I get back to work. I think with a few weeks of work from those of us on the mailing list, we could get something fairly robust and powerful. By the way, if you haven't checked out Dreamweaver yet, I would highly recommend downloading a 30 day trial version. I think we are very, very close to having something that designers can use to create pages and hand off to us perl developers without needing to modify the HTML. Brian |
From: Max <ma...@va...> - 2002-08-30 23:26:41
|
Hi, I have been using HTML::Template extensively for my current project (this week) and there are some questions and comments I have about it. First off, I enjoy using it tremendously :) .. I have combined it with CGI::Session and the two together are very useful. I also really like the flexibility of the caching architecture ... I am producing a package for unknown environments, so it was nice to still be able to use some form of caching via file_cache that is pretty much guaranteed to work anywhere perl does :). First comment/question: I am glad that the filtering option exists ... I have actually used it to produce a mini-framework for programmers who use the application I am writing to be able to add custom tags to HTML::Template. I have used JSP taglibs to a limited extent and I would like to see a framework for easily defining tag classes added to HTML::Template. My code is a bit of a hack as I needed to pass in more than just the filter text to my tag lib framework .. I wanted the tag libs to get the current CGI object and CGI::Session object too, along with the complete filename of the template being worked on. My first use of this was to produce a select list tag that will create a list from an external file .. again, my application will be given to an audience that may or may not know perl but will know at least some HTML ... so my tag is <TMPL_SELECT NAME="xxxx" FILE="xxxx"> This will create the list from the file (file has one option per line, path is relative to the directory of the template) and also set the selected element to the current value of either 1) the variable in the CGI object or 2) the variable in the session ... or none if neither contain it. The real hack part of my framework is that I had to also pass in the template filename so that for files that contain the custom tags I can update the mtime/atime so that HTML::Template will create them over again each time it comes across the file. This was the only way I could think to avoid having HTML::Template filter my file once then not touch it again ... therefore completely overriding the purpose of my custom tags! So ... my ideal situation would be to have a taglib framework that would be separate from the filtering to let programmers easily extend and add new tags to HTML::Template without affecting the core .. which would lead to easy tag sharing too .. something I would like to see :). I was planning on mentioning other things but I think I have written enough for now :). Any comments/feedback welcome. I would be happy to discuss/work with someone to add this to HTML::Template if it is deemed to be a feature that is wanted. Max |
From: Sam T. <sa...@tr...> - 2002-08-30 20:56:16
|
On Fri, 30 Aug 2002, Dave Van Abel wrote: > So where is the real home for HT these days? > > I need to put it in some documentation. http://html-template.sourceforge.net/ -sam |
From: Dave V. A. <da...@va...> - 2002-08-30 20:35:58
|
So where is the real home for HT these days? I need to put it in some documentation. Thks, Dave Dave Van Abel Lakewood, CO USA http://www.vanabel.com http://perlsources.com Yahoo Instant Messenger: dave_vanabel 303-989-6481 (home-office) |
From: Philip S T. <phi...@gm...> - 2002-08-30 07:46:57
|
Sometime on Aug 29, Jeff Pelkey assembled some asciibets to say: > However, If I pass a CGI param /cgi-bin/foo.cgi?ID=456 > My $ID = $cgi->param('ID'); > $sql = qq/ SELECT * FROM Foo WHERE ID = ? ORDER BY bar /; > $sth->execute($ID) ... > > I even used associate => $cgi, thinking this would pass the CGI params to > the template. what does your template look like? you've either got to have ?ID=456 in all your urls, or if you have a form, then as a hidden field. -- The first version always gets thrown away. |
From: Sam T. <sa...@tr...> - 2002-08-30 03:05:34
|
On 30 Aug 2002, simran wrote: > ps: You did not mention anything about adding filter args support... i > though that you were going to put in some sort of a feature to support > filter arguments (for which Cees sent a patch...) - is this still on the > agenda? Ah, you're right. I knew I was forgetting something. I'll take another look at that soon. -sam |
From: simran <sim...@le...> - 2002-08-29 23:42:34
|
Excellent... can't wait to try it out... thanks Sam. ps: You did not mention anything about adding filter args support... i though that you were going to put in some sort of a feature to support filter arguments (for which Cees sent a patch...) - is this still on the agenda? On Sat, 2002-08-31 at 07:13, Sam Tregar wrote: > CHANGES > > - New Feature: HTML::Template will combine HTML_TEMPLATE_ROOT > environment variable and path option if both are > available. (Jesse Erlbaum) > > - New Feature: __counter__ variable now available when > loop_context_vars is set (Simran Gambhir) > > - New Feature: The default attribute allows you to specify > defaults for <tmpl_var> tags. > > - Bug Fix: fixed parser to reject <tmpl_var>s with no names. > (crazyinsomniac) > > - Doc Fix: fixed documentation to correctly describe the > interaction of case_sensitive and loop_context_vars. > (Peter Claus Lamprecht) > > - Doc Fix: updated mailing-list information to reflect move from > vm.com to sourceforge.net > > DESCRIPTION > > This module attempts to make using HTML templates simple and natural. It > extends standard HTML with a few new HTML-esque tags - <TMPL_VAR>, > <TMPL_LOOP>, <TMPL_INCLUDE>, <TMPL_IF>, <TMPL_ELSE> and <TMPL_UNLESS>. > The file written with HTML and these new tags is called a template. It > is usually saved separate from your script - possibly even created by > someone else! Using this module you fill in the values for the > variables, loops and branches declared in the template. This allows you > to separate design - the HTML - from the data, which you generate in the > Perl script. > > This module is licensed under the GPL. See the LICENSE section below for > more details. > > TUTORIAL > > If you're new to HTML::Template, I suggest you start with the > introductory article available on the HTML::Template website: > > http://html-template.sourceforge.net > > AVAILABILITY > > This module is available on SourceForge. Download it at: > > http://html-template.sourceforge.net > > The module is also available on CPAN. You can get it using > CPAN.pm or go to: > > http://www.cpan.org/authors/id/S/SA/SAMTREGAR/ > > CONTACT INFO > > This module was written by Sam Tregar (sa...@tr...). You can > join the HTML::Template mailing-list by visiting: > > http://lists.sourceforge.net/lists/listinfo/html-template-users > > > > > |
From: Sam T. <sa...@tr...> - 2002-08-29 22:51:53
|
On Thu, 29 Aug 2002, Chisel Wright wrote: > Whoever pasted the chages into sourceforge > (http://sourceforge.net/project/shownotes.php?release_id=107880) > forgot to replace '<' with '<' etc. Uh, yeah, whoever did that should get his act together. Thanks! -sam |
From: Jeff P. <jp...@gr...> - 2002-08-29 22:17:56
|
Howdy! This will probably show my ignorance, but here goes... I wrote a couple of app's that work fine until I add a CGI param to the SQL mix. If I hardcode the param in: my OLE_LINK1$sql = qq/ SELECT * FROM Foo WHERE ID = 123 ORDER BY bar /; Then each page displays only rows with ID equal to 123 -Works Great! However, If I pass a CGI param /cgi-bin/foo.cgi?ID=456 My $ID = $cgi->param('ID'); $sql = qq/ SELECT * FROM Foo WHERE ID = ? ORDER BY bar /; $sth->execute($ID) ... I even used associate => $cgi, thinking this would pass the CGI params to the template. The first page displays correctly, but the following pages contain all the data in the table. Is there something I am doing wrong or need to change? MTIA - Jeff Pelkey |
From: Sam T. <sa...@tr...> - 2002-08-29 21:20:54
|
CHANGES - Fixed parser to recognize negative numbers. Thanks to Fran Fabrizio for the report. - Fixed parser to allow for HTML-comment style tags. Thanks to Stuhlpfarrer Gerhard for the spot. - Updated mailing-list information to reflect move from vm.com to sourceforge.net DESCRIPTION This module provides an extension to HTML::Template which allows expressions in the template syntax. This is purely an addition - all the normal HTML::Template options, syntax and behaviors will still work. Expression support includes comparisons, math operations, string operations and a mechanism to allow you add your own functions at runtime. AVAILABILITY This module is available on SourceForge. Download it at: http://html-template.sourceforge.net The module is also available on CPAN. You can get it using CPAN.pm or go to: http://www.cpan.org/authors/id/S/SA/SAMTREGAR/ CONTACT INFO This module was written by Sam Tregar (sa...@tr...). You can join the HTML::Template mailing-list by visiting: http://lists.sourceforge.net/lists/listinfo/html-template-users |
From: Sam T. <sa...@tr...> - 2002-08-29 21:20:19
|
CHANGES - Added support for HTML::Template 2.6's new DEFAULT attribute. - Added support for HTML::Template 2.6's new __counter__ variable. - Updated mailing-list information to reflect move from vm.com to sourceforge.net - Fixed bug where tmpl_var's with the escape attribute would cause a crash if not set with a value. DESCRIPTION This module provides a just-in-time compiler for HTML::Template. Templates are compiled into native machine code using Inline::C. The compiled code is then stored to disk and reused on subsequent calls. HTML::Template::JIT is up to 8 times as fast as HTML::Template using caching. NOTE This module is not feature-complete. Be sure to read the CAVEATS section in the documentation before using! AVAILABILITY This module is available on SourceForge. Download it at: http://html-template.sourceforge.net The module is also available on CPAN. You can get it using CPAN.pm or go to: http://www.cpan.org/authors/id/S/SA/SAMTREGAR/ CONTACT INFO This module was written by Sam Tregar (sa...@tr...). You can join the HTML::Template mailing-list by visiting: http://lists.sourceforge.net/lists/listinfo/html-template-users |
From: Sam T. <sa...@tr...> - 2002-08-29 21:18:45
|
CHANGES - New Feature: HTML::Template will combine HTML_TEMPLATE_ROOT environment variable and path option if both are available. (Jesse Erlbaum) - New Feature: __counter__ variable now available when loop_context_vars is set (Simran Gambhir) - New Feature: The default attribute allows you to specify defaults for <tmpl_var> tags. - Bug Fix: fixed parser to reject <tmpl_var>s with no names. (crazyinsomniac) - Doc Fix: fixed documentation to correctly describe the interaction of case_sensitive and loop_context_vars. (Peter Claus Lamprecht) - Doc Fix: updated mailing-list information to reflect move from vm.com to sourceforge.net DESCRIPTION This module attempts to make using HTML templates simple and natural. It extends standard HTML with a few new HTML-esque tags - <TMPL_VAR>, <TMPL_LOOP>, <TMPL_INCLUDE>, <TMPL_IF>, <TMPL_ELSE> and <TMPL_UNLESS>. The file written with HTML and these new tags is called a template. It is usually saved separate from your script - possibly even created by someone else! Using this module you fill in the values for the variables, loops and branches declared in the template. This allows you to separate design - the HTML - from the data, which you generate in the Perl script. This module is licensed under the GPL. See the LICENSE section below for more details. TUTORIAL If you're new to HTML::Template, I suggest you start with the introductory article available on the HTML::Template website: http://html-template.sourceforge.net AVAILABILITY This module is available on SourceForge. Download it at: http://html-template.sourceforge.net The module is also available on CPAN. You can get it using CPAN.pm or go to: http://www.cpan.org/authors/id/S/SA/SAMTREGAR/ CONTACT INFO This module was written by Sam Tregar (sa...@tr...). You can join the HTML::Template mailing-list by visiting: http://lists.sourceforge.net/lists/listinfo/html-template-users |
From: Kenny S. <ke...@jo...> - 2002-08-27 15:27:57
|
Hi Philip, > yeah, but not if two variables share the same name. > I'd like to be able to separately specify which loop's > var I want. If you dislike the overlapping of names and whatnot, then I would just recommend when you create your data structure that you actually name your variables according to the DOM system you want. Call your global scope variables "document.var1" and the variables in your loops "document.loop1.var1" and you're done. You satisfy your desire for uniqueness in names, and others who don't need to worry about it... well, don't need to worry about it. Kenny |