Lines Matching defs:src
455 $this->_firstimage($name['src']);
457 $this->_recordMediaUsage($name['src']);
473 $this->_firstimage($name['src']);
475 $this->_recordMediaUsage($name['src']);
512 $this->_firstimage($name['src']);
514 $this->_recordMediaUsage($name['src']);
536 $this->_firstimage($name['src']);
538 $this->_recordMediaUsage($name['src']);
558 $this->_firstimage($name['src']);
560 $this->_recordMediaUsage($name['src']);
584 $this->_firstimage($name['src']);
586 $this->_recordMediaUsage($name['src']);
602 * @param string $src media ID
611 $src,
622 $this->_firstimage($src);
623 $this->_recordMediaUsage($src);
629 * @param string $src full media URL
638 $src,
649 $this->_firstimage($src);
732 * @param string $src image URL or ID
734 protected function _firstimage($src)
742 [$src] = explode('#', $src, 2);
743 if (!media_isexternal($src)) {
744 $src = (new MediaResolver($ID))->resolveId($src);
746 if (preg_match('/.(jpe?g|gif|png|webp|svg)$/i', $src)) {
747 $this->firstimage = $src;
754 * @param string $src media ID
756 protected function _recordMediaUsage($src)
760 [$src] = explode('#', $src, 2);
761 if (media_isexternal($src)) {
764 $src = (new MediaResolver($ID))->resolveId($src);
765 $file = mediaFN($src);
766 $this->meta['relation']['media'][$src] = file_exists($file);