IWP doesn't recognize active portal record
I am working on a web page that displays portal records that allow user to update record fields. Once the data is entered I have a button that runs a script that sets variables from the contents of the active records fields then preforms a scripts based on the variables created.
My problem is that IWP is not recognizing the active record. Most of the time it uses the last portal record and occassionaly it uses the active portal record.
The script works fine in Filemaker without a problem. What do I do to make IWP recognize the active portal record?