1
2
3
4
<?php

$text = htmlentities($_POST['text']);
...

PHP Sanitizing a submitted Foru...

by Anri, August 10, 2010 19:21, 6 refactorings, tagged with php, forum, POST, sanitize

Lets say I am building a fo...

4058d6b5dc2bfd92fd7f7f9a13eb61a6 Talk
1
2
3
4
has_many :fight_wins, :class_name => 'Fight', :finder_sql =>
      '#{sanitize_sql_array(
          "SELECT f.* 
...

Ruby Refactor sanitize_sql_array

by keruilin.myopenid.com, June 20, 2010 01:31, 2 refactorings, tagged with rails, sanitize

I can't get this to work pr...

2669fbd62908cf7787bd6ac81bad624c Talk
1
2
3
4
public string CleanHtml(object Html) {
	var s = Html.ToString();
	var b = new StringBuilder();
...

C# C# HTML Encoding

by GateKiller, March 05, 2009 15:08, 6 refactorings, tagged with C#, html, sanitize

This is my own attempt at w...

98c852e2d9b26249745ea92c72964d3f Talk
1
2
3
4
#!/usr/bin/php
<?php
/**
...

PHP HTML Filter

by grom, October 23, 2008 23:00, 5 refactorings, tagged with php, html, parser, sanitize

Only allow subset of HTML. ...

A14537020ec5b11fea3b956353724860 Talk
1
2
3
4
private static Regex _tags = new Regex("<[^>]*(>|$)",
    RegexOptions.Singleline | RegexOptions.ExplicitCapture | RegexOptions.Compiled);
private static Regex _whitelist = new Regex(@"
...

C# Sanitize HTML

by Jeff Atwood, June 20, 2008 08:24, 54 refactorings, tagged with xss, sanitize, html

Takes a provided HTML strin...

51d623f33f8b83095db84ff35e15dbe8 Talk