Posts

Showing posts from December, 2022

IN LOOP INPUT TYPE DATA GET

  {% for i in con: %} <td class="Test">                   <input type="text" id="search" name="{{i.name}}" onkeydown="search(this)">                               </td>             </tr>             {% endfor %}                        </table>           <script>                       function search(ele) {                   if(event.key === 'Enter') {                       alert(ele.value);                                console.log(ele.name);                          }               }  </script>          

API - GET, POST, DELETE - REACT JS, CORE PHP

Image
 API - GET, POST, DELETE - REACT JS, CORE PHP ROUTE NPM INSTALL LINK AND AXIOS LINK IN REACT, SRC, FOLDER IN COMPONENTS : MAKE FILE: CreateUser.js import { useState } from "react" ; import axios from "axios" ; import { useNavigate } from "react-router-dom" ; export default function CreateUser (){     const navigate = useNavigate ();         const [inputs, setInputs ] = useState ({})     const handleChange = ( event ) => {         const name = event . target . name ;         const value = event . target . value ;         setInputs ( values => ({ ... values, [name]:value}));     }     const handleSubmit = ( event ) => {         event . preventDefault ();         axios . post ( 'http://localhost/api/user/save' , inputs) . then ( function ( response ){             console . log (response . data);             navigate ( '/' );         });     }     return (         < div >             < h1 > Create

EXAMPLES - HTML, CSS, JAVASCRIPT, REACTJS

Image
 EXAMPLES - HTML, CSS, JAVASCRIPT LISTING.HTML <html> <head> <title></title> </head> <body> <h3>ordered list</h3> <ol type="i"> <li>kolkata</li> <li>howrah</li> <li>dankuni</li> <li>kalyani</li> <li>dunlop</li> </ol> <h3>unordered list</h3> <ul type="square"> <li>kolkata</li> <li>howrah</li> <li>dankuni</li> <li>kalyani</li> <li>dunlop</li> </ul> <h3>Nested List</h3> <ol type="i"> <li>West Bengal <ul type="square"> <li>kolkata</li> <li>howrah</li> </ul> </li> <li>Assam <ul type="circle"> <li>gwahati</li> <li>dispur</li> </ul> </li> <li>Gujrat <ul type="square"> <li>ahmadabad</