echo "$id2\n","$name2";这是哪门子语法?

解决方案 »

  1.   

    楼上的,$id = "9981";$name = "henly";echo "$id\n","$name";//我这边测试可以
    当然如果不赋初值的话,也会有楼主的提示,估计楼主是没取到值,如果不影响楼主的程序功能,可以把这些信息关闭,比如:error_reporting(0);
      

  2.   

    谢谢  如果赋初值是可以  而且如果把两个脚本合并也是可以的  但是删除记录时是从最后一条开始的,可见原来的dele.php并没有取到值,但是我修改了好长时间也没有找到毛病出在什么地方,你能再帮我看看吗?谢谢!
      

  3.   

    这是我用dzsoft php editor时的出错提示:PHP Notice: Undefined variable: id in C:\Documents and Settings\jswb\桌面\dele.php on line 18 PHP Notice: Undefined variable: name in C:\Documents and Settings\jswb\桌面\dele.php on line 18
      

  4.   

    $query="delete from stu1 where id=$id and name='$name'";-------------------------------
    Where do you get the $id and $name here ???
    If they are posted or got, use $_GET['id'] or $_POST['id'] to get the value.
      

  5.   

    thanks  a lot  i will try again.
      

  6.   

    是这样吗:
    $id=$_GET['id'] ;
    $name=$_GET['name'] ;
    $query="delete from stu1 where id='$id' and name='$name'";还是不行.
    学生愚钝,大侠明示.
      

  7.   

    <a href=\"dele.php?$id=$id&$name='$name'\">$id</a></td>  这么不能直接可以把$id和$name传给dele.php吗    我该怎么get或post呢