Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@claushellsing
claushellsing / tablesorter.html
Created June 6, 2012 15:27
Test Sort Table publing
<html>
<head>
<title></title>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="jquery.tablesorter.js"></script>
<script type="text/javascript">
$(document).ready(function () {
// body...
$.tablesorter.addWidget({
id:"transformer",
<html>
<head>
<title></title>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="jquery.tablesorter.js"></script>
<script type="text/javascript">
var stripExtraTags = function(ObjCollection) {
ObjCollection.each(function () {
$(this).html($(this).text());
});
@claushellsing
claushellsing / whitelist.cs
Created June 7, 2012 17:42
This is how i mean to store the white list
public Dictionary<String, String[]> WhiteListTagStyle = new Dictionary<string, String[]>()
{
{"p",new String[]{""}},
{"a",new String[]{"href"}},
{"img",new String[]{"src","alt","width","height"}}
};
[{"fechas":{"anyo":"2012","semestre":"2"},"asignaturas":[{"asignatura":{"nombre":"simulacion","id":"1"},"grupos":[{"grupo":"5t2","idgrupos":"1"},{"grupo":"5t1","idgrupos":"2"}]},{"asignatura":{"nombre":"inteligencia artifucal","id":"4"},"grupos":[{"grupo":"5c1","idgrupos":"4"},{"grupo":"5c2","idgrupos":"5"}]}]}]
@claushellsing
claushellsing / combinations.js
Created October 4, 2015 00:38
Create all the N combinations of a characters
/**
* Created by Usuario on 03/10/2015.
*/
var available_characters = ["a","b"];
console.log(combinations(available_characters,5));
function combinations(available_characters,count_char)
{
var acum_results = {combs : []};