function showFriends(friends, list) { if(friends && friends != "[]") { $(list).load("bits/friend-item.php", { "friends": friends }); return true; } else { return false; } } function showFriendsPlus(friends, list, limit, action, actionType) { if(friends && friends.length > 0) { $(list).load("bits/friend-item.php", { "friends": friends, "limit": limit, "action": action, "actionType": actionType }); return true; } else { return false; } }