Thread Rating:
  • 1 Votes - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
 Support Form
RateU Offline
Administrator
*******
Posts: 2,350
Joined: Mar 2010
Post: #8
RE: Support Form
Updated:
Solution Post custom thread field:
  • Blank Replacement Value:

    Code:
    <setvar xtsviewable>($mybb->user['uid'] == $thread['uid'] || is_moderator($fid, '', $mybb->user['uid'])) && THIS_SCRIPT == 'showthread.php'</setvar>
    <setvar firstpost>$tplvars['xtsviewable'] ? get_post($thread['firstpost']) : ''</setvar>
    <setvar solvebutton1>$tplvars['xtsviewable'] ? ' --><form action="editpost.php" method="post"><input type="hidden" name="my_post_key" value="'.$mybb->post_code.'" /><input type="hidden" name="action" value="do_editpost" /><input type="hidden" name="prefix" value="'.$thread['prefix'].'" /><input type="hidden" name="subject" value="'.htmlspecialchars_uni($tplvars['firstpost']['subject']).'" /><input type="hidden" name="icon" value="'.$tplvars['firstpost']['icon'].'" /><input type="hidden" name="message" value="'.htmlspecialchars_uni($tplvars['firstpost']['message']).'" /><input type="hidden" name="options[signature]" value="'.$tplvars['firstpost']['includesig'].'" /><input type="hidden" name="options[disablesmilies]" value="'.$tplvars['firstpost']['smilieoff'].'" /><input type="hidden" name="pid" value="'.$thread['firstpost'].'" /><input type="hidden" name="xthreads_sis" value="Solved" /><input type="hidden" name="xthreads_xtspt_solvepost" value="' : ''</setvar>
    <setvar solvebutton2>$tplvars['xtsviewable'] ? '" /><input type="submit" value="Mark this post as solution" /></form><!-- ' : ''</setvar>

  • Display Format:

    Code:
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    <setvar xtsviewable>($mybb->user['uid'] == $thread['uid'] || is_moderator($fid, '', $mybb->user['uid'])) && THIS_SCRIPT == 'showthread.php'</setvar>
    <setvar firstpost>$tplvars['xtsviewable'] ? get_post($thread['firstpost']) : ''</setvar>
    <setvar solvebutton1>$tplvars['xtsviewable'] ? ' --><form action="editpost.php" method="post"><input type="hidden" name="my_post_key" value="'.$mybb->post_code.'" /><input type="hidden" name="action" value="do_editpost" /><input type="hidden" name="prefix" value="'.$thread['prefix'].'" /><input type="hidden" name="subject" value="'.htmlspecialchars_uni($tplvars['firstpost']['subject']).'" /><input type="hidden" name="icon" value="'.$tplvars['firstpost']['icon'].'" /><input type="hidden" name="message" value="'.htmlspecialchars_uni($tplvars['firstpost']['message']).'" /><input type="hidden" name="options[signature]" value="'.$tplvars['firstpost']['includesig'].'" /><input type="hidden" name="options[disablesmilies]" value="'.$tplvars['firstpost']['smilieoff'].'" /><input type="hidden" name="pid" value="'.$thread['firstpost'].'" /><input type="hidden" name="xthreads_sis" value="Solved" /><input type="hidden" name="xthreads_xtspt_solvepost" value="' : ''</setvar>
    <setvar solvebutton2>$tplvars['xtsviewable'] ? '" /><input type="submit" value="Mark this post as solution" /></form><!-- ' : ''</setvar>
    <setvar solved>{VALUE} && $tplvars['issue_status'] == 'Solved' && THIS_SCRIPT == 'showthread.php'</setvar>
    <setvar post>$tplvars['solved'] ? get_post(intval({VALUE})) : ''</setvar>
    <if $tplvars['post']['pid'] && $tplvars['post']['tid'] == $thread['tid'] && $tplvars['post']['visible'] then>
    	<tr><td class="solved largetext" colspan="2"><a href="{$threadurl_q}pid={$tplvars['post']['pid']}#pid{$tplvars['post']['pid']}"><span style="color: green;"><strong>Solution Post</strong></span></a> by <a href="<?=get_profile_link(intval($tplvars['post']['uid']))?>"><strong><func htmlspecialchars_uni>{$tplvars['post']['username']}</func></strong></a></td></tr>
    	<setvar solvepostcss>array($tplvars['post']['pid'] => ' solved')</setvar>
    </if>


Thank you very much, Yumi Smile

03-11-2011 07:40 AM
Find all posts by this user Quote this message in a reply

« Next Oldest | Next Newest »

Messages In This Thread
Support Form - RateU - 03-06-2011, 09:50 AM
RE: Support Form - techu - 03-06-2011, 12:48 PM
RE: Support Form - ZiNgA BuRgA - 03-06-2011, 04:09 PM
RE: Support Form - RateU - 03-07-2011, 10:51 AM
RE: Support Form - ZiNgA BuRgA - 03-07-2011, 05:45 PM
RE: Support Form - MattR - 03-08-2011, 07:36 AM
RE: Support Form - RateU - 03-08-2011, 08:03 AM
RE: Support Form - RateU - 03-11-2011 07:40 AM
RE: Support Form - RateU - 07-18-2011, 03:19 AM
RE: Support Form - blakefire - 08-10-2011, 06:41 PM
RE: Support Form - RateU - 08-11-2011, 04:11 AM
RE: Support Form - bogdan - 08-11-2011, 04:23 AM
RE: Support Form - RateU - 08-11-2011, 05:26 AM
RE: Support Form - bogdan - 08-11-2011, 05:45 AM
RE: Support Form - RateU - 08-12-2011, 01:54 AM
RE: Support Form - bogdan - 08-12-2011, 05:24 AM
RE: Support Form - RateU - 08-23-2011, 05:22 AM
RE: Support Form - Alan11 - 08-28-2011, 09:37 AM
RE: Support Form - Seabody - 12-23-2012, 01:03 PM
RE: Support Form - Andre - 02-11-2013, 05:31 PM
RE: Support Form - ZiNgA BuRgA - 02-12-2013, 09:17 AM
RE: Support Form - RateU - 02-13-2013, 01:59 AM
RE: Support Form - Andre - 02-13-2013, 09:48 AM
RE: Support Form - RateU - 02-14-2013, 03:07 AM
RE: Support Form - Andre - 02-15-2013, 11:55 PM
RE: Support Form - RateU - 02-16-2013, 01:08 AM
RE: Support Form - Andre - 02-16-2013, 02:13 AM
RE: Support Form - lion - 02-18-2016, 11:13 PM
RE: Support Form - ZiNgA BuRgA - 02-19-2016, 12:52 PM
RE: Support Form - lion - 02-19-2016, 05:29 PM
RE: Support Form - lion - 02-19-2016, 10:22 PM
RE: Support Form - lion - 02-21-2016, 04:27 AM
RE: Support Form - xensor - 06-09-2016, 04:46 AM
RE: Support Form - Yoda - 06-19-2018, 01:39 PM

 Standard Tools
Forum Jump: