Article Categories
- All Categories
-
Data Structure
-
Networking
-
RDBMS
-
Operating System
-
Java
-
MS Excel
-
iOS
-
HTML
-
CSS
-
Android
-
Python
-
C Programming
-
C++
-
C#
-
MongoDB
-
MySQL
-
Javascript
-
PHP
-
Economics & Finance
Articles by Rushi Javiya
Page 10 of 14
Hide the cursor on a webpage using CSS and JavaScript
In this tutorial, we will learn to hide the cursor on a webpage using CSS and JavaScript. Sometimes, we need to create custom cursor styles or hide the cursor entirely for specific HTML elements to enhance user experience or create interactive interfaces. There are two main approaches to hide the cursor on a webpage. One uses CSS, and another uses JavaScript. We will explore both methods with practical examples. Syntax selector { cursor: none; } Method 1: Using CSS to Hide the Cursor The CSS cursor property allows us ...
Read MoreOnline Group Chat application Using PHP
A web-based online group chat application enables users to communicate in real-time through text messaging. This tutorial demonstrates how to build a complete group chat application using PHP, MySQL, and Bootstrap for a modern interface. Prerequisites Installation Requirements: XAMPP or WAMP server with PHP support MySQL database Web browser for testing Step 1: Database Setup First, create the database and table structure for storing chat messages − CREATE DATABASE onlinechatapp DEFAULT CHARACTER SET utf8; GRANT ALL ON onlinechatapp.* TO 'admin'@'localhost' IDENTIFIED BY 'admin'; USE onlinechatapp; CREATE TABLE ...
Read MoreJava Program to Delete a Node From the Ending of the Circular Linked List
In this article, we will learn the remove the last node of the circular linked list in Java. We set Null to the next pointer of the second-last node to remove the last node from the regular linked list, but in the circular linked list, we need to set the root node to the next pointer of the second-last node. Steps to delete a node from the ending of the circular linked list We will find the second-last node of the circular linked list. While traversing the linked list, we can check whether the next pointer of the current node ...
Read MoreJava program to find 2 elements in the array such that difference between them is largest
In this problem, we will find two array elements such that the difference between them is maximum using Java. We can make a pair of each element and find the difference between the elements of each pair. After that, we can take a pair whose element has a maximum difference. Another approach is to sort the array and take the largest and smallest elements from the array. Problem statement We have given an array containing the integer values. We need to find two array elements to maximize the difference between them. Input 1 array[] = { 50, 10, 30, ...
Read MoreJava Program to Extract Digits from A Given Integer
In Java programming, there are scenarios where we need to extract individual digits from an integer for further manipulation or analysis. This tutorial will guide you through the process of extracting digits from a given integer using Java. Syntax while (num > 0) { int digit = num % 10; System.out.println(digit); num = num / 10; } The above is the syntax to extract digits from an integer in Java. We keep extracting the last digit by taking the remainder of the number with 10. We divide the number by 10 until it ...
Read MoreHow to remove Time from Date TypeScript?
When working with date objects in TypeScript, sometimes it's necessary to extract only the date and remove the time component from it. This can be useful when displaying dates in a user interface or comparing dates. In this tutorial, we will explore several ways to remove time from date in TypeScript. Syntax const dateWithoutTime = date.toLocaleDateString(); const dateWithoutTime = date.toISOString().split('T')[0]; The above is the syntax of two different typescript methods for removing time from date. The first method uses the toLocaleDateString() method. The second method uses this string () method. Example 1: Using the toLocaleDateString() Method const date = ...
Read MoreShow Data Using Text Box in TypeScript
Data representation is crucial in software development, and it is essential to present data in a user-friendly way with the increasing demand for web-based applications. Text boxes are one of the ways to do so. Text boxes provide an easy way to display data to users in a structured and presentable way. This tutorial will provide a comprehensive guide on using text boxes in TypeScript to show data effectively. We will cover what text boxes are, provide syntax and algorithms for working with text boxes, and give multiple examples to illustrate how to use text boxes. What are Text Boxes ...
Read MoreHow to Use Lambda Expression in TypeScript?
Lambda expressions offer a succinct and expressive means of defining functions in TypeScript and are versatile enough to be utilized as class methods, object properties, and callbacks in higher-order functions. This tutorial aims to delve into the syntax of lambda expressions, highlight their advantages over conventional functions, and provide guidance on how to use lambda expressions in TypeScript effectively. What are Lambda Expressions? Lambda expressions, commonly referred to as arrow functions, were first introduced in ECMAScript 6 and have gained widespread usage in contemporary JavaScript and TypeScript code. These expressions provide a succinct syntax for defining functions in both languages. ...
Read MoreHow to fix property not existing on EventTarget in TypeScript?
TypeScript is an open-source language that provides optional static typing for JavaScript. It allows developers to write more maintainable code by catching type-related errors at compile-time rather than runtime. However, working with event listeners in TypeScript can be a bit tricky. One common issue is the "property not existing on EventTarget" error. This error occurs when you try to access a property on an event target that TypeScript doesn't recognise. In this article, we will discuss how to fix this error and provide examples to demonstrate how to use event listeners in TypeScript. Understanding the Error Before we dive into ...
Read MoreHow to get class properties and values using Typescript Reflection?
TypeScript is a superset of JavaScript that provides static typing capabilities, allowing developers to write more reliable and efficient code. One of the most powerful features of TypeScript is its support for reflection. Reflection enables TypeScript developers to inspect and manipulate the properties of classes at runtime, making it easier to write more flexible and dynamic code. In this article, we will explore how to use TypeScript reflection to get class properties and values. We will discuss what reflection is and how it works in TypeScript, provide a brief overview of TypeScript decorators, and then walk through three examples of ...
Read More