From d62048e192b9471a90aac0a5497697e4e19d609f Mon Sep 17 00:00:00 2001 From: sebastian Date: Fri, 30 Sep 2005 12:32:33 +0000 Subject: [PATCH] bugfixing for 1.0.1 --- .../htmlUI/var/formmask/generic.inc.php | 37 ++++++------------- .../modules/htmlUI/var/html/img/test.m3u | 2 +- .../modules/htmlUI/var/html/ui_browser.php | 9 ++++- .../htmlUI/var/localizer/require.inc.php | 20 +++++----- .../var/templates/script/contextmenu.js.tpl | 7 ++-- .../var/templates/system/stationprefs.tpl | 4 +- .../modules/htmlUI/var/ui_browser.class.php | 20 ++++++++++ 7 files changed, 56 insertions(+), 43 deletions(-) diff --git a/livesupport/modules/htmlUI/var/formmask/generic.inc.php b/livesupport/modules/htmlUI/var/formmask/generic.inc.php index 75ebf93fc..59783759e 100644 --- a/livesupport/modules/htmlUI/var/formmask/generic.inc.php +++ b/livesupport/modules/htmlUI/var/formmask/generic.inc.php @@ -7,15 +7,6 @@ $ui_fmask = array( 'type' => 'hidden', 'constant' => 'changeStationPrefs' ), - array( - 'element' => 'basics', - 'type' => 'header', - 'label' => 'Station Settings', - ), - array( - 'rule' => 'nopunctuation', - 'element' => 'stationMaxfilesize', - ), array( 'element' => 'stationFrequency', 'isPref' => TRUE, @@ -66,11 +57,6 @@ $ui_fmask = array( 'requiredmsg'=> 'please select Logo file', 'attributes'=> array('multiple' => 'application/pdf') ), - array( - 'element' => 'systemsettings', - 'type' => 'header', - 'label' => 'System Settings' - ), array( 'element' => UI_SCRATCHPAD_MAXLENGTH_KEY, 'isPref' => TRUE, @@ -86,21 +72,22 @@ $ui_fmask = array( 'required' => TRUE ), array( - 'element' => 'stationMaxfilesize', - 'isPref' => TRUE, - 'type' => 'text', - 'label' => 'Limit upload filesize', - 'rule' => 'numeric', - 'attributes' => array( - 'onClick' => 'alert ("'.tra('Note: System Maximum is set to $1 in php.ini. You can just reduce this amount here.', - ini_get('upload_max_filesize')).'")' - ) + 'element' =>'cancel', + 'type' =>'button', + 'label' =>'Cancel', + 'attributes'=>array('onclick' => 'location.href="'.UI_BROWSER.'"'), + 'groupit' => TRUE ), array( 'element' =>'Submit', 'type' =>'submit', - 'label' =>'Submit' - ) + 'label' =>'Submit', + 'groupit' => TRUE + ), + array( + 'group' => array('cancel', 'Submit'), + 'label' => ' ' + ), ), 'chgPasswd' => array( diff --git a/livesupport/modules/htmlUI/var/html/img/test.m3u b/livesupport/modules/htmlUI/var/html/img/test.m3u index d5febc54b..6b92aba53 100644 --- a/livesupport/modules/htmlUI/var/html/img/test.m3u +++ b/livesupport/modules/htmlUI/var/html/img/test.m3u @@ -1 +1 @@ -http://fm4.amd.co.at/m3us/listen-high.m3u \ No newline at end of file +http://phoenux/livesupport/storageServer/var/xmlrpc/simpleGet.php?sessid=3058d2c812f32d5daca3fb30cb1aaf52&id=374aa797870b672a diff --git a/livesupport/modules/htmlUI/var/html/ui_browser.php b/livesupport/modules/htmlUI/var/html/ui_browser.php index 249ca9094..91d557144 100644 --- a/livesupport/modules/htmlUI/var/html/ui_browser.php +++ b/livesupport/modules/htmlUI/var/html/ui_browser.php @@ -108,7 +108,12 @@ if (is_array($_REQUEST['popup'])){ $Smarty->assign('data', $uiBrowser->testStream($_REQUEST['url'])); $Smarty->display('popup/testStream.tpl'); break; - + + case "listen2AudioClip": + $Smarty->assign('data', $uiBrowser->listen2AudioClip($_REQUEST['id'])); + $Smarty->display('popup/listen2AudioClip.tpl'); + break; + case "help": $Smarty->display('popup/help.tpl'); break; @@ -118,7 +123,7 @@ if (is_array($_REQUEST['popup'])){ }; if ($uiBrowser->userid) { - $Smarty->assign('showMenuTop', TRUE); + $Smarty->assign('showMenuTop', TRUE); switch ($_REQUEST['act']){ case "fileList": diff --git a/livesupport/modules/htmlUI/var/localizer/require.inc.php b/livesupport/modules/htmlUI/var/localizer/require.inc.php index da3056b4b..50bd138b4 100644 --- a/livesupport/modules/htmlUI/var/localizer/require.inc.php +++ b/livesupport/modules/htmlUI/var/localizer/require.inc.php @@ -1,14 +1,16 @@  ##Remove from Scratchpad## "; + contextmenuHtml = contextmenuHtml + "
  •  ##Remove from ScratchPad## 
  • "; break; case "listen": - contextmenuHtml = contextmenuHtml + "
  •  ##Listen## 
  • "; + contextmenuHtml = contextmenuHtml + "
  •  ##Listen## 
  • "; break; case "edit": @@ -128,8 +128,7 @@ return false; } - - + function showcontextmenu(e) { var contextmenuWidth = document.getElementById('contextmenu').clientWidth; var contextmenuHeight = document.getElementById('contextmenu').clientHeight; diff --git a/livesupport/modules/htmlUI/var/templates/system/stationprefs.tpl b/livesupport/modules/htmlUI/var/templates/system/stationprefs.tpl index 6487e08dc..5b52b3947 100644 --- a/livesupport/modules/htmlUI/var/templates/system/stationprefs.tpl +++ b/livesupport/modules/htmlUI/var/templates/system/stationprefs.tpl @@ -1,6 +1,6 @@ -{*include file="sub/x.tpl"*}
    -{include file="sub/dynForm_sections.tpl"} +

    ##Station settings##

    +{include file="sub/dynForm_plain.tpl"}
    \ No newline at end of file diff --git a/livesupport/modules/htmlUI/var/ui_browser.class.php b/livesupport/modules/htmlUI/var/ui_browser.class.php index 0c84f5b04..e45cfc808 100644 --- a/livesupport/modules/htmlUI/var/ui_browser.class.php +++ b/livesupport/modules/htmlUI/var/ui_browser.class.php @@ -431,5 +431,25 @@ class uiBrowser extends uiBase { 'port' => $port, ); } + + function listen2AudioClip($clipid) + { + #$pls = "[playlist]\n". + #$pls .= "File1=http://{$_SERVER['SERVER_NAME']}".$this->config['accessRawAudioUrl']."?sessid={$this->sessid}&id=$clipid\n"; + #$pls .= "Title1=Mein Titel\n"; + #$pls .= "NumberOfEntries=1\nVersion=2"; + + #$m3u = "#EXTM3U\n"; + #$m3u .= "#EXTINF:111,Mein Titel\n"; + $m3u .= "http://{$_SERVER['SERVER_NAME']}".$this->config['accessRawAudioUrl']."?sessid={$this->sessid}&id=$clipid\n"; + + touch(UI_TESTSTREAM_MU3_TMP); + $handle = fopen(UI_TESTSTREAM_MU3_TMP, "w"); + fwrite($handle, $m3u); + fclose($handle); + } + + + } ?> \ No newline at end of file