471,898 Members | 1,766 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,898 software developers and data experts.

Window size and javascript HTML for my site.

Hi. I must first say I'm not an experienced scripter.

Here's my problem and how far I am so far. I struggled for awhile to get the browser to fill most of it with my flash movie and keep it proportional if the user chooses to size up or size down. This pretty much takes care of the browser size complications. Here is original script and it works. But now I have few problems after this.
Expand|Select|Wrap|Line Numbers
  1. <!-- masked -->
  3. <html> 
  4. <head>
  5. <title>PinkSlipStudio</title>
  6. </head>
  7. <!--text used in the movie-->
  10. <frameset rows="100%,*" border="0">
  12. <frame src="http://www.spiralof5.com/pinkslipstudio.swf" frameborder="0">
  14. <frame frameborder="0" noresize>
  16. </frameset>
  18. </html>
  19. <!-- m -->
So far so good. But, if I'm calling out a complicated java action (I am using borderless exact size popups which is this code in flash
Expand|Select|Wrap|Line Numbers
  1. getURL("javascript:openNewWindow('http://www.spiralof5.com/tb_flash2.swf','thewin', 'height=206,width=430,toolbar=no,scrollbars=no')");
in flash this isn't enough. If I were to just export my html file (instead of starting on my own from scratch) flash 2007 USE TO export out this html

Expand|Select|Wrap|Line Numbers
  1. <script language="JavaScript">
  2. function openNewWindow(URLtoOpen, windowName, windowFeatures) {
  3. newWindow=window.open(URLtoOpen, windowName, windowFeatures); }
  4. </script>
o.k. The reason why I say USE TO is because Flash 8 now exports out something different which doesn't allow me to do popups the way I used to. So I export the html from Flash 8, insert the above code #2 and oila, javascript works again in Flash8 and I now have popups.

But remember this doesn't have code #1 in it. Since I don't want the object tags and body tags messing with the code from #1 I instead paste code #2 into my made from scratch html that contains code #1. I get no popups. I've tried to mix and match the html files and this is what I came up with but it doesn't work.

Expand|Select|Wrap|Line Numbers
  1. <!-- masked -->
  3. <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> 
  4. <head>
  5. <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
  7. <title>PinkSlipStudio</title>
  8. <script language="JavaScript">
  9. function openNewWindow(URLtoOpen, windowName, windowFeatures) {
  10. newWindow=window.open(URLtoOpen, windowName, windowFeatures); }
  11. </script>
  13. </head>
  14. <!--text used in the movie-->
  16. <frameset rows="100%,*" border="0">
  18. <frame src="http://www.spiralof5.com/pinkslipstudio.swf" frameborder="0">
  20. <frame frameborder="0" noresize>
  22. </frameset>
  23. <object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0">
  24. <param name="allowScriptAccess" value="sameDomain"/>
  25. <embed allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer"/>
  26. </object>
  27. </html>
  28. <!-- m -->
just so you know this isn't for annoying popups, I am an artist and this is for my portfolio site www.spiralof5.com.

Thank you very much,

Sep 11 '07 #1
2 1578
7,435 Expert 4TB
Please be aware that html is not a scripting languge but a "markup" language.
Also, Java is not the same thing as Javascript and they have nothing in common despite the name.

Your page does not have a proper doctype. Without one, IE goes into 'quirks mode'. See the article above about doctypes under Articles.

While you are there, also read about validating your html and css so you can get those lists of errors in your markup.
I am an artist
That's OK. We get all kinds here. :)

Since this is really a javascript question, I will send this thread there.
Sep 11 '07 #2
thank you!

I apologize, I thought this would be an html question due to the fact there's something not in the html that I thought I needed to add.
Sep 12 '07 #3

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

5 posts views Thread by Carol Lyn | last post: by
3 posts views Thread by Chris | last post: by
14 posts views Thread by D. Alvarado | last post: by
26 posts views Thread by yb | last post: by
5 posts views Thread by JNariss | last post: by
3 posts views Thread by EnjoyNews | last post: by
7 posts views Thread by Dr J R Stockton | last post: by
reply views Thread by YellowAndGreen | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.