var fckuri=[]; function apelaereFCK(n){ if (!fckuri[n]) { var oFCKeditor = new FCKeditor('descriere_'+n) ; oFCKeditor.Height=450; oFCKeditor.BasePath = "panou-control/includes/fckeditor/" ; oFCKeditor.ReplaceTextarea() ; fckuri[n]=true; } } function sendComment(f) { if ($val('comment')=='') { alert('Please type the comment!'); } else { document.getElementById(f).submit(); } } function ads_op(tip,val,val2) { if (tip=='paginare') { var trim='tip='+tip; trim+='&ftitle='+eurl($val('ftitle')); trim+='&fcateg='+eurl($val('fcateg')); trim+='&fstatus='+eurl($val('fstatus')); trim+='&af_pag='+val; Ejax(window.siteurl+'includes/ajax_php/ads_op.php',trim,'divClassified'); } if (tip=='delete') { if (confirm('Are you sure you want to delete this ads?')) { var trim=''; trim+='tip='+tip; trim+='&a='+val; trim+='&ftitle='+eurl($val('ftitle')); trim+='&fcateg='+eurl($val('fcateg')); trim+='&fstatus='+eurl($val('fstatus')); trim+='&af_pag='+eurl($val('pagina')); Ejax(window.siteurl+'includes/ajax_php/ads_op.php',trim,'divClassified'); } } if (tip=='filtru') { var trim='tip='+tip; trim+='&ftitle='+eurl($val('ftitle')); trim+='&fcateg='+eurl($val('fcateg')); trim+='&fstatus='+eurl($val('fstatus')); Ejax(window.siteurl+'includes/ajax_php/ads_op.php',trim,'divClassified'); } if (tip=='del_image') { var trim='tip='+tip; trim+='&a='+val; trim+='&img='+val2; Ejax(window.siteurl+'includes/ajax_php/ads_op.php',trim,'divImagine'); } } function cauta() { window.location=window.siteurl+'search.html?str='+$val('search')+'&c='+$val('categSearch'); } function deleteImageUser(val2) { if (confirm('Are you sure you want to delete the image!')) { var trim=''; trim+='img='+val2; Ejax(window.siteurl+'includes/ajax_php/image_op.php',trim,'divImage'); } } function msg_inbox_op(tip,val,val2) { if (tip=='paginare') { var trim='tip='+tip; trim+='&af_pag='+val; Ejax(window.siteurl+'includes/ajax_php/inbox_msg_op.php',trim,'divMessagesInbox'); } if (tip=='delete') { if (confirm('Are you sure you want to move this message in trush?')) { var trim=''; trim+='tip='+tip; trim+='&m='+val; trim+='&af_pag='+eurl($val('pagina')); Ejax(window.siteurl+'includes/ajax_php/inbox_msg_op.php',trim,'divMessagesInbox'); } } } function msg_sent_op(tip,val,val2) { if (tip=='paginare') { var trim='tip='+tip; trim+='&af_pag='+val; Ejax(window.siteurl+'includes/ajax_php/sent_msg_op.php',trim,'divMessagesInbox'); } if (tip=='delete') { if (confirm('Are you sure you want to move this message in trush?')) { var trim=''; trim+='tip='+tip; trim+='&m='+val; trim+='&af_pag='+eurl($val('pagina')); Ejax(window.siteurl+'includes/ajax_php/sent_msg_op.php',trim,'divMessagesInbox'); } } } function msg_trash_op(tip,val,val2) { if (tip=='paginare') { var trim='tip='+tip; trim+='&af_pag='+val; Ejax(window.siteurl+'includes/ajax_php/trash_msg_op.php',trim,'divMessagesInbox'); } if (tip=='delete') { if (confirm('Are you sure you want to delete this message?')) { var trim=''; trim+='tip='+tip; trim+='&m='+val; trim+='&af_pag='+eurl($val('pagina')); Ejax(window.siteurl+'includes/ajax_php/trash_msg_op.php',trim,'divMessagesInbox'); } } } function addFriend(id) { var trim=''; trim+='id='+id Ejax(window.siteurl+'includes/ajax_php/add_friend_op.php',trim,''); } function friends_inv_op(tip,val,val2) { if (tip=='paginare') { var trim='tip='+tip; trim+='&af_pag='+val; Ejax(window.siteurl+'includes/ajax_php/friends_inv_op.php',trim,'divFriends'); } if (tip=='accept') { var trim='tip='+tip; trim+='&id='+val; trim+='&af_pag='+eurl($val('pagina')); Ejax(window.siteurl+'includes/ajax_php/friends_inv_op.php',trim,'divFriends'); } if (tip=='deny') { var trim='tip='+tip; trim+='&id='+val; trim+='&af_pag='+eurl($val('pagina')); Ejax(window.siteurl+'includes/ajax_php/friends_inv_op.php',trim,'divFriends'); } } function friends_op(tip,val,val2) { if (tip=='paginare') { var trim='tip='+tip; trim+='&af_pag='+val; Ejax(window.siteurl+'includes/ajax_php/friends_op.php',trim,'divFriends'); } if (tip=='delete') { if (confirm('Are you sure you want to delete this friend?')) { var trim='tip='+tip; trim+='&id='+val; trim+='&af_pag='+eurl($val('pagina')); Ejax(window.siteurl+'includes/ajax_php/friends_op.php',trim,'divFriends'); } } } function categs_op(tip,val,val2) { if (tip=='add') { if ($val('name')=='') { alert('Please type the category name!'); } else if ($val('categ')=='') { alert('Please select the parent category!'); } else { var trim=''; trim+='tip='+tip; trim+='&name='+eurl($val('name')); trim+='&parent='+eurl($val('categ')); Ejax(window.siteurl+'includes/ajax_php/categs_op.php',trim,'divCategs'); document.getElementById('name').value=''; document.getElementById('categ').value=''; } } if (tip=='update') { if ($val('name2')=='') { alert('Please type the category name!'); } else if ($val('categ2')=='') { alert('Please select the parent category!'); } else { var trim=''; trim+='tip='+tip; trim+='&name='+eurl($val('name2')); trim+='&parent='+eurl($val('categ2')); trim+='&x='+eurl($val('idCateg')); Ejax(window.siteurl+'includes/ajax_php/categs_op.php',trim,'divCategs'); document.getElementById('divUpdate').innerHTML=''; } } if (tip=='paginare') { var trim=''; trim+='tip='+tip; trim+='&af_pag='+val; Ejax(window.siteurl+'includes/ajax_php/categs_op.php',trim,'divCategs'); } if (tip=='delete') { if (confirm('Are you sure you want to delete this category?')) { var trim=''; trim+='tip='+tip; trim+='&x='+val; trim+='&af_pag='+eurl($val('pagina')); Ejax(window.siteurl+'includes/ajax_php/categs_op.php',trim,'divCategs'); } } if (tip=='modify') { var trim=''; trim+='tip='+tip; trim+='&x='+val; trim+='&af_pag='+eurl($val('pagina')); Ejax(window.siteurl+'includes/ajax_php/categs_op.php',trim,'divUpdate'); } } function topics_op(tip,val,val2) { if (tip=='filtru') { var trim=''; trim+='tip='+tip; trim+='&ftitle='+eurl($val('ftitle')); Ejax(window.siteurl+'includes/ajax_php/topics_op.php',trim,'divTopics'); } if (tip=='paginare') { var trim=''; trim+='tip='+tip; trim+='&ftitle='+eurl($val('ftitle')); trim+='&af_pag='+val; Ejax(window.siteurl+'includes/ajax_php/topics_op.php',trim,'divTopics'); } if (tip=='delete') { if (confirm('Are you sure you want to delete this topic?')) { var trim=''; trim+='tip='+tip; trim+='&ftitle='+eurl($val('ftitle')); trim+='&af_pag='+eurl($val('pagina')); trim+='&x='+eurl(val); Ejax(window.siteurl+'includes/ajax_php/topics_op.php',trim,'divTopics'); } } }