adjacent fields on the same row

1 view
Skip to first unread message

gazza

unread,
Jan 3, 2010, 5:54:45 PM1/3/10
to pylons-discuss
Hello,

I'm using the h.field to represent fields on the html

${h.field(
"card Expiration Month",
h.select("cardExpirationMonth","initial
value",c.credexpiremonths),
)}

${h.field(
"card Expiration Year
h.select("cardExpirationYearnitial value",c.credexpireyears),
)}

This renders:

card Expiration Month [ ]
card Expiration Year [ ]

I would like to represent the data as

card expiration [07] [2010]


I dont know how to put the h.fields on the same row? I know I could
use table in html just thought is there
a way to accomplish this in pylons?

Thanks,
garyc

Paweł Stradomski

unread,
Jan 3, 2010, 7:17:44 PM1/3/10
to pylons-...@googlegroups.com
W liście gazza z dnia niedziela 03 stycznia 2010:

> Hello,
>
> I'm using the h.field to represent fields on the html
>
> I dont know how to put the h.fields on the same row? I know I could
> use table in html just thought is there
> a way to accomplish this in pylons?

h.field got removed in 0.6.4, wasn't it?

Anyway, you can just lay it out yourself - and use CSS instead of tables.
You could probably mimic the HTML code as being output by the field helper.
Consult the source for details
http://hg.splee.co.uk/webhelpers/src/31e6eed7a527/webhelpers/html/form_layout.py

--
Paweł Stradomski

Reply all
Reply to author
Forward
0 new messages