Change Height and Width using javascript

classic Classic list List threaded Threaded
11 messages Options
Reply | Threaded
Open this post in threaded view
|

Change Height and Width using javascript

lvskrishna
Hi, Is the any possibility of changing the height and width using javascript. Thanks & regards, Sai
Reply | Threaded
Open this post in threaded view
|

Re: Change Height and Width using javascript

Kzeon
Height and width of what ?
Reply | Threaded
Open this post in threaded view
|

Re: Change Height and Width using javascript

lvskrishna
height and width of the child window.
Reply | Threaded
Open this post in threaded view
|

Re: Change Height and Width using javascript

Marcin
In reply to this post by lvskrishna
I used that piece of code on the page displayed within Shadowbox window and it works for me:

    parent.$("#sb-wrapper").width(300);
    parent.$("#sb-wrapper-inner").height(200);
Reply | Threaded
Open this post in threaded view
|

Re: Change Height and Width using javascript

Stefan
Your code works with jquery. If jquery is not present you can use :

parent.document.getElementById("sb-wrapper").style.width='300px';
parent.document.getElementById("sb-wrapper-inner").style.height='200px';
Reply | Threaded
Open this post in threaded view
|

Re: Change Height and Width using javascript

Angel
sorry, but where i must put it ?
Reply | Threaded
Open this post in threaded view
|

Re: Change Height and Width using javascript

Angel
Ok i found it, but it doesn't work for height

Width works, height not
SxM
Reply | Threaded
Open this post in threaded view
|

Re: Change Height and Width using javascript

SxM
Edit
Reply | Threaded
Open this post in threaded view
|

Re: Change Height and Width using javascript

riarda
In reply to this post by Angel
Where did you put this code into?
Reply | Threaded
Open this post in threaded view
|

Re: Change Height and Width using javascript

majid
In reply to this post by lvskrishna
hiiii
<a href="login.php" rel="shadowbox;height=500;width=500">LINKKKKKKK</a>
Reply | Threaded
Open this post in threaded view
|

Re: Change Height and Width using javascript

Shay
Thanks so much! This works