Changeset 1691 in ExiteCMS
- Timestamp:
- 08/25/08 18:49:18 (3 years ago)
- Location:
- branches/PLi-Fusion
- Files:
-
- 7 edited
-
forum/viewthread.php (modified) (1 diff)
-
includes/core_functions.php (modified) (1 diff)
-
includes/forum_functions_include.php (modified) (2 diffs)
-
includes/jscripts/core_functions.js (modified) (3 diffs)
-
includes/templates/forum.post.tpl (modified) (4 diffs)
-
includes/templates/forum.viewthread.tpl (modified) (4 diffs)
-
includes/user_functions.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/PLi-Fusion/forum/viewthread.php
r1666 r1691 301 301 } 302 302 if (is_array($groups)) { 303 // check for group matching as well, assume a match will be found304 $ranking_match = true;303 // check for group matching as well, start with the opposite of the 'bail out' value 304 $ranking_match = $data2['rank_groups_and']; 305 305 foreach($groups as $group) { 306 306 if ($data2['rank_groups_and']) { -
branches/PLi-Fusion/includes/core_functions.php
r1666 r1691 695 695 // quote & code blocks 696 696 $text = preg_replace('#\[quote=([\r\n]*)(.*?)\]#si', '<b>\2 '.$locale['199'].':</b><br />[quote]', $text); 697 $qcount = substr_count( $text, "[quote]"); $ccount = substr_count($text, "[code]");697 $qcount = substr_count(strtolower($text), "[quote]"); $ccount = substr_count(strtolower($text), "[code]"); 698 698 for ($i=0;$i < $qcount;$i++) $text = preg_replace('#\[quote\](.*?)\[/quote\]#si', '<div class=\'quote\'>\1</div>', $text); 699 699 for ($i=0;$i < $ccount;$i++) $text = preg_replace('#\[code\](.*?)\[/code\]#si', '<b>code:</b><div class=\'codeblock\'>\1</div>', $text); -
branches/PLi-Fusion/includes/forum_functions_include.php
r1666 r1691 401 401 global $urlblocks; 402 402 403 $urlblocks[] = array($matches[1]=="="?$matches[2]:substr($matches[1],1), $matches[2]);403 $urlblocks[] = array($matches[1]=="="?$matches[2]:substr($matches[1],1), parseubb(shortenlink($matches[2],50))); 404 404 return "{@@*".(count($urlblocks)-1)."*@@}"; 405 405 } … … 417 417 // validate the URL before converting it 418 418 if (isURL($matches[0])) { 419 $urlblocks[] = array($matches[0], shortenlink($matches[0], 50));419 $urlblocks[] = array($matches[0], parseubb(shortenlink($matches[0], 50))); 420 420 return "{@@*".(count($urlblocks)-1)."*@@}"; 421 421 } else { -
branches/PLi-Fusion/includes/jscripts/core_functions.js
r1666 r1691 59 59 60 60 // update the innerHTML of 'id' using an AJAX call 61 function clientSideInclude(id, url ) {61 function clientSideInclude(id, url, error) { 62 62 63 63 var element = document.getElementById(id); … … 67 67 } 68 68 var response = AjaxCall(url); 69 if (response != false) {69 if (response != null) { 70 70 element.innerHTML = response; 71 71 } else { 72 element.innerHTML = "Sorry, your browser does not support XMLHTTPRequest objects. This page requires Internet Explorer 5 or better for Windows, or Firefox for any system, or Safari. Other compatible browsers may also exist."; 73 } 74 } 75 76 // simple synchronous AJAX call 72 if (error != null && error) { 73 element.innerHTML = "Sorry, your browser does not support XMLHTTPRequest objects. This page requires Internet Explorer 5 or better for Windows, or Firefox for any system, or Safari. Other compatible browsers may also exist."; 74 } 75 } 76 } 77 78 // simple synchronous AJAX call, return null when it fails 77 79 function AjaxCall(url) { 78 80 … … 98 100 } 99 101 if (req) { 100 // Synchronous request, wait till we have it all 101 req.open('GET', url, false); 102 req.send(null); 103 return req.responseText; 104 } else { 105 return false; 102 try { 103 // Synchronous request, wait till we have it all 104 req.open('GET', url, false); 105 req.send(null); 106 if (req.status != 200) { 107 return null; 108 } else { 109 return req.responseText; 110 } 111 } catch (e) { 112 return null; 113 } 114 } else { 115 return null; 106 116 } 107 117 } -
branches/PLi-Fusion/includes/templates/forum.post.tpl
r1666 r1691 91 91 var hoteditor_path = "{$smarty.const.INCLUDES}jscripts/hoteditor-4.2/"; 92 92 var hoteditor_theme_path = "{$smarty.const.THEME}hoteditor"; 93 var hoteditor_reply_to = "{$orgauthor|default:""}"; 93 94 </script> 94 95 <script language="javascript" type="text/javascript" src="{$smarty.const.INCLUDES}jscripts/hoteditor-4.2/editor__0001.js?version=4.2"></script> … … 191 192 <textarea name='attach_comment' cols='50' rows='2' class='textbox'>{$comments}</textarea> 192 193 <br /> 193 <input type='submit' name='upload' value='{$locale.471}' class='button' /> 194 {if $settings.hoteditor_enabled == 0 || $userdata.user_hoteditor == 0} 195 <input type='submit' name='upload' value='{$locale.471}' class='button' /> 196 {else} 197 <input type='submit' name='upload' value='{$locale.471}' class='button' onclick='javascript:get_hoteditor_data();' /> 198 {/if} 194 199 </td> 195 200 </tr> … … 230 235 <input type='text' id='fpm_option_{$opt}' name='fpm[option][{$opt}]' value='{$option}' class='textbox' maxlength='200' style='width:250px' /> 231 236 {if $opt == $fpm.option_show && $opt != $fpm_settings.option_max} 232 <input type='submit' name='fpm[add_options]' class='button' value='{$locale.FPM_104}' /> 237 {if $settings.hoteditor_enabled == 0 || $userdata.user_hoteditor == 0} 238 <input type='submit' name='fpm[add_options]' class='button' value='{$locale.FPM_104}' /> 239 {else} 240 <input type='submit' name='fpm[add_options]' class='button' value='{$locale.FPM_104}' onclick='javascript:get_hoteditor_data();' /> 241 {/if} 233 242 {/if} 234 243 </td> … … 296 305 {/if} 297 306 <input type='submit' name='cancel' value='{$locale.417}' class='button' /> 298 <input type='submit' name='preview' value='{$button_preview}' class='button' onclick='javascript:get_hoteditor_data();' /> 299 <input type='submit' name='save' value='{$button_save}' class='button' onclick='javascript:get_hoteditor_data();' /> 307 {if $settings.hoteditor_enabled == 0 || $userdata.user_hoteditor == 0} 308 <input type='submit' name='preview' value='{$button_preview}' class='button' /> 309 <input type='submit' name='save' value='{$button_save}' class='button' /> 310 {else} 311 <input type='submit' name='preview' value='{$button_preview}' class='button' onclick='javascript:get_hoteditor_data();' /> 312 <input type='submit' name='save' value='{$button_save}' class='button' onclick='javascript:get_hoteditor_data();' /> 313 {/if} 300 314 <input type='hidden' name='post_author' value='{$post_author}' /> 301 315 <input type='hidden' name='random_id' value='{$random_id}' /> -
branches/PLi-Fusion/includes/templates/forum.viewthread.tpl
r1666 r1691 265 265 <table align='center' cellpadding='0' cellspacing='1' width='100%' class='tbl-border'> 266 266 <tr> 267 {if $settings.hoteditor_enabled == 0 || $userdata.user_hoteditor == 0} 267 268 <td align='center' class='tbl1'> 268 {if $settings.hoteditor_enabled == 0 || $userdata.user_hoteditor == 0}269 269 <textarea name='message' cols='80' rows='7' class='textbox' style='width:100%; height:{math equation='x/4' x=$smarty.const.BROWSER_HEIGHT format='%u'}px;'></textarea> 270 270 <br /> … … 282 282 <input type='button' value='quote' class='button' style='width:45px;' onclick="addText('message', '[quote]', '[/quote]');" /> 283 283 {else} 284 <td align='left' class='tbl1'> 284 285 <style type='text/css'>@import url({$smarty.const.THEME}hoteditor/style.css);</style> 285 286 <input type='hidden' id='message' name='message' value='' /> … … 287 288 var hoteditor_path = "{$smarty.const.INCLUDES}jscripts/hoteditor-4.2/"; 288 289 var hoteditor_theme_path = "{$smarty.const.THEME}hoteditor"; 290 var hoteditor_reply_to = ""; 289 291 </script> 290 292 <script language="javascript" type="text/javascript" src="{$smarty.const.INCLUDES}jscripts/hoteditor-4.2/editor__0001.js?version=4.2"></script> … … 325 327 {/if} 326 328 <tr> 327 <td align=' center' class='tbl1'>329 <td align='left' class='tbl1'> 328 330 <input type='submit' name='postquickreply' value='{$locale.514}' class='button' onclick='javascript:get_hoteditor_data();' /> 329 331 {if $settings.hoteditor_enabled == 0 || $userdata.user_hoteditor == 0} -
branches/PLi-Fusion/includes/user_functions.php
r1668 r1691 56 56 } 57 57 58 // Check if a user islogging in58 // Check if a user wants to logging in 59 59 if (isset($_POST['login'])) { 60 60 $auth_result = false; … … 97 97 } 98 98 99 // login session expired?100 if ( !empty($_SESSION['login_expire']) && $_SESSION['login_expire'] < time()) {99 // if not in the process of posting a form, did the login session expired? 100 if (count($_POST)==0 && !empty($_SESSION['login_expire']) && $_SESSION['login_expire'] < time()) { 101 101 // clear the login info from the session 102 102 unset($_SESSION['user']);
Note: See TracChangeset
for help on using the changeset viewer.
