473,325 Members | 2,870 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,325 software developers and data experts.

Generating html tables on the fly

I am trying to scavange a example script I found on the web. The aubroutine
is below. Basically I want to extract data from a sql db then generate a
table of values on the fly. The script below keeps generating a malformed
header error

sub gen_table {
my $array_ref=query_data('%Ave%');

my @headings = ('id no.','street no.','street name','city');
my @rows = th(\@headings);
foreach my $row_array (@$array_ref) {
my ($id,$str_no,$str_name,$city) = @$row_array;
push(@rows,"td([$id,$str_no,$str_name,$city])");
}
print table({-border=>undef,-width=>'25%'},
caption(b('Wow. I can multiply!')),
Tr(\@rows)
);

}
Jul 19 '05 #1
0 1552

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

17
by: flupke | last post by:
Hi, i create my GUIs mainly via wxGlade. However when you start of to program and want to do some rearranging to the gui, wxglade overwrites your file and you've got to put your own code back...
11
by: annie | last post by:
Hello all. I am writing an XSL stylesheet that automatically converts a page with frames to a noframes equivalent of this page, using tables. I can get the positioning of each frame write in the...
5
by: shauldar | last post by:
Is there a way (tool, hack...) to create an XSL:FO from an XSLT + XML files? My motivation is that we want to use a tool to design reports, and from that "design" generate both HTML (via XSLT)...
12
by: Martin_Hurst | last post by:
Has some one come up with a similar type script that could be used in a Postgresql database? The script below was created for a SQLServer database. Thx, -Martin ...
0
by: Raghavendra | last post by:
hi, we r using forms authetication. problem :- i am using the below code to generate excel report but since we r using forms authetication.. after generating excel report the browser directs...
1
by: Ryan Ginstrom | last post by:
I have been maintaining a body of documentation in plain HTML files. I would now like to automate the generation of the HTML files. Maintaining the HTML files now is tedious and error prone,...
2
by: Simon Wittber | last post by:
I'm building a web application using sqlalchemy in my db layer. Some of the tables require single integer primary keys which might be exposed in some parts of the web interface. If users can...
0
by: srk | last post by:
hi to all, i need some help , my problem is that i have to generate a word document withe the data from data base and it should be displayed as tables in word and i have to insert some header and...
0
by: =?Utf-8?B?U2hhcm9u?= | last post by:
Hello Gurus, I produced an RDLC file with 3 tables. My application holds a DataSet with 3 kind of tables. I'm generating Visual Studio 2005 report for the 3 tables in the DataSet. I'm using the...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.