fitting <textbox> input into DDS fixed length fields
Posted: Wed Nov 05, 2008 7:26 am
I have an HTML textboox (say 60 columns * 5 lines = 300 characters) that I want to write to 5 X 60-character fields in a set of 5 X 60 fixed length character fields.
My first inclination was to substring 60 character increments of the returned text.
But this won't work because textboxes do some funky word wrapping and HTML sucks out extra spaces. Then I started to figure out last full word and add back extra spaces but that is getting messy.
Anyone have a better HTML/PHP approach too this?
(And don't tell me to change the field to VARCHAR(300) or something like that. This file is used by 50+ programs on a green screen application that is over 20 years old)
My first inclination was to substring 60 character increments of the returned text.
But this won't work because textboxes do some funky word wrapping and HTML sucks out extra spaces. Then I started to figure out last full word and add back extra spaces but that is getting messy.
Anyone have a better HTML/PHP approach too this?
(And don't tell me to change the field to VARCHAR(300) or something like that. This file is used by 50+ programs on a green screen application that is over 20 years old)