Gossamer Forum
Home : Products : DBMan : Installation :

Text wrap in "Description" output field

Quote Reply
Text wrap in "Description" output field
Hi all,

I searched the databse looking for messages on this but couldn't find one. Basically when someone enters several lines of text in the description field, it shows up in search results as one really long horizontal line (no returns). I've tried fixing the cell width in html.pl but it makes no difference. I have a feeling it's some simple HTML field parameter I am unaware of. Ideas? Thanks in advance for any suggestions!
Quote Reply
Re: Text wrap in "Description" output field In reply to
cfb,

In html.pl file, underneath the sub html_record { subroutine,
right after my (%rec) = @_;

add this line:
$rec{'Description'} =~ s/\n/<br>/g;

[This message has been edited by Katana Man (edited February 04, 1999).]
Quote Reply
Re: Text wrap in "Description" output field In reply to
Are you using a textarea to display the results in the search field? If so, you don't need to. Just use the variable in a cell. If you have any spaces at all in the text, it should wrap just fine.

If you want to include line feeds, you'll need to do a little adjusting of things. At the beginning of html_record, just after

my (%rec) = @_;

add a line:

$rec{'Field'} =~ s/\n/<br>/g;

replacing, of course, "Field" with the name of your field.


------------------
JPD
Quote Reply
Re: Text wrap in "Description" output field In reply to
A wrap parameter supporting different values should be used with TEXTAREA to achieve what you are looking for. The tag should be:

<TEXTAREA WRAP=PHYSICAL>

To you and all people searching infos on HTML, I suggest to downlad a freeware named HTMLlib.exe (V4.x), a very nice tool !

This tool is necessary because, for example, the WRAP parameters were changed with Netscape Navigator 4.X and IE 4.X and now you should use HARD as parameter instead of PHYSICAL !

Bye now,
Germinator


[This message has been edited by Germinator (edited February 04, 1999).]

[This message has been edited by Germinator (edited February 04, 1999).]
Quote Reply
Re: Text wrap in "Description" output field In reply to
Eureka, it's fixed! Thanks a lot to everyone for all the suggestions!

CFB