Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.php > #11511
| From | Jerry Stuckle <jstucklex@attglobal.net> |
|---|---|
| Newsgroups | comp.lang.php |
| Subject | Re: str_replace ? |
| Date | 2013-10-20 21:06 -0400 |
| Organization | A noiseless patient Spider |
| Message-ID | <l41un2$6uc$6@dont-email.me> (permalink) |
| References | <izrf52ctugy3.3kvtllz245pf$.dlg@40tude.net> |
On 10/20/2013 8:48 PM, richard wrote: > In my database I am noting that none of the song names containing a single > quote are being written. > If I use str_replace, how exactly should I write it? > > The php manual is not all that clear. > http://php.net/manual/en/function.str-replace.php > > e.g. > > Name of song is "I'm Sorry". > > $song=str_replace($song,"'%"); > As you've been told may times before. ALL strings used in accessing ANY SQL database need to be escaped. You're not doing that. -- ================== Remove the "x" from my email address Jerry Stuckle JDS Computer Training Corp. jstucklex@attglobal.net ==================
Back to comp.lang.php | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
str_replace ? richard <noreply@example.com> - 2013-10-20 20:48 -0400
Re: str_replace ? Lew Pitcher <lew.pitcher@digitalfreehold.ca> - 2013-10-20 21:02 -0400
Re: str_replace ? richard <noreply@example.com> - 2013-10-20 21:55 -0400
Re: str_replace ? David Robley <me@home.invalid> - 2013-10-21 12:41 +1030
Re: str_replace ? richard <noreply@example.com> - 2013-10-21 09:16 -0400
Re: str_replace ? Jerry Stuckle <jstucklex@attglobal.net> - 2013-10-20 21:06 -0400
Re: str_replace ? Denis McMahon <denismfmcmahon@gmail.com> - 2013-10-21 18:43 +0000
Re: str_replace ? Norman Peelman <npeelman@cfl.rr.com> - 2013-10-21 19:10 -0400
Re: str_replace ? Norman Peelman <npeelman@cfl.rr.com> - 2013-10-21 19:14 -0400
Re: str_replace ? Tobiah <toby@tobiah.org> - 2013-10-23 10:04 -0700
Re: str_replace ? Scott Johnson <noonehome@chalupasworld.com> - 2013-10-23 17:03 -0700
csiph-web