Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - Validation with Frames?
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Validation with Frames?

 Post Reply Post Reply
Author
mlhopper View Drop Down
Newbie
Newbie


Joined: 07 March 2003
Status: Offline
Points: 8
Post Options Post Options   Thanks (0) Thanks(0)   Quote mlhopper Quote  Post ReplyReply Direct Link To This Post Topic: Validation with Frames?
    Posted: 11 March 2003 at 7:02am

My page is set up in the following way:

outer border - with a frame (and separate page) within a smaller square in the center of the page. My form is in the center frame...but my submit button is in the outer border frame.

My question:

Is there a way to validate the form in the center frame, even though the submit button is in the border frame?

Thanks,

Melissa

Back to Top
michael View Drop Down
Senior Member
Senior Member
Avatar

Joined: 08 April 2002
Location: United States
Status: Offline
Points: 4670
Post Options Post Options   Thanks (0) Thanks(0)   Quote michael Quote  Post ReplyReply Direct Link To This Post Posted: 11 March 2003 at 8:48am
From what I understand you have the submit button of a form in a different frame then the actual form! Is that correct? Well then there is a problem as they are actuall two different pages and you could not submit the form in the centerframe with a button in another frame. Unless I understand you completely wrong there is no way you can do what you want.
Back to Top
mlhopper View Drop Down
Newbie
Newbie


Joined: 07 March 2003
Status: Offline
Points: 8
Post Options Post Options   Thanks (0) Thanks(0)   Quote mlhopper Quote  Post ReplyReply Direct Link To This Post Posted: 11 March 2003 at 9:06am

You understood right.  I didn't think it was possible either...

This thing is...I am creating a training simulator for a company's website.  Their website is set up like this - the form is in the center frame and the outer border contains the submit (continue) button and the following validation occurs:
If no name, error message appears at top of screen "Please complete name"
If no address, error message "Please complete address", etc.

I have no idea how they did this, as they have hidden a great deal of code.  I have to replicate the website to look as similar as possible, and this is why I must find out how they did this.  Any suggestions as to ways to replicate without being in frames?  I have to have the scroll bar on the right side of the center form though - which is why I thought I would have to have frames.

Thanks,

Melissa

Back to Top
mlhopper View Drop Down
Newbie
Newbie


Joined: 07 March 2003
Status: Offline
Points: 8
Post Options Post Options   Thanks (0) Thanks(0)   Quote mlhopper Quote  Post ReplyReply Direct Link To This Post Posted: 11 March 2003 at 10:00am

One of the guys here figured it out and it worked...to reference the frame - put the function in the main (outer) frame...

Reference the Frame by top.frameName.FormName.radioGroupName.value......(example below)

function dslType()
{
 
 if (top.centerConfig.fm10.dslType[0].checked != true)
 {
  
  alert("Please check the correct DSL type.");
  popNotes();
  return false;
  
 }
 
 if (top.centerConfig.fm10.dslType[1].checked == true)
 {
  
  alert("Please check the correct DSL type.");
  popNotes();
  return false;
  
 } 


  if(top.centerConfig.fm2.networking[0].checked != true)
  {
     
     alert("Please select the correct radio button for Home Networking.");
     popNotes();
     return false;   
     
  }
  return true;
}

Then add the following to the form containing the Continue/Submit button...

<form name="buttons" action="01index.htm" method="get" onSubmit="return dslType(this);">

Let me know if anyone has any questions about it.

Melissa

Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.