Common file for Javascript functions
//////////////////////////////////////////////////////////////////////////////
// FILE : common.js
// AUTHOR : http://www.asolver.com
// PURPOSE : Common file for Javascript functions
//////////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////////
// FUNCTIONS
//////////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////////
function PdfView(pdfNam)
// PURPOSE: Writes a Html code for view a Pdf document.
// The internal height of the DIN A4 page is 500 pixels,
// this functions added 35 pixels for the controls.
// the with lets to fit 2 pages like a book.
// Asumes an specific directory for pdf and an specific extension.
//////////////////////////////////////////////////////////////////////////////
{
var htmCod =
" <div class='multimedia'>"+
" <object"+
" data = 'http://www.forense.info/multimedia/"+pdfNam+".pdf"+
"#toolbar=0&navpanes=0&scrollbar=1&page=1&view=FitV'"+
" width = '100%'"+
" height = '100%'"+
" type = 'application/pdf'>"+
" <p>Su navegador no puede visualizar documento en formato PDF.</p>"+
" </object>"+
" </div>";
document.write(htmCod);
}
//////////////////////////////////////////////////////////////////////////////
function Mp4View(mp4Nam)
// PURPOSE: Writes a Html code for view a MP4 video.
// The height of the video is always 500 pixels,
// and the width proportional to this height is 667.
// Asumes an specific directory for MP4 and an specific extension.
//////////////////////////////////////////////////////////////////////////////
{
var htmCod =
" <div class='multimedia'>"+
" <video width='100%' height='100%' controls='controls'>"+
" <source src='../multimedia/"+mp4Nam+".mp4' type='video/mp4'>"+
" <p>Su navegador no puede visualizar videos en formato MP4.</p>"+
" </video>"+
" </div>";
document.write(htmCod);
}
//////////////////////////////////////////////////////////////////////////////
function IFrView(pagUrl,
widPix,
heiPix)
// PURPOSE: Writes a Html code for a iframe.
//////////////////////////////////////////////////////////////////////////////
{
var iFrCod =
" <center>"+
" <iframe "+
" frameborder='0'"+
" scrolling ='no'"+
" src ='"+pagUrl+"'"+
" width ='"+widPix+"'"+
" height ='"+heiPix+"'>"+
" </iframe>"+
" </center>";
document.write(iFrCod);
}
iForense construye las paginas del sitio sobre informática forense Forense.Info
2015 asolver.com | Aviso legal | XHTML | Δ Θ Ξ | Creative Commons | Mapa y funciones del sitio