The popular open-source contract for web professionals by Stuff & Nonsense
- Originally published: 23rd December 2008
- Revised date: March 15th 2016
- Original post
| #EXTM3U | |
| #EXTINF:-1 tvg-id="ntvnp" tvg-logo="https://upload.wikimedia.org/wikipedia/en/8/84/Nepal_Television_Logo.png" group-title="Nepal", Nepal Television (NTV) | |
| http://202.166.207.67:1935/live/ntv/playlist.m3u8 | |
| #EXTINF:-1 tvg-id="ntvplusnp" tvg-logo="https://upload.wikimedia.org/wikipedia/en/8/84/Nepal_Television_Logo.png" group-title="Nepal", NTV Plus | |
| http://202.166.207.67:1935/live/ntvplus/playlist.m3u8 | |
| #EXTINF:-1 tvg-id="ntvnewsnp" tvg-logo="https://upload.wikimedia.org/wikipedia/en/8/84/Nepal_Television_Logo.png" group-title="Nepal", NTV News | |
| http://202.166.207.67:1935/live/ntvnews/playlist.m3u8 |
| <?php | |
| function portfolios_shortcode($atts){ | |
| extract( shortcode_atts( array( | |
| 'expand' => '', | |
| ), $atts) ); | |
| global $paged; | |
| $posts_per_page = 6; | |
| $settings = array( |
| <?php | |
| // Add your own function to filter the fields | |
| add_filter( 'submit_job_form_fields', 'remove_listify_submit_job_form_fields', 9999999999 ); | |
| // This is your function which takes the fields, modifies them, and returns them | |
| // You can see the fields which can be changed here: https://github.com/mikejolley/WP-Job-Manager/blob/master/includes/forms/class-wp-job-manager-form-submit-job.php | |
| function remove_listify_submit_job_form_fields( $fields ) { | |
| if( ! isset( $fields['company'] ) ) return $fields; |
| add_action('post_submitbox_misc_actions', createCustomField); | |
| add_action('save_post', saveCustomField); |
| <? | |
| /** | |
| * Repeatable Custom Fields in a Metabox | |
| * Author: Helen Hou-Sandi | |
| * | |
| * From a bespoke system, so currently not modular - will fix soon | |
| * Note that this particular metadata is saved as one multidimensional array (serialized) | |
| */ | |
| function hhs_get_sample_options() { |
| <?php | |
| // source: http://wordpress.stackexchange.com/questions/211703/need-a-simple-but-complete-example-of-adding-metabox-to-taxonomy | |
| // code authored by jgraup - http://wordpress.stackexchange.com/users/84219/jgraup | |
| // REGISTER TERM META | |
| add_action( 'init', '___register_term_meta_text' ); | |
| function ___register_term_meta_text() { |
| function add_jquery_ui() { | |
| wp_enqueue_script( 'jquery-ui-core' ); | |
| wp_enqueue_script( 'jquery-ui-widget' ); | |
| wp_enqueue_script( 'jquery-ui-mouse' ); | |
| wp_enqueue_script( 'jquery-ui-accordion' ); | |
| wp_enqueue_script( 'jquery-ui-autocomplete' ); | |
| wp_enqueue_script( 'jquery-ui-slider' ); | |
| wp_enqueue_script( 'jquery-ui-tabs' ); | |
| wp_enqueue_script( 'jquery-ui-sortable' ); | |
| wp_enqueue_script( 'jquery-ui-draggable' ); |
| <!doctype html> | |
| <title>Site Maintenance</title> | |
| <style> | |
| body { text-align: center; padding: 150px; } | |
| h1 { font-size: 50px; } | |
| body { font: 20px Helvetica, sans-serif; color: #333; } | |
| article { display: block; text-align: left; width: 650px; margin: 0 auto; } | |
| a { color: #dc8100; text-decoration: none; } | |
| a:hover { color: #333; text-decoration: none; } | |
| </style> |
| <?php | |
| require dirname(__FILE__).'/wp-blog-header.php'; | |
| $wpdb->query("DELETE FROM wp_terms WHERE term_id IN (SELECT term_id FROM wp_term_taxonomy WHERE taxonomy LIKE 'pa_%')"); | |
| $wpdb->query("DELETE FROM wp_term_taxonomy WHERE taxonomy LIKE 'pa_%'"); | |
| $wpdb->query("DELETE FROM wp_term_relationships WHERE term_taxonomy_id not IN (SELECT term_taxonomy_id FROM wp_term_taxonomy)"); | |
| $wpdb->query("DELETE FROM wp_term_relationships WHERE object_id IN (SELECT ID FROM wp_posts WHERE post_type IN ('product','product_variation'))"); | |
| $wpdb->query("DELETE FROM wp_postmeta WHERE post_id IN (SELECT ID FROM wp_posts WHERE post_type IN ('product','product_variation'))"); | |
| $wpdb->query("DELETE FROM wp_posts WHERE post_type IN ('product','product_variation')"); |