MyBB Community Forums

Full Version: Thumbnail of attachment in threadlist
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4 5 6 7 8
is it possible to add css support to the code? (i mean the code that we use to show the thumbnail)
^ yes, of course Smile you can modify the code like below
$attachment_thumbnail = "<div style=\"float:left\"><img class = \"thumbnailimage\" src=\"./uploads/{$thumbnail}\" /></div>"; 

(edited)
(2018-04-01, 04:24 AM).m. Wrote: [ -> ]^ yes, of course Smile you can modify the code like below
$attachment_thumbnail = "<div style=\"float:left\"><img class = "thumbnailimage" src=\"./uploads/{$thumbnail}\" /></div>"; 

thanks....

can you give us the code in case that we want to add some lines of code into a global.css to formatting the display of the thumbnail?
^ you can try adding required style properties to class thumbnailimage - like below
.thumbnailimage {width: 200px; height: 160px; border: 2px solid magenta;}
(2018-04-01, 06:20 AM).m. Wrote: [ -> ]^ you can try adding required style properties to class thumbnailimage - like below
.thumbnailimage {width: 200px; height: 160px; border: 2px solid magenta;}


the class thumbnailimage must be a new one? i'm searching css files but i can't find this class.

When i add this class how can i call it (into the .php file before the call of $attachment_thumbnail)

thanks
^ if you have modified the code segment in the php file like below
$attachment_thumbnail = "<div style=\"float:left\"><img class = \"thumbnailimage\" src=\"./uploads/{$thumbnail}\" /></div>"; 
then you can use new class style property in global.css as suggested above (post #74)

(edited)
(2018-04-01, 06:48 AM).m. Wrote: [ -> ]^ if you have modified the code segment in the php file like below
$attachment_thumbnail = "<div style=\"float:left\"><img class = "thumbnailimage" src=\"./uploads/{$thumbnail}\" /></div>"; 
then you can use new class style property in global.css as suggested above (post #74)

sorry but i receive an error message... "This page isn’t working"
:oops: please change php code modification as below
$attachment_thumbnail = "<div style=\"float:left\"><img class = \"thumbnailimage\" src=\"./uploads/{$thumbnail}\" /></div>"; 
(2018-04-01, 07:26 AM).m. Wrote: [ -> ]:oops: please change php code modification as below
$attachment_thumbnail = "<div style=\"float:left\"><img class = \"thumbnailimage\" src=\"./uploads/{$thumbnail}\" /></div>"; 

everything is working now!!!!
thanks once again my friend!!!  Smile Smile

(2014-09-25, 02:28 AM)anhmjn Wrote: [ -> ]Hi, this code working perfectly in mybb 1.8 forumdisplay.php
but how to show thumbnail of attachment in portal.php ?
Can anyone help me, please ?

i have the same question....is it possible to show thumbnail in portal?
Pages: 1 2 3 4 5 6 7 8