Page 1 of 1

how to access php file in index.html

Posted: Mon Feb 01, 2010 3:31 am
by manojsemwal1
hai i want to call php file in index.html how can i use it.....

iam using iframe and .php file is opening properly but when i select the value from select box and pass to next page its passing the value but the result is shown in that partucular area only. i want when i select the value and submit it . it will open new window and display the result...................

index.html code are

<script type="text/javascript">
var iframesrc="callDistblock.php"


document.write('<iframe id="datamain" src="'+iframesrc+'" width="275px" height="100px" marginwidth="0" marginheight="0" hspace="0" vspace="0" frameborder="0" scrolling="No"></iframe>')

</script>

Thanks

Re: how to access php file in index.html

Posted: Mon Feb 01, 2010 4:18 am
by amargharat
put target='_blank' attribute in your form tag if you are submitting using form

Re: how to access php file in index.html

Posted: Mon Feb 01, 2010 4:48 am
by manojsemwal1
Thanks Amar

iam using the follwoing code

<script language="javascript">
function selfun()
{
if(document.frm.txtDistrict.selectedIndex==0)
{
alert("Pl Select District");
document.frm.txtDistrict.focus();
return false;
}
if(document.frm.txtBlock.selectedIndex==0)
{
alert("Pl Select District");
document.frm.txtDistrict.focus();
return false;
}
else
{
document.frm.action=window.open('SGSYCentreDetails.php','popuppage','width=850,scrollbars=yes,height=700,top=100,left=100');

}

}
</script>

its open in new window but select value is not passing in result page..........