Nick
VIP
v5 Beta Tester[M:5000]
Philadelphia Eagles: 8-8
Posts: 2,239
|
Post by Nick on Nov 8, 2010 3:45:01 GMT
I started making a forum system a couple weeks before I joined this forum, but I haven't got to work on it for awhile. I started back up yesterday. I am making the category/board system. I just made the category system work with an admin feature to create a new category. I just need some code that will decide how to order them. I am a little worn out and I can't really think, so any ideas?
|
|
Cam
Administrator
[M:5000]
Posts: 6,381
|
Post by Cam on Nov 8, 2010 4:34:25 GMT
Sounds good! I will post ideas later, got to run Sounds good though, good start ;D
|
|
xcessive
Epic Poster
.[M:5000]
Posts: 526
|
Post by xcessive on Nov 8, 2010 6:31:38 GMT
...lol
SELECT * FROM whatever ORDER BY DESC
|
|
russellr
Elite Level 1
[M:5000]
rCs?
Posts: 525
|
Post by russellr on Nov 8, 2010 9:03:32 GMT
Yes ^ that could use the Id or just make an order line all depends really....
|
|
Nick
VIP
v5 Beta Tester[M:5000]
Philadelphia Eagles: 8-8
Posts: 2,239
|
Post by Nick on Nov 8, 2010 15:01:59 GMT
Yeah, I have that part. What I meant, is how to insert the order number. Like in Pb where it asks where you want to place it (above/below) a certain category.
|
|
russellr
Elite Level 1
[M:5000]
rCs?
Posts: 525
|
Post by russellr on Nov 8, 2010 15:36:43 GMT
Create another column with your board and add it to the query....
|
|
Nick
VIP
v5 Beta Tester[M:5000]
Philadelphia Eagles: 8-8
Posts: 2,239
|
Post by Nick on Nov 8, 2010 15:54:10 GMT
I think I know what to do now, but itll be a long function
|
|
russellr
Elite Level 1
[M:5000]
rCs?
Posts: 525
|
Post by russellr on Nov 8, 2010 16:36:43 GMT
Could just be SELECT * FROM table_name ORDER BY order_col DESC
thats not too long
|
|
Nick
VIP
v5 Beta Tester[M:5000]
Philadelphia Eagles: 8-8
Posts: 2,239
|
Post by Nick on Nov 8, 2010 17:37:39 GMT
I meant inserting the order and making sure none are the same number
|
|
russellr
Elite Level 1
[M:5000]
rCs?
Posts: 525
|
Post by russellr on Nov 8, 2010 18:29:28 GMT
Well it would not matter if they are the same number really as you could set it to order by a-b in title if the same and then select order number in admin panel :/ But yes it slightly longer function but it does the job and thats all the matters really.
|
|