| View previous topic :: View next topic |
| Author |
Message |
seanie morris
Joined: 02 Jun 2005 Posts: 49 Location: Offaly, Ireland
|
Posted: Mon Jul 09, 2007 6:55 am Link in iFrame to the same browser window? |
|
|
|
Hi folks,
I have added a small iFrame which shows a thumbnail from a gallery I have installed (4Images). The work-in-progress and the 'thumbnail iframe' can be seen here:
http://www.tullamorelife.net/index2.html
I tweaked an associated php file for the 4Images gallery programme to open up from when the thumbnail is clicked to (what will be my new) site gallery introduction page, instead of the actual image in the 4Images gallery. However, as it is embedded in the iframe, the only way I can find opening the page properly is with the "_blank" target path. Using "_parent" and "_self" will only open up the page in the tiny iFrame. Can this be ovrcome?
I have looked back on some older posts, and I am not sure, but would the following post suit my request?
http://www.htmlcodetutorial.com/help/ftopic8381.html
Thanks for looking,
Seanie. |
|
Corey Bryant

Joined: 15 May 2004 Posts: 8154 Location: Castle Rock CO USA
|
Posted: Mon Jul 09, 2007 11:14 am |
|
|
|
|
is the the code
| Code: |
| <iframe src="http://www.tullamorelife.net/4images/random.php" href="../gallery.html" target="_blank" align="center" width="175" height="155" scrolling="No" frameborder="0" bgcolor="#C9D3DE"> </iframe> |
And what do you want to happen when you click on this link to open up gallery.html?
_________________
Corey
Toll Free Fax Numbers | Yahoo Merchant Account |
|
seanie morris
Joined: 02 Jun 2005 Posts: 49 Location: Offaly, Ireland
|
Posted: Mon Jul 09, 2007 1:17 pm |
|
|
|
Hi Corey,
that is the current code above, yes. What I want to do is replace the "_blank" tag with "_parent" or "_self" and have the link open in the same browser window, and not a new one, and also not in the iframe from which the link as you can see is contained therein.
Seanie. |
|
Corey Bryant

Joined: 15 May 2004 Posts: 8154 Location: Castle Rock CO USA
|
Posted: Tue Jul 10, 2007 6:57 am |
|
|
|
Name your iframe and then target your iframe.
| Code: |
| <iframe src="http://www.tullamorelife.net/4images/random.php" href="../gallery.html" target="gallery" name="gallery" align="center" width="175" height="155" scrolling="No" frameborder="0" bgcolor="#C9D3DE"> </iframe> |
_________________
Corey
Toll Free Fax Numbers | Merchant Accounts |
|
seanie morris
Joined: 02 Jun 2005 Posts: 49 Location: Offaly, Ireland
|
Posted: Tue Jul 10, 2007 12:46 pm |
|
|
|
| Corey Bryant wrote: |
| Name your iframe and then target your iframe. |
Won't that mean then Corey that it will simply do what it is already doing? You can see it live the little iframe I am talkin about on the homepage www.tullamorelife.net in the Galleries box in the centre of the page. I managed to tweak the referenced php file from the galleries directory to open the link (referenced by the thmbnail(s) visible) in a new window.
I want to open it in the same window, NOT the tiny iframe that is present.
Seanie. |
|
seanie morris
Joined: 02 Jun 2005 Posts: 49 Location: Offaly, Ireland
|
Posted: Tue Jul 10, 2007 12:49 pm |
|
|
|
| By the way, if there was no solution, but even out of curiosity anyway, can I contain the whole body of the webpage in an iframe? Then give that a name (e.g. "mainiframe"), and reference the link from the thumbnails iframe to "mainiframe"? |
|
Corey Bryant

Joined: 15 May 2004 Posts: 8154 Location: Castle Rock CO USA
|
Posted: Wed Jul 11, 2007 6:05 am |
|
|
|
You could try to target the mainframe - but you seemed to have two iframes. Any reason why you are using iframes? They cause more problems unfortunately.
_________________
Corey
Toll Free Fax Numbers | Mile High Merchant Accounts |
|
seanie morris
Joined: 02 Jun 2005 Posts: 49 Location: Offaly, Ireland
|
Posted: Wed Jul 11, 2007 8:49 am |
|
|
|
| Corey Bryant wrote: |
| You could try to target the mainframe - but you seemed to have two iframes. Any reason why you are using iframes? They cause more problems unfortunately. |
Do they? Darn. I thought iframes eliminate older browsers ability to read webpages made up of regular frames properly. The 2 iframes present are requested from the source of what I wanted to add. But, I think I might tinker around with them to see if I could get them to work in ordinary div's. My attempts to do that were resulting in at least the Gallery thumbnail iframe not working. But then, I'm no expert, so I probably overlooked something in the code.  |
|
Corey Bryant

Joined: 15 May 2004 Posts: 8154 Location: Castle Rock CO USA
|
Posted: Wed Jul 11, 2007 10:43 am |
|
|
|
Frames / iframes are basically the same (problematic) thing. I view a lot of sites on my Blackberry and frames are very cumbersome on a browser like that.
Use divs or even tables to help layout a website. In my opinion (and a lot of others) frames just should not be used at all - from SE point-of-views to browsers.
_________________
Corey
My Merchant Account Blog | Merchant Accounts | Bookkeeper Program |
|
|