News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

ID_ATTACH in smf_members?

Started by packman, September 13, 2004, 04:43:25 PM

Previous topic - Next topic

packman

[Unknown] - I think last time you looked at the phpBB2 converter you added the comment to the section that copies user avatars into SMF...

        // Technically, these should go in attachments/, with each member's ID_ATTACH set properly...

There isn't an ID_ATTACH field in my smf_members table. Is this new in the next release?
Chris

Ben_S

ID_ATTACH is in the messages table.
Liverpool FC Forum with 14 million+ posts.

packman

Quote from: Ben_S on September 13, 2004, 05:22:47 PM
ID_ATTACH is in the messages table.

I'd spotted that one, but I can't see a connection between user uploaded avatars and the messages table. Unknown's comment suggested that uploaded avatars go into the attachments directory (which would make sense), but I can't work out how you'd then find the uploaded avatar for a specific member.
Chris

[Unknown]

Actually, the only ID_ATTACH is on the attachments table.  There is no ID_ATTACH on the messages table. (or, there shouldn't be!)

Actually, in this case, for a variety of reasons... there's an ID_MEMBER on attachments.  If it is not zero, it means this attachment is actually an avatar.  It works just like an attachment (although it's always named avatar_ID_MEMBER.(png|jpeg)...).  The ID_MSG should, of course, be 0.

-[Unknown]

packman

You're right...there isn't an ID_ATTACH on the messages table. I'm starting to see imaginary things...should I see a psychiatrist ::)

Just to confirm...a gif avatar for user 1234 should be called avatar_1234.gif ??
Chris

packman

No need to confirm. I've worked out what's required and the converter now correctly handles uploaded avatars :)
Chris

Advertisement: