do not show visual builder anchor if js is not enabled

This commit is contained in:
Marc Delisle
2010-11-20 07:43:06 -05:00
parent 7212120004
commit 18f6882f89
2 changed files with 11 additions and 5 deletions

View File

@@ -177,7 +177,7 @@ function showColumnSelectCell($columns, $column_number, $selected = '')
$tab['link'] .= $tab['fragment']; $tab['link'] .= $tab['fragment'];
} }
?> ?>
<div class="notice"> <div id="visual_builder_anchor" class="notice hide">
<span id="footnote_1"> <span id="footnote_1">
<?php echo __('Switch to'); ?> <?php echo __('Switch to'); ?>
<form action="<?php echo $tab_designer['link'] ?>" method="post"> <form action="<?php echo $tab_designer['link'] ?>" method="post">

View File

@@ -2392,15 +2392,21 @@ $(document).ready(function() {
); );
}) // end of $(document).ready() for vertical pointer }) // end of $(document).ready() for vertical pointer
$(document).ready(function() {
/** /**
* Vertical marker * Vertical marker
*/ */
$(document).ready(function() {
$('.vmarker').live('click', function(e) { $('.vmarker').live('click', function(e) {
var $this_td = $(this); var $this_td = $(this);
var row_num = PMA_getRowNumber($this_td.attr('class')); var row_num = PMA_getRowNumber($this_td.attr('class'));
// for all td of the same vertical row, toggle the marked class // for all td of the same vertical row, toggle the marked class
$('.vmarker').filter('.row_' + row_num).toggleClass('marked'); $('.vmarker').filter('.row_' + row_num).toggleClass('marked');
}); });
}) // end of $(document).ready() for vertical marker
/**
* Reveal visual builder anchor
*/
$('#visual_builder_anchor').show();
}) // end of $(document).ready()