I managed to upgrade from wwwthreads 5.1 something demo to ubbthreads 5.4.6 and not lose any tables. But I read another post saying you're supposed to run through each alertable script from oldest to newest. This I did not do. When ubbthreads createtable.php didn't work for me, I just went to the newest alertable script (5.4.5 I think). Basically I guessed. Did I screw things up by not going through each alertable? Can I do it backward?
if you had already created the tables when you installed your Demo version, you shouldn't have needed to run the createtable script when upgrading...
that being said, in some cases altertable scripts can be run out of order, if the changes they make are not dependent on changes made in a script you haven't yet run... make sense? To clarify: if altertable1 adds a new column to a table and altertable2 changes that colum's width (from 10 characters to 60 characters), and you try and run altertable2 before altertable1, you will get an error because the column does not exist....
Anyway, I would look over the scripts, see which altertables from 5.1.x -> 5.4.6 you did not run, verify that those changes were not made in your database, back up your database, and try running the scripts in order (minus the one you have already run...)
Remember: ALWAYS back up your database before running the altertables!!! You could regret it if you don't!
OK I backed up my database. I looked over the alertables but the only things I understand are: require main.inc.php and alter table so I'm hesitant to try anything. Are these alertables necessary? I figured out I ran alertable_demo 5.4.5 (which was the newest alertable) when I first installed the full version. I thought that's what the instructions said to do when upgrading from the trial to full version.
But I'm running into a problem with adding a post and was wondering if these alertables are related to it. When I preview a post I get the following message: (fyi -- paths are abbreviated)
Warning file("http://www.linly.com/ubbthreads/filters/badnames" - Success in /public_html/ubbthreads/addpost.php line 169
Warning Variable passed to each () is not an array or object in addpost.php line 170
But I'm still allowed to post. Following the post I get the above two messages again plus the following:
Warning file("http://www.linly.com/ubbthreads/filters/usertitles" - Success in /public_html/ubbthreads/addpost.php line 767
Warning Variable passed to each () is not an array or object in addpost.php line 768
It looks like you are running into a problem with how php is configured. I need to get an option for this in the next release, but for now it just takes a slight edit of addpost.php, about lines 144, 169, 639 and 767 you will see a bit of code that looks like this:
... = file("$config[phpurl]/...
You need to change the $config[phpurl] to $config[path] in each of thost places. If the line numbers don't match just search for the word filters in the file. I apologize for not having this an option yet, still trying to figure out why some installations of php cannot read files as an actual URL and some can.
------------------- Rick Baker UBBThreads developer
I figure I might as well try getting the old altertables before my forum's grand opening. I ran the oldest one that came with v5.4.6 and got the following message. I assume I have to fix this before I can run the next altertable, correct? So how do I fix this?
Altering the posts table to better designate main topic posts (Speed improvement)... SQL ERROR: Unable to do_query: ALTER TABLE w3t_Posts ADD B_Topic INT(1) UNSIGNED DEFAULT '0' NOT NULL , ADD INDEX topic_ndx (B_Topic) Duplicate column name 'B_Topic': 1060Re-indexing the main topics for each board... Altering Users table to allow for thread age display preference... SQL ERROR: Unable to do_query: ALTER TABLE w3t_Users ADD U_ActiveThread INT(4) UNSIGNED Duplicate column name 'U_ActiveThread': 1060Done...
It looks like this altertable has already been run so you should be able to move onto the next. When it gives the duplicate column names, then that means the field already exists.
------------------- Rick Baker UBBThreads developer