Gossamer Forum
Home : Products : DBMan : Customization :

showing spaces in textbox

Quote Reply
showing spaces in textbox
I installed the mod spam-buster-private-mailer and I want the show the 'Title' in the subject textbox( with $rec{'Title'}. If the title is 1 word there is no problem. If the Title consist of more then 1 word it only shows the first word and that's it. It stops showing the title after the first space. I used other fields with spaces and they show up alright if the are not in a textbox.

It would be nice to show the entire title with the spaces, How can I do that without entering underscore's between the words in the title? Is there a workaround?
Quote Reply
Re: [Foton] showing spaces in textbox In reply to
I'm not sure I understand whether you are referring to setting up the fields in your .cfg file or the display of the fields?

In your .cfg file you don't have to add an underscore between two word field names if you enclose them in single quotes such as:

'First Name' => [ 4,'alpha',40,50,1,'',''],
'Last Name' => [ 5,'alpha',40,50,1,'',''],

or for a textarea:

'Description text' => [ 6,'alpha','50x45',2000,1,'',''],

If all of the text is not appearing in your display perhaps you need to increase the number of characters allowed within that field.

Hope this helps

Unoffical DBMan FAQ

http://creativecomputingweb.com/dbman/index.shtml/
Quote Reply
Re: [LoisC] showing spaces in textbox In reply to
Hi LoisC,

Sorry I did not make myself clear enough;

In the 'Send an email' form I want to put the rec{'Title'} as the subject, so they do not have to enter it again. But they could change it if they would like to. If the Title is "abcdefghijklmnopqrstuvwxyz" then the complete word displays in the textbox. But when the Title is "abcd efghijk lmnop qrs tuvw xyz" then the field only shows the "abcd" and no more.

So I want to display the $rec{'Title'} in the subject-textbox in the send-an-email form.

Thanks
Quote Reply
Re: [Foton] showing spaces in textbox In reply to
Hi,

I found the error/typo;

I had:

<input type=text name="subject" value=$rec{'Title'} size=40>

but it should be:

<input type=text name="subject" value="$rec{'Title'}" size=40>

The difference are the 2 quotes "..." around the $rec (ofcourse)

Thanks for thinking over this problem!