Contact Us Forum Rules Search Archive
WebProWorld Part of WebProNews.com
Page One Link To Us Edit Profile Private Messages Archives FAQ RSS Feeds  
 

Go Back   WebProWorld > Webmaster, IT and Security Discussion > Web Programming Discussion Forum
Subscribe to the Newsletter FREE!


Register FAQ Members List Calendar Arcade Chatbox Mark Forums Read

Web Programming Discussion Forum Working with an API? Developing a plugin? Writing a Mod or script for your favorite blog, Web 2.0 site or Forum? Welcome.

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 03-23-2004, 07:42 PM
WebProWorld New Member
 

Join Date: Mar 2004
Location: Illinois
Posts: 8
KRYPTOR RepRank 0
Default Javascript Help.

Hello!

I am an amateur web designer/webmaster. I am having a problem with incorporating this window.open javascript to produce a window dimension to the size of the border in the below form.

The window.open script example is as follows;

window.open("aa032103a.htm","example1","width=400, height=300,
location=no, menubar=no, status=no, toolbar=yes, scrollbars=yes, resizable=yes");

Should <script LANGUAGE="javascript">
function win() come before window.open?


What I want to do is to have a text or
gif or jpeg hyperlink to the file Rate.html. This is the name of the form below. Right now when you click on Rate.html, it opens a FULL browser window with the form in the center of a sea of white, well I want the new browser window to open with the forms border dimensions and to open
top center of your screen. This form will open in a seperate window as to keep the orignal website window the same. Also is it a good idea to add
this javascript


Where would I put this statement <onblur=window.close()>
so that when a person clicks on the original browser window, not the form, the window closes
automatically, or is this not a good idea?

Can you please incorporate the above javascript into the form below for me, so that the window
will open ONLY to the forms dimensions AND to be centered, using left and top, that
is, the top border of the form at the top of the screen and centered horizontally ?

Thanks!

The KRYPTOR

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">


<FORM METHOD="POST" ACTION="http://cgi26.Freedback.com/mail.pl">



<INPUT TYPE="hidden" NAME="to" VALUE="prolongit@hotmail.com">

<INPUT TYPE="hidden" name="subject" VALUE="Freedback.com Form: http://www.savemoneytoo.com/">

<INPUT TYPE="hidden" NAME="form" VALUE="http://www.savemoneytoo.com/">

<INPUT TYPE="hidden" NAME="admin" VALUE="prolongit@hotmail.com">

<INPUT TYPE="hidden" NAME="audience" VALUE="67656e6572616c47">

<INPUT TYPE="hidden" NAME="language" VALUE="en">


<table width="100%" bgcolor="#134c39" cellpadding="0" cellspacing="0" border="2" bordercolor="#000000">
<TR><TD><font face="arial" size="4" color="#E0D77C"><U><CENTER>Site Review</CENTER></U></font></td></tr>


<table width="100%" bgcolor="#134c39" border="1" bordercolor="#000000">
<TR><td width="416"><font face="arial" size="3" color="#E0D77C"><CENTER>Your First Name & Last Initial:</font><font face="arial" size="2" color="#E0D77C">(John S.)</font>
<INPUT TYPE="text" NAME="name" SIZE="30"></CENTER></td>
<TD width="450"><font face="arial" size="3" color="#E0D77C"><CENTER>Your Email Address:</font><font face="arial" size="2" color="#E0D77C">(you@aol.com )</font>
<INPUT TYPE="text" NAME="from" SIZE="30"></CENTER></TD></tr></table>

<table width="100%" bgcolor="#028563" border="1" bordercolor="#000000">
<TR><TD width="49%"><font face="arial" size="3" color="#000000"><CENTER>Save Money Too</CENTER></font></TD>
<TD width="10%" align="center"><font face="arial" size="2" color="#000000">Poor
(1)
</font></TD>
<TD width="10%" align="center"><font face="arial" size="2" color="#000000">Fair
(2)
</font></TD>
<TD width="10%" align="center"><font face="arial" size="2" color="#000000">Good
(3)
</font></TD>
<TD width="10%" align="center"><font face="arial" size="2" color="#000000">Great
(4)
</font></TD>
<TD width="12%" align="center"><font face="arial" size="2" color="#000000">Excellent
(5)
</font></TD>
[/b]</font></table>

<table width="100%" bgcolor="#028563" border="1" bordercolor="#000000">
<TR><td width="49%"><font face="arial" size="3" color="#000000">Site Appearance:</font>
<font face="arial" size="2" color="#000000">How is the overall color coordination and photo/animation quality?</TD>
<TD width="10%" align="center"><INPUT TYPE="radio" NAME="Site Appearance" VALUE="1 Star"></TD>
<TD width="10%" align="center"><INPUT TYPE="radio" NAME="Site Appearance" VALUE="2 Star"></TD>
<TD width="10%" align="center"><INPUT TYPE="radio" NAME="Site Appearance" VALUE="3 Star" CHECKED></TD>
<TD width="10%" align="center"><INPUT TYPE="radio" NAME="Site Appearance" VALUE="4 Star"></TD>
<TD width="12%" align="center"><INPUT TYPE="radio" NAME="Site Appearance" VALUE="5 Star"></TD>
</font></table>

<table width="100%" bgcolor="#028563" border="1" bordercolor="#000000">
<TR><td width='49%'><font face=arial size=3 color=#000000>Site Content:</font>
<font face="arial" size="2" color="#000000">What is the quality of the site content and presentation? Was it original?</TD>
<TD width='10%' align='center'><INPUT TYPE="radio" NAME="Site Content" VALUE="1 Star"></TD>
<TD width='10%' align='center'><INPUT TYPE="radio" NAME="Site Content" VALUE="2 Star"></TD>
<TD width='10%' align='center'><INPUT TYPE="radio" NAME="Site Content" VALUE="3 Star" CHECKED></TD>
<TD width='10%' align='center'><INPUT TYPE="radio" NAME="Site Content" VALUE="4 Star"></TD>
<TD width='12%' align='center'><INPUT TYPE="radio" NAME="Site Content" VALUE="5 Star"></TD>
[/b]</font></table>

<table width="100%" bgcolor="#028563" border="1" bordercolor="#000000">
<TR><td width='49%'><font face=arial size=3 color=#000000>Site Navigation:</font>
<font face=arial size=2 color=#000000>How easy was it to find the information you needed?</TD>
<TD width='10%' align='center'><INPUT TYPE="radio" NAME="Site Navigation" VALUE="1 Star"></TD>
<TD width='10%' align='center'><INPUT TYPE="radio" NAME="Site Navigation" VALUE="2 Star"></TD>
<TD width='10%' align='center'><INPUT TYPE="radio" NAME="Site Navigation" VALUE="3 Star" CHECKED></TD>
<TD width='10%' align='center'><INPUT TYPE="radio" NAME="Site Navigation" VALUE="4 Star"></TD>
<TD width='12%' align='center'><INPUT TYPE="radio" NAME="Site Navigation" VALUE="5 Star"></TD>
[/b]</font></table>

<table width="100%" bgcolor="#028563" border="1" bordercolor="#000000">
<TR><td width='49%'><font face=arial size=3 color=#000000>Site Organization:</font>
<font face=arial size=2 color=#000000>How well is the site organized? How well does it flow?</TD>
<TD width='10%' align='center'><INPUT TYPE="radio" NAME="Site Organization" VALUE="1 Star"></TD>
<TD width='10%' align='center'><INPUT TYPE="radio" NAME="Site Organization" VALUE="2 Star"></TD>
<TD width='10%' align='center'><INPUT TYPE="radio" NAME="Site Organization" VALUE="3 Star" CHECKED></TD>
<TD width='10%' align='center'><INPUT TYPE="radio" NAME="Site Organization" VALUE="4 Star"></TD>
<TD width='12%' align='center'><INPUT TYPE="radio" NAME="Site Organization" VALUE="5 Star"></TD>
[/b]</font></table>

<table width="100%" bgcolor="#028563" border="1" bordercolor="#000000">
<TR><td width='49%'><font face=arial size=3 color=#000000>Site Response:</font>
<font face=arial size=2 color=#000000>How quickly does the site contents and graphics load?
</TD>
<TD width='10%' align='center'><INPUT TYPE="radio" NAME="Site Response" VALUE="1 Star"></TD>
<TD width='10%' align='center'><INPUT TYPE="radio" NAME="Site Response" VALUE="2 Star"></TD>
<TD width='10%' align='center'><INPUT TYPE="radio" NAME="Site Response" VALUE="3 Star" CHECKED></TD>
<TD width='10%' align='center'><INPUT TYPE="radio" NAME="Site Response" VALUE="4 Star"></TD>
<TD width='12%' align='center'><INPUT TYPE="radio" NAME="Site Response" VALUE="5 Star"></TD>
[/b]</font></table>

<table width="100%" bgcolor="#134c39">
<TR><TD><font face=arial size=3 color=#E0D77C><CENTER>Comments:</font>
<font face=arial size=2 color=#E0D77C>Add additional remarks, praise, or constructive criticism.</font>


<TEXTAREA NAME="Comment Box 1" ROWS="5" COLS="42" WRAP="hard"></TEXTAREA></CENTER></TD></TR></table>


<table width="100%" bgcolor="#134c39">
<TR><TD width="100%"><CENTER>
<INPUT TYPE="submit" NAME="Submit Button" VALUE="Submit Your Review">

<INPUT TYPE="reset" VALUE="Clear Form"></TD></TR>
<CENTER><table width="100%" bgcolor="#134c39">
<TR><TD width="50%"><font face="arial" size="4" color="#FFFFFF"><CENTER>The Average Rating For
This Website Is:</center>
</font></td></tr>
<TR><TD width="50%"><CENTER><font face="arial" size="5" color="#FFFFFF">4.5</font></center></td></tr></table>
</table>
__________________
"What is SEEN is Temporal, What is UNSEEN is
Eternal."

My first webmastering site,
www.savemoneytoo.com
Reply With Quote
  #2 (permalink)  
Old 03-25-2004, 08:08 AM
sijpie's Avatar
WebProWorld Pro
 

Join Date: Sep 2003
Location: Scotland
Posts: 108
sijpie RepRank 0
Default

The solution you are looking for is simple: the javascript should not be on the form html, but on the page that calls the form. So in your case the page that holds the graphic to be clicked on.

ie: calling page:

Code:
<head>
....
<script language = "JavaScript">
<!--
 function openWin(URL)  {
    aWindow=window.open(URL,"form","toolbar=no,width=720,height=590,status=no,scrollbars=yes,resize=no,menubar=no");
 }
 
//-->
</script>
</head>
<body>
....
[img]xxx.gif[/img]
...
</body>
In the above file you have the image with a anchor tag which calls the javascript to create the window of the right size (you will have to set the size appropriatly, I just stuck in some pixels). Once the window is created, rate.html is loaded in the window.

That's it.
__________________
Jaap

PalmVenue
Broekhuizen Paintings
MacSijp

You've done it all
You've broken every code (Steve Harley)
Reply With Quote
Reply

  WebProWorld > Webmaster, IT and Security Discussion > Web Programming Discussion Forum
Tags: ,



Thread Tools
Display Modes

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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Search Engine Optimization by vBSEO 3.2.0