|
From: <be...@us...> - 2014-05-10 09:24:16
|
Revision: 12524
http://sourceforge.net/p/xoops/svn/12524
Author: beckmi
Date: 2014-05-10 09:24:13 +0000 (Sat, 10 May 2014)
Log Message:
-----------
source code cosmetic changes
Modified Paths:
--------------
ThirdParty/xoopseditor/trunk/htdocs/class/xoopseditor/tinymce/tinymce/jscripts/tiny_mce/plugins/xoopsemotions/xoopsemotions.php
ThirdParty/xoopseditor/trunk/htdocs/class/xoopseditor/tinymce/tinymce/jscripts/tiny_mce/plugins/xoopsimagemanager/xoopsimagebrowser.php
ThirdParty/xoopseditor/trunk/htdocs/class/xoopseditor/tinymce/tinymce/jscripts/tiny_mce/plugins/xoopsimagemanager/xoopsimagemanager.php
ThirdParty/xoopseditor/trunk/htdocs/class/xoopseditor/tinymce/tinymce/jscripts/tiny_mce/plugins/xoopsmlcontent/xoopsmlcontent.php
Modified: ThirdParty/xoopseditor/trunk/htdocs/class/xoopseditor/tinymce/tinymce/jscripts/tiny_mce/plugins/xoopsemotions/xoopsemotions.php
===================================================================
--- ThirdParty/xoopseditor/trunk/htdocs/class/xoopseditor/tinymce/tinymce/jscripts/tiny_mce/plugins/xoopsemotions/xoopsemotions.php 2014-05-10 09:18:31 UTC (rev 12523)
+++ ThirdParty/xoopseditor/trunk/htdocs/class/xoopseditor/tinymce/tinymce/jscripts/tiny_mce/plugins/xoopsemotions/xoopsemotions.php 2014-05-10 09:24:13 UTC (rev 12524)
@@ -13,10 +13,9 @@
* @version $Id$
*/
-
// load mainfile.php - start
$current_path = dirname(__FILE__);
-if ( DIRECTORY_SEPARATOR != "/" ) {
+if (DIRECTORY_SEPARATOR != "/") {
$current_path = str_replace( DIRECTORY_SEPARATOR, "/", $current_path);
}
$xoops_root_path = substr($current_path, 0, strpos(strtolower($current_path), "/class/xoopseditor/tinymce/"));
@@ -49,7 +48,7 @@
$myts =& MyTextSanitizer::getInstance();
-if ( $admin && $op == 'SmilesAdd' ) {
+if ($admin && $op == 'SmilesAdd') {
if (!$GLOBALS['xoopsSecurity']->check()) {
redirect_header($current_file, 3, implode('<br />', $GLOBALS['xoopsSecurity']->getErrors()));
}
@@ -110,7 +109,7 @@
<body>
<?php
-if ( !$_SESSION['XoopsEmotions'] && !$admin) {
+if (!$_SESSION['XoopsEmotions'] && !$admin) {
echo "<div class='xoopsEmotions'>";
echo "<div>{#xoopsemotions_dlg.error_noemotions}</div>";
echo "</div>";
@@ -136,21 +135,21 @@
<div class="panel_wrapper">
<div id="emotionsbrowser_panel" class="panel current" style="overflow:auto;">
<?php
- if ( $smiles = $_SESSION['XoopsEmotions'] ) {
+ if ($smiles = $_SESSION['XoopsEmotions']) {
echo "<div><strong>" . _MSC_CLICKASMILIE . "</strong></div>";
echo "<div class='xoopsEmotions'>";
$count = count($smiles);
for ($i = 0; $i < $count; $i++) {
- if ( $op == '' ) {
- if ( $smiles[$i]['display'] ) {
+ if ($op == '') {
+ if ($smiles[$i]['display']) {
echo '<img class="xoopsEmotions" onclick="XoopsemotionsDialog.insert(this);" src="' . XOOPS_UPLOAD_URL . '/' . $smiles[$i]['smile_url'] . '" alt="' . $myts->htmlspecialchars($smiles[$i]['emotion']) . '" title="' . $myts->htmlspecialchars($smiles[$i]['emotion']) . '" />';
}
} else {
echo '<img class="xoopsEmotions" onclick="XoopsemotionsDialog.insert(this);" src="' . XOOPS_UPLOAD_URL . '/' . $smiles[$i]['smile_url'] . '" alt="' . $myts->htmlspecialchars($smiles[$i]['emotion']) . '" title="' . $myts->htmlspecialchars($smiles[$i]['emotion']) . '" />';
}
}
- if ( $op == '' ) {
+ if ($op == '') {
echo '<div class="xoopsEmotions">';
echo '<a class="xoopsEmotions" href="' . $current_file . '?op=' . _MORE . '">' . _MORE . '</a>';
echo '</div>';
@@ -195,4 +194,4 @@
</div>
</div>
-<?php xoops_footer(); ?>
\ No newline at end of file
+<?php xoops_footer(); ?>
Modified: ThirdParty/xoopseditor/trunk/htdocs/class/xoopseditor/tinymce/tinymce/jscripts/tiny_mce/plugins/xoopsimagemanager/xoopsimagebrowser.php
===================================================================
--- ThirdParty/xoopseditor/trunk/htdocs/class/xoopseditor/tinymce/tinymce/jscripts/tiny_mce/plugins/xoopsimagemanager/xoopsimagebrowser.php 2014-05-10 09:18:31 UTC (rev 12523)
+++ ThirdParty/xoopseditor/trunk/htdocs/class/xoopseditor/tinymce/tinymce/jscripts/tiny_mce/plugins/xoopsimagemanager/xoopsimagebrowser.php 2014-05-10 09:24:13 UTC (rev 12524)
@@ -15,7 +15,7 @@
// load mainfile.php
$current_path = dirname(__FILE__);
-if ( DIRECTORY_SEPARATOR != "/" ) {
+if (DIRECTORY_SEPARATOR != "/") {
$current_path = str_replace( DIRECTORY_SEPARATOR, "/", $current_path);
}
$xoops_root_path = substr($current_path, 0, strpos(strtolower($current_path), "/class/xoopseditor/tinymce/"));
@@ -27,7 +27,7 @@
*/
$op = "list"; // default
if (isset($_POST)) {
- foreach ( $_POST as $k => $v ) {
+ foreach ($_POST as $k => $v) {
${$k} = $v;
}
}
@@ -39,7 +39,6 @@
xoops_loadLanguage("admin", "system");
xoops_loadLanguage("/admin/images", "system");
-
// include
xoops_load( "xoopsformloader" );
xoops_load( "xoopsmodule" );
@@ -63,7 +62,6 @@
$catreadcount = count($catreadlist); // count readable categories
$catwritecount = count($catwritelist); // count writable categories
-
// check/set parameters - start
if (!isset($_REQUEST["target"])) {
exit();
@@ -87,15 +85,13 @@
$imgcat_id = intval($_GET["imgcat_id"]);
}
-if(isset($imgcat_id)) {
+if (isset($imgcat_id)) {
$imgcat_id = intval($imgcat_id);
}
$target = htmlspecialchars($target);
-
if ( ($isadmin) || ($catreadcount > 0) || ($catwritecount > 0) ) {
-
// Save Image modification - start
if ( !empty($_POST["op"]) && $op == "save" ) {
if (!$GLOBALS["xoopsSecurity"]->check()) {
@@ -346,7 +342,6 @@
}
// Delete categorie - end
-
// ************************* NOT USED ************************************
// Confirm delete file - start
if ( !empty($_GET["op"]) && $op == "delfile" ) {
@@ -402,7 +397,7 @@
echo '<div class="tabs">';
echo '<ul>';
echo '<li id="imagebrowser_tab" class="current"><span><a href="javascript:mcTabs.displayTab(\'imagebrowser_tab\',\'imagebrowser_panel\');" onmousedown="return false;">';
-if ( $op == 'listimg' ) {
+if ($op == 'listimg') {
echo '{#xoopsimagebrowser_dlg.tab_listimages}';
} else {
echo '{#xoopsimagebrowser_dlg.tab_listcategories}';
@@ -411,7 +406,7 @@
if (!empty($catwritelist)) {
echo '<li id="loadimage_tab"><span><a href="javascript:mcTabs.displayTab(\'loadimage_tab\',\'loadimage_panel\');" onmousedown="return false;">{#xoopsimagebrowser_dlg.tab_loadimage}</a></span></li>';
}
-if ( $isadmin ) {
+if ($isadmin) {
echo '<li id="createcategory_tab"><span><a href="javascript:mcTabs.displayTab(\'createcategory_tab\',\'createcategory_panel\');" onmousedown="return false;">{#xoopsimagebrowser_dlg.tab_createcategory}</a></span></li>';
}
echo '</ul>';
@@ -503,7 +498,7 @@
echo '<td class="odd">'.$images[$i]->getVar('image_mimetype').'</td>';
echo '</tr>';
- if ( $catwritelist ) {
+ if ($catwritelist) {
echo '<tr>';
echo '<td class="head">'._IMAGECAT.'</td>';
echo '<td class="even">';
@@ -538,7 +533,7 @@
$nav = new XoopsPageNav($imgcount, 20, $start, 'start', 'op=listimg&target='.$target.'&imgcat_id='.$imgcat_id);
echo '<div text-align="right">'.$nav->renderNav().'</div>';
}
- if ( $catwritelist ) {
+ if ($catwritelist) {
echo '<input type="hidden" name="op" value="save" />'.$GLOBALS['xoopsSecurity']->getTokenHTML().'<input type="submit" name="submit" value="'._SUBMIT.'" />';
echo '</form>';
}
@@ -608,7 +603,7 @@
//create Image - end
//create Category - start
- if ( $isadmin ) {
+ if ($isadmin) {
echo '<div id="createcategory_panel" class="panel" style="overflow:auto;">';
$form = new XoopsThemeForm(_MD_ADDIMGCAT, 'imagecat_form', ''.$current_file.'?target='.$target.'', 'post', true);
$form->addElement(new XoopsFormText(_MD_IMGCATNAME, 'imgcat_name', 50, 255), true);
@@ -634,4 +629,3 @@
echo '</div>';
xoops_footer();
-?>
\ No newline at end of file
Modified: ThirdParty/xoopseditor/trunk/htdocs/class/xoopseditor/tinymce/tinymce/jscripts/tiny_mce/plugins/xoopsimagemanager/xoopsimagemanager.php
===================================================================
--- ThirdParty/xoopseditor/trunk/htdocs/class/xoopseditor/tinymce/tinymce/jscripts/tiny_mce/plugins/xoopsimagemanager/xoopsimagemanager.php 2014-05-10 09:18:31 UTC (rev 12523)
+++ ThirdParty/xoopseditor/trunk/htdocs/class/xoopseditor/tinymce/tinymce/jscripts/tiny_mce/plugins/xoopsimagemanager/xoopsimagemanager.php 2014-05-10 09:24:13 UTC (rev 12524)
@@ -15,7 +15,7 @@
// load mainfile.php
$current_path = dirname(__FILE__);
-if ( DIRECTORY_SEPARATOR != "/" ) {
+if (DIRECTORY_SEPARATOR != "/") {
$current_path = str_replace( DIRECTORY_SEPARATOR, "/", $current_path);
}
$xoops_root_path = substr($current_path, 0, strpos(strtolower($current_path), "/class/xoopseditor/tinymce/"));
@@ -301,12 +301,19 @@
</html>
<?php
+/**
+ * @param string $inputname
+ * @param bool $canbrowse
+ *
+ * @return string
+ */
function imageBrowser( $inputname = "src", $canbrowse = false ) {
$html = "";
- if ( $canbrowse ) {
+ if ($canbrowse) {
$html = "<img title=\"{#xoopsimagebrowser.desc}\" class=\"xoopsimagebrowser\" src=\"img/xoopsimagemanager.png\"
onclick=\"javascript:XoopsImageBrowser('" . $inputname . "');\" />\n";
}
+
return $html;
}
-?>
\ No newline at end of file
+?>
Modified: ThirdParty/xoopseditor/trunk/htdocs/class/xoopseditor/tinymce/tinymce/jscripts/tiny_mce/plugins/xoopsmlcontent/xoopsmlcontent.php
===================================================================
--- ThirdParty/xoopseditor/trunk/htdocs/class/xoopseditor/tinymce/tinymce/jscripts/tiny_mce/plugins/xoopsmlcontent/xoopsmlcontent.php 2014-05-10 09:18:31 UTC (rev 12523)
+++ ThirdParty/xoopseditor/trunk/htdocs/class/xoopseditor/tinymce/tinymce/jscripts/tiny_mce/plugins/xoopsmlcontent/xoopsmlcontent.php 2014-05-10 09:24:13 UTC (rev 12524)
@@ -15,7 +15,7 @@
// load mainfile.php - start
$current_path = dirname(__FILE__);
-if ( DIRECTORY_SEPARATOR != "/" ) {
+if (DIRECTORY_SEPARATOR != "/") {
$current_path = str_replace( DIRECTORY_SEPARATOR, "/", $current_path);
}
$xoops_root_path = substr($current_path, 0, strpos(strtolower($current_path), "/class/xoopseditor/tinymce/"));
@@ -41,7 +41,7 @@
$content .= '<select name="mlanguages" id="mlanguages">';
$content .= '<option value="">{#xoopsmlcontent_dlg.sellang}</option>';
if ( is_array($lang_list)&&count( $lang_list ) > 0 ) {
- foreach( array_keys($lang_list) as $lang_name ) {
+ foreach ( array_keys($lang_list) as $lang_name ) {
$lang =& $lang_list[$lang_name];
$content .= '<option value="' . $lang['base']->getVar('lang_code') . '">' . $lang['base']->getVar('lang_name') . '</option>';
}
@@ -54,7 +54,7 @@
$content .= '<select name="mlanguages" id="mlanguages">';
$content .= '<option value="">{#xoopsmlcontent_dlg.sellang}</option>';
- foreach( $easiestml_langs as $l => $lang ) {
+ foreach ($easiestml_langs as $l => $lang) {
$content .= '<option value="'.$lang.'">'.$langnames[$l].'</option>' ;
}
$content .= '</select>';
@@ -114,7 +114,6 @@
</tr>
</table>
-
<div class="mceActionPanel floatright">
<input type="submit" id="insert" name="insert" value="{#insert}" onclick="XoopsmlcontentDialog.insertMLC();return false;"/>
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
@@ -123,4 +122,4 @@
</div>
</form>
</body>
-</html>
\ No newline at end of file
+</html>
|