Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Frames 2

Status
Not open for further replies.

edgarv

MIS
Jul 25, 2003
248
US
Hello, I am new to web programming. I have a page that has two frames, I tried to put a back button but it sends only that frame to the page, the other frame stays. how can I apply the back button to both pages?

thanks
 
you want to send each frame to it's previous page? Or go to the last page the entire browser was viewing?

*cLFlaVA
----------------------------
[tt]insert funny quotation here.[/tt]
 
I want both frames to go back to whatever link type in.
 
Something like this:

Code:
function forceBack() {
    var w1 = parent.frames['frame1'];
    var w2 = parent.frames['frame2'];

    w1.history.go(-1);
    w2.history.go(-1);
}
Code:
<input type="button" onclick="forceBack();" value="Back" />

*cLFlaVA
----------------------------
[tt]insert funny quotation here.[/tt]
 
ahh very very nice, that is to go back. but how can I open a new link for example I have a picture page that has two frames and I want to have a button that sends the browser to the main page.
 
you mean like this?

Code:
<a href="mainpage.html" target="_top">Click</a>
OR
Code:
<input type="button" value="Click" onclick="top.location = 'mainpage.html';" />

*cLFlaVA
----------------------------
[tt]insert funny quotation here.[/tt]
 
Thank you very much.


every day you learn something new.

I appreciate the help
 
no problem-o.

*cLFlaVA
----------------------------
[tt]insert funny quotation here.[/tt]
 
Hello, I am new to web programming. I have a page that has two frames...
Since you're new to web programming here's some advice from an old hand - don't use frames. My first websites used them, I'm sure a lot of peoples' did, but the more you learn the more problems you discover with frame usage (and abusage). There's a good summary of frames issues here:
Save yourself some time and don't invest a lot of energy using such a flawed technique.

-- Chris Hunt
Webmaster & Tragedian
Extra Connections Ltd
 
Very interesting, well I think I kind of need to use frames on this because it is a photo album, it displays the thumbnails on the bottom and the pictures on top. So I don't really see how I would go about doing this with out frames. But I read and I have to agree with you Chris, frames seem to be more than what I can chew at this time. Thanks for the advice.

Edgar v
 
There is never a definitive need for oldschool frames. There are several solutions to the 'problem' you have described.

Iframes are one
SSI is another
server-script includes are a third (php, asp)

*cLFlaVA
----------------------------
[tt]insert funny quotation here.[/tt]
 
hmmm so I could build my photo album with asp or php? Well I will start reading some more on asp and php.
 
edgar check out even my site which is a photo gallery, I am not using frames, but rather dynamic pages. Also if you must use frames, try using the lesser of two evils such a <iframe> which embeds a window inside of the main window, and can be designed a little better.

Karl Blessing
PHP/MySQL Developer
 
that is a pretty nice website, but it would take me a while to learn asp and write something like that.

I really enjoy your pictures. Very cool
 
It's written in PHP, the way the URL is using mod_rewrite which apache uses to mask the url to make it more understandible. I got the code in php written to the point that there is a folder called 'gallery'

Gallery
|
---PeopleGallery
---AnimalGallery
---MiscGallery

If I want to add a picture, I simply upload the picture into one of the gallery folders, or make a folder and upload to it, the rest is automatic by php, lists them automatically, thumbnails them automatically, addes them to the database for voting automatically, as well as pulls the exif information automatically. Most of which is pretty easy, and the code is rather short in comparism to what I did in the past.

If nothing else, you can start off in PHP/ASP using includes to pull the page desired into the code of the main page.

Karl Blessing
PHP/MySQL Developer
 
I see, did you buy the code, and if you did how much did you pay for it. I unfortunately have not much money but it would be something great to look at and see if I can understand any of it. if you did not pay for it, where did you get it?
 
sure you can contact me via my contact page or my profile's email. I was gona share it thru tek-tips but i might have to do it peice by peice, like "How to get exif data from image", "how to read files out of a folder", "pull text out of file" stuff like that.

Karl Blessing
PHP/MySQL Developer
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top