Version: 1.00, by vtx1800
Developer Last Online: Feb 2012
Version: 3.5.3
Rating:
Released: 01-21-2006
Last Update: Never
Installs: 1
Code Changes
No support by the author.
This is my first attempt on vB code changes, so I hope this works. I also believe this should be a vB ACP feature in the near future.
Credit: I was reading this thread and decided to make this hack. I used it as a place to start and make my version.
What this does: What this will do is restrict images that a user posts that are not hosted on a user defined server.
1. All images not hosted on a defined server will be set to 100x100.
2. User can set the host domain to allow normal image sizes.
Reason for this: I wanted this code to prevent a user from posting a huge image and cause the forum layout to get destroyed. I hated it when a image size of 1024x768 gets posted and my forums width is only 700px.
To install: I don't know how to make a plugin, so it's all via editing the "class_bbcode.php" file in the /includes folder.
You must change the "allowedDomain" text to be the site you want to allow. So, if you want to allow http://www.putfile.com, do not include the 'http' or 'www'.
Hope this is useful to all of you, I know it's something I was looking for, but never found. If it is on the site, sorry, I can't seem to find much with the search feature.
If you like it, please click INSTALL if you use it.
All comments are welcome, as this was my first attempt and would like to make more.
Show Your Support
This modification may not be copied, reproduced or published elsewhere without author's permission.
Regardless of what you do they are still using the [IMG] tag so all images signatures included will be resized. I mad a slight modification to the code in my post that allows any image over 500ox to be resized down to 150 or whatever and that allows my signatures to be up to 400-500 size plenty for users..
Though an Ideal fix would be to create something that ignores the img tag when used within the $signature tag.. I am working on this and having some success.
Regardless of what you do they are still using the [IMG] tag so all images signatures included will be resized. I mad a slight modification to the code in my post that allows any image over 500ox to be resized down to 150 or whatever and that allows my signatures to be up to 400-500 size plenty for users..
Though an Ideal fix would be to create something that ignores the img tag when used within the $signature tag.. I am working on this and having some success.
I have the code (very different that this one) to fix the images in the posts, but not the sig. The code works perfectly. Problem is, in 3.5.3, it is causing a double post in the quick reply. ggiersdorf, you want to team up with me and help figure this out?
Wouldn't it be better to implement an image auto-resize client side with javascript? That way a user can click to enlarge it, the aspect ratio would be correct, and it wouldn't have any server impact. It looks like this one has no server impact, but it produces ugly thumbs and I don't think its really an improvement over the one you copied it from at all (with the exception of ignoring a user specified server). The one you copied it from maintaned the aspect ratio.
Wouldn't it be better to implement an image auto-resize client side with javascript? That way a user can click to enlarge it, the aspect ratio would be correct, and it wouldn't have any server impact. It looks like this one has no server impact, but it produces ugly thumbs and I don't think its really an improvement over the one you copied it from at all (with the exception of ignoring a user specified server). The one you copied it from maintaned the aspect ratio.
-vissa
Thats why the credited version would be better for you.
I could care less about the ratio when a person hosts huge images. Plus, I want it crushed, so the members will know the image is off my server and not, well, approved. I removed the link from this, but it would be an easy add to get an href added.
Is there anyway to do this just by width so that the image doesn't lose aspect ratio? I hate it when folks break my designs with big ole images, but I don't want to torture their images either... just curious.