Gossamer Forum
Home : General : Perl Programming :

wrapping long lines?

Quote Reply
wrapping long lines?
i'm using a censor bad words mod for dbman. the instructions contain the following:
Code:
## You can edit the @dirty_words list however you want. Just be sure to put
## single quotes around each word, keep the list all on one line, and be sure they
## are in lower case.
# Dirty word list
@dirty_words = ('fuck','shit','cocksucker','asshole','cunt','pussy','tits','bastard','bitch','piss');
why do the words have to be on one line? can i shift+enter to break line?
tks & pardon the language!
Quote Reply
Re: [delicia] wrapping long lines? In reply to
Hi,

I'm not sure what you mean? You could do it it multiple ways:

Code:
my @dirty_words = qw/aaa bbb ccc/;
my @dirty_words2 = ('aaa','bbb','ccc');
my @dirty_words3 = (
'aaa',
'bbb',
'ccc'
);

All are perfectly valid :)

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Quote Reply
Re: [Andy] wrapping long lines? In reply to
i didn't understand why the instructions said the words had to be on one line. according to your reply, they don't!
Quote Reply
Re: [delicia] wrapping long lines? In reply to
It could be that older versions of Perl didn't like it. Newer versions are fine though Angelic

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!