You are here: quotes in textarea « PHP Programming Language « IT news, forums, messages
quotes in textarea

Posted by Ja NE on 10/25/05 15:39

and new problem... buit this time I haven't found solution in some
manual...

problem: I would like to allow <a href="link"> tag, but I'm having
problems in hidden field when checking message:

situation:

(STAGE 1 = typing <a href="link">message</a>)
<form method="post">
<textarea name="message"></textarea>
</form>

(STAGE 2 = checking message, my wish)
$message = $_POST['message']
<p>Is following correct?<p>
<p>typing <a href="link">message</a></p>
<form method="post">
<input type="hidden" name="message" value="message">
</form>

(STAGE 2 = checking message, my problem) <----!
$message = $_POST['message']
<p>Is following correct?<p>
<p>typing <a href="link">message</a></p>
<form method="post">
<input type="hidden" name="message" value="typing <a
href="link">message</a>"> <----!
</form>

there it breaks... my $message became
"typing <a href="
insead of
typing <a href="link">message</a>

what to do?
one soulution came right now to my mind... but still have some
questions:
to create copy of $message and to place that copy to hidden holder and
later, just before inserting it to mysql db, to convert it back.... and
what will happen in mysqldb with "?

preg_replace " with ******...? hm, how to find "\""?
maybe preg_replace('/\\\\?\"/', '******', $tekst) ?


--
Ja NE
http://fotozine.org/?omen=janimir
--

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация