-
Implements PHP’s __call magic method to provide a number of clever handlers for the unknown method call.
-
Implements PHP’s __get magic method to provides a number of clever handlers for the unknown property access.
-
Retrieves a collection of ancestors for the current WordPress WOOF::object, from lowest to highest in the hierarchyThis will only return meaningful results when the current object is a post or term.
-
Returns the dimensionality of the supplied array.
-
Removes a value from the specified array, if it exists.
-
Removes (unsets) the values in an array indexed by the keys provided.
-
Retrieves a WOOF_Attachment object for the attachment with the given ID.
-
Retrieves a collection of attachment objects for the given query arguments. Note: The args parameter for this method is a preset for WordPress’ get_posts function that is forced to query for the attachment post_type.
-
Returns either the author for the current post if the current WordPress WOOF::object is a post, or the current logged in user otherwise.
-
A similar function to WordPress’ body_class function, which can combine the values of WOOF::body_id and WOOF::body_class together to populate a class and ID combo for the HTML body tag.
-
A replacement function for WordPress body_class function that can regard the value of a $body_class global, in addition to merging in the standard values from get_body_class.
-
A companion function for WordPress body_class or the WOOF::body_class method to output an attribute for the ID of the body tag.
-
An more concise API terminology for the WordPress Transients API to retrieve OR store a value in a transient for a given amount of time.
-
Retrieves a WOOF_Term object for the given category slug, if it exists.Note: if the $slug argument is not provided, this method will attempt to return the current category (if any). .
-
Checks if the current WordPress WOOF::object is a child of the given object / object id, or object slug. Note: this will only return meaningful results if the current object is a post or term (and the type / taxonomy is hierarchical respectively). .
-
A preset on the WOOF::theme_file method to retrieve a WOOF_File object representing a file at the path given, relative to the directory of the child theme.
-
A preset on the WOOF::theme_image to return a WOOF_Image object representing an image file at the path given, relative to the child theme directory of the active theme appended to a default base directory of “images” inside your theme. This can be really useful for displaying images stored inside your theme folder, opening up the rich image processing API of the WOOF_Image object to those images. .
-
A preset on the WOOF::theme_image to return a WOOF_Image object representing an image file at the path given, relative to the child theme directory of the active theme appended to a default base directory of “img” inside your theme. This can be really useful for displaying images stored inside your theme folder, opening up the rich image processing API of the WOOF_Image object to those images. .
-
A preset on the WOOF::theme_url to returns a URL to a file or folder within the directory of the active theme, but forced to regard only the child theme folder.
-
Retrieves the immediate child objects of the current WordPress WOOF::object.This method uses get_posts or get_terms to retrieve the children, and you can further clarify this query with the args parameter (the parent parameter will be enforced to actually retrieve the children). Note: this will only return meaningful results if the current object is a post or term (and the type / taxonomy is hierarchical respectively).
-
Returns a new WOOF_Collection object, using the provided array to form the items in the collection.
-
Returns the content for the current post.Note that part of the convenience of this function is that the MEOW API does not necessarily require “the loop” code to be wrapping it for the content to be actually output.
-
Retrieves a WOOF_File object representing a file at the path given (which is relative to the wp-content path).
-
Retrieves a WOOF_Image object representing an image file at the path given.
-
Retrieves the URL for a given file path relative to the wp-content directory, or a directory inside blogs.dir for multisite.
-
Returns the current URL derived from PHP server variables.
-
Gets the publish date of the current post.
-
An extension of PHP’s date function to format date timestamps.
-
An internal function that allows common code to be used for the content_file and content_image methods. .
-
A wrapper for wp_enqueue_script which can enqueue more than one stylesheet in your theme at once from a given base directory.Note that this method runs all URLs through WOOF::theme_url which is child theme-aware, with the default setting being to look for files first in the child theme directory then the parent theme directory.Note: in the example, we show this called directly in the template file before the call to wp_head(), but you also make use of the wp_enqueue_scripts action to call these functions.
-
A wrapper for wp_enqueue_style which can enqueue more than one stylesheet in your theme at once from a given base directory, relative to your theme directory.Note that this method runs all URLs through WOOF::theme_url which is child theme-aware, with the default setting being to look for files first in the child theme directory then the parent theme directory.Note: in the example, we show this called directly in the template file before the call to wp_head(), but you also make use of the wp_enqueue_scripts action to call these functions.
-
An internal function that allows common code to be used for the file_from_url and image_from_url methods.
-
Extracts the full domain of a given URL.
-
Conditionally echos a value if the condition passed evaluates to true (first checks if condition is set).
-
A wrapper for wp_enqueue_style which can enqueue more than one stylesheet in your theme at once and assumes a base folder of THEME_DIR/css.Note that this method runs all URLs through WOOF::theme_url which is child theme-aware, with the default setting being to look for files first in the child theme directory then the parent theme directory.Note: in the example, we show this called directly in the template file before the call to wp_head(), but you also make use of the wp_enqueue_scripts action to call these functions.
-
A wrapper for wp_enqueue_script which can enqueue more than one stylesheet in your theme at once and assumes a base folder of THEME_DIR/javascripts.Note that this method runs all URLs through WOOF::theme_url which is child theme-aware, with the default setting being to look for files first in the child theme directory then the parent theme directory.Note: in the example, we show this called directly in the template file before the call to wp_head(), but you also make use of the wp_enqueue_scripts action to call these functions.
-
A wrapper for wp_enqueue_style which can enqueue more than one stylesheet in your theme at once and assumes a base folder of THEME_DIR/javascripts.
-
enqueue_theme_js( Array / String $files, Array $deps = array(), Boolean $in_footer = false, Boolean $timestamp = true, Boolean $root_relative = true, String $default_extension = "js", String $parent = "auto" )
A wrapper for wp_enqueue_script which can enqueue more than one stylesheet in your theme at once and assumes a base folder of THEME_DIR/js.Note that this method runs all URLs through WOOF::theme_url which is child theme-aware, with the default setting being to look for files first in the child theme directory then the parent theme directory.Note: in the example, we show this called directly in the template file before the call to wp_head(), but you also make use of the wp_enqueue_scripts action to call these functions.
-
A wrapper for wp_enqueue_style which can enqueue more than one stylesheet in your theme at once and assumes a base folder of THEME_DIR/js.
-
A wrapper for wp_enqueue_script which can enqueue more than one stylesheet in your theme at once and assumes a base folder of THEME_DIR/script.Note that this method runs all URLs through WOOF::theme_url which is child theme-aware, with the default setting being to look for files first in the child theme directory then the parent theme directory.Note: in the example, we show this called directly in the template file before the call to wp_head(), but you also make use of the wp_enqueue_scripts action to call these functions.
-
A wrapper for wp_enqueue_style which can enqueue more than one stylesheet in your theme at once and assumes a base folder of THEME_DIR/script.
-
A wrapper for wp_enqueue_style which can more simply enqueue the standard style.css in your theme and assumes a base folder of THEME_DIR.Note that this method runs all URLs through WOOF::theme_url which is child theme-aware, with the default setting being to look for files first in the child theme directory then the parent theme directory.Note: in the example, we show this called directly in the template file before the call to wp_head(), but you also make use of the wp_enqueue_scripts action to call these functions.
-
A wrapper for wp_enqueue_style which can enqueue more than one stylesheet in your theme at once and assumes a base folder of THEME_DIR/stylesheets.Note that this method runs all URLs through WOOF::theme_url which is child theme-aware, with the default setting being to look for files first in the child theme directory then the parent theme directory.Note: in the example, we show this called directly in the template file before the call to wp_head(), but you also make use of the wp_enqueue_scripts action to call these functions.
-
Evaluates an expression on a context object to a string result.
-
Evaluates a token part of an expression evaluated by WOOF::eval_expression method.
-
Generate an excerpt for the current post, or get the manual excerpt, depending on the args provided.
-
Creates a new woof-expression object with the given base object, expression, and return type.
-
Downloads a file from the given URL if it has not been downloaded before, caches it to a directory specified, and returns a file object representing it.
-
A synonym of the [method cls=”woof” name=”date-format” method to format date timestamps.
-
Retrieves a filtered collection of WOOF_Post objects, by calling the WOOF::posts method with suppress_filters turned off.
-
Issue a query on the sites in your multisite network.Note: use the WOOF::sites method, which accepts the same arguments, to return a collection of WOOF_Site objects instead.
-
Checks if the current WordPress WOOF::object has any children.Note: this will only return meaningful results if the current object is a post or term (and the post type / taxonomy is hierarchical respectively).
-
Checks if the current WordPress WOOF::object has a parent.Note: this will only return meaningful results if the current object is a post or term (and the post type / taxonomy is hierarchical respectively).
-
Checks if the current WordPress query has a variable for the given name, via WordPress get_query_var function.
-
A synonym for the has_qv method to check if the current WordPress query has a variable for the given name, via WordPress get_query_var function.
-
Converts a 3 or 6 character hex value (with or without hash prefix) to an array of 3 integer values representing the Red, Green, and Blue, values (0 – 255).
-
Returns the database id of the current WordPress WOOF::object. This method will likely be most useful when creating custom SQL queries. .
-
Returns the post ID for a given slug name and post type, if found.
-
Downloads an image file from the given URL if it has not been downloaded before, caches it to a directory specified, and returns an image file object representing it.
-
Includes the phpQuery library.
-
Checks if the current WordPress WOOF::object is the post specified by the parameters given. .
-
Checks if the current WordPress WOOF::object is of the given type.Type has different meanings depending on what the current object is:If the object is a post, type would be the name of a post typeIf the object is a term, type would be the name of a taxonomyIf the object is a user, type would be a user role This method would be useful to display different things in a common include file, based on the current object, for example.
-
A synonym for WOOF::is_a, to check if the current WordPress WOOF::object is of the given type.Type has different meanings depending on what the current object is:If the object is a post, type would be the name of a post typeIf the object is a term, type would be the name of a taxonomyIf the object is a user, type would be a user role This method would be useful to display different things in a common include file, based on the current object, for example.
-
Evaluates to true if the argument supplied is an associative array.
-
A synonym for the WOOF::child_of, to checks if the current WordPress WOOF::object is a child of the given object.Note: this will only return meaningful results if the current object is a post or term (and the post type / taxonomy is hierarchical respectively).
-
Returns true if the value of the argument at the key provided is regarded as a false value, in the context of a set of arguments that would be parsed by wp_parse_args.
-
Checks to see if you’re on the current front page via the WordPress is_front_page function.
-
Checks to see if this page is the front or home page, via a check on both is_front_page and is_home. .
-
Checks to see if the current page is the home page, via the WordPress is_home function.
-
Checks to see if the current post / page is the page given in the page argument.
-
Checks to see if the current page number is the given page, via comparing with the result of calling page_num.
-
Checks to see if the displayed posts are currently paged or not, that is, the visitor is currently on a page that is not the first in an archive of posts. .
-
Checks to see if the current template filename matches the provided file name or is one of a number of file names.
-
Returns true if the value of the argument at the key provided is regarded as a true value, in the context of a set of arguments that would be parsed by wp_parse_args.
-
A conditional output function for displaying a count of items.
-
Retrieves a json object or associative array by requesting a JSON string from a remote URL and decoding it.
-
Formats a JSON object string with indenting for enhanced readability.
-
Uncaches a JSON string that was previously cached by the WOOF::json_get. .
-
Returns objects for the latest 1 or more posts, based on a query with the arguments provided.
-
An alternative syntax for running The Loop in WordPress, i.e.
-
Pads a string with 1 character of your choosing, only if the string does not already have that character on the left. .
-
A powerful method allowing developers to augment the classes in MEOW and WOOF with their own class functions, without needing to create class extensions of them.
-
Gets the modified date of the current post.
-
Converts a newline-formatted string into a string that is broken into blocks wrapped by the specified tag.
-
Converts a newline-formatted HTML string to a paragraph-formatted string.
-
Retrieves the active WordPress object, which is decided by analysing the current template being accessed.
-
Returns a string representing the type of the the current WordPress object, which is decided by analysing the current template being accessed.
-
Pads a character to the left and right of the provided string, but only if the specified character is not already present at the left and right respectively.
-
A synonym for the WOOF::post method to return a WOOF_Post object for the given id argument.
-
A preset of the post-by method, to retrieve a page by a full slug path.
-
Retrieves the total number of pages in the current listing, if that listing is paginated.
-
A synonym of the WOOF::page_number to retrieve the current page number in a paginated listing of posts. Essentially a wrapper around retrieval of the global $paged property, but normalized to return 1 if that property is not set, or is 0.
-
Retrieves the current page number in a paginated listing of posts. Essentially a wrapper around retrieval of the global $paged property, but normalized to return 1 if that property is not set, or is 0.
-
A wrapper around WordPress’ get_pages method to retrieve a collection of MEOW_Post objects matching the args provided.Note that this function is not merely a simple synonym of WOOF::posts since get_pages supports more functionality than get_posts.
-
Retrieves the immediate parent object of the current WordPress WOOF::object.Note: this will only return meaningful results if the current object is a post or term (and the type / taxonomy is hierarchical respectively).
-
A preset on the WOOF::theme_file method to retrieve a WOOF_File object representing a file at the path given, relative to the directory of the parent theme.
-
A preset on the WOOF::theme_image to return a WOOF_Image object representing an image file at the path given, relative to the parent theme directory of the active theme appended to a default base directory of “images” inside your theme. This can be really useful for displaying images stored inside your theme folder, opening up the rich image processing API of the WOOF_Image object to those images. .
-
A preset on the WOOF::theme_image to return a WOOF_Image object representing an image file at the path given, relative to the parent theme directory of the active theme, appended to a default base directory of “img” inside your theme. This can be really useful for displaying images stored inside your theme folder, opening up the rich image processing API of the WOOF_Image object to those images. .
-
A preset on the WOOF::theme_url to return a URL to a file or folder within the directory of the active theme, but forced to regard only the parent theme folder.
-
A utility function which defines a baseline of default settings for post query methods in the WOOF class, while also patching the standard arguments for ease of use, specifically:The default args are: array(“post_type” => “any”, “posts_per_page” => “-1”)If posts_per_page is set, but not numberposts, numberposts will be set to the value of posts_per_page, which smooths over a quirk in the standard query arguments.Note: this method is intended for internal use.
-
An internal filter function used by MasterPress to augment the standard arguments available to WordPress post queries.
-
An internal function used to extract the taxonomy and term from a composite string pair “taxonomy_name:term_id”. .
-
Gets a permalink for the current WordPress WOOF::object. It should be noted that this doesn’t just apply to post and term objects; a permalink can be returned for:posts – a link to the (single) postterms – a link to the archive page for the taxonomy termsites – a link to the site (multi-site environment)users – a link to the author page for that userpost types – a link to the archive page for the post type.
-
Retrieves a WOOF_Post object for the given id and type arguments.
-
Return a WOOF_PostType for the current post.
-
Returns a single WOOF_PostType object representing a post type name in the $arg parameter, or multiple post types if the $arg parameter is an arguments array, as would be passed to the WordPress function get_post_types(). Note: if you do not pass any arguments to this method, a collection of all registered post types will be retrieved.
-
A wrapper around the WordPress function get_posts to retrieve a collection of WOOF_Post objects for the given arguments. .
-
A preset on the WOOF::posts method to retrieve a collection of WOOF_Post objects ordered by title.
-
A preset on the WOOF::posts method to retrieve a collection of WOOF_Post objects with ids falling within the given set of ids, and matching the provided args.
-
A preset on the WOOF::posts method to retrieve a collection of WOOF_Post objects with ids that do not fall within the given set of ids, and matching the provided args.
-
A shorthand wrapper method for the applying WordPress’ the_content filter to a string.
-
Stores a pointer to the global $post object away so that you can use the variable name $post in your code elsewhere.
-
A wrapper around the WordPress function query_posts to alter the way WordPress displays posts at a given URL.
-
A shorthand wrapper method for WordPress get_query_var function.
-
Returns the unfiltered content for the current post.
-
Retrieves a collection of WOOF_Post objects that are related to the current post by their taxonomy terms, configurable via an arguments parameter. .
-
Sets the global $post variable back to its original value after WOOF::protect has been called (which allows a variable named $post to be used in your own code) .
-
Remaps the properties of an arguments array compatible with wp_parse_args to the correct argument keys accepted by another method, as defined in the second argument $aliases.This method is used internally by the update methods in WOOF_Post and WOOF_Term.
-
An internal function used by MasterPress to retain the post object for the current post (if any).
-
Retrieves a remote web page using the HTTP get method, via the WOOF_Request class, which is a wrapper for the WordPress HTTP API.Note: this method can also cache the result for a given amount of time, providing a very concise way to retrieve the content of another site or service in a performant manner.
-
Posts to a remote web page using the HTTP POST method, via the WOOF_Request class, which is a wrapper for the WordPress HTTP API.
-
Renders the supplied String template using the Mustache library with the given data. .
-
A shorthand wrapper method for WordPress get_query_var function.
-
A wrapper method for WordPress’ wp_reset_query function, which destroys the previous query used on a custom loop.
-
Returns a count of posts for the current query, whether this is setup from the current URL, or from a custom query.
-
results_number( String $zero = "No Search Results", String $one = "%d Search Result", String $many = "%d Search Results" )String
Returns a formatted string representing the count of posts in the current query.Note: All format strings are run through sprintf with the current results count.
-
Converts three Red, Green, Blue integers to the hex string representation (with leading hash). .
-
Retrieves the role for the given id, where an id is like a slug for the role, for example “administrator”.
-
Returns a collection of WOOF_Role objects representing all of the roles in the WordPress site.
-
Converts a URL in the current site to a root-relative URL – that is, a URL without protocol and host, beginning with a leading slash to denote the root level.
-
Pads a string at the right with 1 character of your choosing, only if the string does not already have that character on the right. .
-
A wrapper for the WordPress function sanitize_title_with_dashes.
-
A wrapper for the WordPress function sanitize_title_with_dashes.
-
A shorthand version of the WordPress function wp_enqueue_script which will enqueue one or more registered scripts, via the $ids argument, which can be a single identifier, a CSV string of identifiers, or an array of identifiers.Note: this method does not accept a second argument for the URL to the script, it is purely a shorthand for enqueuing scripts registered by WordPress or other themes.
-
A handy function to parse a time duration string into an integer number of seconds.
-
Parses attributes passed to a shortcode handler to retrieve an “id” for the shortcode, accepting the following styles of shortcode:[item 1] [item id=”1″]That is, if there are no named attributes, this function will assume the first attribute is the ID.
-
Retrieves the sibling objects of the current WordPress WOOF::object, that is, objects that exist at the same level in the hierarchy as the current object.Note: this will only return meaningful results if the current object is a post or term (and the type / taxonomy is hierarchical respectively).
-
Returns a WOOF_Site object representing the site for the given id, or the current site if the id is not provided, or we’re not in a multi-site environment. .
-
Retrieves the description of the current site – essentially a wrapper for the WordPress function call get_bloginfo(“description”).
-
Retrieves the name of the current site – essentially a wrapper for the WordPress function call get_bloginfo(“name”).
-
Retrieves the tagline for the current site – essentially a wrapper for the WordPress function call get_bloginfo(“tagline”).
-
A synonym for WOOF_Site::name to retrieves the name of the current site – essentially a wrapper for the WordPress function call get_bloginfo(“name”).
-
Retrieves the URL for the current site – essentially a wrapper for the WordPress function call get_bloginfo(“url”), with the option to make the URL root relative (exclude the domain and protocol).
-
Returns a collection of WOOF_Site objects representing all of the sites in the multi-site network, or a collection of one site if the current environment is not multi-site.
-
Retrieves the slug for the current WordPress WOOF::object.Note: this will only return meaningful results if the current object is a post or term (and the type / taxonomy is hierarchical respectively).
-
A shorthand version of the WordPress function wp_enqueue_style which will enqueue one or more registered stylesheets, via the $ids argument, which can be a single identifier, a CSV string of identifiers, or an array of identifiers.Note: this method does not accept a second argument for the URL to the stylesheet, it is purely a shorthand for enqueuing stylesheets registered by WordPress or other themes.
-
Retrieves a WOOF_Term object for a given tag (a term within the built-in taxonomy “post_tag”).Note: if the $slug argument is not provided, this method will return the current tag (if any).
-
A wrapper around the WordPress function get_taxonomies to retrieve a collection of WOOF_Taxonomy objects for the given arguments. .
-
Retrieves a collection of WOOF_Taxonomy objects which are assigned to the given (post) type name.
-
Retrieves a WOOF_Taxonomy object for the taxonomy with the given name, or a silent object if the taxonomy doesn’t exist.
-
Returns the file name of the current template, sans-extension.
-
Returns the filename of the current template, with or without the extension.
-
Retrieves the full filename (including extension) of the template currently being used for the given post.
-
Returns the full path to the current template being used, derived by calling the WordPress function get_page_template.
-
Retrieves a MEOW_Term object for the given id and taxonomy arguments.
-
Retrieves a MEOW_Term object, by a specific term (database) ID.
-
Retrieves a MEOW_Term object, by a specific (descriptive) name and taxonomy.
-
Retrieves a MEOW_Term object, by a specific URL slug and taxonomy.
-
A wrapper around the WordPress function get_terms to retrieve a collection of WOOF_Term objects for the given taxonomy and arguments. .
-
Retrieves a collection of MEOW_Term objects for the given ids and optionally a taxonomy.
-
An highly useful method which retrieves a MEOW_Post object for the current post, based on wrapping the WordPress global $post variable. This is an important method, which is particularly useful in the following scenarios:Retrieving an object for the current post in a single post template (without necessarily requiring any The Loop code)Retrieving the current post in a standard The Loop in WordPress.
-
Returns a WOOF_User object for the current author.
-
A preset on the WOOF::the_term method, to retrieve the current active category (if any).Note that this method uses “category” for the $taxonomy argument of WOOF::the_term, which means that a silent object will be returned if there is no active category, or the active term is from another taxonomy (such as a tag). .
-
Retrieves a MEOW_Site object representing the current site – this method also works in non-multisite environments, to retrieve an object describing the site.
-
A preset on the WOOF::the_term method, to retrieve the current active post tag (if any).Note that this method uses “post_tag” for the $taxonomy argument of WOOF::the_term, which means that a silent object will be returned if there is no active tag, or the active term is from another taxonomy (such as a category). .
-
Retrieves a WOOF_Taxonomy object for the current taxonomy being displayed.
-
Retrieves a meow-taxonomy object for the current taxonomy term being displayed.
-
Retrieves a WOOF_PostType object for the current post type being displayed.
-
Retrieves a MEOW_User object representing the current logged in user, or a silent object if no-one is currently logged in. .
-
Returns the absolute URL of a file or folder within the directory of the active theme.Note: this method does not check that the file or directory exists.
-
theme_css( Array / String $file = style.css, Array $deps = array(), String $media = "all", Boolean $timestamp = true, String $default_extension = "css", String $parent = "auto" )
An alias for WOOF::enqueue_theme_css which can enqueue more than one stylesheet in your theme at once and assumes a base folder of THEME_DIR/css.Note that this method runs all URLs through WOOF::theme_url which is child theme-aware, with the default setting being to look for files first in the child theme directory then the parent theme directory.Note: in the example, we show this called directly in the template file before the call to wp_head(), but you also make use of the wp_enqueue_scripts action to call these functions.
-
Retrieves a WOOF_File object representing a file at the path given, relative to the directory of the active theme.
-
Retrieves a WOOF_Image object representing an image file at the path given, relative to the directory of the active theme appended to a default base directory of “images” inside your theme. This method is also child-theme aware, in that it is configured by default to first look for the image file in an active child-theme, and if not found there will then look in the parent theme.
-
Retrieves a WOOF_Image object representing an image file at the path given, relative to the directory of the active theme appended to a default base directory of “img” inside your theme. This method is also child-theme aware, in that it is configured by default to first look for the image file in an active child-theme, and if not found there will then look in the parent theme.
-
An alias for the WOOF::enqueue_theme_javascript method which can enqueue more than one stylesheet in your theme at once and assumes a base folder of THEME_DIR/javascripts.Note that this method runs all URLs through WOOF::theme_url which is child theme-aware, with the default setting being to look for files first in the child theme directory then the parent theme directory.Note: in the example, we show this called directly in the template file before the call to wp_head(), but you also make use of the wp_enqueue_scripts action to call these functions.
-
A wrapper for wp_enqueue_style which can enqueue more than one stylesheet in your theme at once and assumes a base folder of THEME_DIR/javascripts.
-
theme_js( Array / String $files, Array $deps = array(), Boolean $in_footer = false, Boolean $timestamp = true, String $default_extension = "js", String $parent = "auto" )
An alias for the WOOF::enqueue_theme_js method which can enqueue more than one stylesheet in your theme at once and assumes a base folder of THEME_DIR/js.Note that this method runs all URLs through WOOF::theme_url which is child theme-aware, with the default setting being to look for files first in the child theme directory then the parent theme directory.Note: in the example, we show this called directly in the template file before the call to wp_head(), but you also make use of the wp_enqueue_scripts action to call these functions.
-
theme_js_css( Array / String $file = style.css, Array $deps = array(), String $media = "all", Boolean $timestamp = true, String $default_extension = "css", String $parent = "auto" )
An alias for the WOOF::enqueue_theme_js_css method which can enqueue more than one stylesheet in your theme at once and assumes a base folder of THEME_DIR/js.
-
theme_script( Array / String $files, Array $deps = array(), Boolean $in_footer = false, Boolean $timestamp = true, String $default_extension = "js", String $parent = "auto" )
An alias for the WOOF::enqueue_theme_js method which can enqueue more than one stylesheet in your theme at once and assumes a base folder of THEME_DIR/scripts.Note that this method runs all URLs through WOOF::theme_url which is child theme-aware, with the default setting being to look for files first in the child theme directory then the parent theme directory.Note: in the example, we show this called directly in the template file before the call to wp_head(), but you also make use of the wp_enqueue_scripts action to call these functions.
-
theme_script_css( Array / String $file = style.css, Array $deps = array(), String $media = "all", Boolean $timestamp = true, String $default_extension = "css", String $parent = "auto" )
A wrapper for wp_enqueue_style which can enqueue more than one stylesheet in your theme at once and assumes a base folder of THEME_DIR/script.
-
theme_style( Array / String $file = style.css, Array $deps = array(), String $media = "all", Boolean $timestamp = true, String $default_extension = "css", String $parent = "auto" )
An alias for the WOOF::enqueue_theme_style method, which can more simply enqueue the standard style.css in your theme and assumes a base folder of THEME_DIR.Note that this method runs all URLs through WOOF::theme_url which is child theme-aware, with the default setting being to look for files first in the child theme directory then the parent theme directory.Note: in the example, we show this called directly in the template file before the call to wp_head(), but you also make use of the wp_enqueue_scripts action to call these functions.
-
theme_stylesheet( Array / String $file = style.css, Array $deps = array(), String $media = "all", Boolean $timestamp = true, String $default_extension = "css", String $parent = "auto" )
An alias for WOOF::enqueue_theme_stylesheet which can enqueue more than one stylesheet in your theme at once and assumes a base folder of THEME_DIR/stylesheets.Note that this method runs all URLs through WOOF::theme_url which is child theme-aware, with the default setting being to look for files first in the child theme directory then the parent theme directory.Note: in the example, we show this called directly in the template file before the call to wp_head(), but you also make use of the wp_enqueue_scripts action to call these functions.
-
Returns a URL to a file or folder within the directory of the active theme.
-
Returns the title of the current WordPress WOOF::object.Note: This method will return a sensible value for each of the classes that represent a WordPress object, since they all provide their own implementation of a title method, which remaps to a sensible notion of “title” for that object.
-
Retrieves the top level ancestor of the current WordPress WOOF::object.Note: this will only return meaningful results if the current object is a post or term (and the type / taxonomy is hierarchical respectively), otherwise the current WordPress object will simply be returned.
-
A preset on the WOOF::posts method to retrieve a collection of the latest $count top level WOOF_Post objects.
-
A preset on the WOOF::posts method to retrieve a collection of the latest $count top level WOOF_Post objects.
-
A string truncation function that chops the String argument to the specified length, with various options to control where and if the truncation takes place.
-
Performs the same truncation as the truncate function, but with traditional expanded function arguments.
-
A basic string truncation function that chops the String argument to the specified length, adding a trailing string at the end only if the string is longer than the specified max length.
-
A synonym for the post_types method, to return a single WOOF_PostType object representing a post type name in the $arg parameter, or multiple post types if the $arg parameter is an arguments array, as would be passed to the WordPress function get_post_types().Note: For readability, the intention is that this method is usually used to retrieve a single type.
-
A synonym for the WOOF::post_types method, to return a single WOOF_PostType object representing a post type name in the $arg parameter, or multiple post types if the $arg parameter is an arguments array, as would be passed to the WordPress function get_post_types().
-
An more concise API terminology for the WordPress Transients API to manually remove a transient for the given key.
-
Retrieves a WOOF_File object representing a file at the given path relative to the WordPress upload directory.
-
Retrieves a WOOF_Image object representing an image file at the given path relative to the WordPress upload directory.
-
Returns the URL of the current WordPress WOOF::object, or the current URL derived from server variables if there is no current object.
-
Returns the encoded URL for the current WordPress WOOF::object, or the current URL derived from server variables if there is no current object.
-
Retrieves a MEOW_User object for the given id.
-
Retrieves a MEOW_User object for the given email address.
-
Retrieves a MEOW_User object for the given (database) id.
-
Retrieves a MEOW_User object for the given login username.
-
A wrapper around the WordPress get_users function to retrieve a collection of MEOW_User objects, based on the arguments provided.
-
A multi-site aware method for getting the current WordPress content directory.
-
A multi-site aware method for getting the full wp-content URL for a given path relative to the wp-content directory. .
-
Wraps the results returned by a standard WordPress posts query (via get_posts, for example).
-
Wraps a post result as would be returned by a standard WordPress posts query (via get_posts, for example) as a WOOF_Attachment object.
-
Wraps an array of post results as would be returned by a standard WordPress posts query (via get_posts, for example) as a collection of WOOF_Attachment objects.
-
A utility method used by the other wrap functions to wrap a stdClass object as an object specific to this API.
-
A utility method used by the other wrap functions to wrap an array of stdClass objects as a collection of objects specific to this API.
-
Wraps a post result as would be returned by a standard WordPress posts query (via get_posts, for example) as a WOOF_Post object.
-
Wraps a post type result as would be returned by get_post_type_object, for example, as a WOOF_PostType object.
-
Wraps an array of post type objects, as would be returned by get_post_types, as a collection of WOOF_PostType objects.
-
Wraps an array of roles as stored in the wp_user_roles option, as a collection of role objects. .
-
Wraps a stdClass representation of a site as a MEOW_Site object.
-
Wraps an array of results as would be returned by WOOF::get_sites as a collection of MEOW_Site objects. .
-
Wraps an array of taxonomy results as would be returned by get_taxonomies as a collection of WOOF_Taxonomy objects.
-
Wraps a taxonomy object as would be returned by get_taxonomy as a WOOF_Taxonomy object.
-
Wraps a term result as would be returned by get_term, for example, as a MEOW_Term object.
-
Wraps an array of term results as would be returned by get_terms, for example, as a collection of MEOW_Term objects.
-
Wraps a user result as would be returned by get_userdata, for example, as a WOOF_User object.
-
Wraps an array of user results as would be returned by get_users, for example, as a collection of WOOF_User objects.