Help with SQL commands to interact with a MySQL database
- Mac /usr/local/mysql/bin
- Windows /Program Files/MySQL/MySQL version/bin
- Xampp /xampp/mysql/bin
<?php | |
/** | |
* When using the WordPress Importer, update existing | |
* posts instead of skipping them. Updates content according | |
* to the import file even if the existing post was updated | |
* more recently. | |
* | |
* To use, drop this file into your /mu-plugins/ folder or | |
* copy this code into your functions.php file. |
add_action ( 'wp_ajax_nopriv_product_quick_view', 'daisy_product_quick_view' ); | |
add_action ( 'wp_ajax_product_quick_view', 'daisy_product_quick_view' ); | |
function daisy_product_quick_view () { | |
$pid = intval($_GET['post_id']); | |
$the_query = new WP_Query(array( | |
'post_type' => 'product', | |
'posts_per_page' => 1, | |
'p' => $pid | |
)); |
<?php | |
/** | |
* by Adrian Statescu <[email protected]> | |
* Twitter: @thinkphp | |
* G+ : http://gplus.to/thinkphp | |
* MIT Style License | |
*/ | |
<?php | |
/** | |
* Class IceCastPlaylist | |
* See https://stackoverflow.com/questions/60502076/how-to-get-icecast-server-songs-history/60798774#60798774 for context | |
* | |
* This class can be used as follows: | |
* global $wpdb | |
* $playlistClass = new IceCastPlaylist($wpdb); | |
* $playlistClass->fetchSongInfo(); |