Radicore Forum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » RADICORE development » Workflow » Incorrect CSS settings
Incorrect CSS settings [message #7] Fri, 14 April 2006 02:08 Go to previous message
ljkbrost is currently offline  ljkbrost
Messages: 59
Registered: April 2006
Member
I run my apache server on http://localhost:8080 and I found a problem with the XML that gets sent to the client. It looks like the system is not sending the port for the machine.

<cssfiles> <filename>HTTP://localhost/radicore/style_default.css</filename>
<filename>HTTP://localhost/radicore/menu/style_custom.css</filename>
</cssfiles>

I have traced the problem to include.xml.php?.inc inside of the setCSSfiles(...) function. When building the filename values the string building function uses $_SERVER['SERVER_NAME'] when it should use $_SERVER['HTTP_HOST'].

Altering the code to the following resolved my problems:

// if no custom stylesheet is specified use 'style_custom.css' in local directory
if (empty($css_files)) {
$css_files[] = 'HTTP://' .$_SERVER['HTTP_HOST'] .dirname($_SERVER['PHP_SELF']) .'/style_custom.css';
} // if

// prepend the default stylesheet name from base directory
$dir = getParentDIR();
if (!empty($_SERVER['HTTPS'])) {
$default_css = 'HTTP://' .$GLOBALS['https_server'] .$GLOBALS['https_server_suffix'] .$dir .'/style_default.css';
} else {
$default_css = 'HTTP://' .$_SERVER['HTTP_HOST'] .$dir .'/style_default.css';
} // if


Cheers,


Kyle Brost
----
 
Read Message
Read Message
Next Topic: time splits and workitems
Goto Forum:
  


Current Time: Sun Apr 28 03:43:42 EDT 2024

Total time taken to generate the page: 0.00814 seconds