angular.js 怎么往数据库存取数据?还有请问下我哪写错了该怎么写。

<?php
    $path="localhost";
    $name="root";
    $pword="";
    $db="ly";

    $lname=$_REQUEST["lname"];
    $lyx=$_REQUEST["lyx"];
    $lcontent=$_REQUEST["lcontent"];

    $conn=new mysqli($path,$name,$pword,$db);

    $sql="insert into ll(lname,lyx,lcontent)values('".$lname."','".$lyx."','".$lcontent."')";

    if($conn->query($sql)===TRUE){
        echo 1;
    }else{
        echo 0;
    }
?>
angular.module(,[]);
.((){
    .when(,{templateUrl})
        .when(,{templateUrl})
        .when(,{templateUrl})
        .when(,{templateUrl})
        .when(,{templateUrl})
        .when(,{templateUrl,controller});

});
.controller(,(,){
    .lname;
    .lyx;
    .lcontent;
    .(){
        .(,{lname.lname, lyx.lyx,lcontent.lcontent})
            .success(() {
                (.success){
                    ();
                }
            })
    }

});
<>
<>
  <>
    <></>
  </>
  <>
    <><>
      </>
    </></>
  </>
  <>
    <></>
  </>
  <>
    <><>
      </>
    </></>
  </>
  <>
    <></>
  </>
  <>
    <><>
      <></>
    </></>
  </>
  <>
    <> <> </></><></>
    </></>
    </></>
  </>
</>


慕粉4174691
浏览 2549回答 2
2回答

Tobey_滔

首先...ng是不能与数据库交互的.....nodejs就可以.....其次你操作数据库的是使用php

慕瓜9220888

QRNGVSIEEKLDSAFVSBWDHMOHNQTOVNFXDTQMNETFEAJZGXYKZRQJWGNRGODWGILJUMIBUKHGISZRJMCBOFIGPKDDNJEVEUWTZPFHSASOKEGQFAPXTTOBLJKJLRHKXGNEPRDMSCFGXGYIRBUTFZKPXADDZEBNIQTDZFHZAZRXTBIJQFXJRBSOZIRJBORUNOFEWVYEKAWARAJPYYITUJKCCCVBMNMUTMFFYFGVDRNANTESXJKHKDZCGPNZYLLJWNPNWVUUXSRGCKPCOYXYTFAQNZPTKFETCJMFPTVNXDGCMFVTVRDAWJDBWZBLUOBYMOMYIEEUVNWEWJJFPQBQSGJMCZOZEGVHEFZMXEPLOHDXNUWOJTMZPDKGETJDW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