Esato

Forum > General discussions > Esato forum > Random thread

Previous  12
Author Random thread
Deanlambert
T300
Joined: Sep 10, 2003
Posts: 466
From: East Yorkshire
PM
Posted: 2004-01-21 12:25
Reply with quoteEdit/Delete This PostPrint this post
No arguments from me on that 1. I've never had a problem on here. I honestly thought that the random thread wouldn't work on here. Looks like i was wrong. The only reason why i stay on this site is because problems are quickly sorted out. I know we all have a joke when the site goes down etc, but you have to have a laugh now and then. I've been proved wrong. I admit it.

This message was posted from a T300

pachy
P990 no flip
Joined: Nov 05, 2002
Posts: > 500
PM
Posted: 2004-01-21 19:10
Reply with quoteEdit/Delete This PostPrint this post
@Deanlambert, i thought you said RANSOM, lucky i checked again, i was on the verge of sending you ONE MILLION POUNDS IN USED NOTES to free the hostages in time for Easter, those poor souls need a shave & a hot meal, ....can i recommend a dish of Chicken Malabar £5.75;
(specialy cooked in North Kerala this Southern Indian tender chicken meal is cooked in roasted coconut sauce with tomato, spices & curry leaves),
Maybe with a Alo parata bread £1.75 (hot bread stuffed with Potato & herbs).
Best order 5 meals as this will easily serve 6 people.
Ask for a jug of tap water as the beer is a complete stitch
Reminder; milk, sugar, crisps, post letter.
Vlammetje
C702 Cyan
Joined: Mar 01, 2003
Posts: > 500
From: Den Haag
PM, WWW
Posted: 2004-01-21 19:44
Reply with quoteEdit/Delete This PostPrint this post
pachy


Laffen thanks...... although not necessarily useful I have just 'zapped' myself an Apple Theme thread and a thread for Siemens S55 users (Kerry where art thou?? ) so that was good fun
How did you do that so fast?


This is fun. Are garbage threads included in the random draw?

masseur
P910
Joined: Jan 03, 2003
Posts: > 500
From: Sydney, London
PM
Posted: 2004-01-21 19:57
Reply with quoteEdit/Delete This PostPrint this post
well I don't know php but I guess it was just a matter of generating a random number between 1 and n where n is the current maximum topic number and then appending that number to

http://www.esato.com/board/viewtopic.php?topic=

to give the final url for the random thread.

It occurred to me that some threads have been deleted so I have been trying to foil it but so far no luck maybe it was coded a bit cleverer to loop until a succesful thread was found
Deanlambert
T300
Joined: Sep 10, 2003
Posts: 466
From: East Yorkshire
PM
Posted: 2004-01-21 19:58
Reply with quoteEdit/Delete This PostPrint this post
In other words anything i have posted! See I've said it before you :-D

This message was posted from a T300

laffen
Sony Xperia Z5 Compact
Joined: Aug 07, 2001
Posts: > 500
From: Oslo, Norway
PM
Posted: 2004-01-21 20:11
Reply with quoteEdit/Delete This PostPrint this post
Garbage threads are included.
A simple SQL statement did the trick: "SELECT id FROM topics ORDER BY RAND() LIMIT 1" in addition to some access restriction stuff for the mod forum. Deleted threads will not turn up.
Vlammetje
C702 Cyan
Joined: Mar 01, 2003
Posts: > 500
From: Den Haag
PM, WWW
Posted: 2004-01-21 20:17
Reply with quoteEdit/Delete This PostPrint this post
Now Ima play 'gamble' until I turn a real old fun garbage thread up

thnx laffen


another potentially boring evening saved

(oh god I am pathetic )
masseur
P910
Joined: Jan 03, 2003
Posts: > 500
From: Sydney, London
PM
Posted: 2004-01-21 20:27
Reply with quoteEdit/Delete This PostPrint this post
oh yes, I never had a commercial use for the rand function in 15 years of RDB sql programming so didn't even think of that!

nice solution!

I guess I'll have to try harder to catch you out next time
floke
T68i
Joined: Jan 23, 2002
Posts: > 500
From: Sweden
PM, WWW
Posted: 2004-01-21 23:03
Reply with quoteEdit/Delete This PostPrint this post
This random function will really help me through boring days at work
It sure helped a lot today

A link to the random topic function should only be added to the forum homepage.
That way even people like Deanlambert that doesnt use search will find it too

@Deanlambert: You should try the search.. its really addictive
marlonxp
T610
Joined: Dec 11, 2003
Posts: > 500
From: Somewhere
PM, WWW
Posted: 2004-01-23 17:41
Reply with quoteEdit/Delete This PostPrint this post
here is a random answer dont

This message was posted from a WAP device

kurt04
T68 gold
Joined: Mar 12, 2004
Posts: 1
From: Vermont, USA
PM
Posted: 2004-03-12 04:45
Reply with quoteEdit/Delete This PostPrint this post
Quote:

On 2004-01-21 11:14:22, laffen wrote:
Try this one http://www.esato.com/board/randomtopic.php



Hi,

I'm looking for a thread randomizing script (php) to use on my board. I found yours using google. Is it possible to get a copy of this script? Thanks.
Access the forum with a mobile phone via esato.mobi