summaryrefslogtreecommitdiff
path: root/views/admin
diff options
context:
space:
mode:
authorDaniel Schmitzer <noreply@maennchen1.de>2016-03-22 06:59:01 +0000
committerDaniel Schmitzer <noreply@maennchen1.de>2016-03-22 06:59:01 +0000
commitc14a7c20ec8c489a37412cebb524e367679f5a60 (patch)
tree4b6c5378e3d46ae13f7657054c24fcada65e6a06 /views/admin
parent5dcc69c910adb6e390c7699de5d2bc87c2a54736 (diff)
- Switch
git-svn-id: https://[internal]/wordpress/plugins/wpsg4@5436 0d5edaf7-2b12-4e95-93f4-047927463d4b
Diffstat (limited to 'views/admin')
-rw-r--r--views/admin/form/input.phtml11
-rw-r--r--views/admin/index.phtml50
2 files changed, 57 insertions, 4 deletions
diff --git a/views/admin/form/input.phtml b/views/admin/form/input.phtml
index 4c68a73..1235fc7 100644
--- a/views/admin/form/input.phtml
+++ b/views/admin/form/input.phtml
@@ -3,10 +3,15 @@
<label class="col-sm-6 control-label" for="<?php echo $this->view['field_id']; ?>"><?php echo $this->view['field_label']; ?></label>
<div class="col-sm-6">
- <input type="text" class="form-control input-sm" name="<?php echo $this->view['field_name']; ?>" value="<?php echo wpsg_hspc($this->view['field_value']); ?>" id="<?php echo $this->view['field_id']; ?>" />
- </div>
- <a href="#" class="glyphicon glyphicon glyphicon-info-sign form-control-feedback" aria-hidden="true"></a>
+ <div class="wpsg_field_wrap">
+ <input type="text" class="form-control input-sm" name="<?php echo $this->view['field_name']; ?>" value="<?php echo wpsg_hspc($this->view['field_value']); ?>" id="<?php echo $this->view['field_id']; ?>" />
+ <?php if (wpsg_isSizedString($this->view['field_config']['help'])) { ?>
+ <a href="#" data-wpsg-tip="<?php echo $this->view['field_config']['help']; ?>" rel="?page=wpsg-Admin&subaction=loadHelp&noheader=1&field=<?php echo $this->view['field_config']['help']; ?>" class="glyphicon glyphicon glyphicon-info-sign form-control-feedback" aria-hidden="true"></a>
+ <?php } ?>
+ </div>
+
+ </div>
<div class="clearfix wpsg_clear"></div>
diff --git a/views/admin/index.phtml b/views/admin/index.phtml
index c6f7b0a..0b7e1aa 100644
--- a/views/admin/index.phtml
+++ b/views/admin/index.phtml
@@ -46,4 +46,52 @@
<?php } ?>
</div>
-</div> \ No newline at end of file
+</div>
+
+<script type="text/javascript">/* <![CDATA[ */
+
+ jQuery(document).ready(function() {
+
+ jQuery('*[data-wpsg-tip]').bind('click', function() {
+
+ jQuery(this).unbind('click');
+
+ var po = this;
+
+ jQuery(this).popover( {
+ 'html': true,
+ 'content': function(el) {
+
+ if (this.cache) return this.cache
+
+ jQuery.ajax( {
+ url: '?page=wpsg-Admin&subaction=loadHelp&noheader=1',
+ data: {
+ field: jQuery(this).attr('data-wpsg-tip')
+ },
+ success: function(data) {
+
+ var popover = jQuery(po).attr('data-content', data).data('popover');
+ jQuery(po).data('bs.popover').options.content = data;
+
+ //popover.setContent();
+
+ //jQuery('#wpsg-popover-content').html(data);
+ //jQuery(po).setContent();
+
+ }
+ } );
+
+ return this.cache = '<div id="wpsg-popover-content"><img src="' + wpsg_ajax.img_ajaxloading + '" alt="' + wpsg_ajax.label_pleasewait + '" /></div>';
+
+ },
+ 'trigger': 'focus'
+ } ).popover('show');
+
+ return false;
+
+ } );
+
+ } );
+
+/* ]]> */</script> \ No newline at end of file