Results 1 to 5 of 5

Thread: Html

  1. #1
    tim's Avatar
    tim
    tim is offline Senior Member
    Join Date
    Dec 2007
    Posts
    435
    Rep Power
    7

    Default Html

    Hello everyone :)

    I have placed this in the forum lobby because HTML is not Java related. I would like to use Notepad and HTML to place an applet on the internet. I don't know much about HTML, but I have the following:
    Java Code:
    <HTML>
    	<HEAD>
    		<TITLE>
    			Tim's Site
    		</TITLE>
    	</HEAD>
    	<BODY>
    		<APPLET CODE = site.Main.class WIDTH = 100 HEIGHT = 100>
    		</APPLET>
    		<P>
    			Test
    		</P>
    	</BODY>
    </HTML>
    The applet works but I want it to fit the browser's window. At the moment it is an a 100x100 box.

    Thank you ;)
    Eyes dwelling into the past are blind to what lies in the future. Step carefully.

  2. #2
    fishtoprecords's Avatar
    fishtoprecords is offline Senior Member
    Join Date
    Jun 2008
    Posts
    571
    Rep Power
    7

    Default

    so what happens when you test it without the height= and width= parameters?
    Its been a decade since I did serious applet stuf

  3. #3
    Nicholas Jordan's Avatar
    Nicholas Jordan is offline Senior Member
    Join Date
    Jun 2008
    Location
    Southwest
    Posts
    1,018
    Rep Power
    8

    Default current practice

    Applet probably real problem because too small if no size params. Also, current RFC asks that we use an <object ..../> tag, giving identifiers for applets and full how-to

    Also, we can pass parameters in the html tag that calls the applet.

    I find that handy, I will even use trivial name=value pairs.
    Introduction to Programming Using Java.
    Cybercartography: A new theoretical construct proposed by D.R. Fraser Taylor

  4. #4
    tim's Avatar
    tim
    tim is offline Senior Member
    Join Date
    Dec 2007
    Posts
    435
    Rep Power
    7

    Default

    Thank you fishtoprecords
    Quote Originally Posted by fishtoprecords View Post
    so what happens when you test it without the height= and width= parameters?
    Its been a decade since I did serious applet stuff
    If I remove the width and height tags, then the applet is shown in a 192x192 box. Maybe it's some portion of the window size or just a default size. However, the applet is still bounded in a small box. ;)
    Eyes dwelling into the past are blind to what lies in the future. Step carefully.

  5. #5
    tim's Avatar
    tim
    tim is offline Senior Member
    Join Date
    Dec 2007
    Posts
    435
    Rep Power
    7

    Default Solution found

    Hello Nicholas Jordan and fishtoprecords.

    I found a solution for my problem:
    Java Code:
    <HTML>
    	<HEAD>
    		<TITLE>
    			Tim's Site
    		</TITLE>
    	</HEAD>
    	<BODY>
    		<APPLET CODE = site.Main.class WIDTH = [COLOR="royalblue"]"100%"[/COLOR] HEIGHT = [COLOR="RoyalBlue"]"100%"[/COLOR]>
    		</APPLET>
    		<P>
    			Test
    		</P>
    	</BODY>
    </HTML>
    Thank you. ;)
    Eyes dwelling into the past are blind to what lies in the future. Step carefully.

Similar Threads

  1. JScrollPane with HTML
    By Java Tip in forum Java Tip
    Replies: 0
    Last Post: 03-14-2008, 12:32 PM
  2. Transforming XML to HTML
    By Java Tip in forum Java Tip
    Replies: 0
    Last Post: 03-01-2008, 11:06 PM
  3. ResultSet to HTML
    By Java Tip in forum Java Tip
    Replies: 0
    Last Post: 02-12-2008, 10:32 AM
  4. HTML editor
    By blueboy in forum AWT / Swing
    Replies: 0
    Last Post: 01-15-2008, 01:52 PM
  5. HTML to PDF
    By Heather in forum New To Java
    Replies: 1
    Last Post: 07-08-2007, 02:24 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •