boardom Forum Index boardom
b2 message board
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Horizontal Blog * Can somebody create one?

 
Post new topic   Reply to topic    boardom Forum Index -> Feature requests
View previous topic :: View next topic  
Author Message
Eyevan



Joined: 16 Aug 2002
Posts: 18

PostPosted: Sat Jun 28, 2003 4:38 pm    Post subject: Horizontal Blog * Can somebody create one? Reply with quote

Has any of you seen a horizontal blog? I have -- a greymatter user owned one, but now that user uses regular vertical, default blogs now. If you don't know what a horizontal blog is, it sort of looks like this:



I need help with this -- can anyone create a code to make horizontal blogs? As you can see from the picture above, the "table" or whatever you call it most towards the left is the most recent post. The other "tables" to the right of it are "past" posts/entries... For my next layout, I only need three "tables". Does anyone know how to make horizontal blogs with three "tables"?

Please email me or just reply to answer, thanks!
_________________
Blog + Meme
Back to top
View user's profile Send private message
swirlee



Joined: 15 Jul 2002
Posts: 8

PostPosted: Mon Jun 30, 2003 5:02 am    Post subject: Reply with quote

I'm going to assume you know basic HTML, including how to build tables. If you don't, you need to back up and learn HTML. Then you can come back to b2. I'm not saying this to condescend -- this is good, earnest advice.

Now, assuming you know your HTML, all you have to do to make a horizontal blog is instead of specifying new posts in a vertical fashion (say, as new paragraphs or table rows), simply specify them in adjacent table cells in the same row:

Code:
<table>
   <tr>
      <td>
         <!-- Contents of most recent post -->
      </td>
      <td>
         <!-- Contents of second post -->
      </td>
      <td>
         <!-- Contents of third post -->
      </td>
   </tr>
</table>


If that code isn't absolutely crystal clear to you at a glance, please go to the link above and learn HTML. You'll be much happier, and a much more capable designer for having done it.

Of course, that's how the final code will look. In your actual PHP script, b2 loops through your posts, so you'll just specify one table cell, which it will repeat as many times as necessary. So, it'll be something (quite roughly like this:

Code:
<table>
   <tr>
      <!-- // b2 loop start -->
      <?php while($row = mysql_fetch_object($result)) { start_b2(); ?>

      <td>
         <?php the_date("m/d/Y","<b>","</b>"); ?><br>
         <?php the_content(); ?>
      </td>

      <!-- // this is just the end of the motor - don't touch that line either :) -->
      <?php } ?>
   </tr>
</table>


There are other ways to do this -- particularly CSS, which I also recommend everybody to learn, but tables are what I tend to recommend for beginners. I will warn you, however, that horizontal layouts can be a massive pain to get right -- current browsers don't support CSS2's max-width or min-width attributes, so you're stuck with however each browser likes to deal with overflowing contents. But have fun.
Back to top
View user's profile Send private message Visit poster's website
Eyevan



Joined: 16 Aug 2002
Posts: 18

PostPosted: Mon Jun 30, 2003 5:16 am    Post subject: Reply with quote

Hi, swirlee

Thanks for your reply! I know basic HTML (if you can see on my site), but I learned it through experience and social help, and a little from website guides...

I'm misunderstanding something, and so is my friend. On your first code that you exemplified, what's the (php) code to show the contents of the second post, and third post? That' confused me, I didn't see anything like that in the installation codes...
_________________
Blog + Meme
Back to top
View user's profile Send private message
swirlee



Joined: 15 Jul 2002
Posts: 8

PostPosted: Mon Jun 30, 2003 7:55 am    Post subject: Reply with quote

In the first chunk of code, I didn't include any PHP code. That's just the HTML required to display three table cells in column format. The second chunk of code is my attempt to translate that into b2-compatible HTML+PHP. If you're confused by the <!-- and --> syntax in the first code chunk, it's the HTML comment tag, which you don't really need to worry about. The second bit of code with the PHP is what you need to concern yourself with.

However, and please don't take this as an insult, it seems as though you don't have a very strong grasp of HTML or b2's PHP syntax. Learning HTML through experience is just fine, but once you've got your start, I think it's important to learn the finer points through written documentation and tutorials and such. So again, I recommend that you follow the link I posted originally and learn about HTML and tables, and also acquaint yourself with PHP as a language and become more intimately acquainted with exactly how b2 works. I know that sounds like a tall order, but I recommend it quite thoroughly, and I think others would, too.
Back to top
View user's profile Send private message Visit poster's website
Eyevan



Joined: 16 Aug 2002
Posts: 18

PostPosted: Mon Jun 30, 2003 5:20 pm    Post subject: Reply with quote

I have another question, have you tested this out, or proved it could work without any major problems?
_________________
Blog + Meme
Back to top
View user's profile Send private message
mrlarter



Joined: 14 May 2003
Posts: 55
Location: Halifax, NS

PostPosted: Mon Jun 30, 2003 5:36 pm    Post subject: Reply with quote

Hey swirlee

I think you are totally missing what hes looking for.

He dosn't want his one post spread out horizonatally he wants the entire blog spread out horrizonally. What you posted Swilee only effects one post and not how the posts are layed out.

Sadly I am unsure how to do this my self...but the b2 file is probably where you need to look.
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger
swirlee



Joined: 15 Jul 2002
Posts: 8

PostPosted: Mon Jun 30, 2003 8:00 pm    Post subject: Reply with quote

No, I haven't tested it out. That's Eyevan's job. But my method should produce output that fits what he's looking for. The code I posted should create a new column (HTML <td>) for each entry. If it doesn't, it's because my PHP/b2 code is untested -- the HTML I know is correct. Feel free to post other solutions, though.
Back to top
View user's profile Send private message Visit poster's website
Eyevan



Joined: 16 Aug 2002
Posts: 18

PostPosted: Tue Jul 01, 2003 5:10 am    Post subject: Reply with quote

Thanks swirlee. I will test it out on a "unused, spare" blog just incase. I will update with the reactions...
_________________
Blog + Meme
Back to top
View user's profile Send private message
confused_juvenille



Joined: 28 May 2003
Posts: 52
Location: bleh

PostPosted: Tue Jul 08, 2003 9:34 pm    Post subject: Reply with quote

I played around with swirlee's code but used tables and iframes. I don't know if I understand what you mean, though. is Iframes ok? If so, I'll post the code. I'm still working with it though.
Back to top
View user's profile Send private message Visit poster's website AIM Address MSN Messenger
yuchy



Joined: 22 Jun 2003
Posts: 28

PostPosted: Sun Jul 13, 2003 8:49 am    Post subject: Reply with quote

iframes may have browser compatibility problems. tables are somewhat cleaner.
Back to top
View user's profile Send private message
confused_juvenille



Joined: 28 May 2003
Posts: 52
Location: bleh

PostPosted: Mon Jul 14, 2003 6:19 am    Post subject: Reply with quote

yeah thats what i was thinking. i've only got the iframes down so far.
Back to top
View user's profile Send private message Visit poster's website AIM Address MSN Messenger
Display posts from previous:   
Post new topic   Reply to topic    boardom Forum Index -> Feature requests All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB 2 © 2001, 2002 phpBB Group