HTML Help!!!!

Discussion in 'Technology' started by Ché, Nov 13, 2003.

Users Viewing Thread (Users: 0, Guests: 0)

  1. Ché

    Ché Registered User

    Joined:
    Nov 11, 2001
    Messages:
    2,053
    Likes Received:
    0
    Location:
    www.dj-che.tk
    HTML Help!!!!

    Right....

    I want to make a page with a couple of links on it. But when you click the link I want a new window to open (which I can do).

    the new window is just going to have a jpg image in it and what i want to do is make the new window open but only the size of the image.

    anyone?
  2. 1615634792921.png
  3. Mr. Revel

    Mr. Revel Registered User

    Joined:
    Nov 12, 2001
    Messages:
    9,894
    Likes Received:
    0
    use java script?


    <SCRIPT LANGUAGE="JavaScript">

    <!-- Begin
    window.open("home.html", "width=400", "height=400" "toolbar=yes" "location=yes","directories=yes","status=yes","menubar=yes","scrollbar=yes")
    // End -->
    </SCRIPT>
  4. Ché

    Ché Registered User

    Joined:
    Nov 11, 2001
    Messages:
    2,053
    Likes Received:
    0
    Location:
    www.dj-che.tk
    now im confused... how do i use this?

    i wanna use an image as the link button and I want the new window to be 372x541
  5. Mr. Revel

    Mr. Revel Registered User

    Joined:
    Nov 12, 2001
    Messages:
    9,894
    Likes Received:
    0
    In the head put.....you can change the position + size by changing the numbers....


    <head>

    <script language="JavaScript">
    <!-- hide

    function openNewWindow() {
    popupWin = window.open('home.htm',
    'open_window',
    'menubar,toolbar=0,location=0,status=0,menubar=0,scrollbars=0,resizable,top=0,left=0,width=800,height=450,left=130,top=140')
    }

    // done hiding -->

    </script>

    </head>


    then in the <body>
    <a href="javascriptpenNewWindow();"><IMG SRC="image.gif"></a>



    should work if ive typed it properly.
  6. Ché

    Ché Registered User

    Joined:
    Nov 11, 2001
    Messages:
    2,053
    Likes Received:
    0
    Location:
    www.dj-che.tk

    :( cant get it to work...

    im using 2x links (both with images as buttons) when each of them is clicked I want a smaller popup window to epen for each of them. java is too hard! :p
  7. Mr. Revel

    Mr. Revel Registered User

    Joined:
    Nov 12, 2001
    Messages:
    9,894
    Likes Received:
    0
    hmm, it should work?

    i htink the only way u can change the size of the window is using java script...

    do a search on google, there should be loads of tutorials?
  8. DoctorMick

    DoctorMick Registered User

    Joined:
    Apr 2, 2002
    Messages:
    3,828
    Likes Received:
    0
    Location:
    Sunderland :)
    Try:

    <a href="JavaScript: void window.open('home.htm', 'open_window', 'menubar,toolbar=0,location=0,status=0,menubar=0,scrollbars=0,resizable,top=0,left=0,width=800,height=450,left=130,top=140')"><img src="button.jpg" /></a>

    You will need to change home.htm to the page or jpg that you want to load in the new window, the height and width to be the size of the new window and the src to be the image of the button you want as the link.

Share This Page