Solved

image in html

Posted on 2000-04-26
6
130 Views
Last Modified: 2010-05-18
Hi
i want to make an html file with image in it that will be opened to the full size of the broweser
how should i do that????
something like
<img src="..." ????>
0
Comment
Question by:ntdragon
  • 3
  • 3
6 Comments
 
LVL 33

Expert Comment

by:knightEknight
Comment Utility
Do you mean you want the image to be the size of the screen?

<HTML>
<BODY>
<SCRIPT language='javascript'>
  var w=screen.width-10;
  var h=screen.height-15;
  top.moveTo(1,1);
  top.resizeTo(w,h);
  document.writeln("<IMG src='myimage.gif' width='"+w+"' height='"+h+"'>");
</script>
</body>
</html>
0
 
LVL 33

Accepted Solution

by:
knightEknight earned 5 total points
Comment Utility
or even better is this:

<HTML>
<BODY>
<SCRIPT language='javascript'>
  var w=screen.width-5;
  var h=screen.height-5;
  top.moveTo(1,1);
  top.resizeTo(w,h);
</script>
<IMG src='myimage.gif' width='100%' height='100%'>
</body>
</html>
0
 
LVL 8

Expert Comment

by:jbirk
Comment Utility
Just tell it to take up 100% of width and height:
<img src="agif.gif" width="100%" height="100%" border=0>

If you are wanting to change more than just one image, it may be more complicated.  Post you current html, and I can try to come up with a plan for stretching it.
-josh
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 8

Expert Comment

by:jbirk
Comment Utility
jbirk changed the proposed answer to a comment
0
 
LVL 8

Expert Comment

by:jbirk
Comment Utility
Kek beat me to it again!  :)
0
 
LVL 33

Expert Comment

by:knightEknight
Comment Utility
just barely!  :)
I don't know why I didn't think of that the first time.  I guess I was just focusing on getting the window size to match the screen size.
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

Building a website can seem like a daunting task to the uninitiated but it really only requires knowledge of two basic languages: HTML and CSS.
This article explains how to prepare an HTML email signature template file containing dynamic placeholders for users' Azure AD data. Furthermore, it explains how to use this file to remotely set up a department-wide email signature policy in Office …
In this tutorial viewers will learn how add a full-size background image to a webpage using CSS3. Create a new HTML document with an internal stylesheet.: In CSS, define the html element to have a background image. Use a high resolution image.: In t…
In this tutorial viewers will learn how to style elements, such a divs, with a "drop shadow" effect using the CSS box-shadow property Start with a normal styled element, such as a div.: In the element's style, type the box shadow property: "box-shad…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now