Page 1 of 1

0.8 killed my blog!

Posted: Mon Jan 03, 2005 6:00 pm
by Martin
I just upped the 0.8 snapshot, and now my blog's disappeared.
What happened was this; When the updater script tried to write a bunch of files I got a message that it couldn't write to any of them (at least a whole freaking bunch). Then it just proceeded to the admin area.

The admin area works fine, and I can even find all my entries but when I go to my blog I get... nothing. A blank page. Not even a 404.

Please help me out with this...

-m

Posted: Tue Jan 04, 2005 12:15 am
by Martin
Fixed it...
Seems there was a SQL-prob...

Now...
What do I have to do to make my templates 0.8-compatible?

-m

Posted: Tue Jan 04, 2005 11:51 am
by garvinhicking
How did you fix it? Because if there's anything we can fix in 0.8, we definitely want to do that :)

Now for your templating question: The "layout.php" file has ben deprecated, and you should now just use the various *.tpl files which are contained in templates/default/ - take those files you want to edit, copy them to your own template folder, and then edit the Smarty-HTML code for what you previously entered as PHP/HTML code in your layout.php.

HTH,
Garvin

Posted: Tue Jan 04, 2005 12:18 pm
by Martin
I believe that the installer somehow couldn't retrieve my database password. I have no idea why. While this is probably my fault somehow, what I would suggest is to make some sort of warning when a problem like this happens. i.e. "I couldn't write the following files, do you want to go ahead with install?" Seing as I was stranded with a non working blog because of it, and had to reinstall my old one and then upgrade again.

Thanks for the tip on the smarty stuff. A bit new to this stuff, but it seems comprehensible enough. Now, if I wanted to make a mod so that the right sidebar does not show in extended or single entry mode, where would I go, and what would I do? I browsed through the tpl-file, but I couldn't figure out how to do this.

-M

Posted: Tue Jan 04, 2005 4:34 pm
by garvinhicking
Okay...about the installer and the files that were to be removed, that is a non-fatal one, so I thought it should suffice to tell the user it has failed and he needs to move the files manually...

About your sidebar: Edit entries.tpl, see this code:

Code: Select all

<table id="mainpane">
    <tr>
{if $leftSidebarElements > 0}
        <td id="serendipityLeftSideBar" valign="top">{serendipity_printSidebar side="left"}</td>
{/if}
        <td id="content" valign="top">{$CONTENT}</td>
{if $rightSidebarElements > 0}
        <td id="serendipityRightSideBar" valign="top">{serendipity_printSidebar side="right"}</td>
{/if}
    </tr>
</table>
{/if}
You see that the serendipity_printSidebar command is done there everytime. You could modify this check to:

Code: Select all

{if $leftSidebarElements > 0 and not $is_single_entry}
And then the sidebars would only be printed in overview mode and not in "single entry" viewmode.

Regards,
Garvin