vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.6 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=194)
-   -   Forum Display Enhancements - Collapsable First Post using AJAX (or Last Post!) (https://vborg.vbsupport.ru/showthread.php?t=145187)

dbirosel 04-19-2007 11:40 PM

Quote:

Originally Posted by TheMilkCarton (Post 1231574)
I'll be adding it regardless, but don't you think adding a reply button would be a good addition to your product anyway? :)

I'm also trying to figure out how to make this product more obvious, without being annoying. I don't think anyone has the slightest clue I added this product, and an announcement or post about it wouldn't do much good. haha

What i did was mass PM everyone about it and directing them to this tutorial:

http://www.caraudiojunkyard.com/foru...ng-thread.html

TheMilkCarton 04-20-2007 12:02 AM

I had another idea about adding an "Exclude Usergroups" option. Not sure if you'll like it as much as my "Exclude Forums" idea, but I thought I'd suggest it anyway. :)

I just thought that this might get pretty server-intensive if all guests can use it, so I'd like to make it an incentive to sign up! And that's another thing, dbirosel, I can't PM guests to tell them about it, so I might as well just not let them use it. :)

dbirosel 04-20-2007 12:05 AM

Quote:

Originally Posted by TheMilkCarton (Post 1231602)
I had another idea about adding an "Exclude Usergroups" option. Not sure if you'll like it as much as my "Exclude Forums" idea, but I thought I'd suggest it anyway. :)

I just thought that this might get pretty server-intensive if all guests can use it, so I'd like to make it an incentive to sign up! And that's another thing, dbirosel, I can't PM guests to tell them about it, so I might as well just not let them use it. :)

Earlier in this thread, that this can't be server-intensive. He said it should run, just like how it should when regularly viewing a thread.

Slave 04-20-2007 12:10 AM

Wonderful hack, thank you!

A few suggestions ..

"View next/previous post in thread" links .. perhaps just << and >> links to enable a whole thread to be read from the forumdisplay page :)

Quote/reply buttons .. which would take you to the advanced post page

Ability to edit the number of posts to show in Admin CP .. so instead of just one, perhaps 2 or 3 etc ..

Ability to pick "First unread post" in the Admin CP as well as "First post" and "Last Post" ..

Edit button (if poster) .. yes I want the world!! :D

magnus 04-20-2007 12:39 AM

Quote:

Originally Posted by Slave (Post 1231607)
Ability to pick "First unread post" in the Admin CP as well as "First post" and "Last Post" ..

I really like this idea.

Not to devalue your other ideas, but those have all already been mentioned and are being considered.. but the one above, that's gold. Thanks! :)

4x4 Mecca 04-20-2007 12:53 AM

I've edited the postbit just to show the user name, and nothing else on the left, changed the column width, and made attachments not show up, rather a message saying to view the thread to see attachments. Also there is an edit button and a reply button
http://www.4x4mecca.com/forum/forumdisplay.php?f=36

Magnus, if you want this removed, I'll do it, just PM me :)
Code:

<table id="post$post[postid]" cellpadding="10" cellspacing="0" border="0" width="100%" align="center">
<tr valign="top">
        <td class="alt2" width="64">
                       
                        <div id="postmenu_$post[postid]">
                                <if condition="$show['profile']">
                                <a class="smallfont" href="member.php?$session[sessionurl]u=$post[userid]">$post[musername]</a>
                                <script type="text/javascript"> vbmenu_register("postmenu_$post[postid]", true); </script>
                                <else />
                                $post[musername]
                                </if>
                        </div>               
        </td>
        <if condition="$show['moderated']">
        <td class="alt2" id="td_post_$post[postid]" style="border-right: $stylevar[cellspacing]px solid $stylevar[tborder_bgcolor]">
        <else />
        <td class="alt1" id="td_post_$post[postid]" style="border-right: $stylevar[cellspacing]px solid $stylevar[tborder_bgcolor]">
        </if>
       
               
               
                <!-- message -->
                <div id="post_message_$post[postid]">$post[message]</div>
                <!-- / message -->
       
                <if condition="$show['attachments']">
_______________<p>
                        <b>*** Please View Thread for Attachments ***</b>
                        </if>
                       
                        </div>
                <!-- / attachments -->
                </if>
               
                <if condition="$show['postedited']">
                <!-- edit note -->
                        <div class="smallfont">                        <hr size="1" style="color:$stylevar[tborder_bgcolor]" />
                                <em>
                                <phrase 1="$post[edit_username]" 2="$post[edit_date]" 3="$post[edit_time]">$vbphrase[last_edited_by_x_on_y_at_z]</phrase>.
                                <if condition="$post['edit_reason']">$vbphrase[reason]: $post[edit_reason]</if>
                                </em>
                        </div>
                <!-- / edit note -->
                </if>
                <!-- controls -->

<if condition="$post['editlink']">
<img style="display: none" id="progress_$postid" src="$stylevar[imgdir_misc]/progress.gif" alt="$vbphrase[loading_editor_please_wait]" />

<a href="$post[editlink]" name="vB::QuickEdit::$post[postid]">
<img src="$stylevar[imgdir_button]/edit.gif" alt="$vbphrase[edit_delete_message]" border="0" /></a>
                </if>

                <if condition="$post['replylink']">
                        <a href="$post[replylink]" rel="nofollow"><img src="$stylevar[imgdir_button]/reply_small.gif" alt="$vbphrase[reply_with_quote]" border="0" /></a>
                </if>

                <if condition="$show['quickreply'] AND !$show['threadedmode']">
                        <a href="$post[replylink]" rel="nofollow" id="qr_$post[postid]" onclick="return false"><img src="$stylevar[imgdir_button]/quickreply.gif" alt="$vbphrase[quick_reply_to_this_message]" border="0" /></a>
                </if>
                <!-- / controls -->
       
        </td>
</tr>
</table>

<!-- post $post[postid] popup menu -->
<div class="vbmenu_popup" id="postmenu_$post[postid]_menu" style="display:none">
        <table cellpadding="4" cellspacing="1" border="0">
        <tr>
                <td class="thead">$post[username]</td>
        </tr>
        <if condition="$show['profile']">
                <tr><td class="vbmenu_option"><a href="member.php?$session[sessionurl]u=$post[userid]">$vbphrase[view_public_profile]</a></td></tr>
        </if>
        <if condition="$show['pmlink']">
                <tr><td class="vbmenu_option"><a href="private.php?$session[sessionurl]do=newpm&amp;u=$post[userid]" rel="nofollow"><phrase 1="$post[username]">$vbphrase[send_private_message_to_x]</phrase></a></td></tr>
        </if>
        <if condition="$show['emaillink']">
                <tr><td class="vbmenu_option"><a href="sendmessage.php?$session[sessionurl]do=mailmember&amp;u=$post[userid]" rel="nofollow"><phrase 1="$post[username]">$vbphrase[send_email_to_x]</phrase></a></td></tr>
        </if>
        <if condition="$show['homepage']">
                <tr><td class="vbmenu_option"><a href="$post[homepage]"><phrase 1="$post[username]">$vbphrase[visit_xs_homepage]</phrase></a></td></tr>
        </if>
        <if condition="$show['search']">
                <tr><td class="vbmenu_option"><a href="search.php?$session[sessionurl]do=finduser&amp;u=$post[userid]" rel="nofollow"><phrase 1="$post[username]">$vbphrase[find_more_posts_by_x]</phrase></a></td></tr>
        </if>
        <if condition="$post['userid'] AND $show['member']">
        <tr><td class="vbmenu_option"><a href="profile.php?$session[sessionurl]do=addlist&amp;userlist=buddy&amp;u=$post[userid]"><phrase 1="$post[username]">$vbphrase[add_x_to_buddy_list]</phrase></a></td></tr>
        </if>
        </table>
</div>
<!-- / post $post[postid] popup menu -->


dbirosel 04-20-2007 01:06 AM

how do you add a reply button?

magnus 04-20-2007 01:10 AM

Quote:

Originally Posted by 4x4 Mecca (Post 1231620)
Magnus, if you want this removed, I'll do it, just PM me :)

