Resolved x10 Hosted images not working on forums

Status
Not open for further replies.

blakessa

New Member
Messages
24
Reaction score
1
Points
3
Hey guys.. been with x10 hosting for years now.. website is working fine but I just noticed in some of my old forum posts that images I had hosted on x10 (for use with my x10 website but also in forums) are no longer displaying in these forums (they'd been displaying fine for YEARS until now). When I copy and paste the image address into a new browser window it loads just fine, but none of them will work on forums anymore. I haven't changed anything as these are old forum posts from years ago. I've checked my old posts across multiple sites and all images hosted by x10 are not displaying. I only noticed this a couple of days ago so maybe its a temporary issue that will resolve itself but something is up as this has never been an issue for me in the past. Hope your domain hasn't been reported to some global forum spam blocking list or something.

EDIT: Wow see below.. even here on your own forum x10 hosted images will not load in a post (only work when opened separately in a new window).

TEST AREA:
Bonus01.png
GScreenshot01.png
Screenshot04.png
GScreenshot02.png
GScreenshot07.png
Screenshot12.png
Screenshot05.png
GScreenshot03.png


.
 
Last edited:

Anna

I am just me
Staff member
Messages
11,750
Reaction score
581
Points
113
My guess would be that it relates to hotlink protection, a directive in .htaccess that basically say that only your domain is allowed to display the images, which would explain why they work opened in a separate window as that is displaying them on your URL.

For the SMF forums it works they may have a setup where they make a local copy rather then utilize your domains bandwidth to display them.

Check if your .htaccess have something similar to this :
Code:
RewriteEngine on 
RewriteCond %{HTTP_REFERER} !^$ 
RewriteCond %{HTTP_REFERER} !^https://(www.)?my-website.com/.*$ [NC] 
RewriteRule .(jpg|jpeg|gif|png|bmp)$ - [F]
 

blakessa

New Member
Messages
24
Reaction score
1
Points
3
My guess would be that it relates to hotlink protection, a directive in .htaccess that basically say that only your domain is allowed to display the images, which would explain why they work opened in a separate window as that is displaying them on your URL.

For the SMF forums it works they may have a setup where they make a local copy rather then utilize your domains bandwidth to display them.

Check if your .htaccess have something similar to this :
Code:
RewriteEngine on
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^https://(www.)?my-website.com/.*$ [NC]
RewriteRule .(jpg|jpeg|gif|png|bmp)$ - [F]

Hi Anna,

Hmm why would it change on it's own though? I've never had a problem with images hosted at x10 displaying in certain places and then recently that just mysteriously changed.

It's not something I've changed as I'm not a programmer so I don't mess with any of that stuff. I just upload my simple html files and pictures into my website folder and don't dare to touch anything else as all that fancy web coding security stuff is way beyond me lol. I just did a search of my hosted files and folders and I don't even seem to have an .htaccess file or folder in my account. All that comes up in the file search is a htaccess_cache file in a .cl.selector folder.
 
Last edited:

spacresx

Community Advocate
Community Support
Messages
2,199
Reaction score
195
Points
63
@blakessa
the htaccess Anna referred to should be in your x10 websites
root/domains/your-domain/public_html directory.

just a heads up on your wordpress link, i get a "Secure Connection Failed"
"The page you are trying to view cannot be shown because the authenticity
of the received data could not be verified." im using an older firefox esr.
but works ok in internet explorer.
 

blakessa

New Member
Messages
24
Reaction score
1
Points
3
@blakessa
the htaccess Anna referred to should be in your x10 websites
root/domains/your-domain/public_html directory.

just a heads up on your wordpress link, i get a "Secure Connection Failed"
"The page you are trying to view cannot be shown because the authenticity
of the received data could not be verified." im using an older firefox esr.
but works ok in internet explorer.

Hi there, yeah that's the first place I looked in both ftp and then in the x10 web file viewer, it's not there. So then I did a search (using the x10 web file viewer) from the root folder of my entire hosted files and folders. All it found was that cache file I mentioned above. It's not there lol, unless its hidden from me in some way. If this a file a user creates then that's why it's not there as I've never heard of it before lol. If it's a file that x10 creates on all users public folder then I don't know why I can't see it.

Even if it is there hidden away why would it change on its own? The pictures have been loading for years up until a few weeks ago lol. I haven't touched anything like that. Like I said above I just drag and drop my pictures and my html files using an ftp program and I don't touch any of that fancy stuff.

As for wordpress.. wonderful.. more good news.. that's another site that does all the work for you and I don't touch any code so I dunno what's wrong with that. It loads fine in every browser I have (Chrome, Firefox, Safari, Edge, IE) but mine are all latest/final versions. Even if it did stuff up for me I wouldn't know what to do about it, it's a post on one of the largest blog sites in the world lol.

Why don't things just work.. and stay working lol. :lol::lol::lol:
 

spacresx

Community Advocate
Community Support
Messages
2,199
Reaction score
195
Points
63
@blakessa
Yeah It sounds like your missing the .htaccess file completely.
many sites dont have it by default, but usually end up needing one.
maybe staff can help you with that.

Creating the .htaccess file is easy,
(use file managers create new file, save it as .htaccess)

The hard part part is knowing what code you need to put inside it.
as every website has different needs.

maybe there was a time just putting something on the internet would work.
but they like changing stuff all the time to make it more complicated for us.
 

blakessa

New Member
Messages
24
Reaction score
1
Points
3
Yeah I was thinking the same thing last night.. if someone gave me a basic .htaccess file I can see if that fixes the issue. Or as you say maybe just making the file myself and sticking in @Anna 's code from above might be enough? Does the file actually NEED to have anything else in it? As I'm quite happy with how my website operates, I just need this weird new hosted image shared on on forums issue to go away as it's mucked up all my old posts lol!

I fear that code Anna posted needs 'something' wrapped around it so just pasting it into a text file and renaming it won't be enough lol.

Also I'm not sure whether Anna's code is an example of what the problem is or what it should be to get things working?
 
Last edited:

blakessa

New Member
Messages
24
Reaction score
1
Points
3
okay I found this.. and used their code to make a .htaccess file.
https://www.hostinger.com/tutorials/locate-and-create-htaccess

Tested it and my website seemed fine, nothing changed, checked my old forum posts and the images still didn't load.

So then I replaced their stuff with Anna's stuff (but keeping their if module tags around it) and yeah.. bad stuff happened lol! The forum pictures problem remained but now all the images stopped loading on my website itself! Eeek!

I quickly deleted the file lol!

So yeah.. I still need rescuing lol. Or the source of the mystery change needs to be found!

EDIT: Oh and I had a look at my wordpress images addresses and noticed it's automatically putting it's own domain into the addresses (as I sure as hell didn't put it in there lol) which I guess is why it's working there..

https://i2.wp.com/blakessanctum.x10.mx/Mods/QFG43D/Bonus01.png

So if I'm right in that I never had an htaccess file (due to not being given or creating one myself due to not know about it) and that I've touched and changed nothing.. then what could happen to my domain to stop it working as it did before?

Did some forums maybe roll out some update that blocks images at http domains? I haven't converted to https as I have no friggin idea how to do that.
 
Last edited:

spacresx

Community Advocate
Community Support
Messages
2,199
Reaction score
195
Points
63
The code that Anna posted was to stop people from hot linking images.
she wanted to make sure you did not have something like that,
because it might of prevented you from doing it to.

as i said everyone's website is different and has different uses
for an htaccess file.

I have a basic one that works for me.
here is my basic htaccess file,
just put this code in yours.

#---------------
# Protect files.
#---------------
#
<Files .htaccess>
Order deny,allow
Deny from all
</Files>
#
DirectoryIndex index.php
IndexIgnore *

the 1st part of the code tells me to protect the .htaccess file,
that stops outside people from viewing my htaccess file,
so its for my eyes only.

the 2nd part directoryindex says i use a index.php file
as my start page. (just change it if you have index.html)
so when ever someone visits my website using www.mysite.com
my index.php file is the 1st file they get automatically.

The indexignore * stops people from getting a listing of my files.
you might have seen some websites that start with text like Index of:
with a list of files and folders, thats because they dont use the code.
and it makes their site vulnerable not to have it.

the hashtags (#) allows you to add a space to add text.
or notes to tell yourself what the code does.
it prevents added text from getting identified as code.
the hashtag needs to be on every line that you add code.

as ive said before, not every website is the same,
so some may not want an htaccess file or the code,
this is just code i use for mine, it works for me.
its up to you if you try it.
 

spacresx

Community Advocate
Community Support
Messages
2,199
Reaction score
195
Points
63
Did some forums maybe roll out some update that blocks images at http domains? I haven't converted to https as I have no friggin idea how to do that.

thats something that wordpress does automatically, its in the code.
(it shouldnt but it does)
 

Anna

I am just me
Staff member
Messages
11,750
Reaction score
581
Points
113
weirdly they still work fine on my Wordpress blog.. however not a single forum I've tried so far works so this is definitely some type of x10 versus forums thing lol!
https://blakessanctum.wordpress.com/2016/12/03/star-trek-doom-project-demo-4-2016-gzdoom-mod/

EDIT: Hmm also on some SMF (simple machines) hosted forums my images still load too. No luck anywhere else though.
Hi Anna,

Hmm why would it change on it's own though? I've never had a problem with images hosted at x10 displaying in certain places and then recently that just mysteriously changed.
I didn't realize that the blog you spoke of is NOT hosted by us, since the images work there the issue has nothing to do with hotlink protection. I assumed you had it installed on your account and was basically linking images from there on the other sites.

EDIT: Oh and I had a look at my wordpress images addresses and noticed it's automatically putting it's own domain into the addresses (as I sure as hell didn't put it in there lol) which I guess is why it's working there..

https://i2.wp.com/blakessanctum.x10.mx/Mods/QFG43D/Bonus01.png

So if I'm right in that I never had an htaccess file (due to not being given or creating one myself due to not know about it) and that I've touched and changed nothing.. then what could happen to my domain to stop it working as it did before?

Did some forums maybe roll out some update that blocks images at http domains? I haven't converted to https as I have no friggin idea how to do that.
I think you are onto something here, to actually pass as true secure site none of the contents can come from a non secure source. It is resonable to assume that the forums where the images no longed work has had updates that are blocking non-secure content for that very reason.

Unfortunately with free hosting you can not use proper ssl and get a secure (https) site. If you have your own domain you can achieve it through cloudflare or other similar services however.

Wordpress probably takes a copy and puts on their content distribution network to ensure speedy loading and make sure the images are loaded through secure protocol (https). This would also ensure sure the images that are linked from other sites always load properly even if that other site goes down temporarily.
 

blakessa

New Member
Messages
24
Reaction score
1
Points
3
Thanks @spacresx I'll have to have a play with that.

@Anna ah yes sorry I should have made it clearer that my Wordpress blog was literally hosted by Wordpress themselves and not on my x10 hosted space where I keep my main website http://blakessanctum.x10.mx/ .

Omg I was actually right about the https thing? Amazing haha!

hmm so there's not much I can do about the secure https thing hey. I'd been wondering if it was just a lack of knowledge or if it was not possible with x10.

Hmm well I did come up with a work around to simply stick that https://i2.wp.com/ in front of all my image links on the affected forums and sure enough they now work fine haha. So as long as Wordpress doesn't go anywhere I'll use this workaround for my x10 images haha! I am using imgur and moddb image hosting for most stuff now days so it's more just all my legacy forum posts (which there's a truck load of) that have been affected by this change!
 
Status
Not open for further replies.
Top