Main Stories
Slash Boxes

Slash Open Source Project

Slashcode Log In

Log In

[ Create a new account ]

Article Poll

Poll I found this article to be
Very Helpful
Helpful
Not Helpful
Not Very Helpful
[ Results | Polls ]
Comments:0 | Votes:0

Trouble with Fortunes

posted by Krow on 01:31 PM February 23rd, 2002   Printer-friendly   Email story
Here's the situation: I'm trying to make the motd block contain quotes that I want to see, that are relevant to my site. Here's what I've done:
Created text file with quotes (myfile). Ran strfile -r myfile. Changed procedure in slashd to:
sub newmotd {
chomp(my $t = `/usr/games/fortune myfile`);
setblock('motd', $t) if $t;
}

Additionally, I'm running Slash 1.0.9 (Slashhosting.com). This works for the first few quotes, but then starts retrieving quotes from the default database. I can't figure out what's happening, and I've read all the FMs. Does anyone have any advice?
This discussion has been archived. No new comments can be posted.
The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login
Loading... please wait.