private function close_php( &$src ){
		if( $this->inphp ){
			$this->inphp = false;
			
			// this may result in back to back tags, which we can avoid with a bit of string manipulation.
			$makenice = $this->opt(COMPILER_OPTION_NICE_TAGS);
			
			if( $makenice && substr( $src, -5 ) === '<?php' ){
				// trim trailing open tag, so no need to close
				$src = substr_replace( $src, '', -5 );
			}
			else {
				$src .= ' ?>';
			}
		}
		return $src;	
	}
private function close_php( &$src ){
		if( $this->inphp ){
			$this->inphp = false;
			
			// this may result in back to back tags, which we can avoid with a bit of string manipulation.
			$makenice = $this->opt(COMPILER_OPTION_NICE_TAGS);
			
			if( $makenice && substr( $src, -5 ) === '<?php' ){
				// trim trailing open tag, so no need to close
				$src = substr_replace( $src, '', -5 );
			}
			else {
				$src .= ' ?>';
			}
		}
		return $src;	
	}
private function close_php ( & $ src ) { if ( $ this -> inphp ) { $ this -> inphp = false ; // this may result in back to back tags, which we can avoid with a bit of string manipulation. $ makenice = $ this -> opt ( COMPILER_OPTION_NICE_TAGS ) ; if ( $ makenice && substr ( $ src , - 5 ) === '<?php' ) { // trim trailing open tag, so no need to close $ src = substr_replace ( $ src , '' , - 5 ) ; } else { $ src .= ' ?>' ; } } return $ src ; }
Close php tag if required.
@usage <code>$src = $this->close_php( $src );</code>
@param string current php source to modify
@return void
Close php tag if required .