1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-11 00:54:49 +02:00

media manager category types

This commit is contained in:
secretr
2012-10-31 21:28:20 +00:00
parent c8612c6d4f
commit a53327433d
2 changed files with 14 additions and 7 deletions

View File

@@ -1566,21 +1566,21 @@ class e107plugin
{
$type = $v['@attributes']['type'];
if($type != 'image' && $type !='file')
if(strpos($type, 'image') !== 0 && strpos($type, 'file') !== 0 && strpos($type, 'video') !== 0)
{
continue;
}
if($c == 3 || ($prevType == $type))
if($c == 4 || ($prevType == $type))
{
$mes->addDebug("Only 2 Media Categories are permitted during install. One for images and one for files.");
$mes->addDebug("Only 3 Media Categories are permitted during install. One for images and one for files.");
break;
}
$prevType = $type;
$data['owner'] = $folder;
$data['category'] = $folder."_".$c;
$data['category'] = $folder."_".$type;
$data['title'] = $v['@value'];
// $data['type'] = $v['@attributes']['type']; //TODO
$data['class'] = 253;