javascript - how to pass parameters to redirected page? -


i have script work on button click:

 $scope.showdetailsaboutticket = function (pinticket) {         if ($scope.showdetail == false && pinticket != null) {             $scope.pinticket = pinticket;               $http.get(ticketurl + 'getticket/' + $scope.terminalid + '/' + $scope.pinticket)                 .success(function(data, status, headers, config)                  {                      $("#background").addclass("darker");                     $scope.showdetail = true;                     $scope.ticketnotfound = false;                     $location.search("ticketid", pinticket);                   })                 .error(function(data, status, headers, config) {                      $scope.ticketnotfound = true;                     $scope.showdetail = false;                })            .then(ticketdetails, errorresponse);          }      } 

everything works fine.i url :http://localhost:60664/home#?ticketid=8837278738 want when user click on button redirect him sport page parameters...how can that? tried window.location dont parameters

you should define routes in configuration , should invoke route when user clicks button.

you can use either ng-route or more extended version ui-router.


Comments

Popular posts from this blog

powershell Start-Process exit code -1073741502 when used with Credential from a windows service environment -

twig - Using Twigbridge in a Laravel 5.1 Package -

c# - LINQ join Entities from HashSet's, Join vs Dictionary vs HashSet performance -