-function REWRITE_LINKS ($HTML) {
- // Skip rewriting for configured modules
- if (eregi($GLOBALS['module'], getConfig('rewrite_skip')) !== false) return $HTML;
-
- // Strip slashes with double-backslashes for the preg_replace() function
- $URL = str_replace('/', '\/', constant('URL'));
+function rewriteLinksInCode ($code) {
+ // Skip rewriting for configured or empty modules
+ if ((getModule() == '') || (isInStringIgnoreCase(getModule(), getConfig('rewrite_skip')) !== false)) {
+ return $code;
+ } // END - if