Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
 Image Preview In Newthread And Editpost
leefish Offline
Hamster
*****
Posts: 1,009
Joined: Apr 2010
Post: #31
RE: Image Preview In Newthread
I edited - thats my postbit.


[Image: leelink.gif]
MYBB1.6 & XThreads
10-02-2010 06:44 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: #32
RE: Image Preview In Newthread
(10-02-2010 06:43 AM)RateU Wrote:  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>


Sorry, Lee. I've edited my post too.

EDIT: Don't forget to remove the {$GLOBALS['threadfields']['pfpic']['value']} variable from your newthread template.

Other method:

Just change the {$GLOBALS['threadfields']['pfpic']['value']} variable in postbit to:

HTML Code
<a href="{$GLOBALS['threadfields']['pfpic']['url']}" rel="lightbox[find]"><img src="{$GLOBALS['threadfields']['pfpic']['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 07:14 AM by RateU.)
10-02-2010 06:54 AM
Find all posts by this user Quote this message in a reply
leefish Offline
Hamster
*****
Posts: 1,009
Joined: Apr 2010
Post: #33
RE: Image Preview In Newthread
RateU, you are indeed an awesome chap. If I could think of a way to help you as much as you have helped me (indeed all of us) I would. Right now, all I can offer is Thank You.


[Image: leelink.gif]
MYBB1.6 & XThreads
10-02-2010 07:11 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: #34
RE: Image Preview In Newthread
No, Lee. It is my mistake that my stupid brain not thinking about other {$GLOBALS['threadfields']['key']['value']} variable in postbit as soon as possible when I see your attachments. How stupid I am!!!

The reason why it happens to you is, the preview post calls postbit template. So, if we have the  {$GLOBALS['threadfields']['key']['value']} variable in our postbit template, the conditional "can't block" it, because it is still in newthread page. It's a bit hard for me to explain it Biggrin

I've added other solution in above post if you encounter the same problem. Maybe more flexible and simple. But if the previous solution has solved the problem, I think it is not needed.

(This post was last modified: 10-02-2010 07:31 AM by RateU.)
10-02-2010 07:27 AM
Find all posts by this user Quote this message in a reply
leefish Offline
Hamster
*****
Posts: 1,009
Joined: Apr 2010
Post: #35
RE: Image Preview In Newthread
I saw the second solution I like it - its more elegant somehow. I shall use that solution. Hopefully this thread will be good for another Xthreads user who has used postbit _first for the variables and likes the post preview idea.


[Image: leelink.gif]
MYBB1.6 & XThreads
10-02-2010 07:56 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: #36
RE: Image Preview In Newthread
Gladly XThreads provides us the "partial" variable to "compose" the {$GLOBALS['threadfields']['key']['value']} variable "manually" using {$GLOBALS['threadfields']['key']['item']}. We can feel it that it is very flexible Smile

10-03-2010 07:18 AM
Find all posts by this user Quote this message in a reply
ZiNgA BuRgA Offline
Fag
*******
Posts: 3,357
Joined: Jan 2008
Post: #37
RE: Image Preview In Newthread And Editpost
Trying this it, it appears that "this.form" isn't always an object (in Opera).
Probably document.getElementById() is more reliable (with changes in ID).

Hope that helps.

My Blog
10-26-2010 08:10 PM
Find all posts by this user Quote this message in a reply
RateU Offline
Administrator
*******
Posts: 2,350
Joined: Mar 2010
Post: #38
RE: Image Preview In Newthread And Editpost
Do you mean like this, Yumi?
Display Format:

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
<if THIS_SCRIPT == 'newthread.php' || THIS_SCRIPT == 'editpost.php' then>
	<tr>
		<td class="trow_sep" align="center" colspan="2"><strong>Image 1 Preview &amp; URL</strong></td>
	</tr>
	<tr>
		<td class="trow1" align="center">
			<img src="{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" id="img1_bbcode" type="text" size="40" value="[IMG]{$mybb->settings['bburl']}/{URL}/thumb160x120[/IMG]" readonly="readonly" />
				<input type="button" value="Select" onClick="document.getElementById('img1_bbcode').focus();document.getElementById('img1_bbcode').select();">
			</div>
			<div class="float_left" style="width: 50%;">
				<strong>Direct Link</strong><br />
				<input name="prev_img1_dl" id="img1_dl" size="40" value="&lt;a href=&quot;{$mybb->settings['bburl']}/{URL}/thumb160x120&quot;&gt;{FILENAME}&lt;/a&gt;" readonly="readonly" />
				<input type="button" value="Select" onClick="document.getElementById('img1_dl').focus();document.getElementById('img1_dl').select();">
			</div>
			<div class="float_left" style="width: 50%;">
				<strong>HTML Code - 160 x 120 Thumbnail</strong>
				<input name="prev_img1_html" id="img1_html" type="text" size="40" value="&lt;img src=&quot;{$mybb->settings['bburl']}/{URL}/thumb160x120&quot; alt=&quot;&quot; title=&quot;&quot; /&gt;" readonly="readonly" />
				<input type="button" value="Select" onClick="document.getElementById('img1_html').focus();document.getElementById('img1_html').select();">
			</div>
			<div class="float_left" style="width: 50%;">
				<strong>Full Size Image URL</strong>
				<input name="prev_img1_full" id="img1_full" type="text" size="40" value="{$mybb->settings['bburl']}/{URL}" readonly="readonly" />
				<input type="button" value="Select" onClick="document.getElementById('img1_full').focus();document.getElementById('img1_full').select();">
			</div>
		</td>
	</tr>
</if>


10-27-2010 05:26 AM
Find all posts by this user Quote this message in a reply
ZiNgA BuRgA Offline
Fag
*******
Posts: 3,357
Joined: Jan 2008
Post: #39
RE: Image Preview In Newthread And Editpost
Yeah, I think so.
But that's weird too, this.form should be valid... http://www.w3schools.com/jsref/prop_button_form.asp

Maybe I should try looking into it more when I get home.

My Blog
10-27-2010 09:16 AM
Find all posts by this user Quote this message in a reply
leefish Offline
Hamster
*****
Posts: 1,009
Joined: Apr 2010
Post: #40
RE: Image Preview In Newthread And Editpost
Well, after several hours of trying I cannot get this to work when editing my post - I already reported it and Zinga says he gets it to change no problem.... I don't get it at all. This is my post from the other day (and Zinga's reply)

(10-26-2010 11:31 AM)leefish Wrote:  Hi
I am using a template modification posted by RateU to show preview images of uploaded attachments. Link to modification

I received a report from a user that the preview function when editing a post only shows the new attachment image once the post has been updated (i.e. posted on the forum).

If they click preview post before that then the old image is still showing in the preview even though they have chosen a replacement image. It would make more sense if it showed the updated image, though I do realise they have not yet actually attached the replacement - only indicated they wish to do so. I was wondering if this would be something that I could change in the template or if it was part of the Xthreads code?

(10-26-2010 08:15 PM)ZiNgA BuRgA Wrote:  I can't seem to reproduce this with MyBB 1.6 and XThreads 1.32.
Did the modification, made a thread with an attached image, did a full edit.  Ticked the replace checkbox, selected a new image and hit preview post.  The new image displayed for me...

So, in order to get this to work I moved my images to the showthread template instead of first post and removed the else statement in my Custom Thread Field - its the same as before - no change in the preview and I have the code in my Custom Thread Field Display format exactly as in Rateus template in this thread (except that my image key is called pfpic not img).

I have a customised New Thread Template and a customised Edit Thread Template. I did not edit the post preview template as I am trying to keep as close to RateU's original set up as I can.

These are my templates:

prefix_editpost_first

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
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
<html>
<head>
<title>{$mybb->settings['bbname']} - {$lang->edit_post}</title>
{$headerinclude}
<script type="text/javascript" src="jscripts/post.js?ver=1400"></script>
</head>
<body>
{$header}
{$preview}
{$post_errors}
{$attacherror}
<form action="editpost.php?pid={$pid}&amp;processed=1" method="post" enctype="multipart/form-data" name="input">
	<input type="hidden" name="my_post_key" value="{$mybb->post_code}" />
	<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder">

<tbody>

		<tr><td class="thead" colspan="2"><strong>LeeFish Upload Wizard</strong></td></tr>
				<tr>
			<td class="trow_sep" colspan="2">
		<div class="float_left" style="margin-left: 19px;">Item Name:</div>
				<div class="float_left" style="margin-left: 9px;"><input type="text" class="textbox" name="subject" size="50" maxlength="85" value="{$subject}" tabindex="1" /></div>
					</td>

		</tr>
		
		<tr><td class="tfoot" colspan="6"><strong>Required Information</strong></td></tr>
		<tr>
			<td class="tcat" colspan="6" style="smalltext">
				<div class="smalltext"><em>Select the information for your upload from the dropdown boxes. You can select multiple EPs - hold CTRL and choose the EPs. Be careful which base game you choose....</em></div><br/>
			</td>
		</tr>
		<tr>
			<td class="trow2" colspan="6">
				<div class="float_left">Game:</div>
				<div class="float_left" style="margin-left: 9px;">{$tfinput['prefix']}</div>
				<div class="float_left" style="margin-left: 19px;">EP(s):</div>
				<div class="float_left" style="margin-left: 9px;">{$tfinput['dld_ep_prefix']} </div>
				<div class="float_left" style="margin-left: 19px;">Category:</div>
				<div class="float_left" style="margin-left: 9px;">{$tfinput['pfcat']}</div>
			</td>
		</tr>

</tbody>
<tbody>
		<tr><td class="tfoot" colspan="8"><strong>Screenshots</strong></td></tr>
		<tr>
			<td class="tcat" colspan="8" style="smalltext">
				<div class="smalltext"><em>You can have up to 4 screenshots - file size is max 200kb, max dimensions 1000*800. Accepted images formats are png, gif and jpg. Images will only be shown full size in the light box - please do not use large images inline with the text as it will break the layouts - instead, use the preview post button and select the bbcoded large thumb to use in the main body. If you get an <strong>attachment error</strong> please check that you have correct FILE TYPE, DIMENSIONS and FILE SIZE.</em></div>
			</td>
		</tr>
<tr class="trow2">
				<td class="trow1" width="50%"><div>Screenshot 1: | This is your preview thumbnail</div></td>
				<td class="trow1" width="50%"><div>Screenshot 2: | Optional picture</div></td>

</tr>
<tr></tr>
<tr class="trow1">

				<td class="trow1" width="50%"><div>{$tfinput['pfpic']}</div></td>
				<td class="trow1" width="50%"><div>{$tfinput['pfapic1']}</div></td>
</tr>
<tr></tr>
</tr>
<tr class="trow2">
				<td class="trow1" width="50%"><div>Screenshot 3: | Optional picture</div></td>
				<td class="trow1" width="50%"><div>Screenshot 4: | Optional picture</div></td>

</tr>
<tr></tr>
<tr class="trow1">

				<td class="trow1" width="50%"><div>{$tfinput['pfapic2']}</div></td>
				<td class="trow1" width="50%"><div>{$tfinput['pfapic3']}</div></td>
</tr>
		</tbody>
<tbody>
<tr></tr>
		<tr><td class="tfoot" colspan="8"><strong>File Upload</strong></td></tr>
		<tr>
			<td class="tcat" colspan="8" style="smalltext">
				<div class="smalltext"><em>You can have up to 3 files in an upload - file size is max 2mb, accepted formats are zip and rar. Please do not upload double rars or double files - server storage space is limited. You can choose to upload a file from your computer or from an url; uploading from the url is not a hotlink - it is uploaded via a file check program to the server. Its handiest for pictures in the finds area..... If you get an <strong>attachment error</strong> please check that you have correct FILE TYPE  and FILE SIZE. If you have a larger file that you wish to upload please contact LeeFish via PM.</em></div>
			</td>
		</tr>
<tr class="trow2">
				<td class="trow1" width="50%"><div>File 1: | Required File</div></td>
				<td class="trow1" width="50%"><div>File 2: | Optional file</div></td>

</tr>
<tr></tr>
<tr class="trow1">

				<td class="trow1" width="50%"><div>{$tfinput['fupload']}</div></td>
				<td class="trow1" width="50%"><div>{$tfinput['fupload2']}</div></td>
</tr>
<tr></tr>

<tr></tr>


<tr class="trow2">
				<td class="trow1" width="50%"><div>File 3: | Optional file</div></td>
				<td class="trow1" width="50%"><div></div></td>


</tr>
<tr></tr>
<tr class="trow1">


				<td class="trow1" width="50%"><div>{$tfinput['fupload4']}</div></td>
				<td class="trow1" width="50%"><div></div></td>
</tr>

		</tbody>
<tbody>
<tr>

			<td class="trow1" colspan="2">
				Some handy tips for uploading: once you have added all the pictures and files hit post preview; you can then see a small thumb of the pictures you have uploaded and a preview of the post. Like many forums we have bb code so you can make text bold, coloured, big small etc. I usually have one picture in the post preview, then a little preamble of text and then one picture in the post body (you can have more - all four if you wish) followed by information about the item - poly count, recolourable channels, price etc.  Its up to you how you do it though - its <em>YOUR</em> upload 
			</td><br /></br />
		</tr>

</table>
<br/>

<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder">

<tbody>
<tr>
<td class="thead" colspan="2">
</tr>
<if $GLOBALS['mybb']->user['usergroup'] == 4 || $GLOBALS['mybb']->user['usergroup'] == 8 then>{$tfinputrow['csbscr']}</if>
{$GLOBALS['threadfields']['pfpic']['value']}
{$GLOBALS['threadfields']['pfapic1']['value']}
{$GLOBALS['threadfields']['pfapic2']['value']}
{$GLOBALS['threadfields']['pfapic3']['value']}
{$tfinputrow['featureportal']}
{$tfinputrow['xtdispportal']}
{$tfinputrow['xtnewsbar']}
{$tfinputrow['xtnewsbar_class']}
{$tfinputrow['xtnewsbar_prefix']}
<tr>
<td class="trow1" width="20%">
</td>
<td class="trow1"width="80%">
</td>

<tr>
<td class="trow1" colspan="6" style="vertical-align: top">
<strong>Game Icon:</strong>
<br/>
<span class="smalltext">
<label>
<input type="radio" class="radio" name="icon" value="-1" checked="checked"/>
no icon
</label>
</span>
&nbsp;
<label>
<input type="radio" name="icon" value="21"/>
<img src="images/icons/sims2icon.png" alt="sims2"/>
</label>

<label>
<input type="radio" name="icon" value="22"/>
<img src="images/icons/sims3icon.png" alt="sims2"/>
</label>
</td>
</tr>


{$codebuttons}
<tr>
<td class="trow2" valign="top"><strong>Your Upload Text</strong>{$smilieinserter}</td>
<td class="trow2">
<textarea name="message" id="message" rows="20" cols="80" tabindex="2">{$message}</textarea>

{$multiquote_external}
</td>
</tr>
<tr>
<td class="trow1" valign="top"><strong>{$lang->post_options}</strong></td>
<td class="trow1"><span class="smalltext">


{$disablesmilies}</span></td>
</tr>
{$modoptions}
{$subscriptionmethod}
</tbody>
{$captcha}
</table>
<br />
	<div align="center"><input type="submit" class="button" name="submit" value="{$lang->update_post}" tabindex="3" />  <input type="submit" class="button" name="previewpost" value="{$lang->preview_post}" tabindex="4" /></div>
	<input type="hidden" name="action" value="do_editpost" />
	<input type="hidden" name="posthash" value="{$posthash}" />
	<input type="hidden" name="attachmentaid" value="" />
	<input type="hidden" name="attachmentact" value="" />
</form>
<br />
<form action="editpost.php" method="post" name="editpost">
	<input type="hidden" name="my_post_key" value="{$mybb->post_code}" />
	<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder">
		<tr>
			<td class="thead" colspan="3"><strong>{$lang->delete_post}</strong></td>
		</tr>
		<tr>
			<td class="trow1" style="white-space: nowrap"><input type="checkbox" class="checkbox" name="delete" value="1" tabindex="9" /> <strong>{$lang->delete_q}</strong></td>
			<td class="trow1" width="100%">{$lang->delete_1}<br /><span class="smalltext">{$lang->delete_2}</span></td>
			<td class="trow1"><input type="submit" class="button" name="submit" value="{$lang->delete_now}" tabindex="10" /></td>
		</tr>
	</table>
	<input type="hidden" name="action" value="deletepost" />
	<input type="hidden" name="pid" value="{$pid}" />
</form>
{$forumrules}
{$footer}
</body>
</html>


prefix_newthread

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
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
<html>
<head>
<title>{$lang->newthread_in}</title>
{$headerinclude}
<script type="text/javascript" src="jscripts/post.js?ver=1400"></script>
</head>
<body>
{$header}
{$preview}
{$thread_errors}
{$attacherror}
<form action="newthread.php?fid={$fid}&amp;processed=1" method="post" enctype="multipart/form-data" name="input">
	<input type="hidden" name="my_post_key" value="{$mybb->post_code}" />
	<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder">
<tbody>
		<tr><td class="thead" colspan="2"><strong>LeeFish Upload Wizard</strong></td></tr>
				<tr>
			<td class="trow_sep" colspan="2">
		<div class="float_left" style="margin-left: 19px;">Item Name:</div>
				<div class="float_left" style="margin-left: 9px;"><input type="text" class="textbox" name="subject" size="50" maxlength="85" value="{$subject}" tabindex="1" /></div>
					</td>
		</tr>
		<tr><td class="tfoot" colspan="6"><strong>Required Information</strong></td></tr>
		<tr>
			<td class="tcat" colspan="6" style="smalltext">
				<div class="smalltext"><em>Select the information for your upload from the dropdown boxes. You can select multiple EPs - hold CTRL and choose the EPs. Be careful which base game you choose....</em></div><br/>
			</td>
		</tr>
		<tr>
			<td class="trow2" colspan="6">
				<div class="float_left">Game:</div>
				<div class="float_left" style="margin-left: 9px;">{$tfinput['prefix']}</div>
				<div class="float_left" style="margin-left: 19px;">EP(s) required:</div>
				<div class="float_left" style="margin-left: 9px;">{$tfinput['dld_ep_prefix']} </div>
				<div class="float_left" style="margin-left: 19px;">Category:</div>
				<div class="float_left" style="margin-left: 9px;">{$tfinput['pfcat']}</div>
			</td>
		</tr>

</tbody>
<tbody>
		<tr><td class="tfoot" colspan="8"><strong>Screenshots</strong></td></tr>
		<tr>
			<td class="tcat" colspan="8" style="smalltext">
				<div class="smalltext"><em>You can have up to 4 screenshots - file size is max 200kb, max dimensions 1000*800. Accepted images formats are png, gif and jpg. You can choose to upload a file from your computer or from an url; uploading from the url is not a hotlink - it is uploaded via a file check program to the server. Its handiest for pictures in the finds area..... Images will only be shown full size in the light box - please do not use large images inline with the text as it will break the layouts - instead, use the preview post button and select the bbcoded large thumb to use in the main body. If you get an <span style="color:red;"><strong>attachment error</strong></span> please check that you have correct FILE TYPE, DIMENSIONS and FILE SIZE.</em></div>
			</td>
		</tr>
<tr class="trow2">
				<td class="trow1" width="50%"><div>Screenshot 1: | This is your preview thumbnail</div></td>
				<td class="trow1" width="50%"><div>Screenshot 2: | Optional picture</div></td>
</tr>
<tr></tr>
<tr class="trow1">
				<td class="trow1" width="50%"><div>{$tfinput['pfpic']}</div></td>
				<td class="trow1" width="50%"><div>{$tfinput['pfapic1']}</div></td>
</tr>
<tr></tr>
</tr>
<tr class="trow2">
				<td class="trow1" width="50%"><div>Screenshot 3: | Optional picture</div></td>
				<td class="trow1" width="50%"><div>Screenshot 4: | Optional picture</div></td>
</tr>
<tr></tr>
<tr class="trow1">

				<td class="trow1" width="50%"><div>{$tfinput['pfapic2']}</div></td>
				<td class="trow1" width="50%"><div>{$tfinput['pfapic3']}</div></td>
</tr>
</tbody>
<tbody>
<tr></tr>
		<tr><td class="tfoot" colspan="8"><strong>File Upload</strong></td></tr>
		<tr>
			<td class="tcat" colspan="8" style="smalltext">
				<div class="smalltext"><em>You can have up to 3 files in an upload - file size is max 2mb, accepted formats are zip and rar. Please do not upload double rars or double files - server storage space is limited. You can choose to upload a file from your computer or from an url; but uploading from an URL will not work as it is uploaded via a file check program to the server, and the program is paranoid. If you get an <span style="color:red;"><strong>attachment error</strong></span> please check that you have correct FILE TYPE  and FILE SIZE and are not attempting to upload an URL type thing. If you have a larger file that you wish to upload please contact LeeFish via PM.</em></div>
			</td>
		</tr>
<tr class="trow2">
				<td class="trow1" width="50%"><div>File 1: | Required File</div></td>
				<td class="trow1" width="50%"><div>File 2: | Optional file</div></td>
</tr>
<tr></tr>
<tr class="trow1">
				<td class="trow1" width="50%"><div>{$tfinput['fupload']}</div></td>
				<td class="trow1" width="50%"><div>{$tfinput['fupload2']}</div></td>
</tr>
<tr></tr>
<tr></tr>
<tr class="trow2">
				<td class="trow1" width="50%"><div>File 3: | Optional file</div></td>
				<td class="trow1" width="50%"><div></div></td>
</tr>
<tr></tr>
<tr class="trow1">
				<td class="trow1" width="50%"><div>{$tfinput['fupload4']}</div></td>
				<td class="trow1" width="50%"><div></div></td>
</tr>
</tbody>
<tbody>
<tr>
			<td class="trow1" colspan="2">
				Some handy tips for uploading: once you have added all the pictures and files hit post preview; you can then see a small thumb of the pictures you have uploaded and a preview of the post. Like many forums we have bb code so you can make text bold, coloured, big small etc. I usually have one picture in the post preview, then a little preamble of text and then one picture in the post body (you can have more - all four if you wish) followed by information about the item - poly count, recolourable channels, price etc.  Its up to you how you do it though - its <em>YOUR</em> upload 
			</td><br /></br />
		</tr>

</table>
<br/>
<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder">
<tbody>
<tr>
<td class="thead" colspan="2">
</tr>
<if $GLOBALS['mybb']->user['usergroup'] == 4 || $GLOBALS['mybb']->user['usergroup'] == 8 then>{$tfinputrow['csbscr']}</if>
{$GLOBALS['threadfields']['pfpic']['value']}
{$GLOBALS['threadfields']['pfapic1']['value']}
{$GLOBALS['threadfields']['pfapic2']['value']}
{$GLOBALS['threadfields']['pfapic3']['value']}
<tr>
<td class="trow1" width="20%">
</td>
<td class="trow1"width="80%">
</td>
<tr>
<td class="trow1" colspan="6" style="vertical-align: top">
<strong>Game Icon:</strong>
<br/>
<span class="smalltext">
<label>
<input type="radio" class="radio" name="icon" value="-1" checked="checked"/>
no icon
</label>
</span>
&nbsp;
<label>
<input type="radio" name="icon" value="21"/>
<img src="images/icons/sims2icon.png" alt="sims2"/>
</label>

<label>
<input type="radio" name="icon" value="22"/>
<img src="images/icons/sims3icon.png" alt="sims2"/>
</label>
</td>
</tr>
{$codebuttons}
<tr>
<td class="trow2" valign="top"><strong>Your Upload Text</strong>{$smilieinserter}</td>
<td class="trow2">
<textarea name="message" id="message" rows="20" cols="80" tabindex="2">{$message}</textarea>
{$multiquote_external}
</td>
</tr>
<tr>
<td class="trow1" valign="top"><strong>{$lang->post_options}</strong></td>
<td class="trow1"><span class="smalltext">
{$disablesmilies}</span></td>
</tr>
{$modoptions}
{$subscriptionmethod}
</tbody>
{$captcha}
</table>
<br />
<div style="text-align:center"><input type="submit" class="button" name="submit" value="{$lang->post_thread}" tabindex="4" accesskey="s" />  <input type="submit" class="button" name="previewpost" value="{$lang->preview_post}" tabindex="5" />{$savedraftbutton}</div>
<input type="hidden" name="action" value="do_newthread" />
<input type="hidden" name="posthash" value="{$posthash}" />
<input type="hidden" name="attachmentaid" value="" />
<input type="hidden" name="attachmentact" value="" />
<input type="hidden" name="quoted_ids" value="{$quoted_ids}" />
<input type="hidden" name="tid" value="{$tid}" />
{$editdraftpid}
</form>
{$forumrules}
{$footer}
</body>
</html>


Display Format

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
<if THIS_SCRIPT == 'newthread.php' OR THIS_SCRIPT == 'editpost.php' then>
<tr><td class="trow2" style="smalltext" colspan="2"><em>Use the select button to select an URL , hit ctrl+C and copy into your post. Just one inline pic please - it keeps the post tidy</em></td></tr>
	<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 - 640 x 480 Thumbnail</strong><br />
				<input name="prev_pfpic_bbcode" type="text" size="40" value="[IMG]{$mybb->settings['bburl']}/{$GLOBALS['threadfields']['pfpic']['url']}/thumb640x480[/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><br />
				<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><br />
				<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>
</if>


I'm sorry to be a pain and I have no idea what can be causing this. The forum is set up with first post to show on every page and a fixed horizontal postbit.

EDIT >> and that was it - the first post being fixed to show on every page made this NOT work (based on the info on the github I turned the show first post option off and BOOM - it worked).

So, will there be a fix for this coming out? My layout looks stupid without the first post on every page option....



[Image: leelink.gif]
MYBB1.6 & XThreads
(This post was last modified: 10-29-2010 02:27 AM by leefish.)
10-29-2010 02:15 AM
Visit this user's website Find all posts by this user Quote this message in a reply

« Next Oldest | Next Newest »

 Standard Tools
Forum Jump: