Is myBB parsing &hash=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
#1
Is myBB parsing 


&hash=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx


in img src tags?

I am not get a script to load in either the templates nor the myCode
Reply
#2
[Image: mascot.png?foo=bar&hash=xxxxxxxxxxxxxxxx...xxxxxxxxxx]

Working fine here. Are you sure it's an image you're loading and not a webpage displaying an image?
No longer involved in the MyBB project.
Reply
#3
Yeah, can you post the link to the image you're trying to us here?
Reply
#4
MyBB doesn't alter the image source in any way nor does it download it. Make sure that the server you are loading the image from isn't hotlink protected, a .htaccess issue on their end could very well lead to this. The easiest way is to open Dev Tools in either google Chrome or Firefox, go to the network tab and press F5. Use the search bar to search for the name of the image and inspect the response headers on the right side. Check the response code (should be "200" if you press F5) and content length (something in the thousands).
[Image: axolis.png]

Project, Portfolio and Product management for freelancers.
Reply
#5
but how do you know its NOT just ignores the hash and displays the img anyways?
Reply
#6
(2015-10-16, 06:29 AM)expat Wrote: but how do you know its NOT just ignores the hash and displays the img anyways?

   

The hash is definitely included.

Try it yourself on your own forum:

[img]http://www.mybb.com/assets/images/mascot.png?foo=bar&hash=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx[/img]
No longer involved in the MyBB project.
Reply
#7
[Image: mascot.png&hash=6c142d32eddc6c8a8e1b480706977795]

No it doesnt work
Reply
#8
Because that's not a valid URL. The first URL parameter must be prepended with a question mark, and any additional parameters must be pretended with an ampersand (&).

E.g.

[img]http://www.mybb.com/assets/images/mascot.png?hash=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx[/img]

or

[img]http://www.mybb.com/assets/images/mascot.png?foo=bar&hash=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx[/img]

Your issue could be solved in a single post if you just tell us what image you're trying to link to.
No longer involved in the MyBB project.
Reply
#9
ok i have a php script to resize the image

http://myScript.php?src=http://www.mybb.com/assets/images/mascot.png&hash=6c142d32eddc6c8a8e1b480706977795

apparently it needs the hash so not to be hacked to pieces

if i turn off the hash function in config and still leave the hash in html it works....if i turn on the hash function, then it returns a error image, as if the hash is NON-existant
Reply
#10
you need to url encode it. http://www.url-encode-decode.com/

http://myScript.php?src=http%3A%2F%2Fwww.mybb.com%2Fassets%2Fimages%2Fmascot.png&hash=6c142d32eddc6c8a8e1b480706977795

https://en.wikipedia.org/wiki/Percent-encoding
Reply


Forum Jump:


Users browsing this thread: 9 Guest(s)