Pseduo-Blog Integration

liunx

Guest
I'm trying to create a sort of blog for my website, and I want the titles of each blog to appear in a certain part of my site, and in that certain part of my site i have <? include("../blogs.php"); ?>, so the blogs.php appears there. Inside that blogs.php, the titles of each blog, I want to appear there. How can I achieve this?

All I want is the title of the blogs to appear in the blogs.php file, preferably dynamicly and when I reach 5 or so blogs, it won't just keep adding, it'll delete the first ones and add the new. Any help appreciated!what are you using? mysql or flat files?The blog I will try with flat files, because I don't know anything about mySQL. If there is maybe an easy (free) blogging utility that uses mySQL, point it out, otherwise, I am planning on using just flat files. All in all, whichever one is easier, and I can only assume flat files would be.I think you're wrong, MySQL is really easy to learn for this type of thing, and you could easily get comfortable with it in an afternoon. Anyway, there's not much help to provide yet, as you haven't showed us the structure you'll use for the files etc. Once you have that figured out, it's a piece of cake to just grab the title from the 5 most recent posts(there's no need to delete any blogs, just timestamp them). But I suggest that you look into MySQL, it's not so complicated, just a few lines of code, probably even less than when using files. One of the good things about using a database like MySQL, is that you get all the data in different variables(usually inside an array), and you can just simply echo them. When using files, you would have to be able to separate the variables somehow, inside the textfile. It's pretty common to separate them with semicolon, ';', or something like it. This is not so good though, since you wouldnt be able to write ';' in your text then. It's generally not a very effective system. If you'll store a lot of data, it will soon grow out of hand too. Well, I suggest that you search for some basic MySQL tutorials... :)Hm, welp I'll take your advice. Sounds like I got in over my head on this one, I'll look into MySQL a bit more before trying it out lol.well, if you only want 5 entries, then you can use flat files no problem. read through some of the stuff in this (<!-- m --><a class="postlink" href="http://www.htmlforums.com/showthread.php?s=&threadid=22913">http://www.htmlforums.com/showthread.ph ... adid=22913</a><!-- m -->) thread. it will help in showing you how to do that
 
Back
Top