GhostManSec
Server: LiteSpeed
System: Linux premium197.web-hosting.com 4.18.0-553.54.1.lve.el8.x86_64 #1 SMP Wed Jun 4 13:01:13 UTC 2025 x86_64
User: parhudrw (1725)
PHP: 7.4.33
Disabled: NONE
Upload Files
File: //home/parhudrw/saifookhan.com/wp-content/plugins/amp/includes/widgets/class-amp-widget-text.php
<?php
/**
 * Class AMP_Widget_Text
 *
 * @since 0.7.0
 * @package AMP
 * @codeCoverageIgnore
 */

_deprecated_file( __FILE__, '2.0.0' );

if ( class_exists( 'WP_Widget_Text' ) ) {
	/**
	 * Class AMP_Widget_Text
	 *
	 * @since 0.7.0
	 * @deprecated As of 2.0 the AMP_Core_Block_Handler will sanitize the core widgets instead.
	 * @internal
	 * @package AMP
	 */
	class AMP_Widget_Text extends WP_Widget_Text {

		/**
		 * Overrides the parent callback that strips width and height attributes.
		 *
		 * @param array $matches The matches returned from preg_replace_callback().
		 * @return string $html The markup, unaltered.
		 */
		public function inject_video_max_width_style( $matches ) {
			if ( amp_is_request() ) {
				return $matches[0];
			}
			return parent::inject_video_max_width_style( $matches );
		}
	}

}