| Server IP : 130.225.57.55 / Your IP : 216.73.216.60 Web Server : Apache System : Linux wp-vhost07 5.15.0-173-generic #183-Ubuntu SMP Fri Mar 6 13:29:34 UTC 2026 x86_64 User : root ( 0) PHP Version : 8.1.2-1ubuntu2.25 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /srv/www/reco2st.eu/https/wp-content/themes/erc04961/library/helpers/ |
Upload File : |
<?php
/**
* WordPress HTML Helpers
*
* @author Max G J Panas <http://maxpanas.com>
*/
/**
* Class MOZ_Html
*
*
*/
class MOZ_Html {
/**
* Returns a self-closing HTML
* element constructed
* by php
*
* @param string $tag
* @param array $attrs
*
* @return string
*/
static function get_sc_element( $tag = 'img', $attrs = array() ) {
$html = "<$tag";
foreach ( (array) $attrs as $attr => $value ) {
$value = ( 'href' === $attr ) ? esc_url( $value ) : esc_attr( $value );
$html .= " $attr=\"$value\"";
}
$html .= '>';
return $html;
}
/**
* Prints a self-closing HTML
* element constructed
* by php
*
* @param string $tag
* @param array $attrs
*
* @return string
*/
static function sc_element( $tag = 'img', $attrs = array() ) {
echo self::get_sc_element( $tag, $attrs );
}
/**
* Returns an HTML
* element constructed
* by php
*
* @param string $tag
* @param array $attrs
* @param string $content
*
* @return string
*/
static function get_element( $tag = 'div', $attrs = array(), $content = '' ) {
$html = self::get_sc_element( $tag, $attrs );
$html .= $content;
$html .= "</$tag>";
return $html;
}
/**
* Prints an HTML
* element constructed
* by php
*
* @param string $tag
* @param array $attrs
* @param string $content
*
* @return string
*/
static function element( $tag = 'div', $attrs = array(), $content = '' ) {
echo self::get_element( $tag, $attrs, $content );
}
}