Results 1 to 4 of 4

Thread: jQuery Form to Form Wizard and IFRAMES

  1. #1
    Join Date
    Dec 2010
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default jQuery Form to Form Wizard and IFRAMES

    jQuery Form to Form Wizard
    http://www.dynamicdrive.com/dynamici...formwizard.htm

    I have a page I am creating that has a header and a footer and also has an iframe for the main body content. I have a jquery script that auto adjusts the height of the iframe and it works fine with all pages that are one page and height, but one of the pages I am loading into that iframe has the JQuery Form to Form Wizard on it, the height of the iframe only seems to go to the largest height of one of the tabs, is there anyway to readjust the height based on what tab I am on?

    TAGrafx

  2. #2
    Join Date
    Aug 2004
    Posts
    10,143
    Thanks
    3
    Thanked 1,008 Times in 993 Posts
    Blog Entries
    16

    Default

    This is probably more of a question for the IFRAME resizing script than the Form Wizard. Is there a function within the later to reflow/calculate the height of the page when the page's height changes, as is the case when the user navigates to a different "tab" within the Form Wizard? If there is, you would call that function inside the onpagechangestart() event handler of Form Wizard, which lets you run code whenever the user changes "tab". For example:

    Code:
    var myform=new formtowizard({
     formid: 'feedbackform',
     persistsection: true,
     revealfx: ['slide', 500],
     onpagechangestart:function($, i, $fieldset){
    	recaliframeheight() //some function to call to recal iframe height
     }
    })
    DD Admin

  3. #3
    Join Date
    Dec 2010
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    I am not a very strong programmer so can you give me a hint to what the "recaliframeheight" should be?

    This is what I have in my script...

    <script type="text/javascript">
    $(function(){
    $("#demoForm").formwizard({
    validationEnabled: true,
    focusFirstInput : true,
    }
    );
    });

    var myform=new formtowizard({
    formid: 'demoForm',
    persistsection: true,
    revealfx: ['slide', 500],
    onpagechangestart:function($, i, $fieldset){
    recaliframeheight() //some function to call to recal iframe height
    }
    })

    </script>

  4. #4
    Join Date
    Aug 2004
    Posts
    10,143
    Thanks
    3
    Thanked 1,008 Times in 993 Posts
    Blog Entries
    16

    Default

    Hi:
    recaliframeheight() is simply an example (non existent) function. The exact function to call as mentioned depends on what's available to you inside the IFRAME resize script. You'll looking for something that when called would re-invoke the IFRAME script to recalculate the IFRAME's height based on the current state of the page.
    DD Admin

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •