Page 1 of 1

Templates

Posted: Wed Apr 21, 2004 2:59 pm
by JMF
Hi, I am planning to switch to Serendipity but I am facing some problems.
I also have some feature requests. :D

So let's start with the templates. My site is made of valid XHTML 1.0 Strict and valid CSS2.

AFAIK there is no way to change the HTML head. The default head provides a HTML 4.01 Transitionnal which does not suit my needs.
Would it be possible to add the possibility to handle HTML head in the template ?
The RSS and Atom feeds links could be given as variables and the head only displayed if the blog is not embed.
Here is an example :

Code: Select all

<?php if (!$serendipity['embed']) {?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
           "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
    <title>Dying Culture</title>
    <meta name="Powered-By" content="Serendipity v.0.6-rc1" />
    <link rel="stylesheet" type="text/css" href="<?php echo $serendipity['styleSheetURL']; ?> " />
    <link rel="alternate"  type="application/rss+xml" title="RSS" href="<?php echo $serendipity['RSSFeedURL']; ?>" />
    <link rel="alternate"  type="application/x.atom+xml"  title="Atom"  href="<?php echo $serendipity['atomFeedURL']; ?>" />
</head>
<?php } ?>
This way it would be possible to also handle meta-tags, alternate style sheets etc. :)

Re: Templates

Posted: Wed Apr 21, 2004 4:09 pm
by garvinhicking
Hi!
JMF wrote:AFAIK there is no way to change the HTML head.
There is. Look at the section "embedded mode" in the README file. There you can add custom headers/footers and only wrapping the contents. My page http://blog.garv.info/ is made using that principle.

Regards,
Garvin.

Posted: Wed Apr 21, 2004 4:30 pm
by JMF
Oops, I did not think about that solution. :oops:

Thanks Garvin. :D