Logo

dev-resources.site

for different kinds of informations.

How to Convert date format to PHP with MYSQLI, using secure queries to avoid SQL injection

Published at
4/28/2020
Categories
php
mysqli
injection
sql
Author
juli6464
Categories
4 categories in total
php
open
mysqli
open
injection
open
sql
open
Author
8 person written this
juli6464
open

How to Convert date format to PHP with MYSQLI, using secure queries to avoid SQL injection

There are cases in which we need to send a date format in Spanish to a sql query, for example the format of (Abril 28 2020) and for this we must do the following:

$ query = mysqli_query ($ conn, "SET lc_time_names = 'es_ES';");

$ query = $ conn-> prepare ('SELECT id, DATE_FORMAT (date, "% M% d% Y") ,, text FROM table WHERE id =?');

Keep in mind that these queries are what we should do in our developments to avoid sql injection.

injection Article's
26 articles in total
Favicon
Ore: Advanced Dependency Injection Package for Go
Favicon
Beauty Injection: Achieve Radiance Without Surgery
Favicon
Exploring Fat Burning Injections in Mt. Juliet, TN
Favicon
Dependency Injection Explained in C#
Favicon
Bug SQL Injection - Sub bawaslu.go.id - Badan Pengawas Pemilihan Umum
Favicon
Custom Plastic Molding Near Me, Mold Makers, Mold Manufacturers, and Rapid Prototyping: A Comprehensive Guide
Favicon
Loose Coupling and Dependency Injection (DI) principle
Favicon
Dependency Injection for JavaScript Developers
Favicon
AWS Security Stories #04.4: OWASP - Injection
Favicon
Angular Dependency Injection
Favicon
How to create your own dependency injection framework in Java
Favicon
NodeJs - Dependency injection, make it easy
Favicon
A Step by Step Guide to ASP.NET Core Dependency Injection
Favicon
Ծրագրային անվտանգություն՝ SQL Injection (մաս 1)
Favicon
How to implement Dependency Injection in Node.js with Example
Favicon
Why you should use dependency injection
Favicon
Handling Injection Attacks in Java
Favicon
A straightforward introduction to Dependency Injection
Favicon
How to create your own dependency injection framework in Java
Favicon
Let's stop being stupid about security
Favicon
Dagger with a Hilt
Favicon
Security: Released npm package 📦 for Protecting CSV Injection 🚀
Favicon
Yet another dependency injection library
Favicon
O11ycon Talks: Dr. Peter Alvaro, "Twilight Of The Experts"
Favicon
Jersey Injection Dependency example with HK2
Favicon
How to Convert date format to PHP with MYSQLI, using secure queries to avoid SQL injection

Featured ones: