PHP Dynamically Created Form with AJAX: No Data Passed?

PHP Dynamically Created Form with AJAX: No Data Passed?

I have some forms whose ID's are dynamically created via PHP by including a variable called "invno" as shown here:

   
  1. <form name="formEditInvoice<?php echo $invno ?>" id="formEditInvoice<?php echo $invno ?>" method="post" action="javascript: SubmitEditedInvoice(<?php echo $invno ?>);" onsubmit="javascript: return ValidateForm(this);">
As you can see in the "action" attribute, I'm calling this function:

   
  1.  function SubmitEditedInvoice(invno) {
    $.post('output.php?mode=6&invno=' + invno, $('#formEditInvoice' + invno).serialize(),
    function(output){
    $('#ajaxinvoices').html(output);
    });
    }




The problem I'm having is that no data is passed to the PHP back end. I have verified that the variable invno is correctly passed to the javascript function, and have tested my .serialize() by using a hard-coded form ID, but I still get no data passed through. 

Can anyone see what's wrong with my code?

TIA