Lines Matching refs:media
84 * Normalizes a media array.
89 // construct media structure based on input
91 $media = $instruction;
94 $media = compact('src','title','align','width','height');
95 $media['type']= 'internalmedia';
98 // normalize internal media links
99 if($media['type'] == 'internalmedia') {
100 list($src,$hash) = explode('#',$media['src'],2);
103 $media['src'] = ':'.$src;
106 // render the media structure
107 return $this->_mediaSyntax($media);
111 * Renders the media syntax.
113 function _mediaSyntax($media) {
115 $src = $media['src'];
118 if(isset($media['width'])) {
119 $size = '?'.$media['width'];
120 if(isset($media['height'])) {
121 $size .= 'x'.$media['height'];
128 if(isset($media['title'])) {
129 $title = '|'.$media['title'];
135 if(isset($media['align'])) {
136 switch($media['align']) {
151 * Renders the link syntax, invoking media normalization