File Editor
Directories:
.. (Back)
open-graph
schema
twitter
Files:
aioseo-helper.php
asset-helper.php
attachment-cleanup-helper.php
author-archive-helper.php
blocks-helper.php
capability-helper.php
crawl-cleanup-helper.php
curl-helper.php
current-page-helper.php
date-helper.php
environment-helper.php
first-time-configuration-notice-helper.php
home-url-helper.php
image-helper.php
import-cursor-helper.php
import-helper.php
indexable-helper.php
indexable-to-postmeta-helper.php
indexing-helper.php
language-helper.php
meta-helper.php
notification-helper.php
options-helper.php
pagination-helper.php
permalink-helper.php
post-helper.php
post-type-helper.php
primary-term-helper.php
product-helper.php
redirect-helper.php
require-file-helper.php
robots-helper.php
robots-txt-helper.php
sanitization-helper.php
score-icon-helper.php
short-link-helper.php
site-helper.php
social-profiles-helper.php
string-helper.php
taxonomy-helper.php
url-helper.php
user-helper.php
wincher-helper.php
woocommerce-helper.php
wordpress-helper.php
wpdb-helper.php
Create New File
Create
Edit File: aioseo-helper.php
<?php namespace Yoast\WP\SEO\Helpers; use wpdb; /** * The AIOSEO Helper. */ class Aioseo_Helper { /** * The WordPress database instance. * * @var wpdb */ protected $wpdb; /** * The wpdb helper. * * @var Wpdb_Helper */ protected $wpdb_helper; /** * Class constructor. * * @param wpdb $wpdb The WordPress database instance. * @param Wpdb_Helper $wpdb_helper The wpdb helper. */ public function __construct( wpdb $wpdb, Wpdb_Helper $wpdb_helper ) { $this->wpdb = $wpdb; $this->wpdb_helper = $wpdb_helper; } /** * Retrieves the AIOSEO table name along with the db prefix. * * @return string The AIOSEO table name along with the db prefix. */ public function get_table() { return $this->wpdb->prefix . 'aioseo_posts'; } /** * Determines if the AIOSEO database table exists. * * @return bool True if the table is found. */ public function aioseo_exists() { return $this->wpdb_helper->table_exists( $this->get_table() ) === true; } /** * Retrieves the option where the global settings exist. * * @return array The option where the global settings exist. */ public function get_global_option() { return \json_decode( \get_option( 'aioseo_options', '' ), true ); } }
Save Changes
Rename File
Rename