forked from Really-Simple-Plugins/really-simple-ssl
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathclass-help.php
More file actions
46 lines (40 loc) · 1.4 KB
/
Copy pathclass-help.php
File metadata and controls
46 lines (40 loc) · 1.4 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
<?php
defined('ABSPATH') or die("you do not have access to this page!");
if ( ! class_exists( 'rsssl_help' ) ) {
class rsssl_help {
private static $_this;
function __construct() {
if ( isset( self::$_this ) )
wp_die( sprintf( __( '%s is a singleton class and you cannot create a second instance.','really-simple-ssl' ), get_class( $this ) ) );
self::$_this = $this;
}
static function this() {
return self::$_this;
}
public function get_help_tip($str, $return=false){
if ($return) {
ob_start();
}
?>
<span class="rsssl-tooltip-right tooltip-right" data-rsssl-tooltip="<?php echo $str?>">
<span class="dashicons dashicons-editor-help"></span>
</span>
<?php
if ($return) {
$content = ob_get_clean();
return $content;
}
}
/**
* Break current row, and start new one.
* @param string $str
* @param string $class
*/
public function get_comment($str, $class = false) {
if (strlen($str) === 0) return;
?>
</td></tr><tr class="rsssl-comment-text <?php echo esc_attr($class)?>"><td colspan="2"><?php echo $str;?></td></tr>
<?php
}
}//class closure
} //if class exists closure