Thread: Major Additions - PhotoPlog: The Lite Gallery
View Single Post
  #664  
Old 01-18-2006, 10:09 PM
KayDEE KayDEE is offline
 
Join Date: Jan 2002
Posts: 14
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

@redundanthost

yes it works with 3.5.3, flawless

@natralis

yes, i've added that kinda option a while ago

open photoplog settings.php
find:
Code:
$photoplog_random_bits = $photoplog_cat_id = $photoplog_subcat_bar = $photoplog_letter_id = '';
below it add:
Code:
$photoplog_latest_bits = $photoplog_cat_id = $photoplog_subcat_bar = $photoplog_letter_id = '';
find:
Code:
// ####################### INITIALIZE LETTER BAR ##########################
above it add:
Code:
// ###################### INITIALIZE LATEST BITS ##########################

$photoplog_latest_bits = '';
if (defined('PHOTOPLOG_LATEST') && !isset($_REQUEST['c']) && !isset($_REQUEST['n']) && !isset($_REQUEST['u']) && !isset($_REQUEST['q']))
{
	$photoplog_file_infos = $db->query_read("SELECT *
						FROM photoplog_fileuploads
						WHERE moderate = 0
						ORDER BY dateline DESC
						LIMIT 3
	");

	$photoplog_cnt_bits = 0;
	$photoplog_row_top = '';
	$photoplog_row_bottom = '';

	while ($photoplog_file_info = $db->fetch_array($photoplog_file_infos))
	{
		$photoplog_cnt_bits++;

		$photoplog_fileid = $photoplog_file_info['fileid'];
		$photoplog_userid = $photoplog_file_info['userid'];
		$photoplog_username = $photoplog_file_info['username'];

		$photoplog_row_top .= "

			<td class=\"alt2\" nowrap><nobr>
			<table class=\"alt1\" width=\"100%\" border=\"0\" cellpadding=\"5\" cellspacing=\"1\">

			<td class=\"alt2\" align=\"center\" width=\"20%\">
				<a href=\"".$photoplog_location."/index.php?".$vbulletin->session->vars['sessionurl']."n=".$photoplog_fileid."\">
					<img src=\"".$photoplog_location."/file.php?".$vbulletin->session->vars['sessionurl']."n=".$photoplog_fileid."&amp;w=s\" border=\"0\" />
				</a>
			</td>

			</table>
			</td>

		";

		$photoplog_row_bottom .= "
			<td class=\"alt2\" align=\"center\" width=\"20%\">
				<div class=\"smallfont\">
					".$vbphrase['posted_by']." <a href=\"".$photoplog_location."/index.php?".$vbulletin->session->vars['sessionurl']."u=".$photoplog_userid."\">".$photoplog_username."</a>
				</div>
			</td>
		";
	}

	$db->free_result($photoplog_file_infos);

	$photoplog_table_start = "<table class=\"tborder\" border=\"0\" cellpadding=\"".$stylevar['cellpadding']."\" cellspacing=\"".$stylevar['cellspacing']."\" align=\"center\" width=\"100%\"><tr>

		<td colspan=\"5\" class=\"tcat\"><a style=\"float: ".$stylevar['right'].";\" href=\"#top\" onclick=\"return toggle_collapse('photoplog_latest_bits')\"><img id=\"collapseimg_photoplog_latest_bits\" src=\"".$stylevar['imgdir_button']."/collapse_thead".$vbcollapse['collapseimg_photoplog_latest_bits'].".gif\" alt=\"\" border=\"0\" /></a><span class=\"smallfont\"><strong>Latest Pictures</strong></span></td>

		</tr> <tbody id=\"collapseobj_photoplog_latest_bits\" style=\"".$vbcollapse['collapseobj_photoplog_latest_bits']."\"><tr>";

	$photoplog_table_end = "</tr></tbody></table><br />";

	$photoplog_latest_bits = $photoplog_table_start.$photoplog_row_top."</tr>".$photoplog_table_end;

	if (!$photoplog_cnt_bits)
	{
		$photoplog_latest_bits = '';
	}
}
open photoplog functions.php

find:
Code:
	global $photoplog_random_bits, $photoplog_cat_id, $photoplog_subcat_bar, $photoplog_letter_id;
replace with:
Code:
	global $photoplog_random_bits, $photoplog_latest_bits, $photoplog_cat_id, $photoplog_subcat_bar, $photoplog_letter_id;
open photoplog index.php

find:
Code:
define('PHOTOPLOG_RANDOM','bits');
below it add:
Code:
define('PHOTOPLOG_LATEST','bits');
open template photoplog_file_list

add to top:
Code:
$photoplog_latest_bits
done ... hope i didnt forget anything, i changed and added alotta things on it

Cheers
Reply With Quote
 
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01166 seconds
  • Memory Usage 1,783KB
  • 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
  • (9)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