Visibility must be declared on method “__construct” Add public before the class method Detected usage of a non-sanitized input variable: $_POST[‘xyz’] You need to sanitize it. E.g. esc_html( $_POST[‘xyz’] ) or sanitize_text_field( $_POST[‘xyz’] ) Detected usage of a possibly undefined superglobal array index: $_POST[‘query’]. Use isset() or empty() to check Wrap it inside empty() e.g.
Author: imranhsayed
Object Caching In WordPress
Posted onAs a CMS, WordPress is heavily dependent on its database, and database efficiency is crucial to scaling( capability to handle increased/growing workload ) WordPress. If requests to your website generates a large number of database queries, your database servers resource can become overwhelmed. This will reduce your site’s performance and uptime. To avoid multiple database
Storybook for React
Posted onIn this blog, we will talk about what is storybook, why should we use it and how to set up storybook for your React project using storybook and create-react-app. So what is storybook? Storybook is an open source tool that is used for developing UI components in isolation for React, Vue, and Angular. Why should
Google Maps in React: Autocomplete Location Search | Draggable Marker | Marker Infobox
Posted onI will teach you how to integrate Google Maps in your React Project.You will also learn how to create an autocomplete location search and draggable marker. When you search the location and select one the marker will automatically move to that location and display the address in the infobox. We will use the following npm
File Or Image Uploads on Amazon Web Services ( AWS ) using React, Node and Express JS ( aws-sdk )
Posted onI will teach you the quickest and easiest way to upload single as well as multiple files on AWS using React js, Node js and Express js Here are the steps you will take: 1-Create an account on console.aws.amazon.com 2-Create a user and a new bucket. Note the accessKeyId and the secretAccessKey 3-Add policy to the bucket and the
How to create a user and bucket Amazon Web Services ( AWS )
Posted onIn this blog you will learn how to create amazon bucket and user and get the Access key ID and Secret access key for uploading files.. Step-1: Create an account on console.aws.amazon.com Step-2: Create user on console.aws.amazon.comOnce you have created the account Click on service > Security, Identity & Compliance > IAM Now click on Users > Add User
Interesting things about Node JS
Posted onNode JS is a runtime environment built on Chrome’s V8 engine.It is is very efficient in communication. Its great with WebSocket communication.Write data validation only once( DRY Rule )Because you can write your JS code both for front end and for the server, you can do the data validation only one. How does Node work?
Browser APIs
Posted onStorage API Local Storage and Session Storage Few Important points: 1-Local Storage never expire.2. Session storage expire when the user closes the browser tab. Each browser tab will have a separate session.3. When you change local Storage data, an event gets fired that you can listen to. If user has open multiple tabs and changes
Live Search with React
Posted onIn this blog, we will learn about how to create a live search input field, which fetches the result as the user types in the query.Of all the results available for that query, we will only fetch 20 results. We will create a pagination for the user to navigate to the next or previous 20
Set Up React App with WebPack and Babel
Posted onIn this blog you will learn to set up a React Application: Using create-react-app Using Webpack, Webpack Dev Server and Babel from scratch I am assuming that you have Node installed already on your system. Using create-react-app We will first install the create-react-app globally. Then we create a project using create-react-app command. npm install -g create-react-app create-react-app projectnamecd projectname npm run