Re: how to generate html table from "table" data?

2007-12-28 Thread Bruno Desthuilliers
Ricardo Aráoz a écrit : > Bruno Desthuilliers wrote: (snip) >> FWIW, I just wrote a function generating an html table from a list >> of header and a list of rows. I wrote the most Q&D, straightforward, >> braindead way, it's 17 lines long, doesn't even need an import >> statement, and took me le

Re: how to generate html table from "table" data?

2007-12-27 Thread Ricardo Aráoz
Bruno Desthuilliers wrote: > [EMAIL PROTECTED] a écrit : > > Vasudev Ram wrote: >>> Why not try writing your own code for this first? >>> If nothing else, it'll help you learn more, and may also help you >>> understand better, the other options. >>> >> Thanks for your reply even it was not really

Re: how to generate html table from "table" data?

2007-12-26 Thread petr . jakes . tpc
Dennis, Thank you very much for your code snippet. I will try to install CherryTemplate and use it. I did not work with any template tool before and I am not the * class programmer as other people here, so my questions maybe look "strange" or "stup..". I didn't mean to offend somebody here an

Re: how to generate html table from "table" data?

2007-12-26 Thread Bruno Desthuilliers
[EMAIL PROTECTED] a écrit : > Vasudev Ram wrote: >>Why not try writing your own code for this first? >>If nothing else, it'll help you learn more, and may also help you >>understand better, the other options. >> > > Thanks for your reply even it was not really helpful. The answers boil down to:

Re: how to generate html table from "table" data?

2007-12-26 Thread petr . jakes . tpc
> > Why not try writing your own code for this first? > If nothing else, it'll help you learn more, and may also help you > understand better, the other options. > > Vasudev Ram Thanks for your reply even it was not really helpful. Of course some attempts to generate htm

Re: how to generate html table from "table" data?

2007-12-26 Thread vasudevram
> [EMAIL PROTECTED] a écrit : > > > Hi group, > > I would like to convert the output of the SQL query, or more generally > > I would like to convert any "table" data to the html table. > > > I would like to set some rules to format cells, columns or rows (font, > > colour etc.) of the html table, a

Re: how to generate html table from "table" data?

2007-12-26 Thread Bruno Desthuilliers
[EMAIL PROTECTED] a écrit : > Hi group, > I would like to convert the output of the SQL query, or more generally > I would like to convert any "table" data to the html table. There's MoreThanOneWayToDoIt... from simple string formatting to a full-blown template engine. > I would like to set some

how to generate html table from "table" data?

2007-12-25 Thread petr . jakes . tpc
Hi group, I would like to convert the output of the SQL query, or more generally I would like to convert any "table" data to the html table. I would like to set some rules to format cells, columns or rows (font, colour etc.) of the html table, according to the values in the specific cells. Googl

Re: generate HTML

2005-11-15 Thread s99999999s2003
thanks i will check out the example you have given.actually my html output is a bit dynamic in the sense that i may have different number of rows depending on some inputs. so i am putting everything into a list and using 'extend' to append to that list for every dynamically generated rows using for

Re: generate HTML

2005-11-15 Thread Thomas Guettler
Am Tue, 15 Nov 2005 02:52:54 -0800 schrieb ss2003: > alist = [ ' > ValueError: unsupported format character '"' (0x22) at index 14 Look at this: ===> python Python 2.3.4 (#1, Feb 7 2005, 15:50:45) [GCC 3.3.4 (pre 3.3.5 20040809)] on linux2 Type "help", "copyright", "credits" or "li

Re: generate HTML

2005-11-15 Thread Kent Johnson
Jim wrote: > Perhaps you are trying to do this: > 'text to go here: %s' % ('text',) > ? For that you need a double-quoted string: > "text to go here: %s" % ('text',) Uh, no, not in Python: >>> 'text to go here: %s' % ('text',) 'text to go here: text' >>> "text to go here: %s" % ('text',) 't

Re: generate HTML

2005-11-15 Thread Jim
Perhaps you are trying to do this: 'text to go here: %s' % ('text',) ? For that you need a double-quoted string: "text to go here: %s" % ('text',) (or triple-doubles: """ .. """ as you noted). Jim -- http://mail.python.org/mailman/listinfo/python-list

Re: generate HTML

2005-11-15 Thread s99999999s2003
hi thanks for all the help actually i am doing it the hard way alist = [ 'TEST', '', 'blah' ] f = open('test.html",'w') f.writelines(alist) f.close() but everytime i hit ... alist = [ ' ValueError: unsupported format character '"' (0x22) at index 14 what does it mean? i tried alist = [ 'TE

Re: generate HTML

2005-11-14 Thread Scott David Daniels
Jeffrey Schwab wrote: > [EMAIL PROTECTED] wrote: ... >> def genpage(arg1,arg2): >>print ''' BLAH BLAH.%s %s >> ''' % (arg1, arg2) ... >> i wish to print all these into a HTML output file so that >> when i click on it, it shows me the html page. How can i do that? > ... > Why

Re: generate HTML

2005-11-14 Thread Jeffrey Schwab
[EMAIL PROTECTED] wrote: > hi > i have fucntion that generates a HTML page > > def genpage(arg1,arg2): >print ''' BLAH BLAH.%s %s > ''' % (arg1, arg2) > >print ''' blah blah... %s %s > > ''' % (arg1,arg2)' > > The func is something like that, alot of open'''

generate HTML

2005-11-14 Thread s99999999s2003
hi i have fucntion that generates a HTML page def genpage(arg1,arg2): print ''' BLAH BLAH.%s %s ''' % (arg1, arg2) print ''' blah blah... %s %s ''' % (arg1,arg2)' The func is something like that, alot of open''' and closing ''' triple quotes. anyway, i wish to

Re: generate HTML

2005-11-14 Thread Richie Hindle
[ss2003] > I am stuck at above after doing a lot of f.write for every line of HTML > . Any betterways to do this in python? See the "Templating Engines" section of http://wiki.python.org/moin/WebProgramming - I hope you have a few hours to spare! 8-) -- Richie Hindle [EMAIL PROTECTED]

Re: How can I use PyDoc to generate html file (modul in directory d)

2005-01-31 Thread [EMAIL PROTECTED]
Hello all, I finaly find the solution, but please share yours if you have different way to do it. Theories: PyDoc menu can only search the module in directory when it was first called and in python directory for example c:\python24. So I have to call PyDoc in my module directory. It would be nec

How can I use PyDoc to generate html file (modul in directory d)

2005-01-31 Thread [EMAIL PROTECTED]
Hello How can I use PyDoc to generate html file when my file.py is in other directory. Sincerely Yours, Pujo -- http://mail.python.org/mailman/listinfo/python-list