url = document.location.href; xend = url.lastIndexOf("/") + 1; var base_url = url.substring(0, xend); function ajax_do (url) { // Does URL begin with http? if (url.substring(0, 4) != 'http') { url = base_url + url; } // Create new JS element var jsel = document.createElement('SCRIPT'); jsel.type = 'text/javascript'; jsel.src = url; // Append JS element (therefore executing the 'AJAX' call) document.body.appendChild (jsel); } function ajax_reload_right(the_lang, the_apfa_id, the_tbl_name, the_profile_id) { if(document.getElementById('online_friends')){ document.getElementById('online_friends').innerHTML = ''; } if(document.getElementById('unread_messages_cnt')){ document.getElementById('unread_messages_cnt').innerHTML = ''; } if(document.getElementById('online_aupair_cnt')){ document.getElementById('online_aupair_cnt').innerHTML = ''; } if(document.getElementById('online_family_cnt')){ document.getElementById('online_family_cnt').innerHTML = ''; } if(document.getElementById('online_visitors_cnt')){ document.getElementById('online_visitors_cnt').innerHTML = ''; } atoj = new Date(); atoj1= atoj.getHours(); atoj2 = atoj.getMinutes(); atoj3= atoj.getSeconds(); atoj4= atoj.getMilliseconds(); theTimestamp = atoj1+''+atoj2+''+atoj3+''+atoj4 ; var ajax_params = '?lang='+the_lang+'&s_apfa_id='+the_apfa_id+'&s_tbl_name='+the_tbl_name+'&s_profile_id='+the_profile_id+'×tamp='+theTimestamp; ajax_do('http://www.aupair-options.com/right_menu/ajax_friends_ussers_online.php'+ajax_params); } function get_stanete_link(the_href, the_text){ var the_link = '' + the_text + ''; return(the_link); }