Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
+1 vote
746 views
in Q2A Core by
edited by

I know that most websites use HTTPS protocols nowadays, but I've encountered the following bug.

I've noticed that different Avatar Blob sizes won't load consistently to everybody on HTTP protocol.
The weird thing is that for example, a image with "&qa_size=52" might load fine for me on this device, but if I change browsers or change to a different device, that same image won't load, but others will, and vice-versa.

No webpage was found for the web address: http://mywebsite.com/?qa=image&qa_blobid=8419242312434086559&qa_size=52

HTTP ERROR 404 

  • This problem doesn't seem to occur locally on Localhost.
  • Also, "&qa_size=100" is the only size that seems to be working consistently for everybody.
  • Caching is also disabled.
  • On HTTPS seems to be working fine, as if we open my avatar here for example, and give it a random size, this problem doesn't happen.
    But if you open this avatar here, and give it a random size (52 for example), it throws out a 404 page.
  • Tried with different themes and the result is the same.
Q2A version: 1.8.8

1 Answer

+1 vote
by
selected by
 
Best answer

On HTTPS seems to be working fine

Not really, take a look at this: https://polaris.unaux.com/?qa=image&qa_blobid=1536534528642848890&qa_size=123

This suggests you've setup the server (or upgraded PHP) without the GD library.

PS: There seems to be some kind of SSL error as well.

by
Ahh ok. Yeah that makes sense. I'll open a ticket on the server provider then.
Oh no, I was talking about question2answer.org/qa , that's working fine. That website doesn't have an SSL .
by
Can we change the image URL from this: http://mywebsite.com/?qa=image&qa_blobid=8419242312434086559&qa_size=52
to this: http://mywebsite.com/image/8419242312434086559.png?

I'm asking because the current Q2A setup, which stores images as blobs in the database, creates too much load on the database in case the website traffic is high. If we change the image URL to direct image links by storing the images in AWS S3 storage, there will be a significant performance improvement on the Q2A site.

Can we create a plugin or make changes to the Q2A core to modify the image URLs and store images on S3 rather than in the database as blobs?
...