如何使用angularjs将单选按钮值传递给php页面
我正在用html显示单选按钮如何使用angularjs将单选按钮值传递给php页面,php,angularjs,html,Php,Angularjs,Html,我正在用html显示单选按钮 <body ng-app="myApp" ng-controller="MainCtrl"> <form enctype="multipart/form-data" id="FileUploadForm" name="FileUpload" ng-submit="submitData(FileUpload)" novalidate> <div style="text-align: left;font-size:
<body ng-app="myApp" ng-controller="MainCtrl">
<form enctype="multipart/form-data" id="FileUploadForm" name="FileUpload" ng-submit="submitData(FileUpload)" novalidate>
<div style="text-align: left;font-size: 20px;padding: 10px;color: #487eaa;">
<font> Upload Resume</font>
</div>
<div class="file-upload">
<input type="text" id="name" name="name" ng-model="name" />
<br /><br />
<input type="text" id="place" name="place" ng-model="place" />
<br /><br />
<label class="control-label" for="Dilation" style="padding:3px 0;">Dilation</label>
<label>Yes <input type="radio" name="dilation" id="dilation" ng-model="dilation" value="Yes" ng-checked="false" /></label>
<label>No <input type="radio" name="dilation" id="dilation" ng-model="dilation" value="No" ng-checked="false" /></label>
<br /><br />
<label class="control-label" for="NCT" style="padding:3px 0;">NCT</label>
<label>Right <input type="radio" name="nct" id="nct" ng-model="nct" value="Right" ng-checked="false" /></label>
<label>Left <input type="radio" name="nct" id="nct" ng-model="nct" value="Left" ng-checked="false" /></label>
<br /><br />
<input type="file" id="i_file" name="file" ng-file-select="onFileSelect($files)" multiple />
<br /><br />
<input type="submit" id="submit" name="submit" value="submit" ng-disabled="FileUploadForm.$invalid" />
<br /><br />
<div ng-bind="dilation" ng-hide="dilation"></div>
<div ng-bind="nct" ng-hide="nct"></div>
</div>
</form>
</body>
这是一把小提琴:
得到这样的回应
name:qqq,place:eeee,dilation:{\"ng339\":8},nct:{\"ng339\":10}
我是新来的
angularjs
请帮我整理一下。我在你的JS代码中没有看到var dillation
或dillation=whatever
。我想说你的意思是$scope.diability
?查看dnode。我认为它适用于你的问题。@SergiuParaschiv$scope.diagration它的工作原理。谢谢但我用同样的东西来检查它。为什么?我在你的JS代码中没有看到var-dillation
或dillation=whatever
。我想说你的意思是$scope.diability
?查看dnode。我认为它适用于你的问题。@SergiuParaschiv$scope.diagration它的工作原理。谢谢但我用同样的东西来检查它。为什么?
$result = array("filename" => $_FILES["file"],"name" => $_POST['name'],"place" => $_POST['place'],"dilation" => $_POST['dilation'],"nct" => $_POST['nct']);
echo json_encode($result);
name:qqq,place:eeee,dilation:{\"ng339\":8},nct:{\"ng339\":10}