1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

XF 1.5 How to find what post or forum an image is posted in?

Discussion in 'Troubleshooting and Problems' started by marcv, May 19, 2016.

  1. marcv

    marcv Member

    Trying to isolate a permission issue where all guest permissions are set to explicitly allow viewing attachment but this image won't show for guest.


    Is there a way from the image name to locate which post or forum this is in so I can check the node permissions for it to see if there is some permission that is off on the node?
  2. ENF

    ENF Well-Known Member

    You can go to your AdminCP and take a look at the attachment browser.

    AdminCP > Applications > Attachment Browser

    You can find the attachment in that list and it will show where it's posted in the column to the right. (conversation, post, etc.)

    And just FYI for external images and if you're using the image proxy system, you can do the same in the Tools section 'Image Proxy Log'.
  3. marcv

    marcv Member

    Problem with attachment browser is if you have 10's of thousands of images the visual page by page search is needle in a haystack. Need something direct. How to decipher the image name and what post points to it. maybe a query or something
  4. AndyB

    AndyB Well-Known Member

    You will need to use phpMyAdmin.

    Look at the xf_attachment table, the attachment_id is 958. The data_id is the post number.
    marcv likes this.
  5. marcv

    marcv Member

  6. Chris D

    Chris D XenForo Developer Staff Member

    data_id is the xf_attachment_data ID it is not the post number.

    In the xf_attachment table you will see a content_type field (which should be post, in this case) and a content_id field, the content_id will be the post ID.

    marcv and AndyB like this.
  7. marcv

    marcv Member

    Awesome. You helped me track it down. Looks like this post was moderated so guest could not see but we could as admin. Found the image and some others on google webmasters as errored images and could see that guests were unable to view them. Wasn't sure if it was a permission issue or something like this so thanks to your advice we verified this so everything is working logically!


Share This Page