我有一个场景: 1.必须在新标签中显示数据。 2.必须传递Post参数。 我可以使用超链接完成此操作并使用_blank设置目标。 问题是当我发送参数时,它采用GET格式,参数可在浏览器中看到。 任何以Post格式发送数据和返回数据的解决方案都显示在新标签中。 我使用过的片段,我在POST参数中需要相同的内容。我已经取代了< with(以便显示标签。 (a)href =mmtasks_update_task.php?type = view_hdr_rep&task =(?php echo $ tid;?) target =_ blank>查看HDR(a)
I have a scenario: 1. Have to show the data in the new tab. 2. Have to pass a Post parameter. I can do this with hyperlink and also setting the target with _blank. The problem is when i send the parameter, it is in GET format and the parameters are seen in the browser. Any solution for sending the data in the Post format and the returning data to show in new tab. Snippet I used, I need the same in the POST parameters. I have replaced < with ( so that tags gets displayed. (a) href="mmtasks_update_task.php?type=view_hdr_rep&task="(?php echo $tid;?)" target="_blank">View HDR (a)
推荐答案tid;?) target =_ blank>查看HDR (a) tid;?)" target="_blank">View HDR (a)
我想你想要的是表格。只需一个链接就无法发送POST数据。 创建一个包含(或多个)隐藏字段的表单,并且 target =_ blank,应该完成这项工作。 I guess what you want would be a form. Just with a link you can't send POST data. Create a form with a (or multiple) hidden field(s), and a target="_blank", that should do the job.
更多推荐
如何在PHP中发送jQuery Ajax Post参数
发布评论