Page 1 of 1

Importing from b2evolution with 0.9-beta2

Posted: Sat Oct 15, 2005 3:17 am
by Judebert
I tried b2evo, but its development community didn't live up to my standards as I tried to port my static site to their blog. Serendipitously, I found this one, and the community seems extremely active and interested.

I'm trying to import my b2evo work. I get:

Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in /www/j/judebert/htdocs/wasted_youth/include/admin/import.inc.php on line 106

Strangely, it worked for me when I installed 0.8.5 as a test; now that I've moved to 0.9 and a new directory, it's failing.

I did some digging, and found that importers/b2evolution.inc.php is calling importCategory() without passing the database resource. If I add the resource to the call and method declaration (lines 129, 261, and 287), everything imports properly.

However, it looks like the same code was used in 0.8.5. Hmmm. The only differences in the installs (besides the versions) is that I installed 0.9 in a different directory, but in the same database with b2evo -- they use different table prefixes, so they should coexist peacefully.

Anyway, it's fixed for me. I thought you might like to know and fix it for others.

Re: Importing from b2evolution with 0.9-beta2

Posted: Sat Oct 15, 2005 6:01 pm
by garvinhicking
Hi Judebert!

Many thanks for spotting this. In fact in 0.8 versions of s9y the importers were not able to import stuff when the source DB was not the same as the target DB. This was fixed for 0.9 but contained an error for the b2evo importer (and two others) like you mentioned.

I just committed your fix, great! :)

Best regards,
Garvin

See what I mean?

Posted: Sun Oct 16, 2005 2:26 am
by judebert
See, this is why I like the s9y development community. 8)

If I find anything else, I'll let you know (like I haven't been enough a pain so far). :lol:

Re: See what I mean?

Posted: Mon Oct 17, 2005 8:45 am
by garvinhicking
You haven't been any pain, it's really appreciated. :)

Have a good time with s9y,
Garvin