View previous topic :: View next topic |
Author |
Message |
Lanochka
Joined: 01 Dec 2004 Posts: 20
|
Posted: Wed Dec 01, 2004 4:24 am Post subject: posts not showing up |
|
|
Ok I am totally confused right now. I got b2 installed and everything, but now I don't know how to make the entries show up on my site. I have the following php code. am i supposed to change it or sumfing? how is it supposed to include php?
Quote: |
<div style="position:absolute; left:246; top:300; width:360; cursor: default>
<?
if (file_exists("$page.html")):
include("$page.html");
else:
include("blog.html");
endif;
?>
</div> |
this is so mind boggling >.< ive read over the readme file and many tutorials several times, but i still dont get it. help? |
|
Back to top |
|
 |
Cyberian75
Joined: 26 Sep 2002 Posts: 1278 Location: Oregon
|
Posted: Wed Dec 01, 2004 5:14 am Post subject: |
|
|
should be
There's no "endif" in PHP by the way. _________________ Michael P.
 |
|
Back to top |
|
 |
Lanochka
Joined: 01 Dec 2004 Posts: 20
|
Posted: Wed Dec 01, 2004 8:51 pm Post subject: |
|
|
That can't be right cuz I did that and I got this error
Quote: | Parse error: parse error, unexpected $ in /home/vibical/public_html/lana/index.php on line 186 |
|
|
Back to top |
|
 |
Lanochka
Joined: 01 Dec 2004 Posts: 20
|
Posted: Thu Dec 02, 2004 1:06 am Post subject: |
|
|
Ok I got the blog to show up in my index, but there are a few problems.
1. When I click on comments, a window pops up and says
Quote: | Not Found
The requested URL /b2commentspopup.php was not found on this server.
Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request. |
How do I fix this?
2. My first post is positioned inside the div layer, along with the date of the second post, but then the rest is like screwd up and aligned to the left. How do I fix this also?
http://lana.vibical.com
And one more question. How do I make my entries justified? I tried doing
but it didn't work.
edit // Damn. Everything looks so messed up in internet explorer vs. mozilla. I took some screen shots. The first one was in Mozilla and the second in Internet Explorer. Is there a way to fix it?
-images removed-
edit 2 // Ok I fixed the alignment of the entries =D but the comments still don't show up, and the date is still different. I've been searching around the forum for the comment things because I've seen that people have had the same problem with php. I couldn't find anything though =[ Help asap please. Thank you!
Last edited by Lanochka on Thu Dec 02, 2004 11:06 pm; edited 1 time in total |
|
Back to top |
|
 |
Cyberian75
Joined: 26 Sep 2002 Posts: 1278 Location: Oregon
|
Posted: Thu Dec 02, 2004 3:30 am Post subject: |
|
|
If you get a 404 error, check to see if the form is pointing to the right directory and file. Also, you should not "include" your blog if it's in a seperate subdirectory. _________________ Michael P.
 |
|
Back to top |
|
 |
Lanochka
Joined: 01 Dec 2004 Posts: 20
|
Posted: Thu Dec 02, 2004 3:55 am Post subject: |
|
|
I have all my files in /b2 but when I check the link for the comments, it links to lana.vibical.com/b2commentspopup.php
if i cant include the blog wut do i do? my site is all in php and i dont want to add iframes
other people have made it work but i tried searching for it and couldnt find anything
iv changed the above code to
Code: | <?php include ("b2/index.php"); ?> |
|
|
Back to top |
|
 |
Cyberian75
Joined: 26 Sep 2002 Posts: 1278 Location: Oregon
|
Posted: Thu Dec 02, 2004 6:27 am Post subject: |
|
|
Move it into the root directory...? _________________ Michael P.
 |
|
Back to top |
|
 |
Sigg3
Joined: 03 Jul 2003 Posts: 826 Location: Oslo, Norway
|
|
Back to top |
|
 |
Lanochka
Joined: 01 Dec 2004 Posts: 20
|
Posted: Thu Dec 02, 2004 8:47 pm Post subject: |
|
|
I did that. I moved all the files into my root directory but I ended up with a bunch of mysql errors. such as blog.header.php does not exist in blah blah blah. =\ Ugh I'm so confused! |
|
Back to top |
|
 |
Lanochka
Joined: 01 Dec 2004 Posts: 20
|
Posted: Thu Dec 02, 2004 11:04 pm Post subject: |
|
|
omg yay ok i figured it out =D woot. lol anyways... to those of you who are having the same problems as me and dont know how to fix it.. this is how i did it...
if you have all your b2 stuff in your root folder (where ur index is stored to view ur site) then u dont need to change a thing.. but if u have all ur b2 stuff in the b2 sub directory (ex: yoursite.com/b2/b2 stuff here... then ur going to have to change
Code: | <?php /* Don't remove this line, it calls the b2 function files ! */ $blog=1; include ("blog.header.php"); ?> |
and add b2/ in front like this
Code: | <?php /* Don't remove this line, it calls the b2 function files ! */ $blog=1; include ("b2/blog.header.php"); ?> |
and then for your comments to work also add the b2/ in front of it like
Code: | <?php include ("b2/b2comments.php"); ?> |
k this is resolved.. thanks for all ur guys help even tho i got even more confused =D lol. its not ur fault. i appreciate it <33 |
|
Back to top |
|
 |
stevem
Joined: 15 Mar 2003 Posts: 328
|
Posted: Fri Dec 03, 2004 5:54 pm Post subject: |
|
|
I'm not sure this is true. Do you have your opening page in the root directory but the rest in b2? If that's the case I can see why the change is necessary. But if you have everything in the b2 folder then that would be the wrong thing to do.
Suppose your blog is at b2/index.php. Then you shouldn't have that extra b2/ in b2/blog.header.php or b2/blog.header.php. I am assuming that in b2config.php you have Code: | $siteurl = 'http://your_domain/b2';
$blogfilename = 'index.php'; | which is how it knows to look inside the b2 folder.
Hope that helps. |
|
Back to top |
|
 |
Lanochka
Joined: 01 Dec 2004 Posts: 20
|
|
Back to top |
|
 |
stevem
Joined: 15 Mar 2003 Posts: 328
|
Posted: Fri Dec 03, 2004 9:46 pm Post subject: |
|
|
Yes I agree with you and b2 is constructed so that it expects you to add /b2 to $siteurl. Otherwise you would also have to change, apart from the files you mention, b2calendar.php, b2print.php, b2trackback.php and maybe other hacks |
|
Back to top |
|
 |
|