I'd never ask you (or anyone) to not provide any customizations. That's the whole point of vBulletin.org -- to share ideas. By all means, share whatever you think anyone could benefit from.

As a sidenote, you no longer need to include <!-- vbpost ok --> at the top of your templates. I've phased that check out in 1.2. :)

magnus 04-20-2007 01:12 AM

Quote:

Originally Posted by dbirosel (Post 1231625)
how do you add a reply button?

Just view your original postbit_legacy template, find the reply button block of code, cut and paste. :)

The vbpost_postbit template is nothing more than a copy/paste of the default postbit_legacy with a few visual modifications. In fact, you could just cut and paste the entire default postbit_legacy into vbpost_postbit if you so desired.

StuntFactoryX 04-20-2007 01:17 AM

ive been watching this for a few days. in the early posts there were reports of alot of database errors and i seen you guys working hard to sort out the bugs. the current version close to stable and bug free?

4x4 Mecca 04-20-2007 01:19 AM

I was doing that, and I replaced my default postbit legacy! lol, big error, I fixed it most of the way, but it was pretty customized. Thanks again for the mod magnus.

magnus 04-20-2007 01:29 AM

Quote:

Originally Posted by StuntFactoryX (Post 1231632)
ive been watching this for a few days. in the early posts there were reports of alot of database errors and i seen you guys working hard to sort out the bugs. the current version close to stable and bug free?

No bugs reported.

dbirosel 04-20-2007 02:10 AM

Quote:

Originally Posted by magnus (Post 1231639)
No bugs reported.

x2, it's running stable over at our forums.

Coders Shack 04-20-2007 02:17 AM

when making the manual edits i get:
Code:

The following error occurred when attempting to evaluate this template:

Parse error: parse error, unexpected '\"', expecting T_STRING or T_VARIABLE or T_NUM_STRING in /var/www/vhosts/site.com/httpdocs/forum/includes/adminfunctions_template.php(3596) : eval()'d code on line 1

This is likely caused by a malformed conditional statement. It is highly recommended that you fix this error before continuing, but you may continue as-is if you wish.

when i add these two:
HTML Code:

<tr <if condition="!in_array($forumid, $ajax_firstpost_excluded)">id="vbpostrow_$thread[<if condition="$vbulletin->options['ajax_firstpost_firstlast']">lastpostid<else />firstpostid</if>]"</if>>
HTML Code:

                                <if condition="!in_array($forumid, $ajax_firstpost_excluded)"><img id="vbpostimg_$thread[<if condition="$vbulletin->options['ajax_firstpost_firstlast']">lastpostid<else />firstpostid</if>]" src="$stylevar[imgdir_button]/expand.gif" onclick="return vbpost_get($thread[<if condition="$vbulletin->options['ajax_firstpost_firstlast']">lastpostid<else />firstpostid</if>])" onMouseOver="this.style.cursor='pointer';" /></if>

magnus 04-20-2007 02:32 AM

Quote:

Originally Posted by Coders Shack (Post 1231656)
when making the manual edits i get:

Did you disable Automatic Template Edits in the Collapsable First Post using AJAX Options from the AdminCP?

Coders Shack 04-20-2007 02:34 AM

Quote:

Originally Posted by magnus (Post 1231664)
Did you disable Automatic Template Edits in the Collapsable First Post using AJAX Options from the AdminCP?

yes

TheBlackPoet 04-20-2007 02:39 AM

this is tight baby!!! good job..... rated excellent!!

dbirosel 04-20-2007 03:09 AM

Since we viewed the thread by expanding the thread. Can we have the newpost icon removed to show that we already read it? Same for the newpost icon on the forum home? Also, removing the thread from the New Posts page.

Coders Shack 04-20-2007 06:00 AM

ok was still unable to make the manual edits so i found a way to get the replacements to work.

also the only thing this is missing i a way to make a reply straight from the forumdisplay :D

rjmjr69 04-20-2007 09:49 AM

Quote:

Originally Posted by Coders Shack (Post 1231656)
when making the manual edits i get:
Code:

The following error occurred when attempting to evaluate this template:

