i have this issue with the text files showing instead of pictures with this npf format...i tried your tips on how to solve it in my theme but it didnt work out...what am i doing wrong?
heya! i took a look at your theme and it seems like the solution i posted is for a different issue to yours!
(skip to the end for the code)
your issue with text files showing instead of pictures is actually intentional and seems to be how the theme was designed. the way the posts are displayed depends on their post type (text posts, video posts, chat posts, etc.). for text posts, it will display either the title of the post or simply “Text Post” (if the post doesn’t have a title) inside a coloured circle.
npf posts don’t have types, so when someone posts a photo using tumblr’s mobile app, it’s treated as a text post. this becomes more obvious when comparing reblogs of photo/npf posts:
i tweaked the theme a little bit so that npf posts with photos in them now display a little more like normal photo posts. to be more specific:
any text post that starts with an image will have a thumbnail of that image.
the image used for the thumbnail will be whatever the first image in the post is.
if the post doesn’t contain an image, it won’t have a thumbnail.
if the post has a title or any text above the image, it won’t have a thumbnail.
if the post has any text below the image, it will have a thumbnail.
a thumbnail will only be shown if the image is in the original post.
all of this only applies to text posts
here’s an example of what it looks like:
i’ve added in two theme options:
SHOW THUMBNAILS ON TEXT POSTS - enabled by default. if you’re having issues, turn it off to completely disable any edits i’ve done
LOAD HQ THUMBNAILS - disabled by default. turn it on to use the original image resolution. can make load times considerably slower, depending on how large the original image is
you can get the code here.
let me know if you need help with anything or want me to change something else!