dthjnc306679 2016-07-09 06:04
浏览 18

url不显示发送到另一个文件的表单值

problem in data sending through url but it not reflect any data on other php page what is wrong in my code here is the code

  if(isset($_POST["submit"]))
         {

            $id1 = $_POST["edit_id"];
            $name1=($_POST['name']);
            $lname1=($_POST['lname']);
            $email1=($_POST['email']);
            $username1=($_POST['username']);
            $password1=($_POST['password']);
            $mobile1=($_POST['mobile']);
            $address1=($_POST['address']);
            $gender1=($_POST['gender']);



$result = file_get_contents('http://localhost/service/service.php?action=update_details&id1='.$id1.'&name1='.$name1.'&lname1='.$lname1.'&email1='.$email1.'&username1='.$username1.'&password1='.$password1.'&gender1='.$gender1.'&mobile1='.$mobile1.'&address1='.$address1);
  • 写回答

1条回答 默认 最新

  • duannong1801 2016-07-09 06:29
    关注

    It's really difficult to tell if you don't provide the other page's code.

    Let's call this code you provide Page B.

    Here you are receiving POST data from another page, let's call it Page A, are you sure the page A is sending the data as a POST request to page B?

    What do you see if you dump the $_POST variable in page B?

    You are calling service.php (let's call it page C) from page B and sending a GET request. Are you sure you the data is read as a GET request in page C?

    What do you do with var $result in page B?

    Can you tell if you have problems in page A, B or C?

    Additionally, you should delete the parentheses around $_POST variables. They are pointless.

    评论

报告相同问题?

悬赏问题

  • ¥15 装 pytorch 的时候出了好多问题,遇到这种情况怎么处理?
  • ¥20 IOS游览器某宝手机网页版自动立即购买JavaScript脚本
  • ¥15 手机接入宽带网线,如何释放宽带全部速度
  • ¥30 关于#r语言#的问题:如何对R语言中mfgarch包中构建的garch-midas模型进行样本内长期波动率预测和样本外长期波动率预测
  • ¥15 ETLCloud 处理json多层级问题
  • ¥15 matlab中使用gurobi时报错
  • ¥15 这个主板怎么能扩出一两个sata口
  • ¥15 不是,这到底错哪儿了😭
  • ¥15 2020长安杯与连接网探
  • ¥15 关于#matlab#的问题:在模糊控制器中选出线路信息,在simulink中根据线路信息生成速度时间目标曲线(初速度为20m/s,15秒后减为0的速度时间图像)我想问线路信息是什么