Skip to content

Instantly share code, notes, and snippets.

@bilalmalkoc bilalmalkoc/sql.php

Created Sep 1, 2019
What would you like to do?
$var = "dangerous'"; // escape yapılmamış veri
$id = some_foo_number(); // int olması beklenen veri
$wpdb->query( $wpdb->prepare( "UPDATE $wpdb->posts SET post_title = %s WHERE ID = %d", $var, $id ) );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.