Welcome, Guest: Register On Nairaland / LOGIN! / Trending / Recent / NewStats: 3,194,273 members, 7,954,071 topics. Date: Friday, 20 September 2024 at 11:52 AM |
Nairaland Forum / Science/Technology / Programming / How Do I Retrieve Data With Apostrophe From Mysql Using PDO (1089 Views)
PDO::FETCH_CLASS Example / Help Me With PDO / XAMPP Mysql ERROR: PDO Driver Not Found (2) (3) (4)
(1) (Reply)
How Do I Retrieve Data With Apostrophe From Mysql Using PDO by kanayoNickel: 7:58pm On May 02, 2017 |
Hi, guys. I am a third year student of Psychology from Unizik. I ve been battling with PHP lately. I could ve gone into normal mysql but some people advised me to go into PDO instead. Now i have a problem that I cant seem to get over for the past 3 days. what is the wahala? I am trying to mimic Seun (yes, I admire u') by creating a forum via tutorials and all. But i've ran into this - I CANT GET OUT DATA that has apostrophe " ' " from my MYSQL table. I have used htmlspecialchars to no avail. What do i do? Any Computer science programmer here can help me. The site is on a demo host http://infobreak./index.php . This problem comes on when the user clicks on the like button for the comments. I dont know if i structured this enough for anyone to understand....Just help me |
Re: How Do I Retrieve Data With Apostrophe From Mysql Using PDO by yorex2011: 8:24pm On May 03, 2017 |
Apostrophe doesn't relate well with mysql Before you insert, use htmlspecialchars() function on the variable to be inserted, then when you retrieve use htmlspecialchars_decode() function to convert all special characters back |
Re: How Do I Retrieve Data With Apostrophe From Mysql Using PDO by kanayoNickel: 9:57am On May 05, 2017 |
yorex2011: Thank you all. Can yo do an appraisal of the site CHECK MY SIGNATURE, give me your honest critique |
(1) (Reply)
Come For Your Web Design And Web Development At A Discount Rate / I Noticed This One This Board. . . . . / Owerri Tech Meetup
(Go Up)
Sections: politics (1) business autos (1) jobs (1) career education (1) romance computers phones travel sports fashion health religion celebs tv-movies music-radio literature webmasters programming techmarket Links: (1) (2) (3) (4) (5) (6) (7) (8) (9) (10) Nairaland - Copyright © 2005 - 2024 Oluwaseun Osewa. All rights reserved. See How To Advertise. 8 |