Vertikale Scrollbar in Popup (IE)

R

Richard

Hi,

ich verwende folgenden Code, den ich im Internet gefunden habe, um
Informationen auf Anfrage in Popupfenstern zu öffnen:

// Script by Thomas Stich
// http://www.stichpunkt.de/beitrag/popup.html
// use it if you like it
//
// <a href="html-or.jpg" onclick="return popup(this,123,456)"
title="..."
// or
// <a href="html-or.jpg" onclick="return popup(this)" title="..."


var pop = null;

function popdown() {
if (pop && !pop.closed) pop.close();
}

function popup(obj,w,h) {
var url = (obj.getAttribute) ? obj.getAttribute('href') : obj.href;
if (!url) return true;
w = (w) ? w += 20 : 150; // 150px*150px is the default size
h = (h) ? h += 25 : 150;
var args = 'width='+w+',height='+h+',resizable';
popdown();
pop = window.open(url,'',args);
return (pop) ? false : true;
}

window.onunload = popdown;
window.onfocus = popdown;

Nun ist mir aufgefallen, dass der IE keine vertikale Scrollbar
anzeigt, falls der Anzeigeplatz nicht reicht. Wie kann ich das
beheben?

Gruß
Richard
 
P

Pascal Ehlert

Hi Richard!

This is an English JavaScript group, if you really want to ask
questions in German try de.comp.lang.javascript.

//
Das hier ist eine englische Newsgroup, guck dir mal
de.comp.lang.javascript an!
//

For the others:
Richard is using the code he posted to open additional information in a
popup window.
The problem is that the IE doesn't display a vertical scrollbar if the
content doesn't fit into the default window's size.

Just another issue is btw, that opening things in popup windows is worse
enough, it sucks even more if the user has to scroll to see the whole
content..


Pascal
 
R

Richard

Hi Richard!

This is an English JavaScript group, if you really want to ask
questions in German try de.comp.lang.javascript.

Ups,

I'm sorry. So lets try this in English. I'm using the following code
to opent user requested popups. My Problem is, that IE doesen't show a
vertical scrollbar, when the text is to long to display. Can somebody
help me?

// Script by Thomas Stich
// http://www.stichpunkt.de/beitrag/popup.html
// use it if you like it
//
// <a href="html-or.jpg" onclick="return popup(this,123,456)"
title="..."
// or
// <a href="html-or.jpg" onclick="return popup(this)" title="..."

var pop = null;

function popdown() {
if (pop && !pop.closed) pop.close();

}

function popup(obj,w,h) {
var url = (obj.getAttribute) ? obj.getAttribute('href') : obj.href;
if (!url) return true;
w = (w) ? w += 20 : 150; // 150px*150px is the default size
h = (h) ? h += 25 : 150;
var args = 'width='+w+',height='+h+',resizable';
popdown();
pop = window.open(url,'',args);
return (pop) ? false : true;

}

window.onunload = popdown;
window.onfocus = popdown;
 
E

Evertjan.

Pascal Ehlert wrote on 19 mei 2007 in comp.lang.javascript:
Hi Richard!

This is an English JavaScript group, if you really want to ask
questions in German try de.comp.lang.javascript.

This is NOT an English language JavaScript group.

Although English is most often used in this NG,
and the chance of a succesful answer on a Q
is enhanced by writing in English,
this NG is an international one,
so all languages are allowed.

Some German, Spanish and Dutch threads
have to my knowledge been successful,
and many French ones.
 
A

ASM

Richard a écrit :
function popup(obj,w,h) {
var url = (obj.getAttribute) ? obj.getAttribute('href') : obj.href;
if (!url) return true;
w = (w) ? w += 20 : 150; // 150px*150px is the default size
h = (h) ? h += 25 : 150;
var args = 'width='+w+',height='+h+',resizable';

var args = 'width='+w+',height='+h+',resizable=1,scrollbars=1';
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,989
Messages
2,570,207
Members
46,782
Latest member
ThomasGex

Latest Threads

Top