Accueil/js/main.js

83 lines
2.5 KiB
JavaScript

function spawnLink(link) {
var url = link.href;
return spawnURL(url);
}
function spawnURL(url) {
var w = window.open();
w.opener = null;
w.document.write('<meta http-equiv="refresh" content="0;' + url + '">');
w.document.close();
return false;
}
function openContactList()
{
window.open("https://hostedtalkgadget.google.com/talkgadget/popout?nav=true#", "Buddy List", "menubar=0,resizable=0,width=320,height=360")
}
function openTodo()
{
window.open("http://www.rememberthemilk.com", "ToDo List", "menubar=0,resizable=0,width=870,height=450")
}
function openCalendar()
{
window.open("https://www.google.com/calendar/gp?hl=en", "Calendar", "menubar=0,resizable=0,width=320,height=360")
}
function openNotepad()
{
window.open("notepad.html", "Notepad", "menubar=0,resizable=0,width=320,height=360")
}
function openCalculator()
{
window.open("calculator.html", "Calc", "menubar=0,resizable=0,width=320,height=360")
}
$(document).ready(function(){
$('body').prepend('<div id="menu-bar"></div>');
$('#menu-bar').prepend($('#config-menu'));
$("#q").focus(); //focus sur la recherche
//$('.iconlist').sortable();
$('#config-menu').fancybox({
'zoomSpeedIn' : 600,
'zoomSpeedOut' : 500,
'easingIn' : 'easeOutBack',
'easingOut' : 'easeInBack',
'hideOnContentClick': false,
'padding' : 15
});
$('#blog-links-manager').fancybox({
'zoomSpeedIn' : 600,
'zoomSpeedOut' : 500,
'easingIn' : 'easeOutBack',
'easingOut' : 'easeInBack',
'hideOnContentClick': false,
'padding' : 15
});
/*$('#config-submit').live('click',function(e){
$(this).replaceWith('<img src="images/interface/ajax_load.gif" style="margin:30px auto;display:block" />');
var data3 = {
'clock' : $('input[type=radio][name=clock_group]:checked').attr('value'),
'weather' : $('input[type=radio][name=weather_group]:checked').attr('value'),
'notes' : $('input[type=radio][name=notes_group]:checked').attr('value'),
'search' : $('input[type=radio][name=search_group]:checked').attr('value'),
'links' : $('input[type=radio][name=links_group]:checked').attr('value'),
'blogs' : $('input[type=radio][name=blogs_group]:checked').attr('value'),
'todo' : $('input[type=radio][name=todo_group]:checked').attr('value')
};
$.post('ajax/post-config.php',data3,function(msg3){
if(msg3=="1"){
location.reload();
}
});
e.preventDefault();
});*/
});