mirror of
https://github.com/e107inc/e107.git
synced 2025-08-24 15:13:04 +02:00
Issue #4049 - Media-Manager Url fix. Fixed Media Preview.
Admin-ui: type='media' example added to blank plugin.
This commit is contained in:
@@ -5316,6 +5316,13 @@ var_dump($select_options);*/
|
||||
|
||||
|
||||
case 'media':
|
||||
|
||||
if(!empty($value) && $attributes['data'] === 'json')
|
||||
{
|
||||
$tmp = e107::unserialize($value);
|
||||
$value = !empty($tmp[0]['path']) ? $tmp[0]['path'] : null; // display first item.
|
||||
}
|
||||
|
||||
return e107::getMedia()->previewTag($value, $parms);
|
||||
break;
|
||||
|
||||
@@ -6006,6 +6013,11 @@ var_dump($select_options);*/
|
||||
|
||||
$max = varset($parms['max'],1);
|
||||
|
||||
if(!empty($value) && $attributes['data'] === 'json')
|
||||
{
|
||||
$value = e107::unserialize($value);
|
||||
}
|
||||
|
||||
$ret = "<div class='mediaselector-multi field-element-media'>";
|
||||
for ($i=0; $i < $max; $i++)
|
||||
{
|
||||
|
Reference in New Issue
Block a user