1
bmolloy
How do I find original attachments names in the database?
  • 2009/2/7 16:11

  • bmolloy

  • Just popping in

  • Posts: 2

  • Since: 2009/2/7 1


I'm trying to download all attachments from newbb with their original file names, but it seems XOOPS randomizes the names...

In uploads/newbb I have several files like this:

5_4862cdec4b5dc.doc
5_4862d19a99185.doc
5_4862d890bde2c.doc
5_4887a2c2d5913.doc
5_4937195eb6c37.doc
6_487d41fecc821.docx

In the attachment field in xoops_bb_posts I have attachment as:

YToxOntpOjEyMzE5NDM1MTE7YTo0OntzOjEwOiJuYW1lX3NhdmVkIjtzOjE5OiI4XzQ5NmRmNzU3M
jNiZGIuZG9jIjtzOjEyOiJuYW1lX2Rpc3BsYXkiO3M6NTY6IkUtR3VhcmRzIFZlcm8gQmVhY2ggU3
Vic3RhdGlvbiAjOCBTY2FyZWNyb3cgU25hcHNob3QuZG9jIjtzOjg6Im1pbWV0eXBlIjtzOjE4OiJ
hcHBsaWNhdGlvbi9tc3dvcmQiO3M6MTI6Im51bV9kb3dubG9hZCI7aTo0O319

Yet the original post might say "Site Survey.doc"

So how do I download all of the attachments and figure out what their original file names were when they were attached?

2
ghia
Re: How do I find original attachments names in the database?
  • 2009/2/7 18:42

  • ghia

  • Community Support Member

  • Posts: 4953

  • Since: 2008/7/3 1


bmolloy, welcome on the XOOPS forum!

Did you have a look in the bb_attachments table?

3
bmolloy
Re: How do I find original attachments names in the database?
  • 2009/2/10 16:30

  • bmolloy

  • Just popping in

  • Posts: 2

  • Since: 2009/2/7 1


This was my first place to look, though the table is completely empty.

4
ghia
Re: How do I find original attachments names in the database?
  • 2009/2/11 9:11

  • ghia

  • Community Support Member

  • Posts: 4953

  • Since: 2008/7/3 1


They are in the attachment field of bb_posts as a base64 encoded serialized array. (see eg /class/post.php)

Login

Who's Online

479 user(s) are online (353 user(s) are browsing Support Forums)


Members: 0


Guests: 479


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Nov 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits