How to Show Special Characters in PHP?
Firstly if you are having a trouble in mysql look that article. If you handle that problem and still your special characters looking like ???? this because you didn't identify the character set in database connection. If you identify the character set as charset=utf8mb in PDO connecrion your problem will be solved.
<?php
$db = new PDO('mysql:host=localhost;charset=utf8mb4;dbname=dbName', 'dbUser', 'dbPass');
Comments
Popular Articles
Popular Tags
- #directive
- #Function
- #Json
- #Class
- #SASS
- #Form
- #Redirect
- #API
- #Special Characters
- #Special
- #Random
- #Generating
- #
- #Text
- #Ajax
- #URL
- #Encrypting
- #React
- #Show
- #timeAgo
- #PSR-4
- #Hide
- #DDOS Protection
- #DDOS
- #cURL
- #Logic For Displaying Posts
- #Error
- #Key
- #General Error
- #1364 Field
- #Abbreviation
- #Blade
- #Version
- #QR
- #QR Code Generating
- #Array
- #Arrays with Key Values to String Statement
- #Short Tag
- #Activate
- #Real Time
- #Socket.io
- #301
- #Custom Directives
- #Iframe Detection
- #Date
- #Characters
- #Insert
- #Autoloader
- #Composer
- #Reading
There are no comments, make the firs comment