PDA

View Full Version : link from an iframe to a table?


Oreias
06-09-2011, 03:36 PM
Hey there!

This feels so silly to ask but I'm stuck and my brain just won't give me the answer like it has before lol

I have an iframe for my links section in my sidebar and I want to link from that iframe to the main table I have in the actual layout. For some reason the target="main" doesn't work like it should :(

What am I doing wrong? This is what I've tried:
<a href="tidsbokning.html" target="main">Tidsbokning</a>

So far the site isn't up online yet so it's hard for me to show the codes, but if you'd like I'm sure I can flip it up somewhere even though I'm not done yet heh.. I'd rather not do it yet tho lol

Can anyone help me to solve this mystery? :roll:

domedia
06-09-2011, 06:24 PM
Hi Oreias,
If the window is named 'main', then it should work. If it does not work, something else is wrong.

But really, no parts of your local website should be in a frame unless you're loading any kind of external web page. This is going to be very frustrating for you to maintain, when you can just have one html document per page like all normal web sites do.

johnMoss
06-10-2011, 04:19 AM
Have you validated your code? Links breaking down that otherwise are in order may be doing so due to an either unclosed, or improperly closed tag somewhere upstream in the flow...

Oreias
06-10-2011, 04:49 AM
Domedia: Well, I'm not using frames at all first of all, I'm using tables because my layout is based on css mostly.

John: I'll look into that again and see if I can find anything today, I might have over worked myself for a few hours so small details are easy to miss when coding that long ^^

thank you both of you! ^^

domedia
06-10-2011, 12:48 PM
I have an iframe for my links section in my sidebar and I want to link from that iframe to the main table I have in the actual layout.

Domedia: Well, I'm not using frames at all first of all, I'm using tables because my layout is based on css mostl
:confused: So are you using frames or not?

And a table based layout is opposite from a CSS based output.

Oreias
06-10-2011, 01:47 PM
No. I'm NOT using frames, I'm using Tables with css stylesheets that links to every page.

gentleone
06-10-2011, 09:08 PM
I have an iframe for my links section in my sidebar and I want to link from that iframe to the main table I have in the actual layout. For some reason the target="main" doesn't work like it should.
Why do you have your link section (menu I assume) in an iframe anyway (yes these belong to frames and are bad for numerous things such as accessibility, usability and SEO).
Anyways... it's not going to work like that how you want. If you have an iframe. then the content of it is a separate, individual page from which you can't control content into you're other page (your page with the table). Oh and Domedia is right... you have a table based layout and perhaps with aome CSS hooks on it, but tables are meant to hold tabular data... that's where they are invented for and not for layout.

DWcourse
06-10-2011, 11:08 PM
I'm totally confused :confused: an iframe is a frame and a table-based layout with CSS is different from a CSS-based layout.

You need to find a serveer where you can upload a sample page and send a url.

jmichae3
06-14-2011, 06:04 AM
one thing you could consider is writing a PHP script to generate your menus, using comment-substitution. I did
essentially, it uses a template-based page (such as a dreamweaver template you can create or a flat file)

I have written 3 such menu systems for 3 different types of menus - breadcrumb, tree (2 types), and horizontal tab. the code is pretty much similar. it uses an XML file to store the menu structure. not safe to interrupt the process while it is generating the menus, but you can interrupt while it is FTP-ing.
it automatically can ftp the entire site HTML/xhtml files up to the server for you. it uses comments such as <!--pagecounterstart--> <!--pagecounterend--> and substitutes content in between the comments during menu7.php script execution.

the code is GPL3'd.


you can find it at http://JesusnJim.com/code/php/menu.html

jmichae3
06-14-2011, 06:29 AM
by the way, it is something you run on your local machine, NOT on the server.

jmichae3
06-30-2011, 09:08 PM
I should mention that you don't run it on the server because it was never meant to run on the server. it has very long runtime for sites with 700 pages (15 minutes to generate menus and ftp the files to the server.