Mobiion Forum
February 04, 2012, 01:00:40 pm
Welcome,
Guest
. Please
login
or
register
.
Did you miss your
activation email?
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
News
:
Home
Help
Search
Login
Register
Mobiion Forum
>
MagiCall
>
General Discussion
>
RegEx Rules Problem
Pages:
1
Go Down
« previous
next »
Print
Author
Topic: RegEx Rules Problem (Read 769 times)
funnyPC
Newbie
Offline
Posts: 5
RegEx Rules Problem
«
on:
August 17, 2010, 12:26:53 am »
When RegEx rules defined in SMS filters, SMS with words not defined in expressions are also filtered.
To confirm this bug, I use the 'Run Application' action with different parameter to show a dialog when filters works, so I could distinguish which rules has problem. But the result shows, messages are wrongly filtered by random rules.
So I think there's a character compare bug in regex function when use unicode charset (Simplified Chinese in my case)
«
Last Edit: August 18, 2010, 11:36:04 pm by funnyPC
»
Logged
admin
Administrator
Hero Member
Offline
Posts: 1185
Re: [BUG]Unicode Character Compare Defect in RegEx Rules
«
Reply #1 on:
August 17, 2010, 08:26:53 pm »
No, RegEx in MagiCall can and only can filter Unicode characters.
Can you provide your SMS filter? Maybe I can find problem from it.
Logged
funnyPC
Newbie
Offline
Posts: 5
Re: [BUG]Unicode Character Compare Defect in RegEx Rules
«
Reply #2 on:
August 18, 2010, 04:07:03 am »
for example, sms does NOT include any one of following words often filtered by this rule:
Quote
<[现房|名城|开盘|典藏|旺铺|金铺|美宅|美墅|高层|户型].*\d{4,}>
I don't know if your system could display chinese correctly,so I uploaded pictures also(with another rules).
Screen001.png
(19.43 KB, 320x240 - viewed 108 times.)
Screen002.png
(19.55 KB, 320x240 - viewed 1108 times.)
Logged
funnyPC
Newbie
Offline
Posts: 5
Re: [BUG]Unicode Character Compare Defect in RegEx Rules
«
Reply #3 on:
August 18, 2010, 04:10:25 am »
ps:
I use many '.*' pattern in rules because spam sms sender insert chars such as '.\~;%' to evade sms filter applications without regex support.
Logged
admin
Administrator
Hero Member
Offline
Posts: 1185
Re: [BUG]Unicode Character Compare Defect in RegEx Rules
«
Reply #4 on:
August 18, 2010, 01:08:47 pm »
Hi, there is a problem in your regular expression. You use [] to enclose keywords, which is a wrong way. [] is used to define character class, every character in it is a keyword. You may just replace [] with (), it should work:
<(现房|名城|开盘|典藏|旺铺|金铺|美宅|美墅|高层|户型).*\d{4,}>
Logged
funnyPC
Newbie
Offline
Posts: 5
Re: [BUG]Unicode Character Compare Defect in RegEx Rules
«
Reply #5 on:
August 18, 2010, 11:35:02 pm »
thanks for reply, i'll correct it & test for some days...
Logged
Pages:
1
Go Up
Print
« previous
next »
Jump to:
Please select a destination:
-----------------------------
General
-----------------------------
=> News and Announcements
=> General Discussion
-----------------------------
MagiCall
-----------------------------
=> FAQs and Knowledge Base
=> General Discussion
-----------------------------
MagiKB Lite
-----------------------------
=> General Discussion
=> Additional keyboard layout files
-----------------------------
Callback
-----------------------------
=> General Discussion
Loading...