Saturday 7 January 2017

First AngularJS program with ASP.NET

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>

<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
     <script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.2.5/angular.min.js"></script>
    <script>
     
        angular.module("myapp", [])
            .controller("HelloController", function ($scope) {
                $scope.helloTo = {};
                $scope.helloTo.title = "World,This is first AngularJS Program With ASP.NET BY SANTOSH KUMAR SINGH";
               
            });
</script>
</head>
<body ng-app="myapp">
    <form id="form1" runat="server">
   <div ng-controller="HelloController" >
<h2>Hello {{helloTo.title}} !</h2>
</div>
       
       
    </form>
</body>
</html>

No comments:

Post a Comment