Page 1 of 1

open blog post inside page?

Posted: Mon Dec 19, 2005 1:55 am
by StarF
Hey

got the blog intigrated into a page.
Now when i make a post, for some reason it dosent open inside the intigrated page, but on a new page.

http://www.perestrojka.dk/index.php
would like that post were open inside the page, and not on a new one.

what am i missing?

Re: open blog post inside page?

Posted: Mon Dec 19, 2005 10:17 am
by garvinhicking
It doesn'T open on a new page for me. Maybe you misconfigured your browser?

Regards,
Garvin

Re: open blog post inside page?

Posted: Mon Dec 19, 2005 2:17 pm
by StarF
garvinhicking wrote:It doesn'T open on a new page for me. Maybe you misconfigured your browser?

Regards,
Garvin
i meant a blank page.

does the header and side bars stay there?

caus here it just looks like this:

http://tmp.blacknet.dk/page.jpg

i would like for it to open inside my design.

Re: open blog post inside page?

Posted: Mon Dec 19, 2005 2:22 pm
by garvinhicking
Where did you put your header and sidebars? Seems you didn't edit your index.tpl template properly....?!

Regards,
Garvin

Re: open blog post inside page?

Posted: Mon Dec 19, 2005 2:25 pm
by StarF
garvinhicking wrote:Where did you put your header and sidebars? Seems you didn't edit your index.tpl template properly....?!

Regards,
Garvin
Just used the old wrapper method.

index.php

Code: Select all

<?php 
$_REQUEST['page'] = 'blog'; 

ob_start(); 
chdir('blog'); 
require 'blog/index.php'; 
$blog_data = ob_get_contents(); 
chdir('..'); 
ob_end_clean(); 

require 'index_main.php'; 
?>
where index_main contains my design.

Re: open blog post inside page?

Posted: Mon Dec 19, 2005 2:50 pm
by garvinhicking
Seems you didn'T set your indexFile config option to your custom index file, you must adjust that.

Regards,
Garvin

Re: open blog post inside page?

Posted: Mon Dec 19, 2005 3:18 pm
by StarF
garvinhicking wrote:Seems you didn'T set your indexFile config option to your custom index file, you must adjust that.

Regards,
Garvin
with the change to sound like a noob, how do i do that?

Re: open blog post inside page?

Posted: Mon Dec 19, 2005 8:07 pm
by garvinhicking
go to the s9y configuration, and see somewhere inside the option "Index file", which is set to "index.php" by default.

Regards,
Garvin

Re: open blog post inside page?

Posted: Mon Dec 19, 2005 8:24 pm
by StarF
garvinhicking wrote:go to the s9y configuration, and see somewhere inside the option "Index file", which is set to "index.php" by default.

Regards,
Garvin
alright..

Now if i change that to Index_main.php
all get when clicking a post, all i get is "The page cannot be found"

befor eit was set at index.php, so what i am i now doing wrong?

Re: open blog post inside page?

Posted: Mon Dec 19, 2005 8:27 pm
by garvinhicking
It seems "Index_main.php" does not exist. You must use the actual filename with correct upper and lowercase letters!

You mest set the directive to how you called your wrapper php file!

Best regards,
Garvin

Re: open blog post inside page?

Posted: Mon Dec 19, 2005 9:24 pm
by StarF
garvinhicking wrote:It seems "Index_main.php" does not exist. You must use the actual filename with correct upper and lowercase letters!

You mest set the directive to how you called your wrapper php file!

Best regards,
Garvin
index_main does exist, i just wrote it with a big I in the forum. I dident do that on the setup page thought..

my wrapper, is index.php
my design is index_main.php

now if i change the index file to index_main.php how does it talk to the wrapper/blog?

also when i set the index as index_main.php
all the colurs and gfx on the admin page disapers.

Re: open blog post inside page?

Posted: Mon Dec 19, 2005 9:40 pm
by garvinhicking
Your wrapper cannot be called "index.php", because serendipity's file is called index.php!

You didn't rename the serendipity index.php, did you? That is not allowed.

Do this:

1. Rename your wrapper to wrapper.php
2. Restore serendipity's original index.php
3. Configure indexFile option to "wrapper.php"

Now call your blog via http://blabla/wrapper.php. Or use http://blabla/ -- the .htaccess directive should then take care that wrapper.php is used.

That's actually how embed mode is described on www.s9y.org. :-)

Regards,
Garvin

Re: open blog post inside page?

Posted: Mon Dec 19, 2005 10:14 pm
by StarF
garvinhicking wrote:Your wrapper cannot be called "index.php", because serendipity's file is called index.php!

You didn't rename the serendipity index.php, did you? That is not allowed.

Do this:

1. Rename your wrapper to wrapper.php
2. Restore serendipity's original index.php
3. Configure indexFile option to "wrapper.php"

Now call your blog via http://blabla/wrapper.php. Or use http://blabla/ -- the .htaccess directive should then take care that wrapper.php is used.

That's actually how embed mode is described on www.s9y.org. :-)

Regards,
Garvin
i got my blog in its own dir in this case its /blog
ofcource it got its own index there, i dident touch or change that in any way.

in the root dir i got a index, wich is the wrapper. Is this not alowed?

if i rename index.php to wrapper.php
i am still having the same problem.

my blog wrapper looks like this:

Code: Select all

<?php 
$_REQUEST['page'] = 'blog'; 

ob_start(); 
chdir('blog'); 
require 'blog/index.php'; 
$blog_data = ob_get_contents(); 
chdir('..'); 
ob_end_clean(); 

require 'index_main.php'; 
?>
notice it gets blog/index.php

so i guess my problem is.
i need something to be in the blog dir? like a wrapper there that gets my design?

Re: open blog post inside page?

Posted: Tue Dec 20, 2005 2:07 pm
by garvinhicking
Hi!
in the root dir i got a index, wich is the wrapper. Is this not alowed?
No. The wrapper needs to be in the same directory as Serendipity.

Regards,
Garvin