/*
HPE - News Portal Engine
Copyright (C) 2000-2001 Mike Krus
This program is free software; it is distributed in the hope
that it will be useful, but WITHOUT ANY WARRANTY; without
even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE.
READ LICENSE.TXT IN THE BASE DIRECTORY FOR INFORMATION
ABOUT REDISTRIBUTING THIS SOURCE CODE
*/
function HPEGetSelectedItems()
{
var docObjName = (document.all) ? "document.all." : "document.";
dml = eval(docObjName + 'HPENewsTools');
len = dml.elements.length;
var i;
var items = new Array();
for(i=0;i<len;i++)
{
if(dml.elements[i].name == 'il')
{
if(dml.elements[i].checked)
items.push(dml.elements[i].value);
}
}
if(items.length)
{
return items.join('/');
}
else
{
alert(HPENoSelectError);
return '';
}
}
function HPEResetItems()
{
var docObjName = (document.all) ? "document.all." : "document.";
dml = eval(docObjName + 'HPENewsTools');
len = dml.elements.length;
var i;
for(i=0;i<len;i++)
{
if(dml.elements[i].name == 'il')
{
if(dml.elements[i].checked) dml.elements[i].checked = false;
}
}
}
function HPEMailItems()
{
selection = HPEGetSelectedItems();
if(selection != '')
{
link = HPESiteRoot + 'post/mail/' + selection;
res = window.open(link, 'HPEpopuptool', 'toolbar=no,resizable=yes,width=640,height=600');
res.focus();
}
}
function HPEBloggerItems()
{
selection = HPEGetSelectedItems();
if(selection != '')
{
link = HPESiteRoot + 'post/blogger/' + selection;
res = window.open(link, 'HPEbloggertool', 'scrollbars=no,status=yes,toolbar=no,width=475,height=300');
res.focus();
}
}
function HPEManilaItems()
{
selection = HPEGetSelectedItems();
if(selection != '')
{
link = HPESiteRoot + 'post/manila/' + selection;
res = window.open(link, 'HPEpopuptool', 'toolbar=no,resizable=yes,width=640,height=600');
res.focus();
}
}
function HPERadioItems()
{
selection = HPEGetSelectedItems();
if(selection != '')
{
link = HPESiteRoot + 'post/radio/' + selection;
alert(link);
// res = window.open(link, 'HPEpopuptool', 'toolbar=no,width=620,height=570');
// res.focus();
}
}