Previous Thread
Next Thread
Print Thread
Hop To
Joined: Jul 2007
Posts: 103
member
member
Joined: Jul 2007
Posts: 103
Hi,

I've imported my ubb classic board, and implemented some new skins by just adding files, images, greamlins etc to the specific folders. Also overwriting any present images (like I was used to in ubb classic wink ). Now I notice some behaviour in ubb threads, that saves the image size in the database. Although this is a very cool feature, I now have an inconsistent DB not representating the reality.

I am looking for an easy way to fix this. Actually a Control panel function that is called "Recalculate Image Sizes in dabatabase" would be a very cool feature. Is there any script / resource or function I can use?

Sirdude pointed me in some code that could fix the avatar sizing issue that still is present in 7.2 that looks a little like this:
PHP Code
if (!picheight) && (!picwidth) { 
$wh = getimagesize("http://url/to/avatar.jpg"); 
if ($wh[0] > $boardmaxwidth) then { limit width; } 
if ($wh[1] > $boardmaxheight) then { limit height; } else 
{ we have a width and height here, so it is good; } 
 

Joined: Apr 2007
Posts: 3,940
Likes: 1
SD Offline
Former Developer
Former Developer
Joined: Apr 2007
Posts: 3,940
Likes: 1
hehe, that was pseudo code.. just fyi and i wrote it up quick to get the idea..

that won't actually execute.. would need to modify.. wink


Link Copied to Clipboard
ShoutChat
Comment Guidelines: Do post respectful and insightful comments. Don't flame, hate, spam.
Recent Topics
PHP 8 bug in membermanage.tmpl
by phoenix011235 - 09/08/2026 7:47 PM
Are any of these legitmate?
by Baldeagle - 09/06/2026 1:37 PM
After server reboot
by Morgan - 09/02/2026 8:27 AM
Email Settings
by Outdoorking - 05/13/2026 2:44 AM
Who's Online Now
1 members (1 invisible), 304 guests, and 96 robots.
Key: Admin, Global Mod, Mod
Random Gallery Image
Latest Gallery Images
Ride safe!
Ride safe!
by Morgan, December 7
Los Angeles
Los Angeles
by isaac, August 6
3D Creations
3D Creations
by JAISP, December 30
Artistic structures
Artistic structures
by isaac, August 29
Powered by UBB.threads™ PHP Forum Software 8.1.0
(Snapshot build 20260527)