‘A-Z Listing Search and Replace’ usage instructions

The A-Z Listing Search and Replace extension will augment the A-Z Listing plugin to provide two additional attributes on the

shortcode. Use the shortcode as normal, and optionally provide the additional search and replace attributes.

Additional Attributes on the Shortcode

  • search Optionally tells the extension what text to find in the titles of your listing’s items. The value will be parsed as a regular expression using the preg_replace format from PHP (do not include the delimiters, usually / characters, at the start and end of the expression). Anything the pattern matches will be replaced with the value of replace.
  • replace Optionally tells the extension what value to replace the matched text from search. It defaults to empty string meaning remove the matches from the titles entirely. However, it can take any text value.
  • case-sensitive-search Optionally tells the plugin to match the search terms exactly, where upper case and lower case are different values. This option can be set to either on or off and defaults to being disabled meaning that the search is case-insensitive.

Example

Remove “WordPress” from the titles

Note that when removing text you do not need to specify a replace value as the default is an empty string.

Replace “WordPress” followed by a version number in the titles with “Joomla” followed by the same version number

*)" replace="Joomla \1"]