FRIHOSTFORUMSFAQTOSBLOGSDIRECTORY
You are invited to Log in or Register a Frihost Account!

Pop-Ups

 


Twikki
Ok I know how to do pop-ups but im wondering, is it possible to resize the pop-up in HTML without using javascript?
riv
Not that I know of. The only option is to use JavaScript. But I'm curious, why do you want a XHTML alternative for the JavaScript? Question
Twikki
Most Javascript doesnt work in firefox
Kaneda
Twikki wrote:
Most Javascript doesnt work in firefox


Any Javascript works in Firefox. The only thing that doesn't work is browser/DOM features specific to other browsers (usually IE), like "document.all".

window.open() for popups works in all browsers, although some features may be turned off by default (since they're annoyances - like removing the status bar).
burningjacks
i use this code in javascript which makes a pop up that appears on the first visit and allows you to resize it... but ya id rather use JS anyway...it just makes me feel special.

check it

Code:

<SCRIPT LANGUAGE="JavaScript">
<!--
function GetCookie(name) {
var arg=name+"=";
var alen=arg.length;
var clen=document.cookie.length;
var i=0;
while (i<clen) {
var j=i+alen;
if (document.cookie.substring(i,j)==arg)
return "here";
i=document.cookie.indexOf(" ",i)+1;
if (i==0) break;
}
return null;
}
var visit=GetCookie("COOKIE1");
if (visit==null){
var expire=new Date();
window.name = "thiswin";
newwin=open("yourpagename.html", "dispwin",
"width=450,height=455,scrollbars=yes,menubar=no");
expire=new Date(expire.getTime()+7776000000);
document.cookie="COOKIE1=here; expires="+expire;
}
// -->
</SCRIPT>



i kinda stole that cuz im not smart enough to do it by myself but i try. lol
darkness
Code:

<SCRIPT LANGUAGE="JavaScript">
<!--
function GetCookie(name) {
var arg=name+"=";
var alen=arg.length;
var clen=document.cookie.length;
var i=0;
while (i<clen) {
var j=i+alen;
if (document.cookie.substring(i,j)==arg)
return "here";
i=document.cookie.indexOf(" ",i)+1;
if (i==0) break;
}
return null;
}
var visit=GetCookie("COOKIE1");
if (visit==null){
var expire=new Date();
window.name = "thiswin";
newwin=open("yourpagename.html", "dispwin",
"width=450,height=455,scrollbars=yes,menubar=no");
expire=new Date(expire.getTime()+7776000000);
document.cookie="COOKIE1=here; expires="+expire;
}
// -->
</SCRIPT>


Why Those coockies???? you can make a simple script like this

Code:

<--HEADER-DoNotModefy this-Your script will not work -->
<--But You may change witdth, statusbar,scrollbar, etc... -->
<script language="javascript">

function popUp(URL) {
day = new Date();
id = day.getTime();
eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width=width here (in pixels),height=higth here (in pixels)');");
}
// End -->
</script>

<-- Body Tags-Modefy this but only yoururlhere.***-->
<BODY onLoad="javascript:popUp('yoururlhere.***')">
darkness
BTW......
FireFox can load JS.. But you must give Firefox acces 2 the scripts.
FireFox has a build in pop-up and JSscript blocker...
Stubru Freak
darkness wrote:
BTW......
FireFox can load JS.. But you must give Firefox acces 2 the scripts.
FireFox has a build in pop-up and JSscript blocker...


Firefox doesn't have JScript, JScript is MS-specific. Firefox uses javascript. Most firefox extensions are made in javascript.
burningjacks
cookies make it so it only pops up for the first visit. you can ditch them but i dont want a pop up every time...and besides, most ppl have blockers anyways. ya no.
S3nd K3ys
Twikki wrote:
Ok I know how to do pop-ups but im wondering, is it possible to resize the pop-up in HTML without using javascript?


Doesn't matter. I won't be seeing your annoying popups anyway.

GG FF! Wink
blackninja_af
Why pop ups they just make me mad and i won't come back as often
Reply to topic    Frihost Forum Index -> Scripting -> Html, CSS and Javascript

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2007 Frihost, forums powered by phpBB.