Gossamer Forum
Quote Reply
QUOTES
<input type=hidden name=Description value="Here goes my description, but when "I use quotes" in this field nothing appears after the quotes, I have tried every possible thing but nothing is happening. PLLLLZZZ HELP">



in the perl script:

$Description =~ s/\n/<br>/g;
$Description =~ s/&quot;/"/g;

I have alos tried like this:
$Description =~ s/"/&quot;/g;

print NEWFILE "$Description\n";



Nothing is printed in the NEWFILE after the point " " are used. i.e.

it will be printed like this:

Here goes my description, but when ....NOTHING AFTER THIS

----- I have also tried all these possible options.......


$Description =~
s/"/\&quot\;/g;
$Description =~
s/\"/&quot;/g;
$Description =~
s/\"/\&quot\;/g;
$Description =~
s/"/&quot;/g;
$Description =~
s/&quot;/"/g;
$Description =~
s/\&quot\;/"/g;
$Description =~
s/\&quot\;/\"/g;
$Description =~
s/&quot;/\"/g;

BUT NOTHING IS WORKING? ANY HELP? is it something to do with hidden input or what is it.

Last edited by:

zeshan: Apr 7, 2003, 3:03 PM
Quote Reply
Re: [zeshan] QUOTES In reply to
Is this related to DBMAN?

If so an answer has been posted in the DBMAN forum.
Quote Reply
Re: [Paul] QUOTES In reply to
Its not related to DBMan at all. If it would have been I haven't asked this question on perl board, I would rather have asked it on DBMan Board.

In the meantime I have also tried this option, but it looks like I am totally stuck.

$Description =~
s/\"/\\\"/g;

It's not working also.

Thanks for your help in advance.

Zeshan.
Quote Reply
Re: [zeshan] QUOTES In reply to
If you are using quotes inside quotes in your html, then anything you add in the perl code will have no effect as the Description field will already be chopped in half by the time it is parsed by your cgi script.

You need to escape the quotes in your html to solve it, or change your value=" " to value=' '

Last edited by:

Paul: Apr 7, 2003, 3:54 PM
Quote Reply
Re: [Paul] QUOTES In reply to
Okay buddy thanks,

I have changed my values in the html <input type=hidden value='in single quote' rahter than value="double quotes"

so it worked.

Thanks a lot for your help Paul. I really appreciate your help, I needed it.

Zeshan.