Parse error: parse error, unexpected '\"', expecting T_STRING or T_VARIABLE or T_NUM_STRING in /var/www/vhosts/site.com/httpdocs/forum/includes/adminfunctions_template.php(3596) : eval()'d code on line 1

This is likely caused by a malformed conditional statement. It is highly recommended that you fix this error before continuing, but you may continue as-is if you wish.

when i add these two:
HTML Code:

<tr <if condition="!in_array($forumid, $ajax_firstpost_excluded)">id="vbpostrow_$thread[<if condition="$vbulletin->options['ajax_firstpost_firstlast']">lastpostid<else />firstpostid</if>]"</if>>
HTML Code:

                                <if condition="!in_array($forumid, $ajax_firstpost_excluded)"><img id="vbpostimg_$thread[<if condition="$vbulletin->options['ajax_firstpost_firstlast']">lastpostid<else />firstpostid</if>]" src="$stylevar[imgdir_button]/expand.gif" onclick="return vbpost_get($thread[<if condition="$vbulletin->options['ajax_firstpost_firstlast']">lastpostid<else />firstpostid</if>])" onMouseOver="this.style.cursor='pointer';" /></if>

I'm getting this same exact problem after upgrading. I shut down the autotemplate edit as I had to the first time too. Any idea?

Is that the portion of the code that updates the post view amount? If not this feature is not working for me.

magnus 04-20-2007 11:16 AM

Quote:

Originally Posted by Coders Shack (Post 1231656)
when making the manual edits i get:

Quote:

Originally Posted by rjmjr69 (Post 1231844)
I'm getting this same exact problem after upgrading. I shut down the autotemplate edit as I had to the first time too. Any idea?

My apologies, that was my fault. I've updated the template edits with new, tested, conditionals. That's what I get for not testing. Sorry!

rjmjr69 04-20-2007 08:44 PM

Quote:

Originally Posted by magnus (Post 1231894)
My apologies, that was my fault. I've updated the template edits with new, tested, conditionals. That's what I get for not testing. Sorry!

Still does not work Now I get errors on both lines


Can you look and see if you can figure it out please...
Attachment 63427

magnus 04-20-2007 08:55 PM

@rjmjr69:
Attached is your modified threadbit. I pasted this over my own threadbit and it tested fine.

rjmjr69 04-20-2007 10:25 PM

Even with your edit I get these errors still

The following error occurred when attempting to evaluate this template:

Warning: in_array() [function.in-array]: Wrong datatype for second argument in /includes/adminfunctions_template.php(3596) : eval()'d code on line 1

Warning: in_array() [function.in-array]: Wrong datatype for second argument in /includes/adminfunctions_template.php(3596) : eval()'d code on line 15

This is likely caused by a malformed conditional statement. It is highly recommended that you fix this error before continuing, but you may continue as-is if you wish.

magnus 04-20-2007 10:26 PM

Did you upload the new files and overwrite the old ones? (as well as reimport the new product xml and disable automatic template edits via the AdminCP)

TheMilkCarton 04-21-2007 12:07 AM

This is probably impossible, or at least really hard, but I thought I'd suggest it anyway.

In addition to allowing us to select among First post, Last post, or First Unread (if you add this to a later update), what about a "User Selectable" option which would then put the "First, Last, or First Unread" options in everyone's UserCP options. Another admin at my site suggested it, so don't blame me. :) I think it's a good idea, but maybe not worth the effort to the developer.

And here I am suggesting really hard things, and I haven't even gotten around to adding a "Reply" button to this mod. :)

magnus 04-21-2007 12:30 AM

Quote:

Originally Posted by TheMilkCarton (Post 1232333)
In addition to allowing us to select among First post, Last post, or First Unread (if you add this to a later update), what about a "User Selectable" option which would then put the "First, Last, or First Unread" options in everyone's UserCP options. Another admin at my site suggested it, so don't blame me. :) I think it's a good idea, but maybe not worth the effort to the developer.

Too late. Already working on it. :)

This was my original plan, I just wanted to get the backend solid first.

TheMilkCarton 04-21-2007 12:41 AM

Nice!! Great minds think alike. hahah. :rolleyes:

dbirosel 04-21-2007 01:16 AM

Woot!! I can't wait for the next update. This mod has a lot of potential to become MOTM

apdcanari 04-21-2007 04:11 AM

Hello,

3.5 please ? I speak french.

Thanks,

C?dric:rolleyes:

magnus 04-21-2007 04:33 AM

Quote:

Originally Posted by apdcanari (Post 1232433)
Hello,

3.5 please ? I speak french.

Thanks,

C?dric:rolleyes:

This hack is for 3.6. I haven't tested it on 3.5, but I don't see why it wouldn't work.

It would take 5 minutes for you to try it.

rayw 04-21-2007 10:37 AM

Fantastic work magnus, thank you very much. Working fine on my forum. :) Rated excellent and hanging out for the next version.

Cheers!

akulion 04-21-2007 11:16 AM

nice
I also got the template edit errors

PHP Code:

The following error occurred when attempting to evaluate this template:

Warningin_array() [function.in-array]: Wrong datatype for second argument in /includes/adminfunctions_template.php(3596) : eval()'d code on line 1

Warning: in_array() [function.in-array]: Wrong datatype for second argument in /includes/adminfunctions_template.php(3596) : eval()'
d code on line 14

This is likely caused by a malformed conditional statement
It is highly recommended that you fix this error before continuingbut you may continue as-is if you wish

but it still seems to work...so ill just say "if it works dont touch it lol

BobbyBig 04-21-2007 12:31 PM

Holy... that makes me want to have sex with you :)
Nominated.
Thanks.

magnus 04-21-2007 01:45 PM

Quote:

Originally Posted by akulion (Post 1232568)
nice
I also got the template edit errors

PHP Code:

The following error occurred when attempting to evaluate this template:

Warningin_array() [function.in-array]: Wrong datatype for second argument in /includes/adminfunctions_template.php(3596) : eval()'d code on line 1

Warning: in_array() [function.in-array]: Wrong datatype for second argument in /includes/adminfunctions_template.php(3596) : eval()'
d code on line 14

This is likely caused by a malformed conditional statement
It is highly recommended that you fix this error before continuingbut you may continue as-is if you wish

but it still seems to work...so ill just say "if it works dont touch it lol

Did you perform the template edits manually, or were they automatic? If they were manual, did you perform them BEFORE you imported the product or after? Are you using 3.6.5?

I'd like to try and track this down, since I can't seem to replicate it and this is the third report. It seems to be scattered, some people get an errors -- other's don't. There has to be a common link somewhere..

rayw 04-22-2007 07:59 AM

Just found a little problem I think.

If you move a thread to a different forum leaving a redirect, the redirect appears with a + next to it still but when you click on it, it doesn't open anything. You just get that little icon spinning in circles over and over again.

Is it possible to remove the plus from the redirect or fix it so that it will still display the contents. Doesn't bother me really but I thought I would make you aware of it.

Cheers! :)

rjmjr69 04-22-2007 08:39 AM

Still having issues. Do you happen to have the original template edits you had posted?

magnus 04-22-2007 01:10 PM

Quote:

Originally Posted by rjmjr69 (Post 1233237)
Still having issues. Do you happen to have the original template edits you had posted?

What's the issues? When do you receive the error?

magnus 04-22-2007 01:11 PM

Quote:

Originally Posted by rayw (Post 1233217)
Just found a little problem I think.

If you move a thread to a different forum leaving a redirect, the redirect appears with a + next to it still but when you click on it, it doesn't open anything. You just get that little icon spinning in circles over and over again.

Is it possible to remove the plus from the redirect or fix it so that it will still display the contents. Doesn't bother me really but I thought I would make you aware of it.

Cheers! :)


Noted. Thanks.

rjmjr69 04-22-2007 11:12 PM

Quote:

Originally Posted by magnus (Post 1233333)
What's the issues? When do you receive the error?


The original issue. You sent me a redone template that still does not work. I get those errors trying to alter it.


All times are GMT. The time now is 07:18 PM.

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.02071 seconds
  • Memory Usage 1,887KB
  • 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
  • (3)bbcode_code_printable
  • (4)bbcode_html_printable
  • (2)bbcode_php_printable
  • (19)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)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