SitePoint Sponsor

User Tag List

Results 1 to 11 of 11

Thread: quicky

  1. #1
    SitePoint Guru
    Join Date
    Apr 2001
    Location
    BC, Canada
    Posts
    630
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hey, I need a script (javascript) that when a link is clicked, a new window pops up with a particular size (lets say 400x400) no scroolbars, no toolbars.. none of that junk.. just the blue title bar. When the window is opened it has to be directed to a particular page with a querystring
    lets say
    page.php?name=ak

    possible?


    thanx
    Last edited by slighltywhacked; May 23, 2001 at 18:06.

  2. #2
    SitePoint Wizard silver trophy
    beley's Avatar
    Join Date
    May 2001
    Location
    LaGrange, Georgia
    Posts
    6,117
    Mentioned
    3 Post(s)
    Tagged
    0 Thread(s)
    Adobe GoLive has that feature built-in. Dreamweaver probably does as well. Do you have either of these programs? I would be happy to describe how to do it in GoLive, or let me know. I'll create one and upload it for you to see. You could probably copy the code and modify it.

  3. #3
    SitePoint Wizard silver trophy
    beley's Avatar
    Join Date
    May 2001
    Location
    LaGrange, Georgia
    Posts
    6,117
    Mentioned
    3 Post(s)
    Tagged
    0 Thread(s)
    Actually, just email me and give me a full URL with query and I'll create the JS in GoLive and upload it. I'll post it here for everyone.

    Just let me know the dimensions of the page (400x400), the URL, and whether you want a text link or a graphic.

    My email is beley@mac.com

  4. #4
    SitePoint Wizard silver trophy
    beley's Avatar
    Join Date
    May 2001
    Location
    LaGrange, Georgia
    Posts
    6,117
    Mentioned
    3 Post(s)
    Tagged
    0 Thread(s)
    Try this - http://www.2bigfeet.com/test.html - see if that works for you... Good luck!

  5. #5
    SitePoint Addict Drinky's Avatar
    Join Date
    Jan 2001
    Location
    England
    Posts
    338
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    OMG WTH is all that?!?!?!
    Adobe javascript bloatware!

    BTW it doesn't work http://www.guntrisoft.com/dev/james/...4013/error.gif


    Try this

    Code:
    <html>
    <head>
    
    <script language="javascript">
    <!--
    	function openPopUp(WindowURL,WindowName,X,Y){
    		newPopUp = window.open(WindowURL,WindowName,'toolbar=no,location=no,directories=no,status=no,resizable=no,copyhistory=no,width=' + X +',height=' + Y)
    	}
    //-->
    </script>
    
    </head>
    <body>
    	<a href="javascript:openPopUp('page.php','myNewWin',400,400);">Click Me!</a>
    </body>
    </html>
    Drinky

  6. #6
    SitePoint Guru
    Join Date
    Apr 2001
    Location
    BC, Canada
    Posts
    630
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I get butchered with error messages Drinky

    here...


    Internal Server Error
    The server encountered an internal error or misconfiguration and was unable to complete your request.
    Please contact the server administrator, webmaster@dotcommediainc.com and inform them of the time the error occurred, and anything you might have done that may have caused the error.

    More information about this error may be available in the server error log.

  7. #7
    SitePoint Addict Drinky's Avatar
    Join Date
    Jan 2001
    Location
    England
    Posts
    338
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    ??? Can you be a little more specific, as that means nothing.
    Javascript cannot cause internal server errors.
    Drinky

  8. #8
    I am the night... bman's Avatar
    Join Date
    Mar 2001
    Location
    In a van... down by the river.
    Posts
    366
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    did you take the space out of where it says
    Code:
    <a href="java script:openPopUp('page.php','myNewWin',400,400);">Click Me!</a>
    you need to remove the space in java script for it to work.. the forums put the space there.. that could be a possible cause..

    or you are trying to call a page that doesn't exsist..
    i dont know.. i am just guess here.. any of them could be a probable cause I would think
    Last edited by bman; May 25, 2001 at 11:11.
    Some say the world will end in fire, Some say in ice.
    From what I've tasted of desire
    I hold with those who favor fire.

  9. #9
    PHP Developer W1LL's Avatar
    Join Date
    Apr 2001
    Location
    Leicester, UK
    Posts
    459
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Here is a simple solution that actually works, and there isn't tonnes of script:

    <script language="JavaScript">
    function Start1(page) {
    OpenWin = this.open(page, "NewWindow1", "toolbar=no,menubar=no,location=no,scrollbars=no,resizable=no,width=400,height=400");
    }
    </script>

    Leave that script how it is, then just change all in red, in this next bit:

    <a href="javascript:Start1('page.htm')">

    NOTE: As said prior to this post, take out the space in "java script". It is an automatic thing SitePoint does.
    Hope that helps.

    - Will

  10. #10
    SitePoint Addict Drinky's Avatar
    Join Date
    Jan 2001
    Location
    England
    Posts
    338
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally posted by W1LL
    Here is a simple solution that actually works, and there isn't tonnes of script:
    My simple solution actually works too
    Drinky

  11. #11
    PHP Developer W1LL's Avatar
    Join Date
    Apr 2001
    Location
    Leicester, UK
    Posts
    459
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Okay fair enough, but I found it hard to work with and understand. Seeing as I'm not experienced in JavaScript.

    - Will


Bookmarks

Posting Permissions

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