1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Div links

Discussion in 'CSS' started by cosa, May 6, 2005.

  1. #1
    i'm not very good at this, but i have been trying to create a page with all tables and divs. I been trying to create a menu that links .html files into a <div> box.. is there a way to do that? or do i have to create another type of file different than .html ? please let me know! =(
    SEMrush
     
    cosa, May 6, 2005 IP
    SEMrush
  2. pgruach

    pgruach Peon

    Messages:
    26
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #2
    you can't load a seperate page (html file) into a div. You could use an iframe to do that.
     
    pgruach, May 6, 2005 IP
  3. SEbasic

    SEbasic Peon

    Messages:
    6,318
    Likes Received:
    318
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Here is the code if you need it...

    <iframe src ="location of file goes here" width="163px" style="border: none; height: 130px;" frameborder="0"> </iframe>
     
    SEbasic, May 6, 2005 IP
  4. pgruach

    pgruach Peon

    Messages:
    26
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #4
    give the iframe a name

    <iframe src ="page1.html" name="myIframe" style="border: none;" frameborder="0"></iframe>

    Then in the menu.html you can do this (via javacript):
    frames['myIframe'].document.location.href = 'page2.html';
     
    pgruach, May 6, 2005 IP
  5. cosa

    cosa Peon

    Messages:
    6
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #5
    tnx for the help.
    i am actually using an iframe, but i dun like the horizontal scroll, that's what i was trying to use a <div> so it will only have the vertical scroll when the page within the frame is larger.

    and actually.. i used to link divs into divs with this line:
    <span onClick="document.getElementById('main').innerHTML=document.getElementById('links').innerHTML" style="cursor: crosshair" onMouseOut="this.style.textDecoration='none';this.style.color='#6666CC'" onMouseOver="this.style.textDecoration='underline';this.style.color='#6666CC'"><span style="color:#6666CC;">links</span></span><br />
     
    cosa, May 6, 2005 IP
  6. Stin

    Stin Guest

    Messages:
    264
    Likes Received:
    9
    Best Answers:
    0
    Trophy Points:
    0
    #6
    if you have php you could just include it in there..
     
    Stin, May 8, 2005 IP