How to pass parameters through iframe from parent html?

前端 未结 3 693
無奈伤痛
無奈伤痛 2020-12-03 03:06

I have a html page in which I am setting the src for an iframe programmatically. How can I pass parameters through the iframe src and get them in the child html?

Bel

3条回答
  •  南笙
    南笙 (楼主)
    2020-12-03 03:30

    you should make a serverside page like (myIframeRequest.php) php/jsp and get the parameter value in that page if it s an html page then parse the window.location.href through javascript and find the query/param

提交回复
热议问题