Thread: Major Additions - VB image Hosting
View Single Post
  #226  
Old 09-19-2006, 08:57 PM
toolblast's Avatar
toolblast toolblast is offline
 
Join Date: Mar 2004
Posts: 266
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Suggestion:
I would like there to be comments and rating added to the images when you view them in 'full view' only. This would be great!

IMPROVEMENT:
I have edited the imagebit somewhat. In the original script... all users always see that bbcode, permissions, and other stuff that for the user who owns the photos may be useful, but for other users it just seems to clutter up the photo gallery page in my opinion.

I was wanting something more like Facebook... where if they go to view their friend's gallery... it simply shows a gallery page with a bunch of thumbnails only... no details or stuff underneath. However, I didn't want to remove this stuff, so what I did was edited the template and added an extra condition so that:

1) When viewing photos, if the photos belong to the user that is logged in... they see all that extra bbcode and permission stuff underneath the photo.

2) For OTHER users viewing photos that belong to their friends... they will just see the gallery page with only the photo thumbnails listed.

3) In either case... clicking the thumbnail will open up the main view page and will have the large photo, and will have all the bbcode stuff showing.. but only when the image is viewed in the fullscreen size page.


CODE CHANGES:

OPEN template called "vbimghost_imgbits"

Delete everything in that template, and replace it with this:

Code:
<td>
	<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0">
	<tr>
		<td class="alt1" align="center" valign="center"><a href="$vbimghost[dispath]"><img src="$vbimghost[thumbpath]" <if condition="$vbimghost[thumbsize]!=0"> width="$vbimghost[thumbsize]"</if> border="0"></a></td>
	</tr>

<if condition="$vbimghost[private]!=None">
	<tr>
			<td class="alt2" align="center" valign="center">
				<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0">
					<thead>




						<tr>
							<td class="thead" colspan="2">$vbimghost[imgname]</td>
						</tr>
					</thead>
					<tbody>
						<tr>
							<td class="alt1">$vbphrase[vbimghost_filesize]</td>
							<td class="alt2">$vbimghost[filesize] </td>
						</tr>
						<tr>
							<td class="alt1">$vbphrase[vbimghost_imgdime]</td>
							<td class="alt2">$vbimghost[width] x $vbimghost[height] </td>
						</tr>
						<tr>
							<td class="alt1">$vbphrase[vbimghost_update]</td>
							<td class="alt2">$vbimghost[date] </td>
						</tr>
						<tr>
							<td class="alt1">$vbphrase[vbimghost_imgdlink]</td>
							<td class="alt2"><input type="text" value="[img]$vbimghost[path][/img]"></td>
						</tr>
						<tr>
							<td class="alt1">$vbphrase[vbimghost_imgflink]</td>
							<td class="alt2"><input type="text" value=""></td>
						</tr>
						<tr>
							<td class="alt1">$vbphrase[vbimghost_imglink]</td>
							<td class="alt2"><input type="text" value="<a href='$vbimghost[dispath]' border=0><img src='$vbimghost[thumbpath]'></a>"></td>
						</tr>
						<tr>
							<td class="alt1">$vbphrase[vbimghost_perm] </td>
							<td class="alt2">$vbimghost[private]</td>
						</tr>
					</tbody>

				</table>
			</td>
	</tr></if>
	</table>
</td>

VIEW THIS IN ACTION: http://www.undrgrads.com/vbimghost.p...iewimages&id=3
Reply With Quote
 
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01239 seconds
  • Memory Usage 1,780KB
  • Queries Executed 11 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD_SHOWPOST
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_code
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_box
  • (1)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit_info
  • (1)postbit
  • (1)postbit_onlinestatus
  • (1)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • reputationlevel
  • showthread
Included Files:
  • ./showpost.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showpost_start
  • bbcode_fetch_tags
  • bbcode_create
  • postbit_factory
  • showpost_post
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • showpost_complete