403Webshell
Server IP : 82.208.35.60  /  Your IP : 216.73.217.33
Web Server : Apache/2.4.55 (FreeBSD) OpenSSL/1.1.1q-freebsd PHP/7.3.31
System : FreeBSD server7.d2m.cz 12.4-RELEASE-p9 FreeBSD 12.4-RELEASE-p9 GENERIC amd64
User : studiokobylisy_cz ( 1008)
PHP Version : 7.3.31
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : OFF  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /home/d2m/sofident_cz/wp-content/plugins/acfml/classes/strategy/repeater-shuffle/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /home/d2m/sofident_cz/wp-content/plugins/acfml/classes/strategy/repeater-shuffle/post.php
<?php

namespace ACFML\Repeater\Shuffle;

class Post extends Strategy {
	/**
	 * @var string
	 */
	protected $id_prefix = '';

	/**
	 * @param mixed $id
	 *
	 * @return bool
	 */
	public function isValidId( $id ) {
		return is_numeric( $id ) && $id > 0;
	}

	/**
	 * Get value object for given post ID.
	 *
	 * @param  int $id The post ID
	 *
	 * @return object|null Value object with id and type or null when element not found.
	 */
	protected function getElement( $id ) {
		if ( $this->isValidId( $id ) ) {
			return (object) [
				'id'   => $id,
				'type' => get_post_type( $id ),
			];
		}
	}

	/**
	 * @param int $id
	 *
	 * @return mixed
	 */
	public function getAllMeta( $id ) {
		return get_post_meta( $id );
	}

	/**
	 * @param int $id
	 * @param string $key
	 * @param bool $single
	 *
	 * @return mixed
	 */
	public function getOneMeta( $id, $key, $single = true ) {
		return get_post_meta( $id, $key, $single );
	}

	/**
	 * @param int $id
	 * @param string $key
	 *
	 * @return mixed|void
	 */
	public function deleteOneMeta( $id, $key ) {
		delete_post_meta( $id, $key );
	}

	/**
	 * @param int $id
	 * @param string $key
	 * @param mixed $val
	 *
	 * @return mixed|void
	 */
	public function updateOneMeta( $id, $key, $val ) {
		update_post_meta( $id, $key, $val );
	}

	/**
	 * @param $id
	 *
	 * @return mixed|void
	 */
	protected function get_element_type( $id ) {
		return apply_filters( 'wpml_element_type', get_post_type( $id ) );
	}
}

Youez - 2016 - github.com/yon3zu
LinuXploit