javascript - angular show inputs base checkbox ng-model make inputs unreachable -


please help, have following code

<div>     <input type="checkbox" id="chk1" ng-model="status" />     <span ng-bind="title"></span> </div> <div id="div1" ng-show="status">     <span ng-bind="spantitle" ></span>     <input type="text" id="txtlastname"         ng-model="lastname"        ng-click="lastnameclick()"        ng-blur="lastnameout()"        name="txtlastname" /> </div> 

and when checkbox being checked div1 shown input text cannot clicked or written.

any idea please?

edit: added controller user's comment

function dcontroller($scope) {     var defaultinputtext = "hello";     $scope.title = "check";     $scope.spantitle = "span";     $scope.status = false;     $scope.lastname = defaultinputtext;     $scope.lastnameclick = function () {         if ($scope.lastname ==defaultinputtext) {             $scope.lastname = "";         }     }     $scope.lastnameout = function () {         if ($scope.lastname.length == 0) {             $scope.lastname = defaultinputtext;         }     } } 

from code, have provided, can suggest, problem can in css. may elements overlap input.


Comments

Popular posts from this blog

ruby on rails - RuntimeError: Circular dependency detected while autoloading constant - ActiveAdmin.register Role -

c++ - OpenMP unpredictable overhead -

javascript - Wordpress slider, not displayed 100% width -