vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Requests/Questions (Unpaid) (https://vborg.vbsupport.ru/forumdisplay.php?f=112)
-   -   Need News!!! Image Alignment Module/hack (https://vborg.vbsupport.ru/showthread.php?t=124264)

soletrader 08-17-2006 11:29 PM

Need News!!! Image Alignment Module/hack
 
I am in a DESPERATE need to align my news image on my homepage. I have seen many hacks posted for versions 3.5 but none seem to work with 3.6.

I will even pay for this hack/coding. PLEASE let me know asap. THANK YOU

project-Buckfas 08-19-2006 01:34 PM

Are you using vBadvanced??

If so they can look like THIS

I try to keep my images to around 100 x 100, however image size is totally up to you....

DementedMindz 08-19-2006 03:25 PM

project-Buckfas how are you posting different images with each post or you just using bbcode?

project-Buckfas 08-20-2006 12:22 PM

DementedMindz

They are attached images.

You attach an image to a post as you normally would.

Any attached image will show in vbadvanced.

As said above I try to keep my images to 100x100 pixels. It keeps things inline and neat looking!

DementedMindz 08-21-2006 03:59 PM

thanks for the response :). yeah I was hoping it was something kinda like phpnuke uses where you could chose the image per news post.

project-Buckfas 08-22-2006 06:11 AM

Edit the template: adv_portal_newsbits

REPLACE all the code in that template with this code. Don't forget to make a backup of the original beforehand.

Code:

<if condition="!$mod_options['portal_news_legacy']">
<tr>
<td class="thead"><if condition="$mod_options['portal_news_showicon']">$vba_style[portal_blockbullet]</if> <a href="$vboptions[bburl]/showthread.php?t=$news[threadid]">$news[title]</a></td>
</tr>
</if>
<tr>
<td class="<if condition="$mod_options['portal_news_legacy']">thead<else />alt2</if>">
<if condition="$mod_options['portal_news_showrating'] AND $news['votenum']">
<span style="float:$stylevar[right]"><img alt="" src="$stylevar[imgdir_rating]/rating_$news[rating].gif" title="<phrase 1="$news[votenum]" 2="$news[voteavg]">$vbphrase[thread_rating_x_votes_y_average]</phrase>" /></span>
</if>
$news[dateposted] - <phrase 1="$vboptions[bburl]/member.php?$session[sessionurl]u=$news[postuserid]" 2="$news[postusername]">$vbphrase[by_x]</phrase>
</td>
</tr>
<tr>
<td align="$stylevar[left]" class="alt1" valign="top">
<if condition="$news['avatarpath']">
<img align="$stylevar[left]" style="padding:6px" alt="" border="0" src="$news[avatarpath]" title="$news[postusername]'s $vbphrase[avatar]" />
</if>
<if condition="$news['attachment']">
<span style="float: left; margin: $stylevar[cellpadding]px $stylevar[cellpadding]px $stylevar[cellpadding]px 0px">
$news[attachment]
</span>
</if>

$news[message]

<if condition="$show['signature']">
<div>__________________<br />
$news[signature]</div>
</if>

</td>
</tr>

<tr class="alt2" valign="middle">
<td valign="middle">
<span style="float:right">
<if condition="$show['editbutton']">
<a href="$vboptions[bburl]/editpost.php?$session[sessionurl]do=editpost&amp;p=$news[postid]"><img alt="$vbphrase[edit_this_post]" border="0" src="$stylevar[imgdir_button]/edit.gif" /></a>
</if>

<if condition="$show['replybutton']">
<a href="$vboptions[bburl]/newreply.php?$session[sessionurl]do=newreply&amp;t=$news[threadid]"><img alt="$vbphrase[reply_to_this_post]" border="0" src="$stylevar[imgdir_button]/reply_small.gif" /></a>
</if>

<if condition="$mod_options['portal_news_showsendfriend']">
<a href="$vboptions[bburl]/sendmessage.php?$session[sessionurl]do=sendtofriend&amp;t=$news[threadid]"><img alt="" border="0" src="$stylevar[imgdir_button]/sendtofriend.gif" title="$vbphrase[send_to_friend]" /></a>
</if>

<if condition="$mod_options['portal_news_showprintable']">
<a href="$vboptions[bburl]/printthread.php?$session[sessionurl]t=$news[threadid]"><img alt="" border="0" src="$stylevar[imgdir_button]/printer.gif" title="$vbphrase[show_printable_version]" /></a>
</if>
</span>

<span class="smallfont">
<if condition="$mod_options['portal_news_allowreplies']">$news[replycount] <if condition="$news['replycount'] == 1">$vbphrase[reply]<else />$vbphrase[replies]</if> | </if> $news[views] $vbphrase[views]</span>
</td>
</tr>

Now when you attach an image to a post in a thread that shows in vbadvanced, the image will show in the top left corner of the post. :D

DementedMindz 08-31-2006 03:46 PM

ok another question for you how did you remove the size from the image? cause mine shows the thumbnail fine but it displays the width and height under it also how did you get the feildset around your image on the post?

ok i removed the deminisions i would just like the feild set that looks good if you dont mind

project-Buckfas 09-02-2006 01:58 PM

For those that are having problems with guests seeing images, you will need to set the usergroups permissions as follows...


Admincp --> Usergroup Manager --> unregistered/not logged in (or desired usergroup)

Look for "forum viewing permissions"

Set "Can Download Attachments" to yes

DementedMindz 09-10-2006 08:27 PM

project-Buckfas I noticed one flaw with this. If you dont give a long enough description where it would say read more it will post the attachment on the left and under the post it will say the word attachment with the link.

Insert Username 09-20-2006 04:35 PM

project-Buckfas, about your hack. We have vbAdvanced powering our CMPS, but I don't have a adv_portal_newsbits. Am I running an older version or something?


All times are GMT. The time now is 12:11 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01640 seconds
  • Memory Usage 1,739KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.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
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete