0

ok, the basic routing is like this

sampleApp .config(['$routeProvider',
  function($routeProvider) {
    $routeProvider.
      when('/addOrder', {
        templateUrl: 'templates/add-order.html',
        controller: 'AddOrderController'
      }).

Now in my case, in the node.js server side, when “/addOrder", it'll send text message back to web client. So how should i set up the Angularjs routing please ?

Thanks !

2
  • you dont need routing for that.. you use should $http for that Commented Oct 9, 2015 at 3:31
  • ok, found some samples, let me try 1st. If you have good simple samples, i'd appreciate that too ! Commented Oct 9, 2015 at 3:44

1 Answer 1

1

You can use template: ' ' instead of templateUrl:'templates/add-order.html' .

sampleApp .config(['$routeProvider',
  function($routeProvider) {
    $routeProvider.
      when('/addOrder', {
        template: ' ',
        controller: 'AddOrderController'
      }).
Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.