Jump to content


Photo

Passing Variable to a Frameset


  • Please log in to reply
2 replies to this topic

#1 nikhilthecool

nikhilthecool
  • Members
  • PipPip
  • Member
  • 18 posts

Posted 24 April 2006 - 07:00 AM

Hi,

I pass a variable "name" from first.php as follows:

<a href="second.php?name=<?=$row["username"]?>"Click Here</a>


Now i get the value using $_REQUEST["name"]

However, i need the value in second1.php which is a frame in second.php

second.php (frameset)
__|__
| |
second1.php second2.php


As a result, i cant get the value using $_REQUEST.

What do i need to do to access the variable $_REQUEST['name'] in second1.php??????

Please help.

Thanks.

#2 wildteen88

wildteen88
  • Staff Alumni
  • Advanced Member
  • 10,482 posts
  • LocationUK, Bournemouth

Posted 24 April 2006 - 08:16 AM

You will want to give secound1.php frame a name. Then with your link use the target atrribute like so: target="secound1FrameNameHere" When you click the link the browser will goto the secound1.php frame rather than the whole page.

#3 nikhilthecool

nikhilthecool
  • Members
  • PipPip
  • Member
  • 18 posts

Posted 24 April 2006 - 08:52 AM

No. I want to open second.php only on click.

Also i want to access the variable in second1.php

Its like, on first.php i click on the link "Click Here"

After clicking, i need to open second.php and pass variable "name" to both second1.php and second2.php so that i can be able to use them there.

Please help...




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users