Page 1 of 1

Frontpage coding

Posted: Wed Mar 05, 2008 7:10 pm
by israelp
Hi: Someone help me find where is located the frontpage. I want to make changes directly into the source code of the page.

Thank you.

israelp

Posted: Wed Mar 05, 2008 7:24 pm
by judebert
The PHP code is index.php and the files it includes (all over the place).

The HTML is in index.tpl, with the entries printed through entries.tpl.

At this point, we've got a plugin or an option for almost everything, though. If you tell us what you're trying to accomplish, we may be able to show you an easy way to do it.

Source code

Posted: Wed Mar 05, 2008 8:25 pm
by israelp
Hi: Thanks for your quick response. You can see my blog at www.capr.org/blog2. When I view the source page with the browser, this is the document I want to modify (but I cannot find it)

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html>
<head>
<title>DERECHO Y TECNOLOGIA </title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
....................................

Thank you.

israelp

Re: Source code

Posted: Wed Mar 05, 2008 8:38 pm
by mad-manne
israelp wrote:When I view the source page with the browser, this is the document I want to modify (but I cannot find it)
Hi israelp,
you will not be able to find what you see in your browser, because this is the result of content that is dynamically generated by the blog-system.
You are only able to edit the according template-files, which hold "representations" for the real content, that will be added by the scripts.
serendipity(like many other "php-systems") uses a so called template-engine to render the final pages, that are then sent to the browser(what you see in the end!)

Here is a brief explanation of template-engines in general ...

Hope this helps you understand the things "going on under the hood",
Manfred.

Posted: Wed Mar 05, 2008 8:56 pm
by judebert
The DOCTYPE can be modified in index.tpl, although I'm not sure that's a good idea.

The <meta> is also in index.tpl, although you can see there that it uses the Smarty variable {$head_charset}. That's actually determined by the options you set in your blog.

The title HTML is also in index.tpl, and it also uses Smarty variables. These variables are set in Serendipity's configuration. To change them, go to your admin page, click "Configuration", and change your blog name and subtitle under "General Options". (No file modifications required!)