Multi Vendor Marketplace Plugin | WCFM Marketplace › Forums › WCFM – Feature Request › should use PDO and speed to display data
- This topic has 3 replies, 2 voices, and was last updated 5 years, 3 months ago by WCFM Forum.
- AuthorPosts
- January 6, 2019 at 8:34 pm #42469cesarGuest
Hi there, why you don´t use PDO for access to database? i have searching about this, and wordpress was insterested to implement on 2013, but i’ve serching in the core of 5.0.2 and doesn´t use PDO, so you can implement to access data to your plugin use, meanwhile wordpress catch up.
Other thing, is the lag to display data on any crud. it’s o lazy.
my best
Thanks - January 7, 2019 at 9:48 am #42498WCFM ForumKeymaster
Hi,
Do you want to access WP database from site ?
Try this plugin – https://wordpress.org/plugins/ari-adminer/
Thank You
- January 7, 2019 at 11:14 pm #42566cesarGuest
Not, i mean, every data of vendor/customers site data, are saved in SQLi database, and the connections that you use its just query, one of the most insecure, for other hand, PHP allow use PDO (http://php.net/manual/en/book.pdo.php) that it’s so much more secure, this allow use prepare statement and bindParam to put in the query to database values that you want to ask to DB.
eg.<?php
$sentencia = $mbd->prepare(“INSERT INTO REGISTRY (name, value) VALUES (:name, :value)”);
$sentencia->bindParam(‘:name’, $nombre);
$sentencia->bindParam(‘:value’, $valor);// insertar una fila
$nombre = ‘uno’;
$valor = 1;
$sentencia->execute(); - January 8, 2019 at 6:37 am #42610WCFM ForumKeymaster
Hi,
Frankly I am not very comfortable with this.
We use WP standard for this.
WP DB object “$wpdb” and it supports all this prepare statement, param etc …
Thank You
- AuthorPosts
- The topic ‘should use PDO and speed to display data’ is closed to new replies.