html-template-users Mailing List for HTML::Template (Page 38)
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: Alan G. <al...@lo...> - 2004-12-03 01:19:29
|
Hello Brad. I already answered this - didn't you see it? Your HTML is broken. you are missing a double quote character. so you've confused the browser. THIS: <a href="../cgi-bin/foo.pl#top>Top of Page</a> SHOULD BE: <a href="../cgi-bin/foo.pl#top">Top of Page</a> Alan. ----- Original Message ----- From: "Brad Cathey" <bra...@hi...> To: "Sam Tregar" <sa...@tr...> Cc: <htm...@li...> Sent: Thursday, December 02, 2004 5:07 AM Subject: Re: [htmltmpl] Question about page anchors (bookmarks) in H::T Sam, > On Wed, 1 Dec 2004, Brad Cathey wrote: > >> In a regular HTML setting, this is no problem >> >> http://www.domain.com/page.html#top >> >> But in the .TMPL model, it goes to the home page: >> >> http://www.domain.com/#top > > Two answers: > > 1) That's not "the .TMPL model" that's the model of your code. In my > code that would usually look like: > > http://www.domain.com/foo.pl#top > > But that's got nothing to do with HTML::Template 1) Not sure I understand, because in straight HTML <a href="#top">Top of Page</a> works fine. However, I ended up leaving the anchor at the top of the page (would not work without it) and adding the relative cgi-path to my link, as you indicated, and it worked fine. <a href="../cgi-bin/foo.pl#top>Top of Page</a> Thanks. ------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://productguide.itmanagersjournal.com/ _______________________________________________ Html-template-users mailing list Htm...@li... https://lists.sourceforge.net/lists/listinfo/html-template-users |
From: Brad C. <bra...@hi...> - 2004-12-02 13:08:00
|
Sam, > On Wed, 1 Dec 2004, Brad Cathey wrote: >=20 >> In a regular HTML setting, this is no problem=8Bthe URL reads: >>=20 >> http://www.domain.com/page.html#top >>=20 >> But in the .TMPL model, it goes to the home page: >>=20 >> http://www.domain.com/#top >=20 > Two answers: >=20 > 1) That's not "the .TMPL model" that's the model of your code. In my > code that would usually look like: >=20 > http://www.domain.com/foo.pl#top >=20 > But that's got nothing to do with HTML::Template 1) Not sure I understand, because in straight HTML <a href=3D"#top">Top of Page</a> works fine. However, I ended up leaving the anchor at the top of the page (would not work without it) and adding the relative cgi-path to my link, as you indicated, and it worked fine. <a href=3D"../cgi-bin/foo.pl#top>Top of Page</a> Thanks. |
From: Carl F. <C.A...@du...> - 2004-12-02 09:41:26
|
Hi Brad, You don't need to create an explicit "top of page" anchor. Use the implicit <a href=3D"#">top</a> link and it'll do what you want. Carl >>> Brad Cathey <bra...@hi...> 01/12/2004 16:17:18 >>> Hello all, I have placed a simple anchor (bookm at the top and "Top of Page" link at the bottom of a .tmpl page. CODE: top: <a name=3D"top"> </a> btm: <a href=3D"#top>Top of Page</a> In a regular HTML setting, this is no problem*the URL reads: http://www.domain.com/page.html#top=20 But in the .TMPL model, it goes to the home page: http://www.domain.com/#top=20 I though about including the entire path in my link: <a href=3D"page.tmpl#top>Top of Page</a> which works in some browsers, but others just echo the html coding. So, what does everyone else do in this case? Brad ------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://productguide.itmanagersjournal.com/=20 _______________________________________________ Html-template-users mailing list Htm...@li...=20 https://lists.sourceforge.net/lists/listinfo/html-template-users |
From: Sam T. <sa...@tr...> - 2004-12-01 22:49:44
|
On Wed, 1 Dec 2004, Brad Cathey wrote: > In a regular HTML setting, this is no problem=8Bthe URL reads: >=20 > http://www.domain.com/page.html#top >=20 > But in the .TMPL model, it goes to the home page: >=20 > http://www.domain.com/#top Two answers: 1) That's not "the .TMPL model" that's the model of your code. In my code that would usually look like: http://www.domain.com/foo.pl#top But that's got nothing to do with HTML::Template 2) Even so, that should work fine, right? -sam |
From: Alan G. <al...@lo...> - 2004-12-01 21:11:54
|
Hi Brad, There is a missing double quote character in the A tags. thats why they print it out. You've confused the browser. <a href="page.tmpl#top> Alan. ----- Original Message ----- From: "Brad Cathey" <bra...@hi...> To: <htm...@li...> Sent: Wednesday, December 01, 2004 8:17 AM Subject: [htmltmpl] Question about page anchors (bookmarks) in H::T Hello all, I have placed a simple anchor (bookm at the top and "Top of Page" link at the bottom of a .tmpl page. CODE: top: <a name="top"> </a> btm: <a href="#top>Top of Page</a> In a regular HTML setting, this is no problem http://www.domain.com/page.html#top But in the .TMPL model, it goes to the home page: http://www.domain.com/#top I though about including the entire path in my link: <a href="page.tmpl#top>Top of Page</a> which works in some browsers, but others just echo the html coding. So, what does everyone else do in this case? Brad ------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://productguide.itmanagersjournal.com/ _______________________________________________ Html-template-users mailing list Htm...@li... https://lists.sourceforge.net/lists/listinfo/html-template-users |
From: Brad C. <bra...@hi...> - 2004-12-01 16:17:25
|
Hello all, I have placed a simple anchor (bookm at the top and "Top of Page" link at the bottom of a .tmpl page. CODE: top: <a name=3D"top"> </a> btm: <a href=3D"#top>Top of Page</a> In a regular HTML setting, this is no problem=8Bthe URL reads: http://www.domain.com/page.html#top But in the .TMPL model, it goes to the home page: http://www.domain.com/#top I though about including the entire path in my link: <a href=3D"page.tmpl#top>Top of Page</a> which works in some browsers, but others just echo the html coding. So, what does everyone else do in this case? Brad |
From: Alex K. <ka...@ra...> - 2004-11-30 17:02:58
|
Good day to all. I'd like to have such a code in my template: <a href="javascript:func('<TMPL_VAR NAME="email">')">add email</a> I even already do so :) It seems to me that I need _both_ ESCAPE="HTML" and ESCAPE="JS" here to make it work with real data because that 'email' param could easily contain something like q{'John Doe' <jo...@do...>} and break on either apostroph or less-than whichever way of ESCAPing we use. Is there an elegant method of dealing with such data? I can certainly pre-JS-escape in Perl and then use ESCAPE="HTML" in template but that would look ugly. Or am I trying to solve a non-existent problem? -- Alex Kapranoff, #!/usr/bin/perl -w $SIG{__WARN__}=sub{print substr("@_",-43+ord$_,1)for '6.823O1US90:350:739OJ;0:*'=~m}.}g},$}='PJlshrk';reset$}+43; |
From: Mathew R. <mat...@re...> - 2004-11-28 22:27:16
|
> > Are you perhaps unfortunate enough to be using RedHat 8 or 9 and > > Perl 5.8.0, which broke the localisation support quite badly? If > > so, consider a Perl version upgrade. >=20 > The perl version is 5.005_03, I am not sure about the linux = distrubution. I am on a shared=20 > hosting environment though, so it would not be possible for me to = upgrade the system... If you are in a shared environment, just install Perl in your home = directory, then set your PATH and PERL5LIB environmental variables to = this new path. For what its worth, Perl 5.8.x is so much better at handling = multi-lingual text (than previous versions) that you will most likely = bang your head against a brick wall, trying to get earlier versions of = Perl to work as expected. Also, 5.005_03 is a very old version... probably the system default = Perl which is used for boot scripts, etc... this usually means that = there will be another version of Perl installed on the machine... this = scenario is often done on FreeBSD machines. regards, Mathew |
From: Adrian G. <ad...@lo...> - 2004-11-28 11:21:05
|
Hi Roger, Thanks for your reply. > Are you perhaps unfortunate enough to be using RedHat 8 or 9 and > Perl 5.8.0, which broke the localisation support quite badly? If > so, consider a Perl version upgrade. The perl version is 5.005_03, I am not sure about the linux distrubution. I= am on a shared hosting environment though, so it would not be possible for me to upgrade= the system... Best Regards, =09Adrian Grigore =09 -- Adrian Grigore ad...@lo... Lobstersoft - Fun Brain-Bending Games For All Ages http://www.lobstersoft.com Member of the Association of Shareware Professionals |
From: Roger B. W. <ro...@fi...> - 2004-11-26 13:13:48
|
On Fri, Nov 26, 2004 at 01:51:44PM +0100, Adrian Grigore wrote: >For HTML this is of course no problem since I would replace ? with ä , but >for RTF documents this would only lead to more cryptic output. >Do you have any idea how to circumvent this problem? Are you perhaps unfortunate enough to be using RedHat 8 or 9 and Perl 5.8.0, which broke the localisation support quite badly? If so, consider a Perl version upgrade. |
From: Adrian G. <ad...@lo...> - 2004-11-26 12:55:24
|
Hi, I am using HTML-Template not only HTML, but also for RTF templates. It works= great, but I have problems with variables that contain special characters like =E4 =FC =F6 and= the like. Instead of an =E4, html template would insert a few cryptic characters which= seem completely unrelated. For HTML this is of course no problem since I would replace =E4= with ä , but for RTF documents this would only lead to more cryptic output. Do you have any idea how to circumvent this problem? Thanks, =09Adrian Grigore =09 -- Adrian Grigore ad...@lo... Lobstersoft - Fun Brain-Bending Games For All Ages http://www.lobstersoft.com Member of the Association of Shareware Professionals |
From: Kasturirangan R. <kas...@ya...> - 2004-11-26 04:55:52
|
Hi, Thanks to everyone who contributed their inputs. I was able to resolve the issue. Thanks, Sharad --- htm...@li... wrote: > Send Html-template-users mailing list submissions to > htm...@li... > > To subscribe or unsubscribe via the World Wide Web, visit > https://lists.sourceforge.net/lists/listinfo/html-template-users > or, via email, send a message with subject or body 'help' to > htm...@li... > > You can reach the person managing the list at > htm...@li... > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of Html-template-users digest..." > > > Today's Topics: > > 1. Re: Problem accessing directories through .tmpl files (Offer > Kaye) > 2. Re: Problem accessing directories through .tmpl > files (Carl Franks) > > --__--__-- > > Message: 1 > Date: Thu, 25 Nov 2004 08:58:48 +0200 > From: Offer Kaye <off...@gm...> > Reply-To: Offer Kaye <off...@gm...> > To: htm...@li... > Subject: Re: [htmltmpl] Problem accessing directories through .tmpl > files > > On Tue, 23 Nov 2004 20:26:42 -0800 (PST), Kasturirangan Rangaswamy > wrote: > > > > Below are the details (Consider > > ROOT=/usr/local/apache/htdocs/homepages) > > > > Main Perl Script (present in ROOT/software/cgi-bin/sample/) > > > > You need to place the images and CSS files (if you don't supply a > path > for them when calling them) either in ROOT or where your main Perl > script is (i'm unsure - try). This is a matter of logic, not > HTML::Template or <tmpl_include> tags. The final generated HTML is > the > one you are viewing, not the templates, and all paths should be > relative to it, not the template sources. > > Regards, > -- > Offer Kaye > > > --__--__-- > > Message: 2 > Date: Thu, 25 Nov 2004 09:10:42 +0000 > From: "Carl Franks" <C.A...@du...> > To: <htm...@li...> > Subject: Re: [htmltmpl] Problem accessing directories through .tmpl > files > > Sharad, > > The paths to your image files (and css, js, etc) are relative to the > CGI script. The folder that the .tmpl file is in is irrelevant. > Also filesystem paths are irrelevant: it's the website paths you need > to know. > > e.g. if the CGI is at "/cgi-bin/sample/display.pl" > Then the image files must be somewhere inside the "htdocs" folder for > the webserver to be able to serve them. > So if an image is at "/images/pic.jpg", > then the IMG tag source should either be: > src="/images/pic.jpg" > which is an 'absolute' path in relation to the web-root. > or: > src="../../images/pic.jpg" > which is relative to the path of the CGI file. > > Remember, any files referenced from a webpage, such as an image or > css > file, must be within your htdocs folder. > They aren't magically included by the CGI, they are requested by your > browser, and so must be visible to the webserver. > > Hope this helps, > Carl > > > >>> Kasturirangan Rangaswamy <kas...@ya...> 24/11/2004 > 04:26:42 >>> > Hi, > > I have a small Perl Script that calls a .tmpl file A.tmpl. This > .tmpl file has two <TMPL_INCLUDE> statements that include two other > files B.tmpl and C.tmpl. > > Files A,B and C are in the same directory. I am able to display > the > three of them as a single HTML file. No problems till here. > > Now, the B.tmpl and C.tmpl files access images stored in yet > another > directory (NOTE: Also tested by putting them in same directory and > that > is not working either!!!). Those images are not getting displayed. > > Below are the details (Consider > ROOT=/usr/local/apache/htdocs/homepages) > > Main Perl Script (present in ROOT/software/cgi-bin/sample/) > ----------------------------------------------------------------------- > #!/usr/local/bin/perl > > use HTML::Template; > my $template = HTML::Template->new(filename => > "$ENV{DOCUMENT_ROOT}/software/html/Index.tmpl"); > print "Content-Type: text/html\n\n"; > print $template->output; > ----------------------------------------------------------------------- > > Index.tmpl (present in ROOT/software/html/) > ----------------------------------------------------------------------- > <TMPL_INCLUDE top_screen.tmpl> > <TABLE>some table items that do not refer to images/CSS and have not > been included here</TABLE> > <TMPL_INCLUDE bottom_screen.tmpl> > ------------------------------------------------------------------------ > > top_screen.tmpl (present in ROOT/software/html/) > ----------------------------------------------------------------------- > <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> > <!-- saved from url=(0034)http://www.uc.edu/softwareinstall/ --> > <!--- top header included in another file---><HTML><HEAD><TITLE>UCit > - > Software Distribution</TITLE> > <META http-equiv=Content-Type content="text/html; > charset=windows-1252"><LINK > href="main.css" rel=stylesheet> > <META content="MSHTML 6.00.2800.1476" name=GENERATOR></HEAD> > <BODY leftMargin=0 topMargin=0 marginheight="0" marginwidth="0"> > <TABLE cellSpacing=0 cellPadding=0 width=800 border=0> > <TBODY> > <TR> > <TD colspan=3><IMG alt="" > src="banner_software.gif" border=0><IMG > alt="" src="banner_right.gif" > border=0></TD> > </TR> > <TR> > <TD width=616> > <TABLE cellSpacing=0 cellPadding=0 width=616 align=left > border=0> > <TBODY> > <TR> > <TD width=48><IMG height=37 alt="" > src="menu_left_middle.gif" > width=48 border=0></TD> > </TR> > </TABLE> > </TD> > </TR> > </TBODY> > </TABLE> > ----------------------------------------------------------------------- > > bottom_screen.tmpl (present in ROOT/software/html/) > ----------------------------------------------------------------------- > <TABLE cellSpacing=0 cellPadding=0 width=800 border=0> > <TBODY> > <TR> > <TD colSpan=4><BR><IMG height=49 > src="footer.gif" width=800 > useMap=#footer border=0></TD></TR> > </TBODY> > </TABLE> > <!-- > <MAP name=footer><AREA shape=RECT alt=Search coords=34,8,95,39><AREA > shape=RECT alt="Site map" coords=108,8,188,39> > <AREA shape=RECT alt="Contact us" > coords=202,8,293,39 > href="http://www.ucit.uc.edu/contactus.asp"> > <AREA shape=RECT alt="UCit home" coords=305,8,402,39 > href="http://www.ucit.uc.edu/"> > </MAP>--> > > </BODY> > </HTML> > ----------------------------------------------------------------------- > > Though the 3 .tmpl files are getting displayed in one page, > none of the '.gif' or '.css' files in top_screen.tmpl and > bottom_screen.tmpl get displayed. Their actual location is > ROOT/software/images/ but I put them in the same directory as the > .tmpl > files hoping they would work but they don't. > > Any idea why this might be happening? > === message truncated === __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com |
From: Carl F. <C.A...@du...> - 2004-11-25 09:11:18
|
Sharad, The paths to your image files (and css, js, etc) are relative to the CGI script. The folder that the .tmpl file is in is irrelevant. Also filesystem paths are irrelevant: it's the website paths you need to know. e.g. if the CGI is at "/cgi-bin/sample/display.pl" Then the image files must be somewhere inside the "htdocs" folder for the webserver to be able to serve them. So if an image is at "/images/pic.jpg", then the IMG tag source should either be: src="/images/pic.jpg" which is an 'absolute' path in relation to the web-root. or: src="../../images/pic.jpg" which is relative to the path of the CGI file. Remember, any files referenced from a webpage, such as an image or css file, must be within your htdocs folder. They aren't magically included by the CGI, they are requested by your browser, and so must be visible to the webserver. Hope this helps, Carl >>> Kasturirangan Rangaswamy <kas...@ya...> 24/11/2004 04:26:42 >>> Hi, I have a small Perl Script that calls a .tmpl file A.tmpl. This .tmpl file has two <TMPL_INCLUDE> statements that include two other files B.tmpl and C.tmpl. Files A,B and C are in the same directory. I am able to display the three of them as a single HTML file. No problems till here. Now, the B.tmpl and C.tmpl files access images stored in yet another directory (NOTE: Also tested by putting them in same directory and that is not working either!!!). Those images are not getting displayed. Below are the details (Consider ROOT=/usr/local/apache/htdocs/homepages) Main Perl Script (present in ROOT/software/cgi-bin/sample/) ----------------------------------------------------------------------- #!/usr/local/bin/perl use HTML::Template; my $template = HTML::Template->new(filename => "$ENV{DOCUMENT_ROOT}/software/html/Index.tmpl"); print "Content-Type: text/html\n\n"; print $template->output; ----------------------------------------------------------------------- Index.tmpl (present in ROOT/software/html/) ----------------------------------------------------------------------- <TMPL_INCLUDE top_screen.tmpl> <TABLE>some table items that do not refer to images/CSS and have not been included here</TABLE> <TMPL_INCLUDE bottom_screen.tmpl> ------------------------------------------------------------------------ top_screen.tmpl (present in ROOT/software/html/) ----------------------------------------------------------------------- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <!-- saved from url=(0034)http://www.uc.edu/softwareinstall/ --> <!--- top header included in another file---><HTML><HEAD><TITLE>UCit - Software Distribution</TITLE> <META http-equiv=Content-Type content="text/html; charset=windows-1252"><LINK href="main.css" rel=stylesheet> <META content="MSHTML 6.00.2800.1476" name=GENERATOR></HEAD> <BODY leftMargin=0 topMargin=0 marginheight="0" marginwidth="0"> <TABLE cellSpacing=0 cellPadding=0 width=800 border=0> <TBODY> <TR> <TD colspan=3><IMG alt="" src="banner_software.gif" border=0><IMG alt="" src="banner_right.gif" border=0></TD> </TR> <TR> <TD width=616> <TABLE cellSpacing=0 cellPadding=0 width=616 align=left border=0> <TBODY> <TR> <TD width=48><IMG height=37 alt="" src="menu_left_middle.gif" width=48 border=0></TD> </TR> </TABLE> </TD> </TR> </TBODY> </TABLE> ----------------------------------------------------------------------- bottom_screen.tmpl (present in ROOT/software/html/) ----------------------------------------------------------------------- <TABLE cellSpacing=0 cellPadding=0 width=800 border=0> <TBODY> <TR> <TD colSpan=4><BR><IMG height=49 src="footer.gif" width=800 useMap=#footer border=0></TD></TR> </TBODY> </TABLE> <!-- <MAP name=footer><AREA shape=RECT alt=Search coords=34,8,95,39><AREA shape=RECT alt="Site map" coords=108,8,188,39> <AREA shape=RECT alt="Contact us" coords=202,8,293,39 href="http://www.ucit.uc.edu/contactus.asp"> <AREA shape=RECT alt="UCit home" coords=305,8,402,39 href="http://www.ucit.uc.edu/"> </MAP>--> </BODY> </HTML> ----------------------------------------------------------------------- Though the 3 .tmpl files are getting displayed in one page, none of the '.gif' or '.css' files in top_screen.tmpl and bottom_screen.tmpl get displayed. Their actual location is ROOT/software/images/ but I put them in the same directory as the .tmpl files hoping they would work but they don't. Any idea why this might be happening? Thanks, Sharad __________________________________ Do you Yahoo!? Take Yahoo! Mail with you! Get it on your mobile phone. http://mobile.yahoo.com/maildemo ------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://productguide.itmanagersjournal.com/ _______________________________________________ Html-template-users mailing list Htm...@li... https://lists.sourceforge.net/lists/listinfo/html-template-users |
From: Offer K. <off...@gm...> - 2004-11-25 06:58:55
|
On Tue, 23 Nov 2004 20:26:42 -0800 (PST), Kasturirangan Rangaswamy wrote: > > Below are the details (Consider > ROOT=/usr/local/apache/htdocs/homepages) > > Main Perl Script (present in ROOT/software/cgi-bin/sample/) > You need to place the images and CSS files (if you don't supply a path for them when calling them) either in ROOT or where your main Perl script is (i'm unsure - try). This is a matter of logic, not HTML::Template or <tmpl_include> tags. The final generated HTML is the one you are viewing, not the templates, and all paths should be relative to it, not the template sources. Regards, -- Offer Kaye |
From: Karen C. <kar...@gm...> - 2004-11-25 03:35:44
|
On Tue, 23 Nov 2004 20:26:42 -0800 (PST), Kasturirangan Rangaswamy <kas...@ya...> wrote: > Now, the B.tmpl and C.tmpl files access images stored in yet another > directory (NOTE: Also tested by putting them in same directory and that > is not working either!!!). Those images are not getting displayed. That doesn't sound like an H::T problem... the template isn't what's going to give your browser the graphics files, unless you're doing something very different from what it looks like. The template is just presenting the HTML portion to the browser. The browser then parses the HTML and requests the graphics files from the web server (if it chooses to). This happens in separate HTTP requests. If the graphics don't come up, it either means your template has the wrong URL in it, or you need to look at the permissions and paths of your web server. |
From: Roger B. W. <ro...@fi...> - 2004-11-25 01:20:11
|
On Tue, Nov 23, 2004 at 08:26:42PM -0800, Kasturirangan Rangaswamy wrote: > Now, the B.tmpl and C.tmpl files access images stored in yet another >directory (NOTE: Also tested by putting them in same directory and that >is not working either!!!). Those images are not getting displayed. The img src elements are like img src elements anywhere else in HTML - HTML::Template doesn't treat them specially. Just use them as you would when composing a static page. Roger |
From: Kasturirangan R. <kas...@ya...> - 2004-11-24 04:42:29
|
Hi, I have a small Perl Script that calls a .tmpl file A.tmpl. This .tmpl file has two <TMPL_INCLUDE> statements that include two other files B.tmpl and C.tmpl. Files A,B and C are in the same directory. I am able to display the three of them as a single HTML file. No problems till here. Now, the B.tmpl and C.tmpl files access images stored in yet another directory (NOTE: Also tested by putting them in same directory and that is not working either!!!). Those images are not getting displayed. Below are the details (Consider ROOT=/usr/local/apache/htdocs/homepages) Main Perl Script (present in ROOT/software/cgi-bin/sample/) ----------------------------------------------------------------------- #!/usr/local/bin/perl use HTML::Template; my $template = HTML::Template->new(filename => "$ENV{DOCUMENT_ROOT}/software/html/Index.tmpl"); print "Content-Type: text/html\n\n"; print $template->output; ----------------------------------------------------------------------- Index.tmpl (present in ROOT/software/html/) ----------------------------------------------------------------------- <TMPL_INCLUDE top_screen.tmpl> <TABLE>some table items that do not refer to images/CSS and have not been included here</TABLE> <TMPL_INCLUDE bottom_screen.tmpl> ------------------------------------------------------------------------ top_screen.tmpl (present in ROOT/software/html/) ----------------------------------------------------------------------- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <!-- saved from url=(0034)http://www.uc.edu/softwareinstall/ --> <!--- top header included in another file---><HTML><HEAD><TITLE>UCit - Software Distribution</TITLE> <META http-equiv=Content-Type content="text/html; charset=windows-1252"><LINK href="main.css" rel=stylesheet> <META content="MSHTML 6.00.2800.1476" name=GENERATOR></HEAD> <BODY leftMargin=0 topMargin=0 marginheight="0" marginwidth="0"> <TABLE cellSpacing=0 cellPadding=0 width=800 border=0> <TBODY> <TR> <TD colspan=3><IMG alt="" src="banner_software.gif" border=0><IMG alt="" src="banner_right.gif" border=0></TD> </TR> <TR> <TD width=616> <TABLE cellSpacing=0 cellPadding=0 width=616 align=left border=0> <TBODY> <TR> <TD width=48><IMG height=37 alt="" src="menu_left_middle.gif" width=48 border=0></TD> </TR> </TABLE> </TD> </TR> </TBODY> </TABLE> ----------------------------------------------------------------------- bottom_screen.tmpl (present in ROOT/software/html/) ----------------------------------------------------------------------- <TABLE cellSpacing=0 cellPadding=0 width=800 border=0> <TBODY> <TR> <TD colSpan=4><BR><IMG height=49 src="footer.gif" width=800 useMap=#footer border=0></TD></TR> </TBODY> </TABLE> <!-- <MAP name=footer><AREA shape=RECT alt=Search coords=34,8,95,39><AREA shape=RECT alt="Site map" coords=108,8,188,39> <AREA shape=RECT alt="Contact us" coords=202,8,293,39 href="http://www.ucit.uc.edu/contactus.asp"> <AREA shape=RECT alt="UCit home" coords=305,8,402,39 href="http://www.ucit.uc.edu/"> </MAP>--> </BODY> </HTML> ----------------------------------------------------------------------- Though the 3 .tmpl files are getting displayed in one page, none of the '.gif' or '.css' files in top_screen.tmpl and bottom_screen.tmpl get displayed. Their actual location is ROOT/software/images/ but I put them in the same directory as the .tmpl files hoping they would work but they don't. Any idea why this might be happening? Thanks, Sharad __________________________________ Do you Yahoo!? Take Yahoo! Mail with you! Get it on your mobile phone. http://mobile.yahoo.com/maildemo |
From: Keith J. <kja...@ey...> - 2004-11-22 21:11:31
|
To get around that problem, we use a filter that translates virtual includes into tmpl_includes. This way the includes work with or without running them through a perl app. The filter is: sub filter { $text_ref = shift; ${$text_ref} =~ s/<!--\s*#include virtual="[\/]?(.+?)"\s*-->/<TMPL_INCLUDE NAME="$1">/ig; } On Mon, 2004-11-22 at 15:45, Kasturirangan Rangaswamy wrote: > Jason, > > Thanks a lot. Actually, I had tried that first (forgot to include > in my post). > > Anyway, I think I have solved the problem. Being the novice that I > am, I had forgotten that I need to access any .tmpl page through a .pl > script to make use of any <TMPL_> tags. > > I was trying to directly open the .tmpl file on my browser and > that was causing the <TMPL_INCLUDE> to not work. > > Thanks, > Sharad > > --- Jason Purdy <ja...@jo...> wrote: > > > Kasturirangan Rangaswamy wrote: > > > > > Index.tmpl > > > > > > ----------------------------------------------------------------------- > > > <TMPL_INCLUDE top_screen.tmpl> > > > > I think the problem is this line ... try this instead: > > > > <TMPL_INCLUDE NAME="top_screen.tmpl"> > > > > Cheers, > > > > Jason > > > > > > > __________________________________ > Do you Yahoo!? > Meet the all-new My Yahoo! - Try it today! > http://my.yahoo.com > > > > > ------------------------------------------------------- > SF email is sponsored by - The IT Product Guide > Read honest & candid reviews on hundreds of IT Products from real users. > Discover which products truly live up to the hype. Start reading now. > http://productguide.itmanagersjournal.com/ > _______________________________________________ > Html-template-users mailing list > Htm...@li... > https://lists.sourceforge.net/lists/listinfo/html-template-users -- Keith Jackson <kja...@ey...> |
From: Kasturirangan R. <kas...@ya...> - 2004-11-22 20:46:08
|
Jason, Thanks a lot. Actually, I had tried that first (forgot to include in my post). Anyway, I think I have solved the problem. Being the novice that I am, I had forgotten that I need to access any .tmpl page through a .pl script to make use of any <TMPL_> tags. I was trying to directly open the .tmpl file on my browser and that was causing the <TMPL_INCLUDE> to not work. Thanks, Sharad --- Jason Purdy <ja...@jo...> wrote: > Kasturirangan Rangaswamy wrote: > > > Index.tmpl > > > ----------------------------------------------------------------------- > > <TMPL_INCLUDE top_screen.tmpl> > > I think the problem is this line ... try this instead: > > <TMPL_INCLUDE NAME="top_screen.tmpl"> > > Cheers, > > Jason > __________________________________ Do you Yahoo!? Meet the all-new My Yahoo! - Try it today! http://my.yahoo.com |
From: Jason P. <ja...@jo...> - 2004-11-22 20:32:58
|
Kasturirangan Rangaswamy wrote: > Index.tmpl > ----------------------------------------------------------------------- > <TMPL_INCLUDE top_screen.tmpl> I think the problem is this line ... try this instead: <TMPL_INCLUDE NAME="top_screen.tmpl"> Cheers, Jason |
From: Kasturirangan R. <kas...@ya...> - 2004-11-22 20:27:55
|
Hi, I am totally new to HTML::Template so kindly bear with me. I already tried seeking out an answer to this question but could not find one. This seems a trivial question but for a newbie like me, it might as well be the ultimate conundrum! I have 2 static HTML template files called top_screen.tmpl and bottom_screen.tmpl that I wish to include in every other template file. I tried a static inclusion to see if I got a hang of the situation but that simply does not work. I only get to see the "middle" page without the header and the footer. I am pasting below the 3 files I used top_screen.tmpl -----------------------------------------------------------------------<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <!-- saved from url=(0034)http://www.uc.edu/softwareinstall/ --> <!--- top header included in another file---><HTML><HEAD><TITLE>UCit - Software Distribution</TITLE> <META http-equiv=Content-Type content="text/html; charset=windows-1252"><LINK href="images/main.css" rel=stylesheet> <META content="MSHTML 6.00.2800.1476" name=GENERATOR></HEAD> <BODY leftMargin=0 topMargin=0 marginheight="0" marginwidth="0"> <TABLE cellSpacing=0 cellPadding=0 width=800 border=0> <TBODY> <TR> <TD colSpan=3><IMG alt="" src="images/banner_left_middle.gif" border=0><IMG alt="" src="images/banner_software.gif" border=0><IMG alt="" src="images/banner_right.gif" border=0></TD> </TR> <TR> <TD width=616> <TABLE cellSpacing=0 cellPadding=0 width=616 align=left border=0> <TBODY> <TR> <TD width=48><IMG height=37 alt="" src="images/menu_left_middle.gif" width=48 border=0></TD> <TD align=right width=68><IMG height=37 alt="" src="images/menu_right.gif" width=68 border=0></TD></TR></TBODY></TABLE></TD> </TR> </TABLE> </TD> </TR> </TBODY> </TABLE> ----------------------------------------------------------------------- bottom_screen.tmpl ----------------------------------------------------------------------- <TABLE cellSpacing=0 cellPadding=0 width=800 border=0> <TBODY> <TR> <TD colSpan=4><BR><IMG height=49 src="images/footer.gif" width=800 useMap=#footer border=0></TD></TR> </TBODY> </TABLE> <!-- <MAP name=footer><AREA shape=RECT alt=Search coords=34,8,95,39><AREA shape=RECT alt="Site map" coords=108,8,188,39> <AREA shape=RECT alt="Contact us" coords=202,8,293,39 href="http://www.ucit.uc.edu/contactus.asp"> <AREA shape=RECT alt="UCit home" coords=305,8,402,39 href="http://www.ucit.uc.edu/"> </MAP>--> </BODY> </HTML> ----------------------------------------------------------------------- Index.tmpl ----------------------------------------------------------------------- <TMPL_INCLUDE top_screen.tmpl> <TABLE cellSpacing=0 cellPadding=0 width=800 border=0> <TBODY> <TR><TD> <TABLE cellSpacing=0 cellPadding=0 width=616 align=left border=0> <TBODY> <TR> <TD align=center width=490><BR><H3>Welcome to the Software Distribution System</H3> </TD> </TR> <TR> <TD align=center width=490><BR><a href="Data Entry Module/data_entry1.html" >Click here to go to the Data Entry Module</a> </TD> </TR> <TR> <TD align=center width=490><BR><a href="Administration Module/main_admin_screen.html" >Click here to go to the Administration Modul e</a> </TD> </TR> <TR> <TD align=center width=490><BR><a href="" >Click here to go to the Reports Module</a> </TD> </TR> <TR> <TD align=center width=490><BR><a href="" >Click here to go to the Search Module</a> </TD> </TR> </TBODY> </TABLE> </TD></TR> </TABLE> <TMPL_INCLUDE bottom_screen.tmpl> ----------------------------------------------------------------------- Please note that I have individually tested these screens with a .html extension and they appeared OK. If you want to test these out, you wont get any of the images and I am sorry about that. I dont wish to include the images and bloat this post as those are not germane to this discussion. Any help is appreciated. Does HTML::Template also need SSI(server-side-include) enabled on Apache?. Is that why this might not be working? Thanks, Sharad __________________________________ Do you Yahoo!? Meet the all-new My Yahoo! - Try it today! http://my.yahoo.com |
From: Sam T. <sa...@tr...> - 2004-11-22 19:02:08
|
On Mon, 22 Nov 2004, Tim Howell wrote: > I've very recently begun using HTML::Template::JIT to eke some > additional speed out of several fairly complex applications I have. > This morning users of a couple of those applications received messages > like the following: > > Can't locate object method "output" via package > "tmpl_5508c265bab21c4e12849a4621e9849a" > > Any ideas what causes that? Nope. What version? Can you replicate this in a test script? -sam |
From: Tim H. <ti...@fe...> - 2004-11-22 18:35:43
|
I've very recently begun using HTML::Template::JIT to eke some additional speed out of several fairly complex applications I have. This morning users of a couple of those applications received messages like the following: Can't locate object method "output" via package "tmpl_5508c265bab21c4e12849a4621e9849a" Any ideas what causes that? Thanks! =3D) --TWH |
From: Michael L. <mi...@go...> - 2004-11-19 18:56:08
|
Sam, et all: I would like to write a patch to allow single XHTML / HTML compliant variable substitutions. Any chance something like this would get implemented? I have used {%var_name%}, implemented as a filter for quite some time. Currently it is impossible to add vars inside HTML tags and validate the HTML. Also you cannot edit templates in wysiwyg mode without pre/post processing. This doesn't really matter as much with the looping and logic constructs = as HTML comment style tags work okay here. Thanks, Mike Some comments from the message forum follow -------------------------------------------------------------------------= --- By: Chris Burbridge - chrisburbridge Variable syntax =A0=20 2000-05-21 02:03=20 I used HTML::Template for a project earlier this year, and I was very = happy with it. The only thing I would suggest is, some people might prefer a different delimeter for the syntax, than the "<" + ">" ones -- the = problem for me is, the designer [I would be working with] cannot see the current placeholders when the view it in a browser.=A0 =A0 My suggestion is simply to have this be configurable--simply allow the option of setting start and end delims. to a desired string. Then this = would work for everybody.=A0 =A0 Thanks. By: Andrey Melnikov - nimnul RE: Variable syntax =A0=20 2001-03-04 08:34=20 Maybe it would be better to make special debug perl-script which will replace all "<TMPL_VAR xxx>" to TMPL_VAR xxx and show the result in the browser.=A0 =A0 I could attach this script as a handler for *.tmpl and to view the = templates correctly din the browser:=A0 =A0 http://localhost/xxx.tmpl By: Michael Lloyd - mwlloyd RE: Variable syntax =A0=20 2004-11-19 13:44=20 I have run into this problem for a number of different reasons, = including XHTML HTML validation, wysiwyg editing, and many other more site = specific ones.=A0 =A0 I am using {%var_name%} and writing a regular expression, but I think = this would be a major improvement.=A0 |
From: Kevin S. <kev...@gm...> - 2004-11-10 04:49:45
|
On Tue, 09 Nov 2004 14:25:44 -0600, Brad Cathey <bra...@hi...> wrote: > H::T is not returning any errors. Could it be a corrupt .tmpl file? If so, > how would I know? When you say that H::T is not returning any errors are you looking in Apache's error_log to verify? -- Kev. |