Login   Register  
Icontem

File: resize_example.html

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of Arturs Sosins  >  Background resizer  >  resize_example.html  >  Download  
File: resize_example.html
Role: Example script
Content type: text/plain
Description: Example script
Class: Background resizer
Display an image as background of a whole Web page
Author: By
Last change: credits changed
Date: 2011-04-25 11:51
Size: 1,358 bytes
 

Contents

Class file image Download
<!--
/*************************************************************
 * This script is developed by Arturs Sosins aka ar2rsawseen, http://webcodingeasy.com
 * Fee free to distribute and modify code, but keep reference to its creator
 *
 * Background resizer class can be used to display high resolution images as background for websites. 
 * Class will resize background image for different screen resolutions supporting this criterias: 
 * fill window from edge to edge
 * display largest area posible
 * keep image proportions (without streching image)
 * hide scrollbars caused by background image
 * support most popular browsers (including IE)
 *
 * Online documentation: http://webcodingeasy.com/JS-classes/High-resolution-image-background-resizer 
**************************************************************/
-->
<html>
<head>
</head>
<body style='text-align: center;'>
<div style='width:1000px; margin: 0 auto 0 auto; height:500px; border: 3px solid black;'>
somecontent
<p>somecontent here</p>
<div> and here </div>
</div>
<script type="text/javascript" src="./bg_resizer.packed.js" ></script>
<script type="text/javascript">
//create rating instance
//parameter json with configuration values
bg_resizer("./large_bg.png", {minwidth: 600, minheight: 300, maxwidth: 1920, maxheight: 1280});
</script>
</body>
</html>