Title: ignore ; between quotes
Last modified: August 21, 2016

---

# ignore ; between quotes

 *  [antonymken1](https://wordpress.org/support/users/antonymken1/)
 * (@antonymken1)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/ignore-between-quotes/)
 * in this file ajax.php
 * on line 10: i have replaced
    `$cmdArr = explode(';', $commands);` with this `
   $cmdArr = quoted_explode($commands, $delimiters = ';');`
 * you will also need this functions
 *     ```
       function regex_escape($subject) {
       		return str_replace(array('\\', '^', '-', ']'), array('\\\\', '\\^', '\\-', '\\]'), $subject);
       	}
   
       	function quoted_explode($subject, $delimiters = ',', $quotes = '\'') {
       		$clauses[] = '[^'.regex_escape($delimiters.$quotes).']';
       		foreach(str_split($quotes) as $quote) {
       			$quote = regex_escape($quote);
       			$clauses[] = "[$quote][^$quote]*[$quote]";
       		}
       		$regex = '(?:'.implode('|', $clauses).')+';
       		preg_match_all('/'.str_replace('/', '\\/', $regex).'/', $subject, $matches);
       		return $matches[0];
       	}
       ```
   
 * [http://wordpress.org/extend/plugins/wp-mysql-console/](http://wordpress.org/extend/plugins/wp-mysql-console/)

The topic ‘ignore ; between quotes’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/wp-mysql-console.svg)
 * [WP MySQL Console](https://wordpress.org/plugins/wp-mysql-console/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-mysql-console/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-mysql-console/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-mysql-console/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-mysql-console/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-mysql-console/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [antonymken1](https://wordpress.org/support/users/antonymken1/)
 * Last activity: [13 years, 2 months ago](https://wordpress.org/support/topic/ignore-between-quotes/)
 * Status: not resolved