Jump to content

Recommended Posts

Hi,

 

I have made a page that uses an I-frame.

the main page is /gedichten/test/testgedicht.php?poem_id=1  for example

the I-frame is in /functieknoppen/functieknoppengedicht.php

 

I try to get the poem_id from the main page his url  to use it in that I-frame (with $_GET),

is that possible?

Link to comment
https://forums.phpfreaks.com/topic/146647-solved-_get-problem-2/
Share on other sites

Okay..

 

1) Main page is load with ?poem_id=123.

2) the Main page contains an Iframe..

 

So. instead of having

<iframe src="/functieknoppen/functieknoppengedicht.php">

to load up your iframe you do this

<iframe src="/functieknoppen/functieknoppengedicht.php?poem_id=<php echo $_GET['poem_id']; ?>"

thus passing poem_id from the main page to the iframe..

So in view source it will appear as

<iframe src="/functieknoppen/functieknoppengedicht.php?poem_id=123"

 

Now when functieknoppengedicht.php loads up it will be able to use $_GET['poem_id']..

 

Another option is always sessions!

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.