";
- }
+
}
// todo
if($this->getQuery('audio') || $this->getQuery('bbcode') == 'audio')
{
- if(deftrue('e_DEBUG_AUDIO'))
- {
$text .= "
";
// $text .= "
";
$text .= $this->audioTab();
$text .= "
";
- }
-
}
diff --git a/e107_admin/newspost.php b/e107_admin/newspost.php
index 9fc711bc5..a047f97fa 100644
--- a/e107_admin/newspost.php
+++ b/e107_admin/newspost.php
@@ -1752,7 +1752,15 @@ class news_form_ui extends e_admin_form_ui
}
}
- $text = $frm->imagepicker('news_thumbnail[0]', varset($thumbTmp[0]), varset($paths[0]),'media=news&video=1&legacyPath={e_IMAGE}newspost_images');
+ if(deftrue('e_DEBUG_MEDIAPICKER'))
+ {
+ $text = $frm->mediapicker('news_thumbnail[0]', varset($thumbTmp[0]),'media=news&image=1&video=1&audio=1');
+ }
+ else
+ {
+ $text = $frm->imagepicker('news_thumbnail[0]', varset($thumbTmp[0]), varset($paths[0]),'media=news&video=1&legacyPath={e_IMAGE}newspost_images');
+ }
+
$text .= $frm->imagepicker('news_thumbnail[1]', varset($thumbTmp[1]), varset($paths[1]),'media=news&video=1&legacyPath={e_IMAGE}newspost_images');
$text .= $frm->imagepicker('news_thumbnail[2]', varset($thumbTmp[2]), varset($paths[2]),'media=news&video=1&legacyPath={e_IMAGE}newspost_images');
$text .= $frm->imagepicker('news_thumbnail[3]', varset($thumbTmp[3]), varset($paths[3]),'media=news&video=1&legacyPath={e_IMAGE}newspost_images');
diff --git a/e107_admin/ver.php b/e107_admin/ver.php
index 9517cac5a..596a017ff 100644
--- a/e107_admin/ver.php
+++ b/e107_admin/ver.php
@@ -10,6 +10,6 @@
if (!defined('e107_INIT')) { exit; }
-$e107info['e107_version'] = "2.1.8 (git)";
+$e107info['e107_version'] = "2.1.9 (git)";
?>
\ No newline at end of file
diff --git a/e107_handlers/e_parse_class.php b/e107_handlers/e_parse_class.php
index b4c3b8512..dc1a3a872 100644
--- a/e107_handlers/e_parse_class.php
+++ b/e107_handlers/e_parse_class.php
@@ -4624,6 +4624,27 @@ class e_parser
return ($ext === 'jpg' || $ext === 'png' || $ext === 'gif' || $ext === 'jpeg') ? true : false;
}
+
+ /**
+ * @param $file
+ * @param array $parm
+ * @return string
+ */
+ public function toAudio($file, $parm=array())
+ {
+
+ $file = $this->replaceConstants($file, 'abs');
+
+ $text = '
';
+
+ return $text;
+
+ }
+
+
/**
* Display a Video file.
@@ -4640,6 +4661,8 @@ class e_parser
list($id,$type) = explode(".",$file,2);
$thumb = vartrue($parm['thumb']);
+ $mode = varset($parm['mode'],false); // tag, url
+
$pref = e107::getPref();
@@ -4670,6 +4693,13 @@ class e_parser
// $thumbSrc = "https://i1.ytimg.com/vi/".$id."/0.jpg";
$thumbSrc = "https://i1.ytimg.com/vi/".$id."/mqdefault.jpg";
$video = '
';
+ $url = 'http://youtu.be/'.$id;
+
+
+ if($mode === 'url')
+ {
+ return $url;
+ }
if($thumb === 'tag')
@@ -4682,7 +4712,7 @@ class e_parser
$thumbSrc = "http://i1.ytimg.com/vi/".$id."/maxresdefault.jpg"; // 640 x 480
$filename = 'temp/yt-thumb-'.md5($id).".jpg";
$filepath = e_MEDIA.$filename;
- $url = 'http://youtu.be/'.$id;
+
if(!file_exists($filepath))
{
@@ -4742,11 +4772,22 @@ class e_parser
return '
'.$video.'
';
}
- if($type === 'mp4') //TODO FIXME
+ if($type === 'mp4')
{
+ $file = $this->replaceConstants($file, 'abs');
+
+ if($mode === 'url')
+ {
+ return $file;
+ }
+
+
+ $width = varset($parm['w'], 320);
+ $height = varset($parm['h'], 240);
+
return '
-