Filter subject

Tips on writing regular expressions for searching the post list

Moderators: Quade, dexter

Filter subject

Postby ozzii » Tue Mar 14, 2006 5:57 am

Hi!

I'm a newbee and I've got a little question.
I would like to not see (with the help of filter) the subject with (for example) words sex AND paypal.

How can I do to have this filter working.
Normaly, the characters can be upper case or mixed, and can have vary (like sexs)

Help please. :?: :oops:

P.S. I read the "NewsBin Regular Expression Parsing Capabilities" but my english is not so good.
ozzii
Seasoned User
Seasoned User
 
Posts: 410
Joined: Thu Feb 23, 2006 6:10 pm
Location: France

Registered Newsbin User since: 02/23/06

Postby DThor » Tue Mar 14, 2006 10:56 am

Unfortunately Regular Expressions don't have a "not" - it's designed to search for things, not exclude things.

Ugh, that's probably hard to translate, sorry. :) Essentially Regex isn't very good for censorship.

DT
V6 Troubleshooting FAQ . V6 docs. Usenet info at Usenet Tools. Thanks!
User avatar
DThor
Elite NewsBin User
Elite NewsBin User
 
Posts: 5943
Joined: Mon Jul 01, 2002 9:50 am

Registered Newsbin User since: 04/01/03

Postby obvious » Tue Mar 14, 2006 10:59 am

User avatar
obvious
Seasoned User
Seasoned User
 
Posts: 584
Joined: Wed Jun 06, 2001 8:30 pm

Registered Newsbin User since: 04/13/03

Postby ozzii » Tue Mar 14, 2006 11:00 am

If I put the expression into the exclude subject into a filter, I didn't see the subject.
But I don't know how to have an "AND" expression.

P.S. Voted for a system like Google
ozzii
Seasoned User
Seasoned User
 
Posts: 410
Joined: Thu Feb 23, 2006 6:10 pm
Location: France

Registered Newsbin User since: 02/23/06

Postby DThor » Tue Mar 14, 2006 11:31 am

Oh right, the exclude side of the filter, keep forgetting about that. :/

You can just keep adding entries to the Accept filter side, that's effectively an "OR". Close. Also, the more specific you need to be, the better Regex is. For instance, if you want the AND to be in a specific order, that's easier. Like "foobar", "blah blah" ending with a ".rnn".

While there's an interest by some to make this easier to use, you also have to keep in mind that the *vast* majority of end users just type in a word and they're done. That combined with a Subject sort means you're finished. It appears the majority of users that really seem to *need* this do so just because they want to. However, I do agree that having filters that sort out pars, rars, avi's, mp3's, etc. are tremendously useful. Examples of those are already available, no need to reinvent the wheel.

DT
User avatar
DThor
Elite NewsBin User
Elite NewsBin User
 
Posts: 5943
Joined: Mon Jul 01, 2002 9:50 am

Registered Newsbin User since: 04/01/03

Postby ozzii » Tue Mar 14, 2006 11:49 am

For example I have an subject with "for sex with paypal" and another with "with paypal you can have sexs"
Now I would like to had to my filter NO_SEX (into the exclusion subject) something like:
sex* AND paypal*
because I want to keep the song "sexual healing"

It's true that I prefer to wait for an easier way like google (or a mixed system combining Regex and like google).
ozzii
Seasoned User
Seasoned User
 
Posts: 410
Joined: Thu Feb 23, 2006 6:10 pm
Location: France

Registered Newsbin User since: 02/23/06

Postby DThor » Tue Mar 14, 2006 1:55 pm

Well, in that case, for me, I'm either *looking* for that song(in which case typing in "healing" works fine), or I want to find song files without porn links, in which case I'll have a media filter for different kinds of media. It doesn't need to explicitly exclude anything with sex in it at all - unless someone is releasing "bigboobsexmp3.com" spam links. Enable the Fliter Profile in the tab filter, then if need be throw in the odd on-the-fly "find" filter over on the left. They work together. Works fine for me.

I'm not suggesting no-one ever needs to do more explicit search, however I am suggesting that 98% of it really isn't necessary.

DT
User avatar
DThor
Elite NewsBin User
Elite NewsBin User
 
Posts: 5943
Joined: Mon Jul 01, 2002 9:50 am

Registered Newsbin User since: 04/01/03

Postby Smite » Tue Mar 14, 2006 2:51 pm

Please read the FAQ before asking any questions.
If you're new to newsgroups, and the files on them, you can find a very helpful guide here.
User avatar
Smite
Katamari Damacy Addict
 
Posts: 5318
Joined: Sat May 19, 2001 1:54 am
Location: Alberta, Canada

Registered Newsbin User since: 03/27/03

Postby ozzii » Tue Mar 14, 2006 2:59 pm

I allready read this, but it's not an AND.
But, I will try this anyway when I'm home.
ozzii
Seasoned User
Seasoned User
 
Posts: 410
Joined: Thu Feb 23, 2006 6:10 pm
Location: France

Registered Newsbin User since: 02/23/06

Postby Smite » Tue Mar 14, 2006 3:05 pm

ozzii wrote:I allready read this, but it's not an AND.
But, I will try this anyway when I'm home.


Umm, what?
This post tells you how to do an AND operation:
http://forums.newsbin.com/viewtopic.php?p=26616#26616

If you changed your mind and want something other than AND, fine, I'm just answering your original question.
Please read the FAQ before asking any questions.
If you're new to newsgroups, and the files on them, you can find a very helpful guide here.
User avatar
Smite
Katamari Damacy Addict
 
Posts: 5318
Joined: Sat May 19, 2001 1:54 am
Location: Alberta, Canada

Registered Newsbin User since: 03/27/03

Postby ozzii » Tue Mar 14, 2006 3:12 pm

I didn't change my mind. I want to do an AND :?

But like I said, I will try this at home, and told if it's OK.

Thanks :wink:
ozzii
Seasoned User
Seasoned User
 
Posts: 410
Joined: Thu Feb 23, 2006 6:10 pm
Location: France

Registered Newsbin User since: 02/23/06

Postby ozzii » Tue Mar 14, 2006 6:42 pm

This is it :lol:
It's working, even if I can't understand how.

Thanks for all your help.
ozzii
Seasoned User
Seasoned User
 
Posts: 410
Joined: Thu Feb 23, 2006 6:10 pm
Location: France

Registered Newsbin User since: 02/23/06


Return to Regular Expressions

Who is online

Users browsing this forum: Google [Bot] and 2 guests

cron