// Para compatibilidad con NS
function mostrarTexto (texto) {
if (document.all) return texto;
return '' + texto + '';
}
// Sólo muestra el texto en IE
function mostrarIE (texto) {
if (document.all) return texto;
return "";
}
// Principal
function VANews(ancho, borde, colorborde, colorfondo, colorlinks, cantidadNOT, cantidadALE, formato, colorletra) {
var j = 1;
var widthNOT = 100;
var widthALE = 100;
var urlpag = 'http://virusattack.virusattack.com.ar';
// Si el formato es horizontal, se dividen a la mitad
if (formato == "H") {
widthNOT = widthALE = 50;
}
// Encabezado
var encabezado = '
' + mostrarTexto('TODA LA INFORMACION SOBRE VIRUS') + ' (provista por Virus Attack!) |
|
';
// Buscador
var buscador = '';
// Noticias
var noticiasTXT = '| ' + mostrarTexto('ULTIMAS NOTICIAS') + ' |
';
noticiasTXT += ' |
'
for (j=1;j<=cantidadNOT;j++){
noticiasTXT += '| | |
';
noticiasTXT += ' |
'
}
noticiasTXT += '
';
// Alertas
var alertasTXT = '| ' + mostrarTexto('ULTIMAS ALERTAS') + ' |
';
alertasTXT += ' |
'
for (j=1;j<=cantidadALE;j++){
alertasTXT += '| | |
';
alertasTXT += ' |
'
}
if (formato == "H") {
alertasTXT += '| ' + buscador + ' |
';
}
alertasTXT += '
';
if (colorfondo == "nothing"){
var texto = '';
}else{
var texto = '';
}
texto += '';
texto += '| ' + encabezado + ' | ';
if (cantidadNOT > 0) {
texto += '| ' + noticiasTXT + ' | ';
if (formato == "V") texto += ' ';
}
if (cantidadALE > 0) {
if ((formato == "V") || (cantidadNOT <= 0)) {
texto += '';
} else {
if (cantidadNOT > 0) {
texto += '| | ';
}
}
texto += '' + alertasTXT + ' | ';
}
texto += ' |
';
texto += '
';
return texto;
}
function noticia(id, titulo, fecha){
this.id = id;
this.titulo = titulo;
this.fecha = fecha;
}
function alerta(id, nombre, fecha){
this.id = id;
this.nombre = nombre;
this.fecha = fecha;
}
var vError;
var vNot = new Array();
var vAle = new Array();
vNot[1] = new noticia(388,'El CERT publica informe trimestral sobre los principales problemas de seguridad','01/12/2003');vNot[2] = new noticia(389,'Virus Attack! presente en el SIMO TCI 2003','15/11/2003');vNot[3] = new noticia(387,'Disponible crítico parche para Internet Explorer','05/10/2003');vNot[4] = new noticia(386,'Informe critica la política de Microsoft y la culpa de la actual falta de seguridad','30/09/2003');vNot[5] = new noticia(385,'Un parche soluciona importante falla en Microsoft Word','04/09/2003');vAle[1] = new alerta(833,'W32/Cuydoc','09/10/2003');vAle[2] = new alerta(832,'W32/IRCBot.B','07/10/2003');vAle[3] = new alerta(831,'VBS/StartPage.D','03/10/2003');vAle[4] = new alerta(830,'W32/Logitall','01/10/2003');vAle[5] = new alerta(829,'W32/Holar.I','28/09/2003');