well i think u should check the posting settings makes sure u have enabled the thumbnails
regards
They are turned on, but the attachments still do not show.
well if u wanna show the picture, get its URL then edit ur post, post it there as imgage
then it will appear
also try this , while editing scroll down till u reach the upload part, and there u will find add to post/thread . then the thumbnail should appear
regards
even when i add it to the post, i still see no thumnail - is it a permitions problem perhaps?
yeah, they are all correct.
in a post i can see that there is an attachment - i can even download it, but i see no thumbnail.
yeah, i know thats possible- buit its not what i want. Should the thumnail not show itself anyway?
well actually an image will be automaticly posted as thumbnails in any thread if you have set it to YES in the posting settings.
well anyway , i have registred in ur forum, i'm gonna check it
regards
edit
hey check these in template
postbit_attachments_thumbnails:
Code:
<span class="smalltext"><strong>$lang->postbit_attachments_thumbnails</strong></span><br />
$post[thumblist]
<br />
postbit_attachments_thumbnails_thumbnail:
Code:
<a href="attachment.php?aid=$attachment[aid]" target="_blank"><img src="attachment.php?thumbnail=$attachment[aid]" class="attachment" alt="" /></a>
postbit_attachments_images:
Code:
<span class="smalltext"><strong>$lang->postbit_attachments_images</strong></span><br />
$post[imagelist]
<br />
postbit_attachments_images_image:
Code:
<img src="attachment.php?aid=$attachment[aid]" class="attachment" alt="" />
also
check ur attachment.php
PHP Code:
<?php
/**
* MyBB 1.0
* Copyright � 2005 MyBulletinBoard Group, All Rights Reserved
*
* Website: http://www.mybboard.com
* License: http://www.mybboard.com/eula.html
*
* $Id: attachment.php 649 2005-08-30 06:03:31Z chris $
*/
define("KILL_GLOBALS", 1);
require "./global.php";
if($mybb->input['thumbnail'])
{
$aid = intval($mybb->input['thumbnail']);
}
else
{
$aid = intval($mybb->input['aid']);
}
$plugins->run_hooks("attachment_start");
$pid = intval($mybb->input['pid']);
if($aid)
{
$query = $db->query("SELECT * FROM ".TABLE_PREFIX."attachments WHERE aid='$aid'");
}
else
{
$query = $db->query("SELECT * FROM ".TABLE_PREFIX."attachments WHERE pid='$pid'");
}
$attachment = $db->fetch_array($query);
$pid = $attachment['pid'];
if(!$tid)
{
$query = $db->query("SELECT tid FROM ".TABLE_PREFIX."posts WHERE pid='$pid'");
$post = $db->fetch_array($query);
$tid = $post['tid'];
}
$query = $db->query("SELECT * FROM ".TABLE_PREFIX."threads WHERE tid='$tid'");
$thread = $db->fetch_array($query);
if(!$thread['tid'] && !$mybb->input['thumbnail'])
{
error($lang->error_invalidthread);
}
$fid = $thread['fid'];
$forumpermissions = forum_permissions($fid);
if(($forumpermissions['canview'] == "no" || $forumpermissions['candlattachments'] == "no") && !$mybb->input['thumbnail'])
{
nopermission();
}
if(!$attachment['aid'] || !$attachment['attachname'])
{
error($lang->error_invalidattachment);
}
if(!$mybb->input['thumbnail']) // Only increment the download count if this is not a thumbnail
{
$db->query("UPDATE ".TABLE_PREFIX."attachments SET downloads=downloads+1 WHERE aid='$attachment[aid]'");
}
$attachment['filename'] = rawurlencode($attachment['filename']);
$plugins->run_hooks("attachment_end");
header("Content-disposition: filename=$attachment[filename]");
if($mybb->input['thumbnail'])
{
$ext = getextention($attachment['thumbnail']);
switch($ext)
{
case "gif":
$type = "image/gif";
break;
case "bmp":
$type = "image/bmp";
break;
case "png":
$type = "image/png";
break;
case "jpg":
case "jpeg":
case "jpe":
$type = "image/jpeg";
break;
default:
$type = "image/unknown";
break;
}
header("Content-type: ".$type);
$thumb = $settings['uploadspath']."/".$attachment['thumbnail'];
header("Content-length: ".@filesize($thumb));
echo file_get_contents($thumb);
}
else
{
header("Content-type: $attachment[filetype]");
header("Content-length: $attachment[filesize]");
echo file_get_contents($settings['uploadspath']."/".$attachment['attachname']);
}
?>
i think u might have this part missing :
PHP Code:
header("Content-disposition: filename=$attachment[filename]");
if($mybb->input['thumbnail'])
{
$ext = getextention($attachment['thumbnail']);
switch($ext)
{
case "gif":
$type = "image/gif";
break;
case "bmp":
$type = "image/bmp";
break;
case "png":
$type = "image/png";
break;
case "jpg":
case "jpeg":
case "jpe":
$type = "image/jpeg";
break;
default:
$type = "image/unknown";
break;
}
regards