PDA

View Full Version : Programmatically editing a post


dharris
04-16-2008, 11:23 PM
How would i go about programatically adding a preset message to the end of a post?

Will be used in a custom ban system, which will add "User was banned for this post by MOD_USERNAME for LENGTH_OF_BAN. Reason given: REASON" to the end of a certain post. I have the postID sorted out, i can probably figure out most of it myself, but it would save a lot of time if you'd tell me how i can take the information (the message, the post id etc) and edit the correct post in the correct way. I just want to add the message to the end, not overwrite it.

Thanks in advance.

Reeve of shinra
04-17-2008, 12:11 AM
Where is the ban info being stored -- or is it a generic phrase that should show up is a post has been flagged?

I guess what im saying is that we need just a wee bit more info about how this looks in the db.

dharris
04-17-2008, 12:43 AM
I just need to know how to get the contents of a post and then add a string to the end.

Everything else is so far under control.
I know the database structure and all that, but i just need to know how to basically add a string to the end of a record of a field.