Changeset 1669
- Timestamp:
- 09/04/2007 03:28:02 PM (16 months ago)
- Location:
- trunk
- Files:
-
- 2 modified
-
log.php (modified) (1 diff)
-
scripts/bbcode.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/log.php
r1663 r1669 1 1 <?php 2 2 require('.'.DIRECTORY_SEPARATOR.'personal'.DIRECTORY_SEPARATOR.'settings.inc.php'); 3 require(JLOG_BASEPATH.'lang'.DIRECTORY_SEPARATOR.'lang-admin.inc.php');4 3 5 4 $get = strip($_GET); -
trunk/scripts/bbcode.php
r1646 r1669 18 18 19 19 function do_bbcode_url ($action, $attributes, $content, $params, $node_object) { 20 if ($action == 'validate') return true; 20 // URL auslesen 21 $url = isset($attributes['default']) ? $attributes['default'] : $content; 22 23 // URL validieren (Fix #137) 24 if($action == 'validate') { 25 if('javascript:' == substr($url, 0, 11)) return false; 26 return true; 27 } 21 28 22 if (!isset ($attributes['default'])) {23 if (strpos($content, "/") === 0) $content = JLOG_PATH.$content;24 return '<a href="'.htmlspecialchars($content).'">'.$content.'</a>';29 // Optik bei relativen URLs verbessern 30 if(!isset($attributes['default']) AND strpos($url, "/") === 0) { 31 $content = (isset($_SERVER['HTTPS']) ? 'https://' : 'http://') . $_SERVER['HTTP_HOST'] . $url; 25 32 } 26 if (strpos($content, "/") === 0) $attributes['default'] = JLOG_PATH.$attributes['default']; 27 return '<a href="'.htmlspecialchars($attributes['default']).'">'.$content.'</a>'; 33 return '<a href="' . htmlspecialchars($url) . '">' . htmlspecialchars($content) . '</a>'; 28 34 } 29 35
