PHP 클래스 Microweber\Providers\ContentManager

파일 보기 프로젝트 열기: microweber/microweber

공개 프로퍼티들

프로퍼티 타입 설명
$app Microweber\Application
$no_cache Boolean that indicates the usage of cache while making queries.
$precached_links
$skip_pages_starting_with_url
$table_prefix
$tables

공개 메소드들

메소드 설명
__construct ( $app = null )
attributes ( $content_id )
breadcrumb ( $params = false )
custom_fields ( $content_id, $full = true, $field_type = false )
data ( $content_id )
define_constants ( array | boolean $content = false ) Defines all constants that are needed to parse the page layout.
edit_field ( $data, $debug = false )
get ( mixed | array | boolean | string $params = false ) : array | boolean | mixed Get array of content items from the database.
get_by_id ( integer $id ) : array Get single content item by id from the content_table.
get_by_url ( $url = '', $no_recursive = false )
get_children ( $id, $without_main_parrent = false )
get_data ( $params = false )
get_inherited_parent ( $content_id ) Get the first parent that has layout.
get_page ( integer | string $id ) : array Get single content item by id from the content_table.
get_pages ( $params = false )
get_parents ( $id, $without_main_parrent = false )
get_posts ( $params = false )
get_products ( $params = false )
homepage ( ) Returns the homepage as array.
lang_current ( ) Get the current language of the site.
lang_set ( $lang = 'en' ) Set the current language.
link ( integer $id ) : string Gets a link for given content id.
next_content ( $content_id = false, $mode = 'next', $content_type = false )
pages_tree ( integer $parent, boolean $link = false, boolean $active_ids = false, boolean $active_code = false, boolean $remove_ids = false, boolean $removed_ids_code = false, boolean $ul_class_name = false, boolean $include_first = false ) : sting Print nested tree of pages.
paging ( $params ) : string paging.
paging_links ( $base_url = false, $pages_count, $paging_param = 'curent_page', $keyword_param = 'keyword' )
ping ( )
prev_content ( $content_id = false )
reorder ( $params )
save ( $data, $delete_the_cache = true )
save_content ( $data, $delete_the_cache = true )
save_content_admin ( $data, $delete_the_cache = true ) ------------------------------------------------------------------------
save_content_data_field ( $data, $delete_the_cache = true )
save_content_field ( $data, $delete_the_cache = true )
save_edit ( $post_data )
set_published ( string | array | boolean $params ) : string Set content to be published.
set_table_names ( array | boolean $tables = false ) Sets the database table names to use by the class.
set_unpublished ( string | array | boolean $params ) : string Set content to be unpublished.
site_templates ( )
title ( $id )

메소드 상세

__construct() 공개 메소드

public __construct ( $app = null )

attributes() 공개 메소드

public attributes ( $content_id )

breadcrumb() 공개 메소드

public breadcrumb ( $params = false )

custom_fields() 공개 메소드

public custom_fields ( $content_id, $full = true, $field_type = false )

data() 공개 메소드

public data ( $content_id )

define_constants() 공개 메소드

It accepts array or $content that must have $content['id'] set
public define_constants ( array | boolean $content = false )
$content array | boolean

edit_field() 공개 메소드

public edit_field ( $data, $debug = false )

get() 공개 메소드

It accepts string or array as parameters. You can pass any db field name as parameter to filter content by it. All parameter are passed to the get() function You can get and filter content and also order the results by criteria
public get ( mixed | array | boolean | string $params = false ) : array | boolean | mixed
$params mixed | array | boolean | string You can pass parameters as string or as array
리턴 array | boolean | mixed Array of content or false if nothing is found

get_by_id() 공개 메소드

Get single content item by id from the content_table.
public get_by_id ( integer $id ) : array
$id integer The id of the content item
리턴 array

get_by_url() 공개 메소드

public get_by_url ( $url = '', $no_recursive = false )

get_children() 공개 메소드

public get_children ( $id, $without_main_parrent = false )

get_data() 공개 메소드

public get_data ( $params = false )

get_inherited_parent() 공개 메소드

Get the first parent that has layout.
public get_inherited_parent ( $content_id )

get_page() 공개 메소드

Get single content item by id from the content_table.
public get_page ( integer | string $id ) : array
$id integer | string The id of the page or the url of a page
리턴 array The page row from the database

get_pages() 공개 메소드

public get_pages ( $params = false )

get_parents() 공개 메소드

public get_parents ( $id, $without_main_parrent = false )

get_posts() 공개 메소드

public get_posts ( $params = false )

get_products() 공개 메소드

public get_products ( $params = false )

homepage() 공개 메소드

Returns the homepage as array.
public homepage ( )

lang_current() 공개 메소드

Get the current language of the site.
public lang_current ( )

lang_set() 공개 메소드

Set the current language.
public lang_set ( $lang = 'en' )

next_content() 공개 메소드

public next_content ( $content_id = false, $mode = 'next', $content_type = false )

pages_tree() 공개 메소드

Print nested tree of pages.
public pages_tree ( integer $parent, boolean $link = false, boolean $active_ids = false, boolean $active_code = false, boolean $remove_ids = false, boolean $removed_ids_code = false, boolean $ul_class_name = false, boolean $include_first = false ) : sting
$parent integer
$link boolean
$active_ids boolean
$active_code boolean
$remove_ids boolean
$removed_ids_code boolean
$ul_class_name boolean
$include_first boolean
리턴 sting Prints the pages tree

paging() 공개 메소드

paging
저자: Microweber
public paging ( $params ) : string
$params ['num'] = 5; //the numer of pages
리턴 string - html string with ul/li

ping() 공개 메소드

public ping ( )

prev_content() 공개 메소드

public prev_content ( $content_id = false )

reorder() 공개 메소드

public reorder ( $params )

save() 공개 메소드

public save ( $data, $delete_the_cache = true )

save_content() 공개 메소드

public save_content ( $data, $delete_the_cache = true )

save_content_admin() 공개 메소드

------------------------------------------------------------------------
public save_content_admin ( $data, $delete_the_cache = true )

save_content_data_field() 공개 메소드

public save_content_data_field ( $data, $delete_the_cache = true )

save_content_field() 공개 메소드

public save_content_field ( $data, $delete_the_cache = true )

save_edit() 공개 메소드

public save_edit ( $post_data )

set_published() 공개 메소드

Set is_active flag 'y'
public set_published ( string | array | boolean $params ) : string
$params string | array | boolean
리턴 string The url of the content

set_table_names() 공개 메소드

Sets the database table names to use by the class.
public set_table_names ( array | boolean $tables = false )
$tables array | boolean

set_unpublished() 공개 메소드

Set is_active flag 'n'
또한 보기: content_set_unpublished()
public set_unpublished ( string | array | boolean $params ) : string
$params string | array | boolean
리턴 string The url of the content

site_templates() 공개 메소드

public site_templates ( )

title() 공개 메소드

public title ( $id )

프로퍼티 상세

$app 공개적으로 프로퍼티

public Application,Microweber $app
리턴 Microweber\Application

$no_cache 공개적으로 프로퍼티

Boolean that indicates the usage of cache while making queries.
public $no_cache

$skip_pages_starting_with_url 공개적으로 정적으로 프로퍼티

public static $skip_pages_starting_with_url

$table_prefix 공개적으로 프로퍼티

public $table_prefix

$tables 공개적으로 프로퍼티

public $tables