• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

AAC How to make a still background ?

Daniel Kopeć

Member
Joined
Dec 8, 2018
Messages
125
Solutions
4
Reaction score
12
Location
Poland
How to make a still background on Gesior 2012 TFS 0.4 ?

I added background-attachment: fixed; to layout.php

PHP:
<div id="ArtworkHelper" style="background-image:url(<?PHP echo $layout_name; ?>/images/header/background-3.jpg);background-attachment: fixed;" >

and the background is still but disappears from the bottom as i scroll the page.

And here is a piece of code basic.css

CSS:
body {
  margin: 0px;
  padding:  0px;
  background-color: #061222;
}

#ArtworkHelper {
  text-align: center;
  background-position: top center;
  background-attachment: scroll;
  background-repeat: no-repeat;
  width: 100%;
  height: 100%;
  min-width: 1000px;
  min-height: 800px;
}
 
How to make a still background on Gesior 2012 TFS 0.4 ?
Remove this
XML:
style="background-image:url(<?PHP echo $layout_name; ?>/images/header/background-3.jpg);background-attachment: fixed;"
add this to body in css file
CSS:
background-image: url('/layouts/tibiacom/images/header/background-3.jpg');
background-position: top center;
background-attachment: fixed;
background-size: 100%;
 
Remove this
XML:
style="background-image:url(<?PHP echo $layout_name; ?>/images/header/background-3.jpg);background-attachment: fixed;"
add this to body in css file
CSS:
background-image: url('/layouts/tibiacom/images/header/background-3.jpg');
background-position: top center;
background-attachment: fixed;
background-size: 100%;
I did it and it didn't work and the website looks like this now:
background still error.png
 
Remove this
XML:
style="background-image:url(<?PHP echo $layout_name; ?>/images/header/background-3.jpg);background-attachment: fixed;"
add this to body in css file
CSS:
background-image: url('/layouts/tibiacom/images/header/background-3.jpg');
background-position: top center;
background-attachment: fixed;
background-size: 100%;
Surely there is something that needs to be added here?

PHP:
<body onBeforeUnLoad="SaveMenu();" onUnload="SaveMenu();">
 <a name="top"></a>
  <div id="ArtworkHelper" style="background-image:url(<?PHP echo $layout_name; ?>/images/header/background-artwork.jpg);" >
    <div style="width:1200px" id="Bodycontainer">
      <div id="ContentRow">
        <div id="MenuColumn">
          <div id="LeftArtwork">
            <img id="Statue_1" src="<?PHP echo $layout_name; ?>/images/header/animated-statue.gif" alt="logoartwork" />
            <img id="TibiaLogoArtworkTop" src="<?PHP echo $layout_name; ?>/images/header/tibia-logo-artwork-top.gif" onClick="window.location = '?subtopic=latestnews';" alt="logoartwork" />
            <img id="TibiaLogoArtworkBottom" src="<?PHP echo $layout_name; ?>/images/header/tibia-logo-artwork-bottom.gif" alt="logoartwork" />
            <img id="Statue_2" src="<?PHP echo $layout_name; ?>/images/header/animated-statue.gif" alt="logoartwork" />
          </div>
 
<div id="ArtworkHelper" style="background-image:url(<?PHP echo $layout_name; ?>/images/header/background-artwork.jpg);" >
Looks like you have kept inline style attribute, remove that part.
XML:
  <div id="ArtworkHelper" style="background-image:url(<?PHP echo $layout_name; ?>/images/header/background-artwork.jpg);" >
change to:
XML:
  <div id="ArtworkHelper">

css:
CSS:
body {
  margin: 0px;
  padding:  0px;
  background-color: #061222;
  /* add this V */
  background-image: url('/layouts/tibiacom/images/header/background-3.jpg');
  background-position: top center;
  background-attachment: fixed;
  background-size: 100%;
  background-repeat: no-repeat;
}
 
Looks like you have kept inline style attribute, remove that part.
XML:
  <div id="ArtworkHelper" style="background-image:url(<?PHP echo $layout_name; ?>/images/header/background-artwork.jpg);" >
change to:
XML:
  <div id="ArtworkHelper">

css:
CSS:
body {
  margin: 0px;
  padding:  0px;
  background-color: #061222;
  /* add this V */
  background-image: url('/layouts/tibiacom/images/header/background-3.jpg');
  background-position: top center;
  background-attachment: fixed;
  background-size: 100%;
  background-repeat: no-repeat;
}
It didn't do anything. The page is now nicely centered but has no background at all.
I will look at my uncle google. Maybe I'll find something and learn something :)
I'll leave the layout.php and basic.css files below in the standard version. Maybe you will find the reason :)

background still error.png
Post automatically merged:

Looks like you have kept inline style attribute, remove that part.
XML:
  <div id="ArtworkHelper" style="background-image:url(<?PHP echo $layout_name; ?>/images/header/background-artwork.jpg);" >
change to:
XML:
  <div id="ArtworkHelper">

css:
CSS:
body {
  margin: 0px;
  padding:  0px;
  background-color: #061222;
  /* add this V */
  background-image: url('/layouts/tibiacom/images/header/background-3.jpg');
  background-position: top center;
  background-attachment: fixed;
  background-size: 100%;
  background-repeat: no-repeat;
}

basic.css
layout.php
 
Last edited:
Back
Top