2008-11-16, 11:34 AM
This tutorial will show you how to easily get image attachemtns to open in Lightbox.
This tutorial should not take any longer than 5 minutes.
This tutorial is easy to do, and everyone should be able to do it.
Step 1
Download the compressed folder and upload it to the root of your folder. The compressed file is the files needed to allow Lightbox to work. The file has been scanned for your security.
Step 2
Login to your Admin CP
Locate to "Templates & Styles" then select the "Templates" option from the sub menu to the left.
Select your template you use for your boards.
Step 3
Select the "Ungrouped Templates" option from the very bottom. Then select "headerinclude". You should now be at an editor...
Under,
Add,
Click, "Save and Return to Listing".
Step 4
Now select "Post Bit Templates" found near the middle of the page. Next select "postbit_attachments_thumbnails_thumbnail".
Once again you will be taken to an editor. Delete everything in it, and paste the following,
Click, "Save and Return to Listing"
Step 5
That's you done. Easy, eh? Now go off and try it out simply by uploading an image attachment to your post. This particular coding has allowed to all the images in one thread to link together. If you don't want it to do this simply,
Select "Post Bit Templates" found near the middle of the page. Next select "postbit_attachments_thumbnails_thumbnail".
When you see the coding simply locate,
Done.
Live Demo! - http://lightbox.forumhost.cn/index.php
This tutorial should not take any longer than 5 minutes.
This tutorial is easy to do, and everyone should be able to do it.
Step 1
Download the compressed folder and upload it to the root of your folder. The compressed file is the files needed to allow Lightbox to work. The file has been scanned for your security.
Step 2
Login to your Admin CP
Locate to "Templates & Styles" then select the "Templates" option from the sub menu to the left.
Select your template you use for your boards.
Step 3
Select the "Ungrouped Templates" option from the very bottom. Then select "headerinclude". You should now be at an editor...
Under,
<script type="text/javascript" src="{$mybb->settings['bburl']}/jscripts/popup_menu.js?ver=1400"></script>
Add,
<script type="text/javascript" src="{$mybb->settings['bburl']}/jscripts/lb/prototype.js"></script>
<script type="text/javascript" src="{$mybb->settings['bburl']}/jscripts/lb/scriptaculous.js?load=effects,builder"></script>
<script type="text/javascript" src="{$mybb->settings['bburl']}/jscripts/lb/lightbox.js"></script>
<link rel="stylesheet" href="{$mybb->settings['bburl']}/css/lightbox.css" type="text/css" media="screen" />
Click, "Save and Return to Listing".
Step 4
Now select "Post Bit Templates" found near the middle of the page. Next select "postbit_attachments_thumbnails_thumbnail".
Once again you will be taken to an editor. Delete everything in it, and paste the following,
<a href="attachment.php?aid={$attachment['aid']}" rel="lightbox[attach]"><img src="attachment.php?thumbnail={$attachment['aid']}" alt="" /></a>
Click, "Save and Return to Listing"
Step 5
That's you done. Easy, eh? Now go off and try it out simply by uploading an image attachment to your post. This particular coding has allowed to all the images in one thread to link together. If you don't want it to do this simply,
Select "Post Bit Templates" found near the middle of the page. Next select "postbit_attachments_thumbnails_thumbnail".
When you see the coding simply locate,
rel="lightbox[attach]"
Delete,[attach]
Done.
Live Demo! - http://lightbox.forumhost.cn/index.php