Thread Rating:
  • 2 Votes - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
 Download System
Yin Offline
Junior Member
**
Posts: 26
Joined: Mar 2012
Post: #111
RE: Download System
Hi again guys I just finished installing the downloads system on my site, but I am trying to accomplish this layout for displaying the download section:
http://www.14.mynie.co.cc/forumdisplay.php?fid=53

So far I have the vertical layout, but I'm having no luck getting it to be side by side.
What I have so far:
http://cavernofcreativity.com/Atlas/foru...http://cavernofcreativity.com/Atlas/forumdisplay.

Also, do you guys have a block for pro portal laying around somewhere here?
(This post was last modified: 03-09-2012 07:21 AM by Yin.)
03-09-2012 07:17 AM
Find all posts by this user Quote this message in a reply
RateU Offline
Administrator
*******
Posts: 2,350
Joined: Mar 2010
Post: #112
RE: Download System
About the layout: Do you mean the Category on the left, and the threads on the right? I do that like this:

HTML Code
1
2
3
4
5
6
7
8
9
10
<table ......>
<tr>
<td valign="top">
Left side (category)
</td>
<td valign="top">
Right side (threads)
</td>
</tr>
</table>

You can set the width (in percent or in px) for the left or the right column.
You can find the similar layout here (look at the xtldir_forumdisplay_threadlist template and the threadlist screenshots):
http://mybbhacks.zingaburga.com/showthre...http://mybbhacks.zingaburga.com/showthread.php?tid=398&pid=65

Or maybe you can use two div, left and right floated.

About Pro Portal Block: What block?


03-09-2012 08:16 AM
Find all posts by this user Quote this message in a reply
Yin Offline
Junior Member
**
Posts: 26
Joined: Mar 2012
Post: #113
RE: Download System
Thank you! I will try both methods to see which works better!

For blocks, I mean a block for latest downloads.
edit:
That code you gave with the valign="top" worked like a charm! Thanks!
(This post was last modified: 03-09-2012 08:51 AM by Yin.)
03-09-2012 08:20 AM
Find all posts by this user Quote this message in a reply
RateU Offline
Administrator
*******
Posts: 2,350
Joined: Mar 2010
Post: #114
RE: Download System
Try this attachment.
Edit these settings:

PHP Code:
$xtdldfid = 1;// Forum ID for XThreads Downloads
$xtdldlimit = 3;// Number of images to be displayed
$xtdlddim = '320x240';// Thumbs dimension to be displayed

If you change the thumb dimension, please make sure that the dimension is in the Image Thumbnail Generation setting of the Screenshot fields (fscr).



Attached File(s)
.php  block_latest_downloads.php (Size: 1.49 KB / Downloads: 354)

03-10-2012 05:53 AM
Find all posts by this user Quote this message in a reply
Yin Offline
Junior Member
**
Posts: 26
Joined: Mar 2012
Post: #115
RE: Download System
Perfect, this is just what I needed! Everything is working perfectly now. Although I tried to get the vertical table in the showthread as well, but it kept coming out weird, so I just made it horizontal. Do you know where I'd put the table to have it show up like the main download page?

http://cavernofcreativity.com/Atlas/foru...http://cavernofcreativity.com/Atlas/forumdisplay.
This is how I want it to show up in the showthread template.

http://cavernofcreativity.com/Atlas/show...http://cavernofcreativity.com/Atlas/showthread.
This is how I have it now (when you click into the download), but where would I put the vertical table so that it shows up like the downloads page with the vertical menu on the side?
03-10-2012 06:05 AM
Find all posts by this user Quote this message in a reply
RateU Offline
Administrator
*******
Posts: 2,350
Joined: Mar 2010
Post: #116
RE: Download System
You can do that with a similar method in your dld_showthread template.
Here is a simple example for that:

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
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
<html>
<head>
<title>{$thread['subject']}</title>
{$headerinclude}
<script type="text/javascript">
<!--
	var quickdelete_confirm = "{$lang->quickdelete_confirm}";
