Solved

Java Applet Won't Allow Anything Else on its Page

Posted on 2004-04-15
9
227 Views
Last Modified: 2010-05-18
Hello,

Thanks for reading our question.  We have a java applet.  It’s a chat room.  We want to add a banner rotation applet above it.  When we put the chat applet alone on a page, and set its dimensions to 100% x 100%, the resulting chatroom sits dead center in the middle of the page and is infinitely resizable.  You can make the window even super teensy, but the whole applet shrinks or enlarges to any dimension of the page.

However, if we add <i>anything</i> else above the chat applet, even just a <p>, then the lower edge of the chatroom falls beneath the visible.  You can still drag the window to any dimension, but the bottom edge of the chatroom always bleeds off.  Is there any way to add something to the page a java applet is on and still keep all the edges of the applet visible, and have it automatically resize to any window dimension?

Many thanks,

Yunkaa

We have tried putting both in a table and setting the table to 100% width and height, but still the lower edge of the chat applet falls beneath the visible.
0
Comment
Question by:yunkaa
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 3
9 Comments
 
LVL 2

Expert Comment

by:sc0rp10n
ID: 10839676
Hi Yunkaa,

Personally, I dont believe using % values for applet sizes is a good idea. For your situation, I would suggest, the following:

- While page loading, get the window's available width and height,
- then calculate the proper values that you would want to have for the applet, and
- write those values to the applets widht & height params.

Also, for placement of the applet, if the table doesn't work, try using <div> tags and setting the width and height in the div's style properties.

I'm sure you need to play with this for a bit to get it right.

goodluck, HTH.
Ajay


0
 

Author Comment

by:yunkaa
ID: 10840542
Hello,

Is there any workaround for this?  We'd love to be able to add something to this page.  The users are really happy with its performance, drag it any which way.  The situation: a chat applet set at 100% x 100%.  Opens in a popup.  We want to add a banner applet above the chat.  Putting tha banner on the page with the chat causes the chat to fall off the lower edge of its window.  Puttin anything on there, a <p> does the same.  Anyone have a little magic code lying around.

Many thanks,

Yunkaa
0
 
LVL 7

Accepted Solution

by:
mark-b earned 500 total points
ID: 10843142
How about a two framed frameset?  

Ex:

<FRAMESET ROWS="53,*" FRAMESPACING="0" FRAMEBORDER="0" MARGINHEIGHT="0" MARGINWIDTH="0" BORDER="0">
 <FRAME SRC="banner.html" FRAMEBORDER="0" BORDER=0 SCROLLING="NO" MARGINWIDTH="0" MARGINHEIGHT="0" FRAMESPACING="0" NAME="BANNER">
 <FRAME SRC="chat.html" NAME="MAIN" FRAMEBORDER="0" SCROLLING="YES" MARGINWIDTH="0" MARGINHEIGHT="0" FRAMESPACING="0" BORDER=0>
</FRAMESET>

Have the 'banner.html' contain the banner applet for your banners, and have the 'chat.html' contain the chat applet (still at 100% x 100%).
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:yunkaa
ID: 10844240
Hello,

Well...!  WELL?!!! YOU ARE SUCH A <b>SUPER MAGIC EXPERT!!!!!!!!!!!!!!!!!!!!!!!!!!!</b>  Thank you, THANK YOU!! Please get the wizard's hat.  We fooled around with frames for half the day but they kept collapsing on each other in resizing.  This is so WONDERFUL.  
=) =) =)

Please can you tell us which among the many zeroes here should we work with to create some margins around the outer edges of the "page".  And, again... so many thanks.

Yunkaa
0
 

Author Comment

by:yunkaa
ID: 10844428
We have posted a follow up question... =)
0
 
LVL 7

Expert Comment

by:mark-b
ID: 10844565
No problem.  As far as the margin goes, I guess I would suggest you do it by style (in the applet.html file, not in the frameset html file):

<html>
 <head>
  <style type="text/css">
    BODY {
     margin:50px;
    }
  </style>
.
.
.
</html>
0
 

Author Comment

by:yunkaa
ID: 10844677
Hello MArk,

THanks agian.  What we should have wrote is that we WILL BE POSTING  a follow up in another question.  We weren't trying to be pushy!  We have posted that follow up now.  Will probably make more sense there.  And again, aginn x 1,000,000 THANK YOU! :) :) :)
0
 
LVL 7

Expert Comment

by:mark-b
ID: 10844891
Glad I could help!, and thanks for the points.  

Looks like Cd& has a good answer your other question.

-Mark
0
 

Author Comment

by:yunkaa
ID: 10845481
Hello Again Mark,

And, you REALLY did help.  We would never have been able to do it without you.  We were totally stuck.  The developers were dragging their feet, and we were at our wits end.  Our HTML editor was just returning preloaded pages for frames, so we just gave up.  We had Frankenstiened a work around, involving giving the chat applet a height of 80%, but it just looked so rickety.  And, the chat before was so nice, so suddenly rickety was not what we were searching for.  Thank you again for sharing your expertise.  You saved the day, for sure. :))))))))))))))))))))))))))
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Browsers only know CSS so your awesome SASS code needs to be translated into normal CSS. Here I'll try to explain what you should aim for in order to take full advantage of SASS.
SASS allows you to treat your CSS code in a more OOP way. Let's have a look on how you can structure your code in order for it to be easily maintained and reused.
The viewer will receive an overview of the basics of CSS showing inline styles. In the head tags set up your style tags: (CODE) Reference the nav tag and set your properties.: (CODE) Set the reference for the UL element and styles for it to ensu…
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

730 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