Contact | Privacy | Datenschutzerklärung | Impressum

indexRE, IndexCaseRE

Format: indexRE ( string, pattern [ , position ] )
Format: IndexCaseRE ( string, pattern [ , position ] )

Purpose: Looks for a regular expression pattern in a string. The pcre library is used for processing the regular expressions and the exact syntax and semantics is documented there. (1 2) The string and pattern parameter must be strings. The position parameter must be an integer. If position is not given, it defaults to 0.

The IndexCaseRE() function works very similar but is not case sensitive.

Return Values: Looks for regular expression pattern in string from the position denoted by position and returns the position where it starts. If the pattern is not contained within the string, null is returned.

Example:

input:resulting output:
<? indexRE("Hello World","[a-z]")>1
<? indexRE("Hello World","[a-c]")>
<? indexRE("Hello World","[a-z]", 5)>7
<? indexRE("Hello World",".$")>10
<? indexRE("Hello World","[^eo]{3}")>8
<? indexCaseRE("Hello World","[a-z]")>0
<? indexCaseRE("Hello World","[a-z]",5)>6

See Also: containsRE(), containsCaseRE(), substRE(), substallRE().


This page was dynamically generated by the web application development tool RADpage of H.E.I. H.E.I. provides support, tools, and services like Webdesign in Mannheimm, the HTML/CSS 3D WebGL Animation Library taccgl, 3D Webdesign, and 3D Product Configurator (3D Produkt Konfigurator in German).

Selected blog articles : 3D Objects on HTML pages, CSS Transition Visibility, and CSS Transition Display.


© 1996-2024 H.E.I. All Rights Reserved.



Homepage
Intro/Features
Component Guide
Programming
  Language Guide
  Language Ref.
    General Design
    Lexical Structure
    Expressions
    Objects
    Methods
    Classes
    heitml Tags
    heitml Functions
    Advanced Functions
      containsRE
      containsCaseRE
      createMatchArray
      fileio_chmod
      fileio_fclose
      fileio_feof
      fileio_fopen
      fileio_fread
      fileio_fwrite
      fileio_strerror
      indexRE
      indexCaseRE
      regexcomp
      regexexec
      request_string
      request_tuple
      substr
      substRE
      substallRE
      TuSearch
      TuSearchTuple
      TuSort
    Database Access
    Global Variables
    Form Fields
    Server Variables
    Sessions
    heitml Syntax
  Component Ref.
  Class Library
  User Components
  Tutorial
  New Features
  heitml 1
User Guide
Services
Privacy
Datenschutz
 
Contact / Impressum