Page 1 of 1

EMBEDDING FOR DUMMIES! PLEASE SAVE MY LIFE!

Posted: Wed Jan 11, 2006 11:33 am
by area309
Hi,

I am so lost when it comes to embedding, I'm not sure what to do. Here is the situation. I am working on a website and I have constructed a page layout where I want it to go. Here is the page: http://www.locdown.net/TEMP.htm.

What I would like to to is insert my blog on that page where it says "BLOG HERE". To see what I mean, I have done this same process using Gallery v 1.5. You can see that here: http://www.locdown.net/gallery.

At this point, I have downloaded the Static Pages plug in and have tried my best to use it, with no avail: http://www.locdown.net/serendipity. I have also tried to use the HTML nugget system, with little success. I don't really know ANY PHP but I have a great understanding of HTML and SSI, and if I am given manageable steps to follow, I can follow directions.

If someone could just tell what I need to do to get my blog in my template, I will forever be in your debt. Any and all input would be most appreciated. Please take pity on a poor soul!

Thanks,

area309

Re: EMBEDDING FOR DUMMIES! PLEASE SAVE MY LIFE!

Posted: Wed Jan 11, 2006 2:50 pm
by garvinhicking
Actually this is all very easy.

Just edit the "index.tpl" file of your current template and then place your HTML code within that index.tpl file. Usually you'll paste content before the <div id="serendipity_header"> part, and at the end of the HTML template.

You should at best create your own template directory, like templates/locdown. Then copy the info.txt and index.tpl file from the templates/default/ directory there, edit the info.txt to insert your own name for the template, and then take on the index.tpl file to modify the changes I mentioned.

It's pretty easy, don't give up :)

Best regards,
Garvin

EMEDDING FOR DUMMIES...CONT'D

Posted: Wed Jan 11, 2006 9:03 pm
by area309
Hi Garvin,

First off, let me thank you so much for your speedy response.

OK, I have switched my style to the "moz_modern" style and I am looking at the index.tpl file in Notepad. However, I don't see the tag that you mentioned as the place before which I should put the top half of my HTML template. I am going to copy all the code from the index.tpl file into this message, if you could tell me where I should insert my code, that would be an ENORMOUS help!
{if $is_embedded != true}
{if $is_xhtml}
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
{else}
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
{/if}

<html>
<head>
<title>{$head_title|@default:$blogTitle} {if $head_subtitle} - {$head_subtitle}{/if}</title>
<meta http-equiv="Content-Type" content="text/html; charset={$head_charset}" />
<meta name="Powered-By" content="Serendipity v.{$head_version}" />
<link rel="stylesheet" type="text/css" href="{$head_link_stylesheet}" />
<link rel="alternate" type="application/rss+xml" title="{$blogTitle} RSS feed" href="{$serendipityBaseURL}{$serendipityRewritePrefix}feeds/index.rss2" />
<link rel="alternate" type="application/x.atom+xml" title="{$blogTitle} Atom feed" href="{$serendipityBaseURL}{$serendipityRewritePrefix}feeds/atom.xml" />
{if $entry_id}
<link rel="pingback" href="{$serendipityBaseURL}comment.php?type=pingback&entry_id={$entry_id}" />
{/if}

{serendipity_hookPlugin hook="frontend_header"}
</head>

<body>
{else}
{serendipity_hookPlugin hook="frontend_header"}
{/if}

<div id="serendipity_banner">
<h1><a class="homelink1" href="{$serendipityBaseURL}">{$head_title|@default:$blogTitle}</a></h1>
<h2><a class="homelink2" href="{$serendipityBaseURL}">{$head_subtitle|@default:$blogDescription}</a></h2>
</div>

<div id="mainpane">
{if $leftSidebarElements > 0}
<div id="serendipityLeftSideBar">{serendipity_printSidebar side="left"}</div>
{/if}

