Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.5 > vBulletin 3.5 Add-ons

Reply
 
Thread Tools
Phototopost features block on forumhome Details »»
Phototopost features block on forumhome
Version: 1.00, by Delphiprogrammi Delphiprogrammi is offline
Developer Last Online: Aug 2015 Show Printable Version Email this Page

Version: 3.5.4 Rating:
Released: 03-29-2006 Last Update: 03-29-2006 Installs: 47
Uses Plugins Template Edits
 
No support by the author.

hi people,

I see people who are heavenly modifying there boards to get this done.This is actually not needed.Photopost includes a files that does this automatically

1)install the plugin
2)tempate modification

template FORUMHOME find this code

HTML Code:
<!-- /main -->
<br />
<br />
replace with

HTML Code:
<!-- /main -->
 
<br />
$photopostfeature
<br />
remember to modify the path to inc_features.php(this is a PhotoPost file) if your photopost installation is different from mine

that's all

enjoy
all done no more modifications to the original vb files needed

possible problems
Question:After installation i get an error message like

Quote:
Warning: mysql_fetch_row(): supplied argument is not a valid MySQL result resource in /photopost/inc_features.php on line xx

Warning: mysql_fetch_row(): supplied argument is not a valid MySQL result resource in /photopost/inc_features.php on line xx
Answer:This Could be because you did not set a value for the $ppdbprefix (database table prefix) Photopost uses.Open your config-int.php and set the correct value for the $ppdbprefix variable

You can also set this in your Photopost Administration panel under "edit integration" (PhotoPost Database Table Prefixes) field

question i don't know what my path should be can you help me ?

PHP Code:
<?php
phpinfo
(INFO_VARIABLES);
?>
and look at the value of $_SERVER['PATH_TRANSLATED']; this is the serverpath to the file you are currently vieuwing within your webbrowser when you are done remove this file from your server (security )

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #72  
Old 10-10-2006, 09:44 AM
PSDPlayer PSDPlayer is offline
 
Join Date: Jun 2006
Posts: 10
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Dark s.s. Trunk
Code:
userinfo['usergroupid']; if ( $vbulletin->userinfo['membergroupids'] != "" ) $mygroups .= ",".$vbulletin->userinfo['membergroupids']; } $grouparr = explode( ",", $mygroups ); $resultb = mysql_query("SELECT id,ugnoview FROM {$pp_db_prefix}categories"); $ViewPerm = array(); while ( list( $catugid, $ugnoview ) = mysql_fetch_row($resultb) ) { $noview=0; $ViewPerm[$catugid] = 1; $allnoview = explode( ",", $ugnoview ); foreach ($allnoview as $key) { if (in_array($key, $grouparr) ) { $noview=1; } } if ( $noview == 0 ) { $ViewPerm[$catugid]=0; } } } function pp_get_ext( $filename ) { return substr($filename, strrpos($filename,".")); } function pp_is_image( $filename ) { $retval = 0; $mediatypes = array( ".jpg", ".gif", ".png", ".bmp" ); $ext = pp_get_ext( $filename ); if ( in_array(strtolower($ext), $mediatypes) ) $retval = 1; return( $retval ); } // // Featured Photos Code // Follow down to End Feature Photos Code // switch ($q_switch) { case "most_view": $query = "SELECT p.id,p.user,p.userid,p.cat,p.bigimage,p.height,p.width,c.catname,c.photos,c.posts FROM {$pp_db_prefix}photos p LEFT JOIN {$pp_db_prefix}categories c ON c.id = p.cat WHERE c.cattype = 'c' AND p.cat != 500 AND p.storecat = 0 ORDER BY views DESC"; break; case "latest": $query = "SELECT p.id,p.user,p.userid,p.cat,p.bigimage,p.height,p.width,c.catname,c.photos,c.posts FROM {$pp_db_prefix}photos p LEFT JOIN {$pp_db_prefix}categories c ON c.id = p.cat WHERE c.cattype = 'c' AND p.cat != 500 AND p.storecat = 0 ORDER BY date DESC"; break; default: $query = "SELECT p.id,p.user,p.userid,p.cat,p.bigimage,p.height,p.width,c.catname,c.photos,c.posts FROM {$pp_db_prefix}photos p LEFT JOIN {$pp_db_prefix}categories c ON c.id = p.cat WHERE c.cattype = 'c' AND p.cat != 500 AND p.storecat = 0 ORDER BY RAND()"; } $result = mysql_query($query); $counted = 0; $countcol = 0; $featured = ""; while (list($pid,$puser,$puserid,$pcat,$photo,$height,$width,$catname,$cphotos,$cposts) = mysql_fetch_row($result)) { if ( $ViewPerm[$pcat] == 1 ) continue; if ( pp_is_image($photo) ) { $temp_user = $puserid; if ( $height > $width ) $mthumb = ""; else $mthumb = ""; // One box for each feature $featured .= << $mthumb 
by {$puser}
? ? ?
$catname
$cphotos photos
$cposts comments
PPPRINT; $counted++; $countcol++; } // If we've reached our limit, quit if ( $counted == $num_display ) break; // If we need to end the column, do so. if ( $countcol == $columns ) { $featured .= << PPPRINT; $countcol = 0; } } @mysql_free_result($result); // First part is for the featured photos // $photopostfeature not holds the Featured Photos box and $photopostcats (set below) holds the // gallery list $photopostfeature = <<  Featured Photos  
$featured  

