Recent Topics

1 Nov 21, 2008 18:09    

My b2evolution Version: 2.x

hello all!

i have a static site i want to move to b2 with ~500 pg's. each page contains many news items, something like this:

<h1>headline</h1>
<p>article snippet</p>
<div>optional video or graphic</div>

i want to move all this into a database for b2 with each article as a separate post so i can apply tags (right now all articles are just listed one after another on each pg.). isolating the news content from the rest of the html is not a problem -- i can write a script that will do this. i can also easily break up the content into separate articles and surround them with <div> tags so i can style them later. the question is, what is the best/easiest way to then move this into the MySQL DB?

2 Nov 21, 2008 20:38

The only way to import posts into the system that works (at least from my findings) is to convert all the text into MT format. This can be done easily if you already have a blog or other CMS. This gets complicated in your case because you would like to convert regular html. A way to do this that might work best for this situation is to use regular expressions to search and replace and convert your work into what you see below. Each post has all these attributes and can be listed in one convenient file if that works for you. The "<author>" and other tags are just there as a placeholder so you can see where stuff goes. and pay special attention the the type of text file you save it as. I would suggest regular ANSI format.

I hope this helps:

AUTHOR: <author>
TITLE: <title>
DATE: 09/29/2008 19:44:12 <-must use this format for the date
CATEGORY: <category>
-----
BODY:
<body> <---this call all be html or all plain text to style later.
--------

3 Nov 22, 2008 04:53

thanks! this looks pretty easy. is there a sample somewhere of an MT formatted file? i tried to export my blogs contents in MT format to see what ti looks like, but it's a temp install on WAMP and it's giving me problems.


Form is loading...