seleneheart: (Default)
Raederle ([personal profile] seleneheart) wrote in [community profile] style_system2020-07-23 10:09 pm

Theme Layers: Header Image Map & Favicon

I had an image map of my journal navigation for my imported Flexible Squares layout. I recently switched to a native DW layout (Abstractia) and have gotten all the CSS fixed. However, I'm at a loss as to the theme layer coding for DW.

The image map is giving me a compilng error of: Can't define undeclared object function Page::lay_print_header()


Here is the image map code from my previous theme layer:
 
function Page::lay_print_header()
{	
	print  """
        
img src="https://seleneheart.dreamwidth.org/file/22357.png" USEMAP="#travelheader" BORDER=0>
map name="travelheader">
  area name="Recent" shape="poly" coords="139,87,246,61,275,178,160,201,133,87,133,87" href="https://seleneheart.dreamwidth.org"  alt="Recent">
  area name="Friends" shape="poly" coords="347,83,456,120,440,277,318,228,350,82,350,82" href="https://seleneheart.dreamwidth.org/read/Daily Friends"  alt="Reading">
  area name="History" shape="poly" coords="524,158,613,148,637,286,545,294,526,157,526,157,526,157" href="https://seleneheart.dreamwidth.org/calendar"  alt="Archive">
  area name="Profile" shape="poly" coords="692,143,804,167,777,295,686,277,695,138,695,138" href="https://seleneheart.dreamwidth.org/profile"  alt="Userinfo">


        """;	
}




I imagine it's the difference between the core code language in DW versus LJ.


The favicon will compile with no errors, but isn't showing up. I copy/pasted the code I used previously, so it should still be working (it was working a couple hours ago):

function Page::print_custom_head()

{
"""
link rel="shortcut icon" href="http://www.iconj.com/ico/6/8/68zs2jn2z0.ico" type="image/x-icon" />
link rel="icon" type="image/ico" href="http://www.iconj.com/ico/6/8/68zs2jn2z0.ico" type="image/x-icon" />

""";
}


I took several '<' out so the code will show up; I'm aware they should be there, but that's not the source of the errors. I don't see a way to link to the theme layer with the syntax showing, but both the new theme layer and old one are set to viewable.

Thanks for the help!
momijizukamori: Green icon with white text - 'I do believe in phosphorylation! I do!' with a string of DNA basepairs on the bottom (Default)

[personal profile] momijizukamori 2020-07-25 12:10 am (UTC)(link)

It depends on the LJ theme, but yeah, a decent number of them (and anything custom) roll the layout layer and the theme layer into a single file - which you could do here but you'd have to copy over the entire source code for Abstractia, and it's probably faster to just copy your CSS, heh.

Glad I could help!