/** * Runs through the css file and searches for image files * @since 1.2 * * @param string $file The file path to the CSS file * @param string $url The full live (original) file url of the CSS file * * @return string */ public function invoke_css_file($file, $url) { $file_content = file_get_contents($file); // if this is a CSS file that is on Google Drive already, do not invoke it again if (false !== stripos($url, 'https://googledrive.com')) { return $file_content; } $this->_google_drive_cdn->_is_buffer_css_file = true; $this->_google_drive_cdn->_buffer_css_file_path = $file; $this->_google_drive_cdn->_buffer_css_file_url = $url; $file_content = $this->_google_drive_cdn->buffer($file_content); $this->_google_drive_cdn->_is_buffer_css_file = false; return $file_content; }