stingray70m
New Member
I'm having a problem with all pages that contain an image submit button.
When the "fcheckout" button is selected it executes "JY200VALIDATE3.r".
"JY200VALIDATE3.r" is then suppose to load "JY200.r" but what happens is it executes "JY200VALIDATE3.r" twice and then loads "JY200.r".
<html>
<SCRIPT language="JavaScript">
function checkoutPO( )
{
document.POSENT.style.cursor = "wait";
document.POSENT.CHGPO.disabled=true;
document.POSENT.buttonFindOrders.disabled=true;
document.POSENT.action = 'JY200VALIDATE3.r&`{&urlStateInfo}`';
document.POSENT.submit();
}
return true;
}
</SCRIPT>
<form method="post" name="POSENT">
<script language="speedscript">
{&OUT} '<input name="fcheckout" ' skip.
{&OUT} 'type="image"' skip.
{&OUT} 'id="fcheckout" ' skip.
{&OUT} 'src="/images/orders/L1.jpg" alt="Checkout" ' skip.
{&OUT} 'onClick="checkoutPO();">' skip.
</script>
</form>
</html>
/*------------------------------------------------------------------------
File: JY200VALIDATE3.P
Author: mea
Description: COPY TABLE OF ORDER DETAILS
------------------------------------------------------------------------*/
{src/web/method/wrap-cgi.i}
{ttg/ttgdefs.i}
&GLOBAL-DEFINE web-file TTGWEB
def var v-error as char no-undo.
def var v-po as char format "x(40)" no-undo.
v-po = trim(get-value("HIDDENPO")).
if trim(v-po) = "" then
set-user-field("JY200ERROR","PO ERROR").
end.
run run-web-object in web-utilities-hdl("JY200.r&`{&urlStateInfo}`").
return.
/************** END OF JY200VALIDATE ********/
I haven't included all the code as it happens when no relevant code is executed.
I'm relatively new so my method of running progress code which runs or generates an html page may be not the best.
Does anyone have any ideas?
Thanks
Mark
When the "fcheckout" button is selected it executes "JY200VALIDATE3.r".
"JY200VALIDATE3.r" is then suppose to load "JY200.r" but what happens is it executes "JY200VALIDATE3.r" twice and then loads "JY200.r".
<html>
<SCRIPT language="JavaScript">
function checkoutPO( )
{
document.POSENT.style.cursor = "wait";
document.POSENT.CHGPO.disabled=true;
document.POSENT.buttonFindOrders.disabled=true;
document.POSENT.action = 'JY200VALIDATE3.r&`{&urlStateInfo}`';
document.POSENT.submit();
}
return true;
}
</SCRIPT>
<form method="post" name="POSENT">
<script language="speedscript">
{&OUT} '<input name="fcheckout" ' skip.
{&OUT} 'type="image"' skip.
{&OUT} 'id="fcheckout" ' skip.
{&OUT} 'src="/images/orders/L1.jpg" alt="Checkout" ' skip.
{&OUT} 'onClick="checkoutPO();">' skip.
</script>
</form>
</html>
/*------------------------------------------------------------------------
File: JY200VALIDATE3.P
Author: mea
Description: COPY TABLE OF ORDER DETAILS
------------------------------------------------------------------------*/
{src/web/method/wrap-cgi.i}
{ttg/ttgdefs.i}
&GLOBAL-DEFINE web-file TTGWEB
def var v-error as char no-undo.
def var v-po as char format "x(40)" no-undo.
v-po = trim(get-value("HIDDENPO")).
if trim(v-po) = "" then
set-user-field("JY200ERROR","PO ERROR").
end.
run run-web-object in web-utilities-hdl("JY200.r&`{&urlStateInfo}`").
return.
/************** END OF JY200VALIDATE ********/
I haven't included all the code as it happens when no relevant code is executed.
I'm relatively new so my method of running progress code which runs or generates an html page may be not the best.
Does anyone have any ideas?
Thanks
Mark