« Project home page
my little forum
Log in
Register
Search:
Back to the entry by Auge
Post reply
Reply to the message by
Auge
Name:
E-mail:
(optional, won't be displayed directly)
Leave this field empty:
Homepage:
(optional)
Leave this field empty:
Location:
(optional)
Remember me (cookie)
Category:
General
Project organisation
Technics
Design/Themes
Features
Development
Todo
Bugs
German / Deutsch
Spanish / Español
French / Français
Accessibility/UX
Subject:
Formatting help
skip to input
format text bold
[b]bold text[/b]
format text italic
[i]italic text[/i]
insert hyperlink
[link=http://example.com/]link text[/link] / [link]http://example.com/[/link]
set text color
[color=#rgb]colored text[/color]
font size
[size=small]small text[/size]
[size=large]large text[/size]
insert list
[list][*]list item[/list]
insert image
[img]http://example.com/image.jpg[/img]
left: [img=left]http://example.com/image.jpg[/img]
right: [img=right]http://example.com/image.jpg[/img]
thumbnail: [img=thumbnail]http://example.com/image.jpg[/img]
thumbnail left: [img=thumbnail-left]http://example.com/image.jpg[/img]
thumbnail right: [img=thumbnail-right]http://example.com/image.jpg[/img]
upload image
upload image ...
insert TeX code
[tex]TeX code[/tex]
insert code
[inlinecode]code[/inlinecode]
[code]code[/code]
[code=css]code[/code]
[code=html]code[/code]
[code=javascript]code[/code]
[code=perl]code[/code]
[code=php]code[/code]
[code=sql]code[/code]
[code=xml]code[/code]
:-)
;-)
:-P
:-D
:-|
:-(
:yes:
:no:
:ok:
:lol:
:lol2:
:lol3:
:cool:
:surprised:
:angry:
:crying:
:waving:
:confused:
:lookaround:
:clap:
:love:
:tick:
Message:
> Hello > > > Before upgrading, I made a full copy of our forum and DB. I then performed the upgrade on the copied forum, and ran into the Style challenge mentioned above. I confirmed that the CSS and TPL files in that upgraded forum folder were copied correctly, and did not make any changes after the upgrade, but the old forum styles persisted. > > > > The key to all this is actually the Admin / Forum Settings / Forum Address (URL) option. When I originally copied the forum, I did not make any adjustments within Settings, so Forum Address was still pointing to the (original) production forum, which had our existing style changes. And, as I found out, Style information is pulled from the URL specified in Forum Address, and does not use a relative path to the current forum folder. > > Yes, the link to the CSS-file is given as an absolute URL. I don't know, why Alex decided so, but this behaviour is really "old". > > [code=html]<link rel="stylesheet" type="text/css" href="https://mylittleforum.net/forum/themes/default/style.min.css" media="all" />[/code] > > Generally it would be no problem to change this behaviour. In [link=https://github.com/My-Little-Forum/mylittleforum/blob/20240827.1/themes/default/main.tpl#L15]line #15 of the main template[/link] one can see, that the first part of the URL ([inlinecode]{$FORUM_ADDRESS}/[/inlinecode]) can simply be removed. > > [code=html]<link rel="stylesheet" type="text/css" href="{$FORUM_ADDRESS}/{$THEMES_DIR}/{$theme}/style.min.css" media="all" />[/code] > > This would result in a relative and functioning path. > > [code=html]<link rel="stylesheet" type="text/css" href="themes/default/style.min.css" media="all" />[/code] > > As far as I know, the index.php, which is built from the main template, is the base for all pages with exception of the JS-popups, which has their own document-complete HTML-templates. So I expect this to work. But this will not prevent issues with the browser caching and the prerendered templates after an upgrade. > > Tschö, Auge
E-mail notification on reply of this posting
OK - Submit
Preview