wordpress/wp-content/plugins/sqlite-integration/query.class.php
/**
	 * Method to strip all column qualifiers (backticks) from a query except post data.
	 *
	 * All the back quotes execpt user data to be inserted are revomved automatically.
	 * This method must be used when INSERT, UPDATE or REPLACE query is executed.
	 *
	 * Obsolite since 1.5.1
	 *
	 * @access private
	 */
Method to strip all column qualifiers (backticks) from a query except post data.
All the back quotes execpt user data to be inserted are revomved automatically.
This method must be used when INSERT, UPDATE or REPLACE query is executed.



@access private
Method to strip all column qualifiers ( backticks ) from a query except post data . All the back quotes execpt user data to be inserted are revomved automatically . This method must be used when INSERT UPDATE or REPLACE query is executed . @access private
private function safe_strip_backticks() {
		$query_string = '';
		$tokens       = preg_split("/(''|')/s", $this->_query, -1, PREG_SPLIT_DELIM_CAPTURE);
		$literal      = false;
		$query_string = '';
		foreach ($tokens as $token) {
			if ($token == "'") {
				if ($literal) {
					$literal = false;
				} else {
					$literal = true;
				}
			} else {
				if ($literal === false && strpos($token, '`') !== false) {
					$token = str_replace('`', '', $token);
				}
			}
			$query_string .= $token;
		}
		$this->_query = $query_string;
	}
private function safe_strip_backticks ( ) { $ query_string = '' ; $ tokens = preg_split ( " /(''|')/s " , $ this -> _query , - 1 , PREG_SPLIT_DELIM_CAPTURE ) ; $ literal = false ; $ query_string = '' ; foreach ( $ tokens as $ token ) { if ( $ token == " ' " ) { if ( $ literal ) { $ literal = false ; } else { $ literal = true ; } } else { if ( $ literal === false && strpos ( $ token , '`' ) !== false ) { $ token = str_replace ( '`' , '' , $ token ) ; } } $ query_string .= $ token ; } $ this -> _query = $ query_string ; }
Method to strip all column qualifiers (backticks) from a query except post data.
Method to strip all column qualifiers ( backticks ) from a query except post data .