Skip to main content

Posts

Showing posts from August, 2015

Password mismatch validation in angularjs

Angular using to apply password mismatch validation in the form. We need a password match validation, When i interred my password field value say for example admin(*****) and conform password field will inter match the same value from the field. The value are match means set flag for a variable is True or   mismatched the value means it will set Fasle.  Based this flag value to show the message form to apply directive of ng-show. This logic apply email validation also. AngularJS: var app = angular.module('frmVal',[]); app.controller('FrmCtrl', function($scope){     $scope.pwd = "";     $scope.cpwd = "";       $scope.isMatch = true;       $scope.$watch('pwd', function(newValue, oldValue){         if(newValue == $scope.cpwd)         {             $scope.isMatch = false;         } else {             $scope.isMatch = true;         }     });     $scope.$watch('cpwd', function(newValue, oldValue){         if(newVal

Fiksu integration by cordova mobile application

Fiksu: A fiksu is a advertisement agency in various media domain. Especially in mobile application side more effectively analysis by mobile users. Their best to do the ads on your application and collective revenue  and pay to the yours. Fiksu Integration Steps:(Install Linux or Ubuntu) 1.  Create an account from fiksu site as following URL https://dashboard.fiksu.com/en/signin . 2.  Singin your credential from this site. 3. Download the fiksu SDK files Download . 4.Then open your terminal and type android command. Open Android SDK manager widget is select Extra package inside play related package list item is select and install it. 5. Now extract fiksu SDK downloaded and get Path details and execute following command. cordova plugin add com.fiksu.sdk --searchpath home/user/Fiksu-SDK-for-Cordova-1.2.0/Library/plugin --noregistry 6. Add the following code from your index.html inside of the javascrip blog. Android: onDeviceReady: function() { app.receive

Angularjs Button

HTML input element is have properties as following ng-model and ng-value as declare dynamic change the event fire on button click. A button ng-value is change on when event is fire, This logic is apply into ng-model component value is replace the ng-value block. Sample HTML Code: <div ng-app="BtnApp"> <div ng-controller="BtnCtrl">     Do you want Car?     <input type="button" ng-model="youWantCar" ng-value="youWantCar" ng-click="changeStatus()"/> </div>     </div> AngularJS: var app = angular.module('BtnApp', []); app.controller('BtnCtrl',function($scope){     $scope.youWantCar = "No";     $scope.changeStatus = function(){         if($scope.youWantCar == "No")             $scope.youWantCar = "Yes";         else             $scope.youWantCar = "No";     };           }); Result: Demo