PHPackages                             parseword/sfsquery - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. parseword/sfsquery

ActiveLibrary[API Development](/categories/api)

parseword/sfsquery
==================

A PHP class to query the StopForumSpam API

v2.0.0(7y ago)120Apache-2.0PHPPHP &gt;=7.0

Since Apr 23Pushed 7y ago2 watchersCompare

[ Source](https://github.com/parseword/sfsquery)[ Packagist](https://packagist.org/packages/parseword/sfsquery)[ Docs](https://github.com/parseword/sfsquery/)[ RSS](/packages/parseword-sfsquery/feed)WikiDiscussions master Synced 4d ago

READMEChangelog (2)DependenciesVersions (5)Used By (0)

SFSQuery
========

[](#sfsquery)

A PHP class to query the [StopForumSpam](https://stopforumspam.com/) web API or DNSBL for information about an IP address. Help protect your comments, contact form, or other user-generated content from spammers by checking the StopForumSpam database in real time.

### Usage

[](#usage)

SFSQuery is platform-agnostic and can be used with any project. Simply `require()` the class file or place it where your autoloader can find it; Composer installation is supported.

The simplest implementation uses an anonymous object to check whether or not an IP meets one of several criteria. For example, you might want to reject an action if the user's IP has been reported to StopForumSpam in the past 7 days:

```
