Visit Jeremy's Blog.
Go Back > Forums > Non-*NIX Forums > Programming
User Name
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.


  Search this Thread
Old 09-16-2008, 12:52 PM   #1
Senior Member
Registered: Feb 2002
Location: harvard, il
Distribution: Ubuntu 11.4,DD-WRT micro plus ssh,lfs-6.6,Fedora 15,Fedora 16
Posts: 3,225

Rep: Reputation: 402Reputation: 402Reputation: 402Reputation: 402Reputation: 402
force iframe content to remain in iframe?

i have a web script (phpmyadmin) embeded in an iframe on a page, however whenever phpmyadmin refreshes to the login page it takes over the whole page and doesnt return to the iframe, how do i fix it so that it is always forced into the iframe instead?
Old 09-17-2008, 06:29 AM   #2
Senior Member
Registered: Dec 2003
Location: Trondheim, Norway
Distribution: Debian and Ubuntu
Posts: 1,293

Rep: Reputation: 335Reputation: 335Reputation: 335Reputation: 335

I think you need to modify phpmyadmin. It's intentionally coded like this.

Look in the file "libraries/auth/cookie.auth.lib.php"

<script type="text/javascript" language="javascript">
// show login form in top frame
if (top != self) {;
Probably it's because it uses frames itself, and without this, the login form would come in the left/right frames of phpmyadmin.

If your iframe has a name, I think something like this would work:

if (top.frames.iframename != self) {

Never tested it, so I don't know if it works though.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Force /dev/sdX? to remain? tbeehler Linux - Software 2 05-08-2008 04:29 PM
embed table from nagios status page on differnet webpage with maybe iframe? sinbsd Programming 0 05-08-2008 12:57 PM
Problem with iframe in Mozilla and Firefox ! Balakrishnan84 Programming 4 08-05-2007 11:22 PM
iframe woes ScottReed Programming 0 07-26-2007 11:04 AM
javascript - submit an iframe form AM1SHFURN1TURE Programming 1 09-23-2006 05:51 PM > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 01:49 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration