Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
 Image Preview In Newthread And Editpost
RateU Offline
Administrator
*******
Posts: 2,350
Joined: Mar 2010
Post: #21
RE: Image Preview In Newthread
May I know what is the {$newthread} variable in line #12 for, Lee?

10-02-2010 05:56 AM
Find all posts by this user Quote this message in a reply
leefish Offline
Hamster
*****
Posts: 1,009
Joined: Apr 2010
Post: #22
RE: Image Preview In Newthread
I have no idea - I just copied  this whole block from the main templates and gave it a prefix, added the variable and that was it........I shall try and edit it out.

EDIT I edited it out - no change


[Image: leelink.gif]
MYBB1.6 & XThreads
(This post was last modified: 10-02-2010 06:05 AM by leefish.)
10-02-2010 05:59 AM
Visit this user's website Find all posts by this user Quote this message in a reply
RateU Offline
Administrator
*******
Posts: 2,350
Joined: Mar 2010
Post: #23
RE: Image Preview In Newthread
I'm not quite sure whether that's the problem or not, though.

10-02-2010 06:02 AM
Find all posts by this user Quote this message in a reply
leefish Offline
Hamster
*****
Posts: 1,009
Joined: Apr 2010
Post: #24
RE: Image Preview In Newthread
Well, I think I am going to have to make a template for it......


[Image: leelink.gif]
MYBB1.6 & XThreads
10-02-2010 06:07 AM
Visit this user's website Find all posts by this user Quote this message in a reply
RateU Offline
Administrator
*******
Posts: 2,350
Joined: Mar 2010
Post: #25
RE: Image Preview In Newthread
So, the layout still not fixed?

10-02-2010 06:09 AM
Find all posts by this user Quote this message in a reply
leefish Offline
Hamster
*****
Posts: 1,009
Joined: Apr 2010
Post: #26
RE: Image Preview In Newthread
Nope, not fixed. May I ask what result you get on your MYBB 1.6 install using that template and display value?


[Image: leelink.gif]
MYBB1.6 & XThreads
10-02-2010 06:14 AM
Visit this user's website Find all posts by this user Quote this message in a reply
RateU Offline
Administrator
*******
Posts: 2,350
Joined: Mar 2010
Post: #27
RE: Image Preview In Newthread
I think I know the problem, Lee. Give me a little time.

10-02-2010 06:26 AM
Find all posts by this user Quote this message in a reply
RateU Offline
Administrator
*******
Posts: 2,350
Joined: Mar 2010
Post: #28
RE: Image Preview In Newthread
I'm sorry for bumping.

OK, Lee. Do you have the {$GLOBALS['threadfields']['key']['value']} variable in your postbit too?

10-02-2010 06:38 AM
Find all posts by this user Quote this message in a reply
leefish Offline
Hamster
*****
Posts: 1,009
Joined: Apr 2010
Post: #29
RE: Image Preview In Newthread
Ok RateU. Its got me baffled I must admit Ouch
You mean my postbit first? Yes, its all in there, not showthread.

HTML Code
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
{$ignore_bit}
<a name="pid{$post['pid']}" id="pid{$post['pid']}"></a>
<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder" style="{$post_extra_style} {$post_visibility}" id="post_{$post['pid']}">
	<tbody>
		<tr>
			<td class="tcat">
				<div class="float_left smalltext">
					{$post['postdate']}, {$post['posttime']} <span id="edited_by_{$post['pid']}"></span>
				</div>
				{$post['posturl']}
			</td>
		</tr>

		<tr>
			<td class="trow1 {$unapproved_shade}">
				<table cellspacing="0" cellpadding="0" border="0" style="width: 100%;">
					<tr>
						<td class="post_avatar" width="1" valign="bottom" style="{$post['avatar_padding']}">
						<img src="{$GLOBALS['threadfields']['pfpic']['url']}/thumb240x180" alt="" title="{$GLOBALS['threadfields']['pfname']}" />
						</td>
						<td class="post_author">
							<table border="0" width="40%" class="mediumtext">
								<tr>
									<td valign="top">Posted By</td>
									<td width="1" valign="top">:</td>
									<td valign="top"><strong><span class="mediumtext">{$post['profilelink']}</span></strong></td>
								</tr>
                                                                <tr>
									<td valign="top">Game Type</td>
									<td width="1" valign="top">:</td>
									<td valign="top">{$GLOBALS['threadfields']['prefix']}</td>
								</tr>
								<tr>
									<td valign="top">Game Category</td>
									<td width="1" valign="top">:</td>
									<td valign="top">{$GLOBALS['threadfields']['pfcat']}</td>
								</tr>
								<tr>
									<td valign="top">EPs Required</td>
									<td width="1" valign="top">:</td>
									<td valign="top">{$GLOBALS['threadfields']['dld_ep_prefix']}</td>
								</tr>
							</table>
						</td>
					</tr>
				</table>
			</td>
		</tr>

		<tr>
			<td class="trow2 post_content {$unapproved_shade}">
				<div class="largetext" align="center"><strong>{$post['subject']}</strong></div>
                                 
				<div class="post_body" id="pid_{$post['pid']}">
					{$post['message']}
					{$post['attachments']}<br />	

{$GLOBALS['threadfields']['fupload']['value']} 
{$GLOBALS['threadfields']['fupload2']['value']} 
{$GLOBALS['threadfields']['fupload4']['value']} 

<br />                        
<div class="tfoot" style="largetext"><strong>Screenshots<strong>
<div class="smalltext">Click on a thumbnail to bring up the light box</div></div>

 <div>
			{$GLOBALS['threadfields']['pfpic']['value']}
			{$GLOBALS['threadfields']['pfapic1']['value']}
			{$GLOBALS['threadfields']['pfapic2']['value']}
			{$GLOBALS['threadfields']['pfapic3']['value']}</div>


				<div class="post_meta" id="post_meta_{$post['pid']}">
				{$post['iplogged']}
				</div>
			</td>
		</tr>

		<tr>
			<td class="trow1 post_buttons {$unapproved_shade}">
				<div class="author">
					
				</div>
				<div class="postbutton">{$post['button_edit']}{$post['button_quickdelete']}{$post['button_quote']}{$post['button_report']}{$post['button_warn']}
				</div>
			</td>
   </tbody>
</table>



[Image: leelink.gif]
MYBB1.6 & XThreads
(This post was last modified: 10-02-2010 06:44 AM by leefish.)
10-02-2010 06:39 AM
Visit this user's website Find all posts by this user Quote this message in a reply
RateU Offline
Administrator
*******
Posts: 2,350
Joined: Mar 2010
Post: #30
RE: Image Preview In Newthread
EDIT:

OK. In this case, you need to move the layout inside the conditional to your previewpost template. It is under Ungrouped Templates. Create a new previewpost with a prefix.

Example:

HTML Code
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder" style="clear: both; border-bottom-width: 0;">
<tr>
<td class="thead" colspan="2"><strong>{$lang->post_preview}</strong></td>
</tr>
</table>
{$postbit}
<br />
<form>
<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder" style="clear: both; border-bottom-width: 0;">
	<tr><td class="thead" colspan="2"><strong>Images Preview</strong></td></tr>
	<tr><td class="tcat" align="center" colspan="2"><strong>Image 1 Preview &amp; URL</strong></td></tr>
	<tr>
		<td class="trow1" align="center">
			<img src="{$GLOBALS['threadfields']['pfpic']['url']}/thumb160x120" alt="" title="" />
		</td>
		<td class="trow1" valign="top">
			<div class="float_left" style="width: 50%;">
				<strong>BBCODE - 160 x 120 Thumbnail</strong>
				<input name="prev_img1_bbcode" type="text" size="40" value="[IMG]{$mybb->settings['bburl']}/{$GLOBALS['threadfields']['pfpic']['url']}/thumb160x120[/IMG]" readonly="readonly" />
				<input type="button" value="Select" onClick="javascript:this.form.prev_pfpic_bbcode.focus();this.form.prev_pfpic_bbcode.select();">
			</div>
			<div class="float_left" style="width: 50%;">
				<strong>Direct Link</strong><br />
				<input name="prev_pfpic_dl" type="text" size="40" value="<func htmlspecialchars_uni><a href="{$mybb->settings['bburl']}/{$GLOBALS['threadfields']['pfpic']['url']}/thumb160x120">{$GLOBALS['threadfields']['pfpic']['filename']}</a></func>" readonly="readonly" />
				<input type="button" value="Select" onClick="javascript:this.form.prev_pfpic_dl.focus();this.form.prev_pfpic_dl.select();">
			</div>
			<div class="float_left" style="width: 50%;">
				<strong>HTML Code - 160 x 120 Thumbnail</strong>
				<input name="prev_pfpic_html" type="text" size="40" value="<func htmlspecialchars_uni><img src="{$mybb->settings['bburl']}/{$GLOBALS['threadfields']['pfpic']['url']}/thumb160x120" alt="" title="" /></func>" readonly="readonly" />
				<input type="button" value="Select" onClick="javascript:this.form.prev_pfpic_html.focus();this.form.prev_pfpic_html.select();">
			</div>
			<div class="float_left" style="width: 50%;">
				<strong>Full Size Image URL</strong>
				<input name="prev_pfpic_full" type="text" size="40" value="{$mybb->settings['bburl']}/{$GLOBALS['threadfields']['pfpic']['url']}" readonly="readonly" />
				<input type="button" value="Select" onClick="javascript:this.form.prev_pfpic_full.focus();this.form.prev_pfpic_full.select();">
			</div>
		</td>
	</tr>
</table>
</form>
<br />


Leave the contents inside the else condition in your Display Format.
Remove other additional code there. So, it will like the code before you edit the Display Format.
The contents of your Display Format should be only like this:

HTML Code
<a href="{URL}" rel="lightbox[find]"><img src="{URL}/thumb160x120" alt="{$thread['subject']} Screenshot" title="{$GLOBALS['threadfields']['pfpicdesc']}" style="border: 1px solid #C1C1C1; padding: 3px; margin: 3px;" /></a>


(This post was last modified: 10-02-2010 06:53 AM by RateU.)
10-02-2010 06:43 AM
Find all posts by this user Quote this message in a reply

« Next Oldest | Next Newest »

 Standard Tools
Forum Jump: