menuless browser window

Posted:
in Genius Bar edited January 2014
Is there an easy way, applescript or otherwise, to code a link on a webpage so that when you click on it, a new menuless-buttonless fixed size window opens with whatever content?



I have seen lots of websites that do that, and I would like something similar, yet I still haven't understood how to do it after viewing the source. This is an example, click on the link at the bottom of the page to see what I mean:



<a href="http://68.13.229.140:82/weather.htm"; target="_blank">Oklahoma Weather</a>



Tips? Ideas?



Thanks.

Comments

  • Reply 1 of 2
    foadfoad Posts: 717member
    Here is one way to do it.



    STEP 1: Insert this in between your HEAD tags



    [code]

    &lt;script language="JavaScript" type="text/JavaScript"&gt;

    &lt;!--

    function MM_openBrWindow(theURL,winName,features) { //v2.0

    window.open(theURL,winName,features);

    }

    //--&gt;

    &lt;/script&gt;

    </pre><hr></blockquote>



    STEP 2: Insert this where ever you want.



    [code]

    &lt;a href="#" onC1ick="MM_openBrWindow('page.html','','width=500 ,height=500')"&gt;Page With W and H of 500 pixels.&lt;/a&gt;

    </pre><hr></blockquote>





    Let me explain this really quick. Step 1 inserts the Javascript needed to open up a popup window and set the variables needed...ie, URL of the page you want to open.



    Step 2 is the actual link. If you disect what I wrote up top you get open the HTML file page.html, with the window size of 500x500, and the actual link being called "Page With W and H of 500 pixels."



    Let me know if that doesn't make sense.



    NOTE: Replace the "1" in onC1ick with a "l".
  • Reply 2 of 2
    bill mbill m Posts: 324member
    Foad, that is exactly what I was looking for!

    It works great. Thank you very much for your detailed description.



    Regards,

    Bill



    :cool:
Sign In or Register to comment.