vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB4 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=251)
-   -   Brainstorm Help - Best Spot to show information (https://vborg.vbsupport.ru/showthread.php?t=326426)

scottkoz20 05-23-2018 06:41 PM

Brainstorm Help - Best Spot to show information
 
I have a question on how you would potentially build this out.

Background: I allow members to Buy/sell and trade sports cards on the forums; however, the members themselves have the right to designate which countries they want to ship to or not ship to. Sometimes that information is not known until the very end or worse when the negotiations have started.

Suggestion that given by a member was to indicate this somewhere on the thread of on the members profile.

My dilemma is simply the best spot to show this information.

What I would love to do it to have a "pre-signature" at the top of the thread indicating which countries they would be willing to ship to; however, this is probably not an option.

I am not sure I want to add anymore on the postbit as I have a TON of information there already.

My question, is there another spot that would be good to show this information

Thanks,
Scott

z3r0 05-24-2018 07:44 AM

If they have the countries that they don't want to ship to saved in a custom profile field then you could add something like this to the top of your postbit_legacy template (you would need to set the field ID to whatever your field is)

Code:

<vb:if condition="$post['isfirstshown'] AND $post[field7]"><div style="border:1px solid #ccc; padding:7px;background-color:#ffeb90;">Not shipping to the following counties: {vb:raw post.field7} </div><br /></vb:if>
I'm assuming the sales post would be the first in a thread and if so the notice would show above.

scottkoz20 05-24-2018 12:58 PM

1 Attachment(s)
I like this a lot!

I was trying to use a Multi-select option but it does not report the field names, just a numeric value - I would not want to make this a free-form text as I do want to have some consistency.

Also, I need to make sure that this only appears in certain forums, so I am taking this would be an additional AND clause with an array of the forum ID's to be included for this.


Thanks Z3r0

EDIT - Code at this point

Code:

<vb:if condition="$post['isfirstshown'] AND $post[field54]"><div style="border:1px solid #ccc; padding:7px;background-color:#ffeb90;">{vb:raw post.username} will ship to the following countries: {vb:raw post.field54} </div><br /></vb:if>

scottkoz20 05-24-2018 02:18 PM

did try the following with no luck on the array

Code:

<vb:if condition="in_array($forum['forumid'], array(86,87,88,89))">
<vb:if condition="$post['isfirstshown'] AND $post[field54]"><div style="border:1px solid #ccc; padding:7px;background-color:#ffeb90;">{vb:raw post.username} will ship to the following countries: {vb:raw post.field54} </div><br />
</vb:if>
</vb:if>


z3r0 05-24-2018 03:30 PM

Try

Code:

<vb:if condition="in_array($GLOBALS['forumid'], array(86,87,88,89))">

scottkoz20 05-24-2018 03:46 PM

:up: Thank you very much

now to work with the profile fields - I think I'll just use a single select option :)

scottkoz20 05-24-2018 04:02 PM

1 Attachment(s)
screenshots added

z3r0 05-24-2018 04:06 PM

Looks great :)

I've just been doing some reading and there may be a way to do the multiple selections - https://vborg.vbsupport.ru/showthread.php?t=250418

scottkoz20 05-24-2018 04:14 PM

hmmmm - that explains why it was reporting 15 earlier

z3r0 05-24-2018 04:25 PM

Just a thought - I had a quick look at your forum and noticed in the first trade thread I looked at that the user didn't take PayPal - is it worth extending this to show accepted payment methods?


All times are GMT. The time now is 10: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.01132 seconds
  • Memory Usage 1,737KB
  • 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
  • (4)bbcode_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)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