Posts

Showing posts from March, 2022

imp links

 https://www.npmjs.com/package/ionic-long-press long press example https://devdactic.com/custom-ionic-animations/ small animations

pdf upload in angular

  pdfOnload(event) {      const file = event.target.files[0];     const reader = new FileReader();     reader.readAsDataURL(file);     reader.onload = () => {         console.log(reader.result);          this.base64=reader.result;     };   }  <div class="form-group">                         <label for="file">Attach1</label>                         <input type="file"                                id="file" accept="pdf/*"                                  (change)="pdfOnload($event)">                     </div...

image upload in angular

   <input class="display1"                         type="file"                         id="fileInput"                         name="fileInput"                         accept="image/*"                          (change)="selectFiles($event)"                       /> selectFiles(event: any): void {          this.selectedFileNames = [];     this.selectedFiles = event.target.files;     this.previews = [];     if (this.selectedFiles && this.selectedFiles[0]) {       const numberOfFiles = this.selectedFiles.length;       for (let i =...

angular app

import { HttpClient, HttpHeaders } from '@angular/common/http'; import { Injectable } from '@angular/core'; import { Observable, throwError } from 'rxjs'; import { catchError, retry } from 'rxjs/operators'; import {Location, LocationStrategy, PathLocationStrategy} from '@angular/common'; @Injectable({ providedIn: 'root' }) export class ApiService { location: Location; apiURL='http://207.38.84.105/CT/api'; constructor(private http: HttpClient,location: Location){ this.location = location; } Login(data){ return this.http.post(this.apiURL + '/loginCT.php',data) .pipe( retry(1), catchError(this.handleError) ) } queryCandidateget(data){ return this.http.post(this.apiURL + '/queryCandidateget.php',data) .pipe( retry(1), catchError(this.handleError) ) } searchInsert(data){ return this.http.post(this.apiURL + '/insertCandidateSearches.php...

npm

 sudo apt-get remove nodejs sudo apt-get remove npm Then go to /etc/apt/sources.list.d and remove any node list if you have. Then do a sudo apt-get update Check for any .npm or .node folder in your home folder and delete those. If you type install node nvm install 12.14.0 error ionic npm i paulstelzer-ionic-angular-toolkit

git

 echo "# test" >> README.md git init git add README.md git commit -m "first commit" git branch -M main git remote add origin https://github.com/bhavanigattikoppula/test.git git push -u origin main