Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Community Forums
 Community Discussions (All other subjects)
 XML coder
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

Mr Pink
Junior Member

United Kingdom
387 Posts

Posted - 20 February 2008 :  14:08:10  Show Profile  Visit Mr Pink's Homepage  Send Mr Pink an AOL message
I have an xml website but am having trouble with spam in my guestbook. I have realised that the only way to stop it is to have a banned word filter that would ignore any posts with spam words in them.

Is there anybody out there who knows how to write an xml mod? I haven't got a clue.

Martin
Leyland Forum Leyland Lancashire UK

Podge
Support Moderator

Ireland
3775 Posts

Posted - 20 February 2008 :  17:06:47  Show Profile  Send Podge an ICQ Message  Send Podge a Yahoo! Message
The guestbook data is probably stored as an xml file.

I didn't see any spam on your guestbook - http://www.leylandtown.info/default.asp?id=0&ACT=7&page=0

Podge.

The Hunger Site - Click to donate free food | My Blog | Snitz 3.4.05 AutoInstall (Beta!)

My Mods: CAPTCHA Mod | GateKeeper Mod
Tutorial: Enable subscriptions on your board

Warning: The post above or below may contain nuts.
Go to Top of Page

phy1729
Average Member

USA
589 Posts

Posted - 20 February 2008 :  17:35:39  Show Profile
RegEx will probably come in handy something like this possibly
<comment>[.]*<id>([.]+)</id>[.]*<body>[.]*[(spammy|words|here|)]+[.]*</body>[.]*</comment>
If that returned true delete the captured id. This is retroactive moderation what you need after you clean up what you have is just a filter.

Edited by - phy1729 on 20 February 2008 17:39:02
Go to Top of Page

Mr Pink
Junior Member

United Kingdom
387 Posts

Posted - 20 February 2008 :  17:50:13  Show Profile  Visit Mr Pink's Homepage  Send Mr Pink an AOL message
You didn't see any spam because it is moderated until I ok it. I still have to delete each entry separately and today I had around 30.

Martin
Leyland Forum Leyland Lancashire UK
Go to Top of Page

Mr Pink
Junior Member

United Kingdom
387 Posts

Posted - 21 February 2008 :  18:21:45  Show Profile  Visit Mr Pink's Homepage  Send Mr Pink an AOL message
What is RegEx?

Martin
Leyland Forum Leyland Lancashire UK
Go to Top of Page

phy1729
Average Member

USA
589 Posts

Posted - 21 February 2008 :  19:05:58  Show Profile
Regular Expressions (Snitz topic on it right now) But you want something that will delete messages before they reach you. Like inc_func_common.asp 92-101

		for Counter = 0 to UBound(strArray)
			If InStr(UCase(strArray(Counter)), "SPAMMY") > 0 and _
			InStr(UCase(strArray(Counter)), "WORDS") > 0 and _
			InStr(UCase(strArray(Counter)), "HERE") > 0 then
				'delete message
			end if
		next
Go to Top of Page

AnonJr
Moderator

United States
5768 Posts

Posted - 21 February 2008 :  19:06:43  Show Profile  Visit AnonJr's Homepage
RegEx is the object used to create/execute Regular Expressions in VBScript.
Go to Top of Page

Mr Pink
Junior Member

United Kingdom
387 Posts

Posted - 23 February 2008 :  11:09:00  Show Profile  Visit Mr Pink's Homepage  Send Mr Pink an AOL message
phy1729, that's the kind of thing I need but I think it needs to go into my .xsl file.

Martin
Leyland Forum Leyland Lancashire UK
Go to Top of Page

phy1729
Average Member

USA
589 Posts

Posted - 24 February 2008 :  13:19:28  Show Profile
XSL (link:wikipedia) is for styling the output of the XML file. From what I gather an ASP file inputs the comment into the XML file. If so, just before the comment is inserted is where you should stop the spam, but I'd have to see the code to know how everything fits together.
Go to Top of Page

Mr Pink
Junior Member

United Kingdom
387 Posts

Posted - 28 February 2008 :  16:55:35  Show Profile  Visit Mr Pink's Homepage  Send Mr Pink an AOL message
phy1729, I think I've found the file you are referring to, it contains the following code

if sItemName = "visible" and blnCAPTCHAcodeCorrect = false and URLDecode(oFO.Form("file")) = "guestbook" then
sItemValue = "Off"
m_iUserMessage = ERR_FILL_FORM
m_sGoBack = "1"
exit sub
end if



Could this be where I need to add a delete spam mod?

Martin
Leyland Forum Leyland Lancashire UK
Go to Top of Page

phy1729
Average Member

USA
589 Posts

Posted - 28 February 2008 :  17:37:14  Show Profile
I don't think so. You want right before the message is written to the xml file. It would be easier if I had the entire file.Is there some reason that you can do that?
Go to Top of Page

Mr Pink
Junior Member

United Kingdom
387 Posts

Posted - 29 February 2008 :  16:01:16  Show Profile  Visit Mr Pink's Homepage  Send Mr Pink an AOL message
I don't know the first thing about coding in xml or asp. Do you want me to post a link to the code in a text file? I'll have a look but there are about 3 files that could be the one.

Martin
Leyland Forum Leyland Lancashire UK
Go to Top of Page

phy1729
Average Member

USA
589 Posts

Posted - 29 February 2008 :  17:40:24  Show Profile
Just post all of them.
Go to Top of Page

Mr Pink
Junior Member

United Kingdom
387 Posts

Posted - 01 March 2008 :  10:15:51  Show Profile  Visit Mr Pink's Homepage  Send Mr Pink an AOL message
lib_guestbook.xsl from admin

CFullXMLEngine.asp

lib_guestbook.xsl

I've linked these as text files, if you need to see any more let me know.

Thanks

Martin
Leyland Forum Leyland Lancashire UK
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.28 seconds. Powered By: Snitz Forums 2000 Version 3.4.07