PDA

View Full Version : Guest member's posts


JJR512
Tue 12th Dec '00, 6:08pm
Is there a way to change some posts listed as being posted by a Guest Member to a registered member? I had two accounts, one of them not used very much, and I deleted it. I'd like to reclaim the posts from the deleted account, which are now listed by a guest unregistered user, as my own. All posts listed as by guest would be mine; there are no guest posts that weren't made by me.

JJR512
Wed 13th Dec '00, 2:16pm
*JJR512 whistles patiently*

Wayne Luke
Wed 13th Dec '00, 2:27pm
Go into PHPMySqlAdmin, connect to your database and type in the following query:

update post set userid=YOURUSERID where userid=OLDUSERID

Of course this should be done before the account is deleted. If you look at those posts, the userid is most likely 0 now and if you allow guest posting then you'll get more posts than you bargained for.

Wayne Luke
Wed 13th Dec '00, 2:28pm
Oh.. Make sure you go into the Maintenance section of the Control Panel and update all the counters when your done.

JJR512
Wed 13th Dec '00, 2:37pm
OK, well, I've already deleted the account, as I said. But I do not allow non-registered people to post, so there should be no guest posts other than the ones that were from my alternate account, which I deleted. So I should do this with the olduserid as 0 (zero)?

BTW, I have no experience with this PHPMySqlAdmin, I don't even know what it is. But I'm sure I can find it and install it or whatever. But, since I am a newbie to this, and MySQL in general, can you tell me how to make a backup of the database first?

Wayne Luke
Wed 13th Dec '00, 6:24pm
If you do a search on Backup. You will find many threads helping in this matter.

You can find PHPMySQLAdmin at hotscripts.com. You will need it for the easiest way to backup your database. :)

JJR512
Wed 13th Dec '00, 6:39pm
My webhost gives me a control panel with a tool called phpMyAdmin, which I wasn't sure if it was the same as phpMySqlAdmin or not, but I used it. And it worked fine.

Related question: Is the post count for a user always correct? Unlike UBB? And what is the point of being able to put in a number for a person's post count if an admin edits another user's profile, if the number is always right anyway?

Chris Schreiber
Wed 13th Dec '00, 8:29pm
Originally posted by JJR512
Related question: Is the post count for a user always correct?

I've never seen the user's post total be incorrect, however yes it *could* happen. Especially if you are changing things via SQL like you just did. I wrote a hack though you can use to reset everyone's post count according to all of the posts in the database. Look in the code hacking section for it :)

-Chris

JJR512
Wed 13th Dec '00, 9:37pm
Thanks for pointing that out. I actually made the usercounts.php file last night, but I forgot to upload and use it. So I just did it, and I noticed some people's numbers have changed. Some people won't be too happy... :) Anyway, it looks just like the built-in update tools, which I'm sure is intentional, so is there a way I can integrate it into the vB control panel?

Also, here's another question for you. Since I imported from a UBB, some of the old UBB posts, like the ones with UBB lists or quotes, aren't correct. They have the text of the HTML formatting for those codes. Could you write a database query that would automatically replace the HTML version of the UBB code with the correct corresponding vBulletin code?

I.e., replace this: <BLOCKQUOTE><font size="1" face="Verdana, Arial">quote:</font><HR>

and

<HR></BLOCKQUOTE>
with the appropriate open and close quote tags.

And replace this: <UL TYPE=SQUARE>

and

<LI>

and

</UL>

with the appropriate list tags.