Solved

Frameset refresh problem with php vs htm

Posted on 2002-04-10
7
547 Views
Last Modified: 2012-08-13
I have a simple frameset like this:

<frameset cols="50%,*">
<frame src="test2.php" name="menu" >
<frame src="test3.php" name="main" >
</frameset>

// test2.php
<html>
<body>
test2
<a href="test3.php">load test3</a>
</body>
</html>

// test3.php
<html>
<body>
test3
</body>
</html>


Now when I upload the frameset as frameset.htm it runs fine.  Then using the link I can get test3 in both subpages.  Hitting the browser refresh leaves test3 in both subpages.  

But if I save the frameset as frameset.php and follow the same steps it does NOT leave test3 in both pages.  Instead it reloads the default test2.php.

What is going on?  I am not using any php code in this example.  Is this something to do with headers?
0
Comment
Question by:kaller2
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 2
7 Comments
 
LVL 2

Author Comment

by:kaller2
ID: 6932781
BTW I am using IE 5.5, I would be interested to know if this behaviour is browser dependent.
0
 
LVL 2

Author Comment

by:kaller2
ID: 6932783
Also I am using a hosted service PHP 4.1.2 on Apache if that is any help.
0
 
LVL 2

Author Comment

by:kaller2
ID: 6933290
Hmm why when I increase points it still says the old ones?
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 5

Expert Comment

by:harwantgrewal
ID: 6933400
There is not a problem with the PHP every scripting language so the same whenever you refresh the page the request goes to the server and it loaded the page as fresh but when using the htm it opens the file from its cache and thats why you are watching the page as it is but when you refresht the php file the request goest to the webserver and it send the result to the browser..


Harry
0
 
LVL 2

Author Comment

by:kaller2
ID: 6933501
So the cached frameset reloads the current subpages, but if I reload the frameset I get the default subpages.
That makes sense but I don't like it.  

The users ought to be able to click on the main toolbar refresh and not revert to the default subpages, and this may be what happens with IE6 ?.

Anyway it looks as if I should leave my frameset as an html file.  The reason I converted it to a php file was to send it a querystring.  Will the frameset always refresh to the server if it has a querystring like this?

frameset.html?url=test4.php
0
 
LVL 5

Accepted Solution

by:
harwantgrewal earned 200 total points
ID: 6933506
ya if you want to display the page as it is you can manipulate the structure like this

<?if(!isset($ur){
$url=test2.php;
}?>
<frameset cols="50%,*">
<frame src="<?echo $url?>" name="menu" >
<frame src="test3.php" name="main" >
</frameset>

// test2.php
<html>
<body>
test2
<a href="javascrip:void(0)" onclike="top.location='frameset.php?url=test2.php'>load test3</a>
</body>
</html>

Harry
0
 
LVL 2

Author Comment

by:kaller2
ID: 6933633
Yup.  Onward....

0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Author Note: Since this E-E article was originally written, years ago, formal testing has come into common use in the world of PHP.  PHPUnit (http://en.wikipedia.org/wiki/PHPUnit) and similar technologies have enjoyed wide adoption, making it possib…
This article discusses how to implement server side field validation and display customized error messages to the client.
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

733 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question