Icy Phoenix

     
 


Post new topic  Reply to topic 
Page 1 of 2
Goto page 1, 2  Next
 
Reply with quote Download Post 
Post Delete Pots From User Deleted 
 
Hello, I deleted an user and I want to delete all post that this users wrote, but I can't do it, because this user doesn't exists.

How I can delete all post of this user?

Thanks.
[b]version of icy phoenix: 1.3.0.53a[quote]
 




____________
Thanks for all your work...
 
AnakinSend private messageVisit poster's website  
Back to topPage bottom
Icy Phoenix is an open source project, you can show your appreciation and support future development by donating to the project.

Support us
 
Reply with quote Download Post 
Post Re: Delete Pots From User Deleted 
 
I would like to know this one too, very useful.
 



 
batmanSend private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Delete Pots From User Deleted 
 
Well ... Give me the error you get and I'll look at how you can fix it.
 



 
InformproSend private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Delete Pots From User Deleted 
 
well, Simple I don't know how I can delete post of an user that he doesn't exit  
 




____________
Thanks for all your work...
 
AnakinSend private messageVisit poster's website  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Delete Pots From User Deleted 
 
Anakin wrote: [View Post]
well, Simple I don't know how I can delete post of an user that he doesn't exit  


You may have to update the database with something like this

UPDATE `ip_posts` DELETE `user`='whatever' WHERE `user`=whatever;

Informpro wrote: [View Post]
Well ... Give me the error you get and I'll look at how you can fix it.


If you respond properly to Informpro's post - Like WHAT are the posts telling you in regard to the deleted user's handle and ID etc - You may just get the string you need to do it.

Though I'm surprised (and I'm also not sure) that Icy Phoenix doesn't give you that option when you delete the user.
 



 
mortSend private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Delete Pots From User Deleted 
 
as munch as i know, Icy has´nt got the function.

Would be a n good idea, to include this in ACP

Icy normaly replaces the User_ID by anonimos in the front office, even if it mantains the User ID in the Database, it just changes The usergroup to -1 .

So you would have to search your DB Users Table for this user.

When you could run this consult in Phpmyadmin
Code: [Download] [Hide]
  1. UPDATE `ip_posts` DELETE `*` WHERE `USER_ID`=XXX;  
    

replace ip with your prefix, and replace XXX with the user ID ( number)
 




____________
Out of Order
 
spydieSend private messageVisit poster's website  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Delete Pots From User Deleted 
 
Use
Code: [Download] [Hide]
  1. DELETE `ip_posts` WHERE `USER_ID`=XXX; 
(BTW this is NOT the right way to do, you'll create many problems with topics / posts / ... You'd rather update ID to Anonymous.
 



 
InformproSend private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Delete Pots From User Deleted 
 
Icy is doing this by default

changing User-Group to anonimous

have a look for example for Lopalongs old posts here. it says anonimous
 




____________
Out of Order
 
spydieSend private messageVisit poster's website  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Delete Pots From User Deleted 
 
It says "inactive user", that's another IP feature.
 



 
InformproSend private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Delete Pots From User Deleted 
 
Informpro wrote: [View Post]
It says "inactive user", that's another IP feature.


Correct me if I'm wrong?

Anonymous is a "user" for all want and purposes and simply needs to exist. He has no posts or anything else in any of the Db post's tables etc?

So assuming that the "deleted" user's posts have been changed to anonymous, and IF I'm not wrong, then I don't see any problems with deleting anonymous posts.

 

Either way - All Anakin wants to know is can it be done and how to do it - And any deletion of any user should be the same irrespective of who's IP he's being deleted from.

IF I had IP running - I'd create a user - Post a couple - delete him / her and find out "exactly" what happens in the DB - But I don't - - -

 
 



 
mortSend private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Delete Pots From User Deleted 
 
Imagine you delete the first post of a thread (because the author of the thread has been deleted). Could you guess what will happen ?
 



 
InformproSend private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Delete Pots From User Deleted 
 
outsch.

i forgot about that.

to much code today, did´nt think in it

that defenitly would drive the db crazy


better leave it as is,

You might go through your Forum, and delet the hole Post ( with answers) or move them all to Trash Bin

afterwards purge the Trash Bin and you should be done.

I know, this is a lot of work, speacialy if the user was very active
 




____________
Out of Order
 
spydieSend private messageVisit poster's website  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Delete Pots From User Deleted 
 
I'll think and see how it may works, at least to give it to you. But this is not my priority, so you should better do that at hand.

EDIT : in my version of IP, I have, in functions_users_delete.php, a function named ip_user_kill().
 



 
InformproSend private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Delete Pots From User Deleted 
 
yep, thats the script that rewrites/updates all tables to user_name ANONIMOUS

but it want delet any post, only PM as far as I can see
 




____________
Out of Order
 
spydieSend private messageVisit poster's website  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Delete Pots From User Deleted 
 
Informpro wrote: [View Post]
Imagine you delete the first post of a thread (because the author of the thread has been deleted). Could you guess what will happen ?


You're right - It does remove the thread.

But! if anakin isn't worried about that, here's the string he will need to do it with.

Code: [Download] [Hide] [Select]
DELETE FROM ip_posts WHERE post_username= "informpro" AND poster_id= -1;


Just change informpro to whatever the user handle is.  

It's also important that the name be inside quotes. "user name" and NOT `user name`
 



 
mortSend private message  
Back to topPage bottom
Post new topic  Reply to topic  Page 1 of 2
Goto page 1, 2  Next


Display posts from previous:    

HideWas this topic useful?

Link this topic
URL
BBCode
HTML




 
Permissions List
You cannot post new topics
You cannot reply to topics
You cannot edit your posts
You cannot delete your posts
You cannot vote in polls
You cannot attach files
You can download files
You cannot post calendar events


  

 

  cron