I want to display a popup when the page load completes. I am using XSL and javascript for this. But I do not know why the popup does not display when the page loads.
My code:
function alkesh(){
alert("Alkesh called");
var isQuotedPriceChanged = <xsl:value-of select="wtransactionGeneralData/isQuotedPriceChanged"/>;
alert("IsQuotedPriceChanged value is ["+isQuotedPriceChanged+"]");
if(isQuotedPriceChanged=="Y"){
alert("Your requested price was adjusted by spreading calculation");
}
Javascript is at the end of the same XSL file. This is my call to the javascript function:
<script>
window.onload=alkesh;
</script>
Change var isQuotedPriceChanged = <xsl:value-of select="wtransactionGeneralData/isQuotedPriceChanged"/>;
to var isQuotedPriceChanged = '<xsl:value-of select="wtransactionGeneralData/isQuotedPriceChanged"/>';
.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.