PPPRINT; // // End Featured Photos Code // // If you use PhotoPost in a seperate database from vB, you'll need to reselect the vB database! //mysql_select_db ("vb_database"); ?>
i did everything and that is what happends.. i found in my skins i dun have
Code:
<!-- /main -->
<br />
<br />
i do have this
Code:
<!-- main -->
$forumbits
<!-- /main -->

<!-- what's going on box -->
that is the closest i canfind but i get errors
I keep getting the same output at the top of the forum.
Reply With Quote
  #73  
Old 10-11-2006, 01:44 PM
dtdesign dtdesign is offline
 
Join Date: Feb 2002
Location: Ireland
Posts: 44
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I know this will display latest or most viewed, but I'm using it with Photopost Pro Classifieds and was wondering could I use it twice and say call the latest ads in one block and the latest trade ads in another block ?

As you can see here I'm just including the latest ads - Clicky
Reply With Quote
  #74  
Old 10-11-2006, 03:35 PM
phill2003 phill2003 is offline
 
Join Date: Apr 2003
Posts: 217
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

In short----Yes.

you will need to change a couple of function names but once you do that yes it will work a treat.
Reply With Quote
  #75  
Old 11-05-2006, 02:18 PM
roni1015 roni1015 is offline
 
Join Date: Dec 2005
Posts: 25
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Does anyone know if this will work in 3.6?
Reply With Quote
  #76  
Old 11-05-2006, 07:56 PM
roni1015 roni1015 is offline
 
Join Date: Dec 2005
Posts: 25
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Never mind, it does work in 3.6. Well, sort of. It's not *technically* showing a picture though, it's showing everything except instead of an image, it's showing a black box where the thumbnail should be...any idea why??
Reply With Quote
  #77  
Old 11-07-2006, 07:58 PM
roni1015 roni1015 is offline
 
Join Date: Dec 2005
Posts: 25
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Please? Any suggestions why it would only show black images instead of the actual photos?
Reply With Quote
  #78  
Old 11-08-2006, 09:51 AM
cellarius's Avatar
cellarius cellarius is offline
 
Join Date: Aug 2005
Posts: 1,987
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I have the same problem: Only showing black images. Anybody out there?
vB 3.6.2, PP 5.5.
Reply With Quote
  #79  
Old 11-08-2006, 10:25 AM
cellarius's Avatar
cellarius cellarius is offline
 
Join Date: Aug 2005
Posts: 1,987
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

O.K., figured it out. For everybody having the same problem: Go to your PP Admin-Center -> Administration -> Edit Integration -> URL to your PhotoPost DATA directory -> add trailing slash at the end ("data/").

This worked for me.
Reply With Quote
  #80  
Old 11-09-2006, 03:04 PM
roni1015 roni1015 is offline
 
Join Date: Dec 2005
Posts: 25
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

WOOT! You rock!! THANKS!!!
Reply With Quote
  #81  
Old 11-10-2006, 09:01 AM
cellarius's Avatar
cellarius cellarius is offline
 
Join Date: Aug 2005
Posts: 1,987
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You're welcome
Reply With Quote
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 07:55 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.05617 seconds
  • Memory Usage 2,310KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (3)bbcode_code
  • (2)bbcode_html
  • (1)bbcode_php
  • (2)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • 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
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete