Page 1 of 1

Content in an iFrame

Posted: Sun 11. Jan 2004, 12:46
by cguenther
Hello,

i wanna setup an design-full website. an the content in the main-field should be loaded in an iFrame, coz the bg-image should be no repeated an set to fixed position.

Any proposals how to get the {CONTENT} loaded to / in an iFrame ?

Thx

Posted: Sun 11. Jan 2004, 13:38
by frold
I´m not sure if this work and this is just a thought...

what about using the print output in the iframe?

eg.

This is the normal site url:
http://www.phpwcms.de/index.php?id=2,0,0,1,0,0
The print url is:
http://www.phpwcms.de/index.php?id=2,4,1,1,1,0

you maybe have to edit print.css and some other stuff but I guess it would be the most easy way to do it?

Let me know if it works!!

Or you can use the div function as I have used here:
Sorry the site is down right now :(

this is just a test, and it will not let the print function work, but thats another way to fix it.. :wink:

Just some ideas from frold

Posted: Sun 11. Jan 2004, 14:15
by Pappnase
hello!

why did you need to show the content in an iframe!?
am i wrong!? or did you don't need the iframe vie only for complex external scripts!?

pappnase

Posted: Sun 11. Jan 2004, 14:57
by Oliver Georgi
But there might be a problem with iframes - often internal links are using target="_top". So to use it you should create a custom pagelayout/template that handles this for you - or maybe what you need in iframe.

Then you have to patch the index.php a bit -> at line 74 try this:

Code: Select all

echo str_replace('target="_top"', 'target="_self"', $content["all"]);
You can also use iframe's name rather than "_self";

Oliver

Posted: Sun 11. Jan 2004, 15:21
by cguenther
I'm really sorry guys, but i think, that my english is too bad to explain the problem in a foreign language, that why i'm going to use german for further entries.

Ok, iss vielleicht ein bissl tricky zu erklären, deshalb habe ich hier mal zwei Links vorbereitet.

[1] http://nameserver2.gotdns.org/~loki/php ... ,0,0,1,0,0

[2] http://nameserver2.gotdns.org/~loki/php ... ,0,0,1,0,0

wie man im zweiten Beispiel sieht, ist der Content länger als die festgelegte Höhe von 550 px für die gesamte Page bzw. 490px für die Content-Höhe.

Deshalb möchte ich nur den Content unter Vorlagen -> Haupt als iFrame einbinden.

Wie kann ich den Content also an das Externe iFrame übergeben ?

Posted: Sun 11. Jan 2004, 15:33
by Oliver Georgi
Versuch mal sowas hier im Template. Den Content fügst Du einfach in den Layer ein:

Code: Select all

<div id="myscrolllayer" style="position:absolute; left:16px; top:21px; width:430px; height:387px; z-index:1; overflow: auto;">{CONTENT}</div>
Dann erhältst Du bei Überlauf einen normalen Scrollbalken. Musst ein bißchen damit rumspielen, was die Position betrifft. Das sollte gehen.

Kannst Dich diesbezüglich auch mal nach den Sachen wie JavaScript Scroll Layer umsehen. Gibt recht gute Beispiele, um sowas mit eigenen Scrollbalken zu versehen. Wie hier z.B.
http://javascript.internet.com/scrolls/ ... oller.html

Oliver

Posted: Wed 14. Jan 2004, 12:50
by hidiho
Found this on a website
first I would (and have done this before) build two tables, one for the headers and one for the content. since you want to scroll the content I would suggest a div with the height attribute set to the desired size, also set the scrolling attribute to either auto or scroll.
If you need horozantal scrolling capabilities (scroll the data left or right and the headers move with it) let me know, I have some javascript that does the trick.
As for the resorting there are lots of variables involved before answering this one... are you using any serverside code, if so what language? is the table content static or dynamic?
I wuerde einfach im Main teil das ausprobieren, also erst zwei tabellen erstellen, in der zweite dann DIV tag benutzen, und dazwischen {CONTENT}

alles gute

hidiho

Posted: Wed 14. Jan 2004, 15:55
by pSouper
as of 2:54pm 14/01/04 your scrolling back ground look fantastic ;)
I've not seen that effect before and I love it.
your sites colour choices a re beatifull too

Posted: Wed 14. Jan 2004, 17:24
by frold
pSouper wrote:as of 2:54pm 14/01/04 your scrolling back ground look fantastic ;)
I've not seen that effect before and I love it.
your sites colour choices a re beatifull too
Sry, but do you live in your own world.. Hallo, this is the earth..you know in the milky way.... :roll:

To be serius, what is it you are comment? pSouper?

Posted: Wed 14. Jan 2004, 17:59
by pSouper
hehe, I guess I don't get around much.
It's true, I never seen that before.

I make the artwork to computer games not websites s ohave never really spent to long looing at web pages before. I started thinking about doing my own website only since I went freelance last summer. I su[pose I should use some more of this bandwidth I'm paying for ;)

Re: Content in an iFrame

Posted: Wed 14. Jan 2004, 19:45
by Bijan Hemati
cguenther wrote:Hello,

i wanna setup an design-full website. an the content in the main-field should be loaded in an iFrame, coz the bg-image should be no repeated an set to fixed position.

Any proposals how to get the {CONTENT} loaded to / in an iFrame ?

Thx
I'm looking for similar effect also. I don't think FRAMES are supported in phpwcms.

What I am looking for is to be able to show an external webpage for example http://www.cnn.com inside a frame in my webpage.

Posted: Wed 14. Jan 2004, 20:23
by Oliver Georgi
Bijan, never open external content inside your content. It is recommend to open new window - that's fair.

But to use external pages - use iframes.

Oliver

Posted: Wed 14. Jan 2004, 23:10
by Bijan Hemati
I do understand what you mean Oliver.

There are instances where someone has the permission of a particular site owner to include a particular content of that site into theirs.
For example, one could have a subscription (membership) to a service, with their own account number and password.

When I used CNN as an example, was to make clear what I meant by "external webpage". :wink:

I know this occurs a lot in real estate industry
http://www.360house.com/ this site provides a tool to real estate agents who are a member.

This agent is using that tool in her site. http://frittshomes.com/ Click on Our Listings from the menu.

Regards,
Bijan

Posted: Thu 15. Jan 2004, 08:31
by Oliver Georgi
OK,

I've seen you've understand what I mean. If this is a websites feature it's OK - but to use external content to make it your own content then not...

Oliver