|
As a side note, I tried two tests. I first changed the form method to GET and included a hidden field (func) in the form. The program worked as expected. Second, with the new form I changed the method back to POST. The program again worked as expected. Can I just not mix GET and POST in the same web page? -Chris --------------------------------------------------------- Christopher A. Libby, Programmer/Analyst Maine Public Service Company (www.mainepublicservice.com) clibby@mainepublicservice.com (207) 768-5811 ext. 2210 > -----Original Message----- > From: Christopher A. Libby [mailto:clibby@mainepublicservice.com] > Sent: Friday, July 27, 2001 3:43 PM > To: WEB400@midrange.com > Subject: RE: Mixing GET and POST Methods > > > Thanks for the help. I've made the changes and updated the > service program. I also restarted the server, but I still get > the same problem. I think I may have mistated my question > earlier. I'm using the GET method to direct my program to the > correct subroutine, and the POST method the transmit form data. > To setup a new account, I use GET to direct my program to the > NEWACCT2 subroutine, and POST to transmit the form information to > the program. Below is the main program, and the program seems to > fail at the point where it tries to extract Function from > savedquerystring, whose value is "func=". The URL submitted to > the server is "http://.../weblibp/webcusinq.pgm?func=vrfyacct". > > > *-------------------------------------------------------------------- > * START Main Progam > > *-------------------------------------------------------------------- > > * initialize the program > C Exsr Init > > * turn debugging on or off - see JobDebugIndicator > C callp wrtjobdbg(JobDebugInd) > > * read in HTML source file > C Exsr LoadHTML > > * get user input > C eval nbrVars = > zhbgetinput(savedquerystring:qusec) > > C callp > updHTMLVar('COMPANY':company:InitHTMLVars) > C callp > updHTMLVar('SITETITLE':sitetitle:ChgHTMLVars) > C callp > updHTMLvar('BASEHREF':basehref:chgHTMLvars) > C callp wrtsection('header') > > * if no parameters, show login screen > C If nbrVars = 0 > C Exsr ShowLogin > C Eval GetOut = '1' > C EndIf > > * populate session datastructure > C eval Function = zhbgetvar('func') > Function > C eval SessionID = > zhbgetvar('sessionid') SessionID > C eval ErrorID = zhbgetvar('error') > Error Msg > > C If ErrorID <> *Blanks > C Exsr ShowLogin > C Eval GetOut = '1' > C EndIf > > C If GetOut = '0' > C Select > C When Function = 'newacct' > C Exsr NewAcct > C When Function = 'vrfyacct' > C Exsr NewAcct2 > C When Function = 'auth' > C* Exsr Authenticate > C When Function = 'main' > C* Exsr RetrieveSession > C* Exsr ShowMain > C Other > C eval ErrorID='errGen1' > C exsr ShowLogin > C EndSl > C EndIf > > C callp updHTMLVar('DISCLAIMER':sitetitle: > C ChgHTMLVars) > C callp wrtsection('footer') > C callp wrtsection('*fini') > > C EndAll Tag > C Return > > *-------------------------------------------------------------------- > * END Main Progam > > *-------------------------------------------------------------------- > > > --------------------------------------------------------- > Christopher A. Libby, Programmer/Analyst > Maine Public Service Company (www.mainepublicservice.com) > clibby@mainepublicservice.com (207) 768-5811 ext. 2210 > > +--- | This is the WEB400 Mailing List! | To submit a new message, send your mail to WEB400@midrange.com. | To subscribe to this list send email to WEB400-SUB@midrange.com. | To unsubscribe from this list send email to WEB400-UNSUB@midrange.com. | Questions should be directed to the list owner/operator: david@midrange.com +---
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.