how to save data in cookie using jquery code example
Example 1: get all html element data using angular
File your-component-name.component.html
<input type="text"
<button type="submit" (click)="getelementData()">Show element data</button>
file your-component-name.component.ts
In the class make function named as
getelementData(nameinput){
console.log(nameinput); // output will be the whole button element with their attributes
// if you want to show specific attribute data then
console.log(nameinput.value); // it will reflects the value of textbox which has been entered
}
Example 2: print choicefield data from database in django
Try {{ pricedate.get_prices_SD_display }}
Syntax : get_FIELDNAME_display()