Posts

How To Delete A Component In Angular

Steps to delete a component in Angular Remove the import line reference from Angular  app.module.ts  file. Remove the component declaration from @NgModule declaration array in  app.module.ts  file And then manually delete the component folder from Angular project. Finally Delete all the references of component manually from the Angular project. In Angular CLI,there is no command available to delete a component created by Angular CLI as of now. There is no ng delete component command as part of Angular CLI.

How to Create Shareable Download Links for Google Drive Files

First get sharable link grom google Drive , by right click on that file, you will get link like below:  drive.google.com/open?id=111111111 111111111 is the sample fileid. you have to convert this link to like: https://drive.google.com/ uc?export=download&id =111111111  In above line we just replaced  open?id by  uc?export=download&id   

Show/Hide DIV onRadio Buttons

<div class="container"> <p>Click to open div on radio button  </p>   <label class="radio-inline"><input type="radio" name="tab" value="igotnone" onclick="show1();" /> None</label>   <label class="radio-inline"><input type="radio" name="tab" value="igottwo" onclick="show2();" /> Two</label> <div id="div1" class="hide">   <hr><p>Okay Cool! Here is the DIV1...</p> <div class="card" style="width:400px">     <img class="card-img-top" src="https://www.w3schools.com/bootstrap4/img_avatar1.png" alt="Card image" style="width:100%">     <div class="card-body">       <h4 class="card-title">John Doe</h4>       <p class="card-text">Some example text...

pass value from one php page to another using session

page1.php     //store value in session <?php session_start(); $_SESSION['myValue1']=$_GET['cctnspsid']; $_SESSION['myValue2']=$_GET['dairyDate']; $_SESSION['myValue3']=$_GET['srno']; ?> page2.php   // use session value in another page <?php session_start(); echo $_SESSION['myValue1']; session_destroy(); ?>

How to clear all input fields and error messages in bootstrap modal when clicking data-dismiss button?

 $(document).ready(function(){     $('.modal').on('hidden.bs.modal', function (e) {       $(this)       .find(" input[type=text], textarea,select").val('').end()         .find("input[type=checkbox], input[type=radio]").prop("checked", "").end()         /*remove error field when modal close     */         .find(".has-error").removeClass("has-error").end()     .find(".has-success").removeClass("has-success").end()     .find(".FeRror").empty().end();         })     })

clear all error and success div from the input and select fields by jq

function resetData(){ $("#selectorId").find(".has-error").removeClass("has-error"); $("#selectorId").find(".has-success").removeClass("has-success"); $("#selectorId").find(".FeRror").empty(); } /////////////////////////// $('form[name="myform"] input:reset').click(function () {     $('form[name="myform"]')         .find(':radio, :checkbox').removeAttr('checked').end()         .find('textarea, :text, select').val('')           return false; }); //////////////////universe function/////////////// <button type="reset" class="btn btn-primary" onclick="resetDataCaseFrwrd(this)">Clear</button> function resetDataCaseFrwrd(obj){ $(obj).closest("form").find(".has-error").removeClass("has-error"); $(obj).closest("form").f...

Could not find module “@angular-devkit/build-angular”

=========================================== You may try this one also==> npm install ng update and finally npm update