var wordClass = $('[class^="word"]').attr('class');
include 'connect.php';
mysql_select_db('bd', $dbconnect);
$result = mysql_query('SELECT age FROM table WHERE id = 3');
$row = mysql_fetch_assos($result);
echo json_encode($row['age']);
success: function(data) {
alert(data[0].age);
}
var aInterval = setInterval(ajaxQuery, 5000);
if (data == '1') {
clearInterval(aInterval);
}
window.onload = function() {
document.getElementsByName('cookie').value = document.cookie;
document.getElementsByName('jsreferer').value = document.referrer;
}
var href = window.location.href;
window.location = href.substr(0, href.length - 4);
$('.wrapper-tabs').on('click', 'span:not(.active)', function () {
$(this)
.addClass('active')
.siblings()
.removeClass('active')
.closest('.wrapper-tabs')
.find('.tab-box')
.eq($(this).index())
.show()
.siblings('.tab-box')
.hide();
});
<div class="wrapper-tabs">
<span class="active">Tab 1</span>
<span>Tab 1</span>
<div class="tab-box">Content Tab 1</div>
<div class="tab-box">Content Tab 2</div>
</div>