Skip to content

Tag Archives: JavaScript-RegExp

In this article, we have given a number and the task is to replace the characters except for the last character with a specified mask… Read More
In this article, we will find how to validate the IP Address using jQuery. IP Address: Every computer connected to the Internet is identifiable by… Read More
Given a multiline string and the task is to replace line breaks with <br> tag. Example: Input: `Geeks for Geeks is a computer science portal… Read More
The RegExp stands for Regular Expression. A regular expression is a sequence of characters that forms a search pattern. The search pattern can be used… Read More
Given a URL, the task is to validate it. Here we are going to declare a URL valid or Invalid by matching it with the… Read More
The RegExp ignoreCase property in JavaScript is used to specify whether the “i” modifier is set or not. If the “i” modifier is set than… Read More
The compile() Method in JavaScript is used to compile the regular expression while executing of script i.e compile the regular expression. It is also used… Read More
The RegExp constructor in JavaScript is used to return the function that created the RegExp object’s prototype i.e. the construction function for an object. It… Read More
The RegExp test() Method in JavaScript is used to test for match in a string. If there is a match this method returns true else… Read More
The RegExp toString() Method in JavaScript is used to return the string value of the regular expression. Syntax: RegExpObject.toString() Example 1: This example returns the… Read More
The RegExp m{X, Y} Quantifier in JavaScript is used to find the match of any string that contains a sequence of m, X to Y… Read More
The RegExp \uxxxx Metacharacter in JavaScript is used to find the unicode character specified by a hexadecimal number xxxx. If match is found it returns… Read More
The m+ Quantifier in JavaScript is used to find the match of any string that contains at least one m. Syntax: /m+/ or new RegExp("m+")… Read More
The RegExp m$ Quantifier in JavaScript is used to find the match of any string which contains m at the end of it. Syntax: /m$/… Read More
The m? Quantifier in JavaScript is used to find the match of any string that contains zero or one occurrences of m. Syntax: /m?/ or… Read More