Simple Machines Community Forum

SMF Support => Converting to SMF => vBulletin => Topic started by: JayBachatero on January 11, 2008, 02:07:55 AM

Title: [SMF Converter] vBulletin 3.5
Post by: JayBachatero on January 11, 2008, 02:07:55 AM
Software: vBulletin
Version: 3.5.x

Changelog
! Fixed issue with PM conversion. (Thanks to mtindor (http://www.simplemachines.org/community/index.php?action=profile;u=135922))
! Attachments conversion now takes care of thumbnail dimensions.

convert.php
Use this convert.php (http://www.simplemachines.org/community/index.php?topic=140741.0) with the .sql file attached in this topic. 
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Kiv on March 26, 2008, 08:41:22 PM
convert.php is not available for download... timing out when clicked.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: JayBachatero on March 27, 2008, 12:01:07 AM
Works for me.  Try it again.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Alpay on March 29, 2008, 06:52:50 PM
convert.php
http:///http://www.simplemachines.org/community/index.php?topic=140741.0\
is not available for download...
Title: Re: [SMF Converter] vBulletin 3.5
Post by: winrules on March 30, 2008, 04:13:34 PM
I fixed the link. Try again.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: videomasterz on July 15, 2008, 02:29:28 AM
when I click the convert.php I go to a page that only has vbulletin 3.6 convert.php I need 3.5??
Title: Re: [SMF Converter] vBulletin 3.5
Post by: ThorstenE on July 15, 2008, 03:04:19 AM
Quote from: videomasterz on July 15, 2008, 02:29:28 AM
when I click the convert.php I go to a page that only has vbulletin 3.6 convert.php I need 3.5??
download vbulletin35_to_smf.sql from first post in this topic (attachment) and convert.php from this topic (http://www.simplemachines.org/community/index.php?topic=140741.0), attached in first post (scroll down)

Title: Re: [SMF Converter] vBulletin 3.5
Post by: videomasterz on July 15, 2008, 04:45:08 AM
allright thanks, thought since it said:

"Software: vBulletin
Version: 3.6"

it was for ONLY 3.6, ok gonna try it out to convert my 3.5 to smf :)
Title: Re: [SMF Converter] vBulletin 3.5
Post by: SleePy on July 15, 2008, 01:00:35 PM
Where do you see that? I don't see that version number in this topic. I know we have a 3.6 converter. But that is a different topic.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 05, 2009, 12:16:22 PM
I have a vb 3.5 database backup, but no vb forums anymore (webhost accidentally deleted it). How do I do the conversion when the original forums are gone?
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on October 05, 2009, 01:28:45 PM
You don't actually need the forum itself, but you need the vbulletin database, and a configuration file where the converter finds information like what is the name of the vbulletin database and table prefix.
Please eventually:
- install SMF
- restore the database backup into a database. (make sure that database has the same user as the SMF database user; it could also be the same database as SMF; or the SMF database user has also access to it)
- make a folder for vbulletin, and a folder /includes in it.
- make a file config.php into the ./includes folder, with the contents

$config['Database']['dbname'] = 'your_vbulletin_database_name';
$config['Database']['tableprefix'] = 'your_vbulletin_table_prefix';

- upload the converter files in your SMF folder and run convert.php
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 05, 2009, 01:52:05 PM
It would be awesome if I could enter that info manually, and upload an SQL backup file. I'm switching web hosts, so the database isn't even on the new host, and I can't create the db with the same naming scheme used by the old host.

----

update:

I just found out that not only will I have that problem, but the work around for this problem requires the webhost to change my username to the same username I used on the old webhost. This will allow the backup mysql file to work, but it will break the smf installation. In other words, I can't convert a VB backup from another webhost, which defeats the purpose of having backups in the special case where I want to resttore the backup and convert at the same time, and there's no other choice but to do it that way.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on October 05, 2009, 03:52:39 PM
Quote from: qwasty on October 05, 2009, 01:52:05 PM
It would be awesome if I could enter that info manually, and upload an SQL backup file. I'm switching web hosts, so the database isn't even on the new host, and I can't create the db with the same naming scheme used by the old host.
You can enter the information manually, in the config file. The name of the database, and the table prefix.
If you restore the backup under another name, then please enter in the config file the name you use. I didn't say you need to have the same name as the one the former installation had (though when you create a database, you should be able to name it any way you want).
(in most cases)
Please explain, what exactly are you talking about when saying "can't create the db with the same naming scheme used by the old host"?

Quote from: qwasty on October 05, 2009, 01:52:05 PM
I just found out that not only will I have that problem, but the work around for this problem requires the webhost to change my username to the same username I used on the old webhost. This will allow the backup mysql file to work, but it will break the smf installation. In other words, I can't convert a VB backup from another webhost, which defeats the purpose of having backups in the special case where I want to resttore the backup and convert at the same time, and there's no other choice but to do it that way.
Why do you say that you need the webhost to change your username to the same username used by the old webhost?
That should not be the case at all. Please explain what you refer to, the username for the database of vbulletin? Why do you need it changed?
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 05, 2009, 04:05:11 PM
Sorry for being vague. I don't understand the technical issues just yet, but my webhost uses cpanel, and it enforces a prefix on database names of the client's username. I tried to create database with a name appropriate under those restrictions, and then I tried to import the backup using phpmyadimn, but that gives me the following error:

Error

SQL query:

--
-- Database: `oldhostusername_bulletin`
--
CREATE DATABASE `oldhostusername_bulletin` DEFAULT CHARACTER SET latin1 COLLATE latin1_swedish_ci;


MySQL said: 
#1044 - Access denied for user 'newhostusername'@'localhost' to database 'oldhostusername_bulletin'

Apparently, the import does not give me an option to choose which database to but the backup sql data into, and instead tries to put it into whatever db is hardcoded into the backup from the old web host.

So, I tried to create a db with the name "oldhostusername_bulletin", but the new host cpanel only allows "newhostusername_bulletin". After that, I gave up, since I don't know what else to do.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on October 05, 2009, 04:16:10 PM
Please try to open the backup file in a text editor (a lightweight text editor like Notepad++ should do just fine if you are on windows), and comment out the CREATE DATABASE line, like:
Code (find) Select

CREATE DATABASE `oldhostusername_bulletin` DEFAULT CHARACTER SET latin1 COLLATE latin1_swedish_ci;

Code (replace) Select

-- CREATE DATABASE `oldhostusername_bulletin` DEFAULT CHARACTER SET latin1 COLLATE latin1_swedish_ci;

Then, please try again the import.

Note: you can make the backup without CREATE DATABASE too (thus allowing you to import the tables into an existing database). Typically a backup made with phpMyAdmin's Export feature does not have CREATE DATABASE (at least if you have the database already selected and go to the Export tab).
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 05, 2009, 09:47:26 PM
Commenting out CREATE DATABASE did not work. I had to remove all of it entirely. After that, it worked to get it into the db newhostusername_bulletin, however, I got these two lines at the top of the error page after trying to convert:

$config['Database']['dbname'] = 'oldhostusername_bulletin'; $config['Database']['tableprefix'] = 'vb_';
Notice: Undefined variable: config in /home/newhostusername/public_html/smf/convert.php(407) : eval()'d code on line 1

Notice: Undefined variable: config in /home/newhostusername/public_html/smf/convert.php(407) : eval()'d code on line 1

and then I got the following error on the error page after trying to convert. Any ideas?

Sorry, the database connection information used in the specified installation of SMF cannot access the installation of vBulletin 3.5. This may either mean that the installation doesn't exist, or that the MySQL account used does not have permissions to access it.

The error MySQL gave was: Incorrect database name ''
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on October 06, 2009, 04:52:27 AM
Please note that config.php should define the variables appropriate to your new server: the current name of the database where vbulletin data is, and the table prefix (this shouldn't have changed):

$config['Database']['dbname'] = 'your_vbulletin_current_database_name';
$config['Database']['tableprefix'] = 'your_vbulletin_table_prefix';


This file should be in something like:
/home/newhostusername/public_html/vbulletin/includes/config.php

When convert.php is run, the vbulletin installation folder it asks about should then be:
/home/newhostusername/public_html/vbulletin

Please check all the above. If they are correct, and you still get "Notice: Undefined variable: config", then you might have be into a rare situation when the host configuration doesn't allow the config file to be imported from another folder. Perhaps then, you can consider an alternative:
make a subfolder of the SMF folder named /includes, and copy the config.php file there. Make sure you tell the convert script when it asks about vbulletin installation folder that it's exactly
/home/newhostusername/public_html/smf, as well.

Please, in both cases, let us know the full messages/errors, if case may be.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 07, 2009, 03:02:45 PM
I double checked everything, and it's all fine as far as I can tell. I tried your alternative method, but I got the same errors as before, with no change at all.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on October 07, 2009, 03:15:33 PM
I've seen this only once in the past, it could be something rarely seen in a host's configuration settings, that prevents this include from working. Please, still, could you paste here the messages from the second configuration? Where is config.php now (comparing to your_web_root folder)?
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 07, 2009, 03:23:50 PM
config.php is in both

/home/newhostusername/www/vb/includes/config.php
/home/newhostusername/www/smf/includes/config.php

I noticed that public_html and www have the same content, so I don't know if that makes any difference. I've been working with the www directory, but all the errors report the public_html directory.

Below is the errors at the top of the convert page, then the page title, and the reported error below it. I copied and pasted it verbatim excep for some new lines for clarity, and I changed the usernames:

$config['Database']['dbname'] = 'newhostusername_bulletin'; $config['Database']['tableprefix'] = 'vb_';
Notice: Undefined variable: config in /home/newhostusername/public_html/smf/convert.php(407) : eval()'d code on line 1

Notice: Undefined variable: config in /home/newhostusername/public_html/smf/convert.php(407) : eval()'d code on line 1

vBulletin 3.5 to SMF Converter

Sorry, the database connection information used in the specified installation of SMF cannot access the installation of vBulletin 3.5. This may either mean that the installation doesn't exist, or that the MySQL account used does not have permissions to access it.

The error MySQL gave was: Incorrect database name ''
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on October 07, 2009, 03:30:29 PM
What if you make sure you set the path to smf as
/home/newhostusername/public_html/smf
and to vb
/home/newhostusername/public_html/smf
when the convert.php first page asks about them?
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 07, 2009, 08:55:57 PM
That's exactly what I did. A picture is worth a thousand words. Here's some screenshots:

http://img14.imageshack.us/img14/38/smfconvertfailure120091.png
http://img44.imageshack.us/img44/3166/smfconvertfailure220091.png
http://img200.imageshack.us/img200/6293/smfconvertfailure320091.png

Maybe it will be easier for you to figure out what's wrong if you can see what I see. The blanked out stuff is newhostusername. The two lines I have in config.php are:

$config['Database']['dbname'] = 'newhostusername_bulletin';
$config['Database']['tableprefix'] = 'vb_';

Here's screenshots of my FTP webhost dirs with config.php

http://img15.imageshack.us/img15/7200/smfconvertfailure420091.png
http://img43.imageshack.us/img43/2503/smfconvertfailure520091.png

Let me know if there's anything else you'd like to see.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on October 08, 2009, 07:06:51 AM
Please, make sure the config.php file begins with <?php and ends with ?>, that is, its contents are actually

<?php
$config
['Database']['dbname'] = 'newhostusername_bulletin';
$config['Database']['tableprefix'] = 'vb_';
?>

Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 08, 2009, 12:17:29 PM
Got a new error:

Sorry, the database connection information used in the specified installation of SMF cannot access the installation of vBulletin 3.5. This may either mean that the installation doesn't exist, or that the MySQL account used does not have permissions to access it.

The error MySQL gave was: Table 'newhostusername_bulletin.vb_user' doesn't exist
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on October 08, 2009, 01:30:31 PM
Oh! Okay, thank you.
So it seems that the database was not imported, or it has a different prefix. You could perhaps check in phpMyAdmin, to see if the table "user" in vbulletin's database on the new site (with some prefix) exists or not?
If it does not exist, then perhaps you didn't export it completely, or didn't restore the database into newhostusername_bulletin? The database can be restored with phpMyAdmin's "import" feature, please see the tab "import" for it.
If it exists, then what prefix do the tables have, please check the database name and the prefix of the tables.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 08, 2009, 01:44:05 PM
It appears to have been imported OK, as far as I can tell. I see "user", but should it be "vb_user" instead? The original database is still hosted at the old host, and it also has merely "user", and not "vb_user".

UPDATE:

I changed the config.php to not have a prefix, as follows:

<?php
$config['Database']['dbname'] = 'newhostusername_bulletin';
$config['Database']['tableprefix'] = '';
?>

Then, the convert seemed to be working, but gave me a new error:

Converting...
Converting members... Successful.
Converting categories... Successful.
Converting boards... Successful.
Converting topics... Successful.
Converting posts (this may take some time)... Successful.
Converting polls... Successful.
Converting poll options... Successful.
Converting poll votes... Successful.
Converting personal messages (step 1)... Successful.
Converting personal messages (step 2)... Unsuccessful!

This query:

SELECT
pm.pmid AS ID_PM, pm.touserid AS ID_MEMBER, pm.readtime != 0 AS is_read,
'-1' AS labels
FROM `newhostusername_bulletin`.pm AS pm
WHERE pm.folderid != '-1'
LIMIT 0, 500;

Caused the error:

Unknown column 'pm.touserid' in 'field list'
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on October 08, 2009, 06:02:13 PM
In the file vbulletin35_to_smf.sql, please find:
Code (find) Select

---* {$to_prefix}pm_recipients
SELECT
pm.pmid AS ID_PM, pm.touserid AS ID_MEMBER, pm.readtime != 0 AS is_read,
'-1' AS labels
FROM {$from_prefix}pm AS pm
WHERE pm.folderid != '-1';
---*


Code (replace) Select

---* {$to_prefix}pm_recipients
SELECT
pm.pmid AS ID_PM, pm.userid AS ID_MEMBER, pm.readtime != 0 AS is_read,
'-1' AS labels
FROM {$from_prefix}pm AS pm
WHERE pm.folderid != '-1';
---*
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 08, 2009, 06:15:14 PM
None of the posts, boards, and or members are showing up. Here's the results:

SMF Converter
Converting...

Notice: Undefined index: convert_script in /home/newhostusername/public_html/smf/convert.php on line 822

Warning: Invalid argument supplied for foreach() in /home/newhostusername/public_html/smf/convert.php on line 825

Notice: Undefined index: convert_script in /home/newhostusername/public_html/smf/convert.php on line 837

Notice: Undefined index: convert_script in /home/newhostusername/public_html/smf/convert.php on line 733
Successful.
Recalculating forum statistics...
Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1223

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1233

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1241

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1251

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1264

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1277

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1323

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1325

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1331

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1337

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1348

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1349

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1357

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1359

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1365

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1366

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1372

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1373

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1397

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1399

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1405

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1417

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1442

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1444

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1488

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1503

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1532

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1534

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1547

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1569

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1574

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1635

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1637

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1673

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1692

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_row(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1715

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1716

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 2429

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 2429

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258
Successful.

Notice: Undefined index: convert_script in /home/newhostusername/public_html/smf/convert.php on line 1823

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258
Conversion Complete
Congratulations, the conversion has completed successfully. If you have or had any problems with this converter, or need help using SMF, please feel free to look to us for support.
Now that everything is converted over, your SMF installation should have all the posts, boards, and members from the installation.

We hope you had a smooth transition!
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on October 08, 2009, 06:30:46 PM
Errm, I'd say that didn't work ...
How did you edit the .sql file? Some editors may insert characters that break code. On windows a decent editor is Notepad++.
Perhaps you can try with the attached file instead.

On another note, is your database still online and accessible?
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 08, 2009, 06:40:44 PM
I used textpad, which is an excellent windows text editor. All of the databases are still there. I'm not sure which one you want me to check. I get a different MD5 sum for the one you attached to your post, and the one I edited. Should I try it again with the one you attached to your post?

UPDATE:

I just tried it with yours, and it appears I got the same errors.

SMF Converter
Converting...

Notice: Undefined index: convert_script in /home/newhostusername/public_html/smf/convert.php on line 822

Warning: Invalid argument supplied for foreach() in /home/newhostusername/public_html/smf/convert.php on line 825

Notice: Undefined index: convert_script in /home/newhostusername/public_html/smf/convert.php on line 837

Notice: Undefined index: convert_script in /home/newhostusername/public_html/smf/convert.php on line 733
Successful.
Recalculating forum statistics...
Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1223

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1233

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1241

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1251

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1264

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1277

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1323

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1325

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1331

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1337

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1348

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1349

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1357

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1359

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1365

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1366

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1372

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1373

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1397

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1399

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1405

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1417

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1442

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1444

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1488

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1503

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1532

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1534

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1547

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1569

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1574

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1635

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1637

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1673

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1692

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_row(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1715

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 1716

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 2429

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/newhostusername/public_html/smf/convert.php on line 2429

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258
Successful.

Notice: Undefined index: convert_script in /home/newhostusername/public_html/smf/convert.php on line 1823

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2257

Notice: Undefined variable: result in /home/newhostusername/public_html/smf/convert.php on line 2258
Conversion Complete
Congratulations, the conversion has completed successfully. If you have or had any problems with this converter, or need help using SMF, please feel free to look to us for support.
Now that everything is converted over, your SMF installation should have all the posts, boards, and members from the installation.

We hope you had a smooth transition!

UPDATE:

I just tried transferring your file with the FTP client, and then downloading it again. Hashcalc says the file has been altered, so the FTP client is doing something to the file. I'm using Filezilla, and this is super depressing that you can't trust your FTP program to not do stuff to your files! Any ideas how to fix this?

UPDATE:

I changed Filezilla's transfer mode from "Auto" to "Binary", and now I get the same file back that I put on the server. My MD5 checksum is 625fb3f61caad592cacedd079f6a5bc0

However, I still get the same errors. I'm going to fiddle some more to see if I can figure out what's wrong. Maybe I uploaded the wrong file or something.

UPDATE:

The file I edited has the following MD5 sum 632cfc0961a3cbfdf2f532876f4b4f6e and all versions I've tried give me a similar long list of errors. I haven't compared them to be sure they're the same though. Should I try starting over by re uploading everything from scratch to eliminate the possibility that filezilla screwed up everything from the beginning?
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on October 08, 2009, 07:09:14 PM
Please run the following SQL on the SMF database

select * from smf_settings where variable = 'conversion_from';


Could you please tell also if you are using the converter from
http://www.simplemachines.org/community/index.php?topic=140741.0

Also, it seems the converter doesn't access the SMF database. That could happen if something is wrong with its settings in the file Settings.php. Please upload the tool attached here: What is repair_settings.php? (http://docs.simplemachines.org/index.php?topic=663.0) on your SMF directory, and run it from the browser. You will see a number of settings. Please make sure your database information is correct, then save the settings.
In case nothing appears or there's a problem with Settings.php, please note there's also a Settings.bak.php, a backup file, that might help to restore the settings if necessary.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 08, 2009, 07:27:29 PM
repair_settings.php actually downloads as repair_settings.htm. I have to rename the file manually to .php extension. That's a simple but serious problem to add on top of whatever problems people are trying to troubleshoot.

Also, yes, I am using the converter from this thread, which is where the link you gave me eventually leads to. I can see SOME of the data from the database in the admin section of the forums, but none of it shows up anywhere else. Presumably the only place it could get that information is from the SMF database, so it appears it's able to access it just fine. I don't see anything misconfigured in the repair_settings.htm / repair_settings.php tool.

UPDATE:

I didn't see the first part of your reply. Here's what I got from the query from PHPmyadmin (I have no idea what I'm doing):

MySQL returned an empty result set (i.e. zero rows). (Query took 0.0003 sec)
SQL query:
SELECT *
FROM smf_settings
WHERE variable = 'conversion_from';

LIMIT 0 , 30
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on October 09, 2009, 10:40:36 AM
Quote from: qwasty on October 08, 2009, 07:27:29 PM
repair_settings.php actually downloads as repair_settings.htm. I have to rename the file manually to .php extension. That's a simple but serious problem to add on top of whatever problems people are trying to troubleshoot.
You're right and I can fully appreciate that, however please note that it's something in your browser / downloads / file types settings controlling this little thing.

As for the problem, were there any other changes happening between reply #25 (http://www.simplemachines.org/community/index.php?topic=216076.msg2298673#msg2298673) ? Can you please make sure to fully restart the converter? That is, run it with youraddress.com/convert.php. Also, perhaps you renamed the .sql file as well? The converter sql file name has a simple convention to help the convert script recognize multiple conversion sql files if there are from different software: like name_of_software_to_convert_from_to_smf.sql.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 09, 2009, 02:27:24 PM
I just ran the converter again from the beginning, here's the errors:

vBulletin 3.5 to SMF Converter
Converting...
Converting members... Successful.
Converting categories... Successful.
Converting boards... Successful.
Converting topics... Successful.
Converting posts (this may take some time)... Successful.
Converting polls... Successful.
Converting poll options... Successful.
Converting poll votes... Successful.
Converting personal messages (step 1)... Successful.
Converting personal messages (step 2)... Unsuccessful!
This query:
SELECT
pm.pmid AS ID_PM, pm.userid AS ID_MEMBER, pm.readtime != 0 AS is_read,
'-1' AS labels
FROM `newhostusername_bulletin`.pm AS pm
WHERE pm.folderid != '-1'
LIMIT 0, 500;
Caused the error:
Unknown column 'pm.readtime' in 'field list'
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on October 09, 2009, 02:40:56 PM
Please, try using the attached file.

On a side note, are you sure the database dump you had was from vbulletin 3.5? I'm not sure, but I wonder if it's higher, like 3.7 or 3.8, seeing these errors.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 09, 2009, 02:52:33 PM
Database was from VB 3.5.4, if I remember correctly. I searched for the version in the database, and as best I can tell, it was upgraded at least once, from version 3.5.3, to version 3.5.4. I could find no reference to version 3.6, 3.7, or 3.8.

I used your sql file, which has an MD5 checksum of 2f00e44f64d25199c7e3eabe50e5b7ee. I also downloaded it from the server, and checked its MD5, and got the same thing. It gave me the following errors:

Converting...
Converting members... Successful.
Converting categories... Successful.
Converting boards... Successful.
Converting topics... Successful.
Converting posts (this may take some time)... Successful.
Converting polls... Successful.
Converting poll options... Successful.
Converting poll votes... Successful.
Converting personal messages (step 1)... Successful.
Converting personal messages (step 2)... Successful.
Converting topic notifications... Successful.
Converting board notifications... Successful.
Converting smileys... Successful.
Converting attachments... Successful.
Converting avatars... Successful.
Recalculating forum statistics... Successful.
Unsuccessful!
This query:
REPLACE INTO {$to_prefix}settings (variable, value)
VALUES ("conversion_time", 1255113953),
("conversion_from", "vbulletin35_to_smf.sql");
Caused the error:
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '{$to_prefix}settings (variable, value)
VALUES ("conversion_time", 1255113953)' at line 1

UPDATE:

My forums are showing up now. I'm not sure what the error above screwed up.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on October 09, 2009, 02:57:20 PM
It didn't, please ignore this one. The last error is a a little bug in the converter itself, which will probably be  fixed next time the converters will be updated on site.
The step about "Recalculating forum statistics... Successful." was the last that matter. Your conversion has succeeded. :)
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 09, 2009, 02:59:05 PM
Great! Thank you so much for all your help in fixing this! You have been so fast and attentive, it surprised me quite a lot. Thanks!
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 09, 2009, 07:43:24 PM
I just noticed that the text of some of the posts has been altered. There are IRC logs in the forum that begin each line with a user's nickname. The nickname is in the form <nickname>. All of them have been stripped out, except ones of the form <@nickname>, which are the usernames of users with an "@" sign to signify a different status. Can this be corrected?
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on October 10, 2009, 12:52:19 PM
I'm sure it can, and I will take a look to see where did that come from, though I'm not fully sure I'll have time for it this weekend.

Eventually, meanwhile it might help if you can paste here an example - an entire  line of text or two before conversion, and the exact line(s) after.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 10, 2009, 01:24:04 PM
I figured out what's wrong. SMF isn't converting HTML reserved characters into HTML entities. In other words, a line like this:

<nickname> Hi

is displayed by the forum verbatim, and the web browser will render it like this:

Hi

The forum needs to convert the HTML reserved characters < and > into HTML entities that will be displayed by the browser. Right now, browsers are treating <nickname> as an unknown HTML tag and not displaying it. SMF needs to convert them according to this:

http://www.w3schools.com/tags/ref_entities.asp

I noticed that the problem doesn't appear in THIS forum, so I checked my freshly installed forum for some option to turn off HTML in posts, and I found "Enable basic HTML in posts", which is already off by default.

The "tags" are in the forum page source, so the pages will no longer validate. It looks like an easy problem to fix, even though it's quite serious.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on October 10, 2009, 02:05:55 PM
Actually, SMF is converting html entities, in every posts, PMs, etc, made using SMF.
However it remains to be seen what the post looked like in the former database, and what it looks like after conversion, the raw database data, that is.

I'll test myself too, to see, as soon as possible.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 10, 2009, 02:19:16 PM
Database before conversion:

[23:21] <nickname> hey...\r\n

Database after conversion:

[23:21] <nickname> hey...\r\n

Source code of the forum webpage:

[23:21] <nickname> hey...<br />

It's that source code part that's the problem. It should be:

[23:21] &lt;nickname&gt; hey...<br />

UPDATE:

I just found that in the forum title section, if I do

<a href='websitemainpage.com'>Website Title</a>

It will put that string into a meta tag without escaping the < and > with &lt; and &gt; just as before, which will cause the page to not validate. I'm curious what it would do if the URL had an ampersand in it, like many URLs do. They all have to be escaped with &amp; to keep the site valid, even when they're in URLs.

UPDATE:

I just tried putting & in a forum title, and the board converts it to &amp; fine. It looks like the way SMF handles that issue is inconsistent. It ought check everything, but it looks as though some things are checked and fixed, and some aren't.

UPDATE:

I found this post

http://www.simplemachines.org/community/index.php?topic=306815.0

If I understand it correctly, it seems that this might be a pervasive bug in SMF, and it's not related exclusively to conversions from other software.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 15, 2009, 01:25:21 PM
I found another bug, but I don't know if it's related to conversion or not. My VB forum used BB code, but I tried to have BB code turned off in my new SMF forum. When it's completely off, paragraph formatting isn't obeyed in displaying the posts. If I "modify" the post, I can see clearly that the formatting is still there, just not being displayed properly. If I then save the "modification" without actually changing anything, it fixes it. If I turn just one BB code item on, that fixes it too. Is this a bug in SMF as a whole, or just in the conversion?
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 21, 2009, 04:27:28 AM
I've found another problem. Even in post text, reserved HTML characters are not being converted to HTML entities. For example, someone saying in their post " 5 > 4" will cause a validation error on the page. Here's an example:

http://www.livebusinesschat.com/smf/index.php/topic,85.0.html

Is this a problem with an SMF bug, or is it a problem with the conversion?
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on October 21, 2009, 04:23:23 PM
It's definitely with the conversion, I will look into it as soon as possible. You can see for yourself that if you post a new reply saying " 5 > 4", then SMF will handle it. It seems it's in the converted posts that it's not saved properly. I don't have reports for any other converter so it might be a problem restricted to this one.
I will have to see if I can replicate it. Sorry for the delay on this one.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 21, 2009, 04:43:20 PM
OK, thank you. Please let me know how to fix this. It's really giving me headaches, since I'm getting bad data out all over the place.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 22, 2009, 08:59:43 PM
The main page is suddenly not validating anymore. It says there's a misplaced </table> tag that's probably nested improperly. I would be willing to be that's because of the HTML entity problem in the conversion, where we already know there's a > character that didn't get converted. See for yourself:

http://www.livebusinesschat.com/smf/index.php
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on October 23, 2009, 11:55:31 AM
Please, try using the converter to 3.6 or even 3.7. I'm not aware of database changes in vbulletin (not sure they aren't, I don't have a 3.5 version myself, but I just used the 3.7 converter for both vbulletin 3.6 and 3.8 successfully), still, they're fixed to work without such issues.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 23, 2009, 01:41:42 PM
The forum has been active since before this bug was discovered. Is there a way to do this without losing the current data set?

UPDATE:

Since it seems to be only a few rare instances of the < and > characters causing me problems, would it be safe to make a backup of the sql file, put the forum in maintenance mode, and then do a search and replace on the SQL file? Should I replace the characters with HTML entities?
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on October 23, 2009, 04:35:06 PM
That's what I would do, yes, replace the occurrences directly in a SQL backup file.

There is no easy way to redo the conversion and reimport correctly the posts / members / etc meanwhile.(though not impossible, but there would be quite a lot of manual database work)
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 23, 2009, 04:38:52 PM
OK, since there's few occurrences, I should be able to manually check each replacement to make sure it's good before proceeding. I should replace with HTML entities of the form &amp; ? Or, should it be something like #039; ? I'm not sure what the difference is. I converted to UTF-8 from ISO 8859-1 (i think).

UPDATE:

I just had an idea. SMF should include this in its "check for errors" maintenance system. Right now it tells me there's no errors, when clearly there are. This functionality should be added to at least identify such problems in the future (repair is easy after that).
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on October 23, 2009, 05:08:05 PM
I just tested: I can actually reproduce the problem on a 3.6 database even with the latest converter, so it wouldn't help for now. Hopefully it will be possible to be considered for the next version. (of the converter)
Perhaps you're right that there might be also rather few cases (generally), and it didn't happen to be reported as yet, so we didn't know about this bug.
In any case, SMF sets &lt; and &gt; in the raw database data, for random occurrences of '<' and '>', and needs to find them as such in the database.

UPDATE:
Quote from: qwasty on October 23, 2009, 04:38:52 PM
I should replace with HTML entities of the form &amp; ? Or, should it be something like #039; ? I'm not sure what the difference is. I converted to UTF-8 from ISO 8859-1 (i think).
Any is okay (it's simply either the name for those which have names, or the underlying code). There is also a task in maintenance area of the forum, to convert html entities to UTF-8 characters, it might be useful to run afterwards.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 23, 2009, 06:54:10 PM
I think I might have found another bug, and I don't know if I should change it or not. Usually I see \r\n\r\n in the database everywhere that someone makes a new paragraph. I just stumbled across the (wrong) HTML equivalent of <br /><br /> in the actual database, where I think it should be \r\n\r\n instead. Or vice versa. It looks like the convert missed something involving that, correct? What should be change, and what should it change to, if anything?

It doesn't appear to be related, but I made a post about a similar topic here:

http://www.simplemachines.org/community/index.php?topic=344103.msg2324495#msg2324495

In that topic, I think the problem is in one of the functions in SSI.php, not in the actual operation of the forum, or the conversion process, like in this case. The similarities might just be coincidental.

UPDATE:

Now that I look closer at the database, it seems only the posts made with SMF originally, after the conversion, are using <br />. It appears \r\n was used in vBulletin, but never got converted to the SMF way. If that's correct, then my related post mentioned above suddenly becomes relevant.

<br /> is fine for line endings, but <br /><br /> ought to be replaced with <p></p> tags around the block that was ended with <br /><br />. That's a flaw, if not a bug per se, and is relevant to conversion only because the convert didn't keep everything consistent, flawed or otherwise.

UPDATE:

I found some more problems with the conversion. This bizarre undefined character, , shows up in one of the posts and breaks validation on this page:

http://www.livebusinesschat.com/smf/index.php/topic,16.0/all.html

I don't know where it came from or why it's there, but I don't think it was there before the conversion. That's another thing the "find errors" function ought to find is undefined characters. It could be a sign of data corruption, although in this case it does not appear to be.

The other problem I have found looks like bb code that doesn't do anything like [ right ][/ right ] that probably ought to be removed in the conversion or settings changes, but wasn't. And then there's odd things like bbcode closing tags that don't seem to have an opening tag. I'm not certain, but it looks like some or all opening [ quote ] tags have been lost too. It looks like the converter tried to remove them, but only got half of it right, like [/ b ]. And one last problem seems to be bbcode that nothing gets done with it, like [ snapback ][/ snapback ]. All of those issues are visible here:

http://www.livebusinesschat.com/smf/index.php/topic,9.0/all.html

How do I get all of these problems fixed? I managed to fix the < and > html entities by hand, and it doesn't appear that I've accidentally screwed up the <br /> tags that SMF is gratuitously littering everywhere, but there weren't many of those, and all of the postings with the problem were from VB so there were no competing < and > characters to interfere with find and replace. I'm not sure how to fix these new problems, since I'm not sure what's going on with them.

Can I add here that after this experience, I have discovered that \r\n  is much preferred over HTML tags in the database code since it makes it SO MUCH easier to find and fix problems without HTML everywhere. The HTML ought to be added after reading the data from the database.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on October 31, 2009, 05:08:13 PM
Any new info on this?
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on November 04, 2009, 01:27:10 AM
Sorry for the delay. I've been dealing with other things but I'll take my time for this converter these days. On some issues, I am quite at loss how to replicate the problems (like having a closing "[/b]", not sure why that is; I wonder what is the full original text of that post).  Other issues however should be dealt with, as generally html entities should be replaced properly.
I'll post an update as soon as possible.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on November 04, 2009, 02:38:25 AM
Here's my original VB database backup that I converted from, to SMF:

http://www.livebusinesschat.com/vbulletinbackup.zip

Let me know when you've got it so I can take it down.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on November 04, 2009, 02:41:45 AM
Thank you! Done.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on November 04, 2009, 02:43:10 AM
OK, I've taken it down. Let me know what you find out.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on November 04, 2009, 02:44:44 AM
Will do, thanks.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Red G. Brown on January 02, 2010, 06:41:45 PM
Anything new on this?
Title: Re: [SMF Converter] vBulletin 3.5
Post by: buckers_wv on February 18, 2010, 10:40:54 AM
Just managed to successfully convert a vBulletin 3.5.4 forum into SMF 1.1, however I had to modify the "vbulletin35_to_smf.sql" script in order for the conversion process to complete.

Towards the end, I encountered the following error:

>>>>>>>>>>
Converting...
Converting personal messages (step 2)... Unsuccessful!
This query:

    SELECT
    pm.pmid AS ID_PM, pm.touserid AS ID_MEMBER, pm.readtime != 0 AS is_read,
    '-1' AS labels
    FROM `truforum_vb`.pm AS pm
    WHERE pm.folderid != '-1'
    LIMIT 0, 500;

Caused the error:

    Unknown column 'pm.touserid' in 'field list'
>>>>>>>>>>

In order to get the script to complete, I modified the SQL from line 200 (The section saying "Converting personal messages (step 2)...") from this:


TRUNCATE {$to_prefix}pm_recipients;

---* {$to_prefix}pm_recipients
SELECT
   pm.pmid AS ID_PM, pm.touserid AS ID_MEMBER, pm.readtime != 0 AS is_read,
   '-1' AS labels
FROM {$from_prefix}pm AS pm
WHERE pm.folderid != '-1';
---*


to this:

TRUNCATE {$to_prefix}pm_recipients;

---* {$to_prefix}pm_recipients
SELECT
   pm.pmid AS ID_PM, pm.userid AS ID_MEMBER,
   '-1' AS labels
FROM {$from_prefix}pm AS pm
WHERE pm.folderid != '-1';
---*




The script then completed, and my converted forum works perfectly.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Norv on March 18, 2010, 01:25:55 PM
Thank you for the information. Yes, it seems there were some changes in vbulletin around that version (3.5.something), though I am not certain when  exactly it happened.
Title: Re: [SMF Converter] vBulletin 3.5
Post by: Doublejay on July 27, 2013, 10:58:06 AM
Getting this error. Any idea on how to fix it.

Converting...
Converting members... Successful.
Converting categories... Successful.
Converting boards... Successful.
Converting topics...Wrong value type sent to the database. Integer expected. (id_member_updated)