Solved

How to redirect php output to another iFrame

Posted on 2006-10-19
3
379 Views
Last Modified: 2006-11-18
Hi everybody,

How can I redirect php output (echo or print) to another iFrame? Very short question...

Thanks

-A-
0
Comment
Question by:andy7789
3 Comments
 
LVL 14

Expert Comment

by:Aamir Saeed
ID: 17764876
You don't. The iframe should make the request to receive the output.
0
 

Author Comment

by:andy7789
ID: 17765120
No, it is possible to do this and one the ways is as follows:
1) you create a span in the target iFrame
2) create needed text strings with php
3) echo the jscript reference to the span as jscript function

The only thing I am missing is how to reference a content of the span with jscript and trigger the written jscript function. Maybe someone could help
0
 
LVL 4

Accepted Solution

by:
markdoc earned 500 total points
ID: 17766116
hi andy,

it seems you indeed have a javascript problem. you can use the following code in your javascript:

// . . .
window.frames["iframe_name"].document.getElemetById("the_child_window_span").innerHTML = "Sample PHP text";
// . . .

it would help though to know the exact nature of your page so i can be able to help you more.
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

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

Introduction HTML checkboxes provide the perfect way for a web developer to receive client input when the client's options might be none, one or many.  But the PHP code for processing the checkboxes can be confusing at first.  What if a checkbox is…
This article will explain how to display the first page of your Microsoft Word documents (e.g. .doc, .docx, etc...) as images in a web page programatically. I have scoured the web on a way to do this unsuccessfully. The goal is to produce something …
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…
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.

860 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