|
|
|
| Имею ссылку вида:
<a href="index.php?cn=5" id="ln7" onclick="clicklnk(7)" class="sort_cat" rel="7" >Днестровск</a>
|
Необходимо при загрузки страницы вызвать функцию передав при этом параметр rel для:
$(document).ready(
function() {
$('a.sort_cat').click(function(){
$.ajax({
type: "POST",
url: "modules/greetings.php",
data: "sort_cat="+$(this).attr('rel'),
success: function(html){
$("#content").html(html);
}
});
return false;
});
|
| |
|
|
|
|
|
|
|
для: OLi
(12.04.2011 в 02:56)
| |
$(document).ready(
function() {
$('a.sort_cat').click(function(){
$.ajax({
type: "POST",
url: "modules/greetings.php",
data: "sort_cat="+$(this).attr('rel'),
success: function(html){
$("#content").html(html);
}
});
return false;
}
$('a.sort_cat').click();
);
|
| |
|
|
|