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='Centro'>"+
" <object"+
" data = 'http://www.blason.es/heraldo/"+pdfNam+".pdf"+
"#toolbar=0&navpanes=0&scrollbar=1&page=1&view=FitV'"+
" width = '760'"+
" height = '535'"+
" 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='Centro'>"+
" <video width='667' height='500' controls='controls'>"+
" <source src='../heraldo/"+mp4Nam+".mp4' type='video/mp4'>"+
" <p>Su navegador no puede visualizar videos en formato MP4.</p>"+
" </video>"+
" </div>";
document.write(htmCod);
}
//////////////////////////////////////////////////////////////////////////////
function IFrView(pagUrl,
claNam)
// PURPOSE: Writes a Html code for a iframe.
//////////////////////////////////////////////////////////////////////////////
{
var iFrCod =
" <iframe "+
" src = '"+pagUrl+"'"+
" class = '"+claNam+"'>"+
" Este navegador no puede visualizar iframes."+
" </iframe>";
document.write(iFrCod);
}
con-Q.tv construye las páginas del sitio y newsletter Con-Q.tv
2015 asolver.com | Aviso legal | XHTML | Δ Θ Ξ | Creative Commons | Mapa y funciones del sitio