{if $rightSidebarElements < 1}
<div id="content_left">
{elseif $leftSidebarElements < 1}
<div id="content_right">
{else}
<div id="content">
{/if}
{$CONTENT}
{$raw_data}
</div>

{if $rightSidebarElements > 0}
<div id="serendipityRightSideBar">{serendipity_printSidebar side="right"}</div>
{/if}

<div id="copyright">Powered by <a href="http://www.s9y.org/">serendipity</a>, Design by <a href="http://supergarv.de/">Garvin Hicking</a>. Smile, you're on the candid credit line!</div>
</div>
{serendipity_hookPlugin hook="frontend_footer"}
{if $is_embedded != true}
</body>
</html>

{/if}
Again, the file I would like to wrap my blog in is: http://www.locdown.net/TEMP.htm .Any help would be appreciated as I have been trying to fix this for almost 3 days straight.

Thanks again,

area309

Posted: Thu Jan 12, 2006 3:02 am
by judebert
He meant "serendipity_banner".

Here:
{***** ALL THIS STUFF IS GOOD FOR SERENDIPITY *******}
{if $is_embedded != true}
{if $is_xhtml}
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
{else}
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
{/if}

<html>
<head>
<title>{$head_title|@default:$blogTitle} {if $head_subtitle} - {$head_subtitle}{/if}</title>
<meta http-equiv="Content-Type" content="text/html; charset={$head_charset}" />
<meta name="Powered-By" content="Serendipity v.{$head_version}" />
<link rel="stylesheet" type="text/css" href="{$head_link_stylesheet}" />
<link rel="alternate" type="application/rss+xml" title="{$blogTitle} RSS feed" href="{$serendipityBaseURL}{$serendipityRewritePrefix}feeds/index.rss2" />
<link rel="alternate" type="application/x.atom+xml" title="{$blogTitle} Atom feed" href="{$serendipityBaseURL}{$serendipityRewritePrefix}feeds/atom.xml" />
{if $entry_id}
<link rel="pingback" href="{$serendipityBaseURL}comment.php?type=pingback&entry_id={$entry_id}" />
{/if}

{serendipity_hookPlugin hook="frontend_header"}
</head>

<body>
{else}
{serendipity_hookPlugin hook="frontend_header"}
{/if}

{***** THIS IS THE SERENDIPITY HEADER. If you want to get rid of it,
remove this div. If you want stuff above the Serendipity header, put it
here. ******}
<div id="serendipity_banner">
<h1><a class="homelink1" href="{$serendipityBaseURL}">{$head_title|@default:$blogTitle}</a></h1>
<h2><a class="homelink2" href="{$serendipityBaseURL}">{$head_subtitle|@default:$blogDescription}</a></h2>
</div>

{***** THIS IS THE MAIN SERENDIPITY BLOG. Posts, sidebars, stuff
like that. You should probably leave this alone. *****}
<div id="mainpane">
{if $leftSidebarElements > 0}
<div id="serendipityLeftSideBar">{serendipity_printSidebar side="left"}</div>
{/if}

{if $rightSidebarElements < 1}
<div id="content_left">
{elseif $leftSidebarElements < 1}
<div id="content_right">
{else}
<div id="content">
{/if}
{$CONTENT}
{$raw_data}
</div>

{if $rightSidebarElements > 0}
<div id="serendipityRightSideBar">{serendipity_printSidebar side="right"}</div>
{/if}

<div id="copyright">Powered by <a href="http://www.s9y.org/">serendipity</a>, Design by <a href="http://supergarv.de/">Garvin Hicking</a>. Smile, you're on the candid credit line!</div>
</div>
{serendipity_hookPlugin hook="frontend_footer"}
{***** THIS IS THE END OF THE SERENDIPITY BLOG. If you want
something after the blog, put it here. *****}
{if $is_embedded != true}
</body>
</html>

{/if}

Posted: Thu Jan 12, 2006 6:54 am
by area309
I think I may have fixed it! Thanks so much for all of your help! Check it out: http://www.locdown.net/serendipity