Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > it.comp.www.php > #20596
| From | Alessandro Pellizzari <shuriken@amiran.it> |
|---|---|
| Newsgroups | it.comp.www.php |
| Subject | Re: query db |
| Date | 2016-04-02 20:24 +0000 |
| Message-ID | <dmao3qFjbctU1@mid.individual.net> (permalink) |
| References | <2016032610042321718@mynewsgate.net> <nd5p61$2hk7$1@adenine.netfront.net> <ndomba$1lvt$1@gioia.aioe.org> |
Il Sat, 02 Apr 2016 16:52:27 +0200, Enrico Maria Chellini ha scritto: > e insere nel database delle stringhe con htmlspecialcharacters ? > > http://php.net/manual/en/function.htmlspecialchars.php Hai il problema di come tornare alla stringa originale. Non è detto che quella stringa ti serva sempre e solo da mettere in una pagina web. Se è un CMS le devi mostrare all'utente in caso di modifica, e la _decode () presuppone che usi gli stessi flag della fase di encoding. Le funzioni *_escape_string() e PDO sono fatti apposta per non dover convertire roba avanti e indietro, e sono il modo corretto per fare escaping delle stringhe da mettere in DB. Bye.
Back to it.comp.www.php | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
query db "Halnow" <21718invalid@mynewsgate.net> - 2016-03-26 10:04 +0000
Re: query db Alex <tommaso5ita@yahoo.it> - 2016-03-26 11:44 +0100
Re: query db Enrico Maria Chellini <bitit@bitit.it> - 2016-04-02 16:52 +0200
Re: query db Alessandro Pellizzari <shuriken@amiran.it> - 2016-04-02 20:24 +0000
Re: query db Alex <tommaso5ita@yahoo.it> - 2016-04-03 13:45 +0200
Re: query db Alessandro Pellizzari <shuriken@amiran.it> - 2016-04-03 13:32 +0000
Re: query db Alex <tommaso5ita@yahoo.it> - 2016-04-03 18:30 +0200
Re: query db Alessandro Pellizzari <shuriken@amiran.it> - 2016-04-03 18:12 +0000
Re: query db Alex <tommaso5ita@yahoo.it> - 2016-04-04 11:05 +0200
Re: query db Alessandro Pellizzari <shuriken@amiran.it> - 2016-03-26 17:48 +0000
csiph-web