// -->
</script>
<script type="text/javascript" src="jscripts/thread.js?ver=1400"></script>
</head>
<body>
	{$header}
	{$pollbox}
	<div class="float_left">
		{$multipage}
	</div>
	<div class="float_right">
		{$newreply}
	</div>
	{$ratethread}
	<br class="clear" />
	<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" style="clear: both; width: 100%;">
		<tr>
			<td valign="top">
				<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder">
					<tr>
						<td class="thead">
							<div><strong>Category</strong></div>
						</td>
					</tr>
					<tr>
						<td class="trow1">
							Category 1
						</td>
					</tr>
					<tr>
						<td class="trow1">
							Category 2
						</td>
					</tr>
					<tr>
						<td class="trow1">
							Category 3
						</td>
					</tr>
				</table>
			</td>
			<td valign="top">
				<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder" style="clear: both; border-bottom-width: 0;">
					<tr>
						<td class="thead" colspan="2">
							<div style="float: right;">
								<span class="smalltext"><strong><a href="showthread.php?mode=threaded&amp;tid={$tid}&amp;pid={$pid}#pid{$pid}">{$lang->threaded}</a> | <a href="showthread.php?mode=linear&amp;tid={$tid}&amp;pid={$pid}#pid{$pid}">{$lang->linear}</a></strong></span>
							</div>
							<div>
								<strong>{$thread['subject']}</strong>
							</div>
						</td>
					</tr>
					<tr>
						<td class="tcat" colspan="2">
							<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder" style="clear: both;">
								<tr>
									<td class="trow1" width="40%">
										<table border="0" width="100%">
											<tr>
												<td>File Name</td><td width="1">:</td>
												<td>{$GLOBALS['threadfields']['fupload']['filename']}</td>
											</tr>
											<tr>
												<td>File Size</td><td>:</td>
												<td>{$GLOBALS['threadfields']['fupload']['filesize_friendly']}</td>
											</tr>
											<tr>
												<td>Uploaded</td><td>:</td>
												<td>{$GLOBALS['threadfields']['fupload']['upload_date']}</td>
											</tr>
											<tr>
												<td>Last Update</td><td>:</td>
												<td>{$GLOBALS['threadfields']['fupload']['update_date']}</td>
											</tr>
											<tr>
												<td>Downloaded</td><td>:</td>
												<td>{$GLOBALS['threadfields']['fupload']['downloads_friendly']}</td>
											</tr>
										</table>
									</td>
				
									<td class="trow1" width="60%">
										<div align="center">
											<a href="{$GLOBALS['threadfields']['fscr']['url']}" target="_blank"><img src="{$GLOBALS['threadfields']['fscr']['thumbs']['320x240']['url']}" alt="{$thread['subject']} Screenshot" title="{$thread['subject']} Screenshot" width="{$GLOBALS['threadfields']['fscr']['thumbs']['320x240']['w']}" height="{$GLOBALS['threadfields']['fscr']['thumbs']['320x240']['h']}" /></a>
										</div>
									</td>
								</tr>
								<tr>
									<td class="trow1" colspan="2">
										<span class="float_left smalltext">
											{$GLOBALS['threadfields']['fupload']['value']}
										</span>
										<span class="float_right smalltext">
											<em>
											Category: {$GLOBALS['threadfields']['fcat']}
											{$lang->views} {$thread['views']},
											{$lang->replies} <a href="javascript:MyBB.whoPosted({$thread['tid']});">{$thread['replies']}</a>{$unapproved_posts} 
											</em>
										</span>
									</td>
								</tr>
							</table>
						</td>
					</tr>
					{$classic_header}
				</table>
				<div id="posts">
					{$first_post}{$posts}
				</div>
				<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder" style="border-top-width: 0;">
					<tr>
						<td colspan="2" class="tfoot">
							{$search_thread}
							<div>
								<strong>&laquo; <a href="{$next_oldest_link}">{$lang->next_oldest}</a> | <a href="{$next_newest_link}">{$lang->next_newest}</a> &raquo;</strong>
							</div>
						</td>
					</tr>
				</table>
			</td>
		</tr>
	</table>
	<div class="float_left">
		{$multipage}
	</div>
	<div style="padding-top: 4px;" class="float_right">
		{$newreply}
	</div>
	<br style="clear: both;" />
	{$quickreply}
	{$threadexbox}
	{$similarthreads}
	<br />
	<div class="float_left">
		<ul class="thread_tools">
			<li class="printable"><a href="printthread.php?tid={$tid}">{$lang->view_printable}</a></li>
			<li class="sendthread"><a href="sendthread.php?tid={$tid}">{$lang->send_thread}</a></li>
			<li class="subscription_{$add_remove_subscription}"><a href="usercp2.php?action={$add_remove_subscription}subscription&amp;tid={$tid}&amp;my_post_key={$mybb->post_code}">{$add_remove_subscription_text}</a></li>
		</ul>
	</div>

	<div class="float_right" style="text-align: right;">
		{$moderationoptions}
		{$forumjump}
	</div>
	<br style="clear: both;" />
	{$footer}
</body>
</html>

Modify it as your needs.


03-10-2012 08:08 AM
Find all posts by this user Quote this message in a reply
Yin Offline
Junior Member
**
Posts: 26
Joined: Mar 2012
Post: #117
RE: Download System
Oh my goodness, that works perfectly. I was stuck on that all day yesterday and a good chunk of today trying to get it to work before I finally gave up. You made my day! Biggrin Thank you!
03-10-2012 10:38 AM
Find all posts by this user Quote this message in a reply
Yin Offline
Junior Member
**
Posts: 26
Joined: Mar 2012
Post: #118
RE: Download System
Hey again, I'm using the downloads block that you attached, I can't put more than 1 fid in it. I could do it with the others, but not with this one. Is there a way to put more than one fid in it and have it work?
03-14-2012 01:06 PM
Find all posts by this user Quote this message in a reply
ZiNgA BuRgA Offline
Fag
*******
Posts: 3,357
Joined: Jan 2008
Post: #119
RE: Download System
My quick 5 second glance would suggest these changes - open up block_latest_downloads.php, find:

Code:
t.fid='.intval($xtdldfid).'

Replace with

Code:
t.fid IN ('.$xtdldfid.')


Then find the line

Code:
$xtdldfid = 1;// Forum ID for XThreads Downloads

change to

Code:
$xtdldfid = '1,2,3';// Comma separated list of forum IDs for XThreads Downloads


My Blog
03-14-2012 04:03 PM
Find all posts by this user Quote this message in a reply
Yin Offline
Junior Member
**
Posts: 26
Joined: Mar 2012
Post: #120
RE: Download System
Just tried it, it didn't work out. It's still only showing one fid. I used different template prefixes, file upload keys and category keys for all of them. Could that be why? Everything else is the same (screenshot key, author key and description key)

edit: It actually DOES work, I was pointing it to the wrong forum ID. (Was pointing it to the category housing the actual download forums) Thank you so much I appreciate the help!
(This post was last modified: 03-15-2012 08:26 AM by Yin.)
03-15-2012 01:29 AM
Find all posts by this user Quote this message in a reply

« Next Oldest | Next Newest »

 Standard Tools
Forum Jump: