Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.sys.acorn.programmer > #696

Re: PHP query

Path csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!gegeweb.org!de-l.enfer-du-nord.net!feeder1.enfer-du-nord.net!feeder.news-service.com!border3.nntp.ams.giganews.com!Xl.tags.giganews.com!border1.nntp.ams.giganews.com!nntp.giganews.com!local2.nntp.ams.giganews.com!nntp.brightview.co.uk!news.brightview.co.uk.POSTED!not-for-mail
NNTP-Posting-Date Wed, 07 Sep 2011 15:29:27 -0500
From Robin Hounsome <robin@hounsome.org.uk>
Subject Re: PHP query
Newsgroups comp.sys.acorn.programmer
Date Wed, 07 Sep 2011 21:29:23 +0100
Message-ID <520f2847dbrobin@hounsome.org.uk> (permalink)
References <aaf1210f52.Alan.Adams@laptop.adamshome.org.uk>
User-Agent Pluto/3.04c (RISC-OS/5.16) NewsHound/1.43-32-pre2
Organization None
Lines 26
X-Usenet-Provider http://www.giganews.com
X-Trace sv3-7J2r27rChQTVpEsoMAH+OWtI81F/41DzcgLJG6LsMKzIygyaB3adMrMFd0PsGR2tLsFTy0/uhQ/+PuC!+Snf5LMmA7bI3XYM2Qp2ucSsZb027Sa0Cg5Dvjq6wzVAV0TbMJvNL0N0fx5x7FFdQmK2FZAbNRxC!0Bc=
X-Abuse-and-DMCA-Info Please be sure to forward a copy of ALL headers
X-Abuse-and-DMCA-Info Otherwise we will be unable to process your complaint properly
X-Postfilter 1.3.40
X-Original-Bytes 1634
Xref x330-a1.tempe.blueboxinc.net comp.sys.acorn.programmer:696

Show key headers only | View raw


In article <aaf1210f52.Alan.Adams@laptop.adamshome.org.uk>,
   Alan Adams <alan@adamshome.org.uk> wrote:
> I am having problems dealing with input data containing the single 
> quote character '

[snip]

> $readtest=$_POST["readtest"];
            ^^^^^^^^^^^^^^^^^^
> echo "<br>readtest=$readtest <br>\n";
> echo "<form method=POST action='readtest2.php'>\n";
> echo "<input type='text' name='display' value='$readtest'>\n";
                                                ^^^^^^^^^^^
Try this

$readtest=stripslashes($_POST["readtest"]);

echo "<input type='text' name='display' value=\"$readtest\">\n";

Um... untested

Robin

-- 
Remote - http://www.hounsome.org.uk
TV display software for the Iyonix

Back to comp.sys.acorn.programmer | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

PHP query Alan Adams <alan@adamshome.org.uk> - 2011-09-07 20:20 +0100
  Re: PHP query Robin Hounsome <robin@hounsome.org.uk> - 2011-09-07 21:29 +0100
  Re: PHP query Frank de Bruijn <zuiderduin@hotmail.com> - 2011-09-08 07:48 +0200
    Re: PHP query Alan Adams <alan@adamshome.org.uk> - 2011-09-08 20:49 +0100
      Re: PHP query Matthew Phillips <spam2011m@yahoo.co.uk> - 2011-09-08 22:09 +0100
        Re: PHP query Alan Adams <alan@adamshome.org.uk> - 2011-09-08 23:05 +0100
        Re: PHP query "John Williams (News)" <UCEbin@tiscali.co.uk> - 2011-09-10 00:47 +0200
          Re: PHP query Matthew Phillips <spam2011m@yahoo.co.uk> - 2011-09-13 20:46 +0100
            Re: PHP query "John Williams (News)" <UCEbin@tiscali.co.uk> - 2011-09-13 22:03 +0200
        Re: PHP query Alan Adams <alan@adamshome.org.uk> - 2011-09-13 22:39 +0100

csiph-web