Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
# Name: jdw_if_ajax v0.1
# Type: Client side plugin
# Helper tags for TXP + AJAX
# Author: Jan De Wilde
# URL: http://www.jandewilde.com/
# Recommended load order: 5
# .....................................................................
# This is a plugin for Textpattern - http://textpattern.com/
# To install: textpattern > admin > plugins
# Paste the following text into the 'Install plugin' box:
# .....................................................................
YToxMTp7czo0OiJuYW1lIjtzOjExOiJqZHdfaWZfYWpheCI7czo2OiJhdXRob3IiO3M6MTI6
IkphbiBEZSBXaWxkZSI7czoxMDoiYXV0aG9yX3VyaSI7czoyNjoiaHR0cDovL3d3dy5qYW5k
ZXdpbGRlLmNvbS8iO3M6NzoidmVyc2lvbiI7czozOiIwLjEiO3M6MTE6ImRlc2NyaXB0aW9u
IjtzOjI2OiJIZWxwZXIgdGFncyBmb3IgVFhQICsgQUpBWCI7czo0OiJoZWxwIjtzOjExNDQ6
Igk8aDEgY2xhc3M9InRpdGxlIHRhZyI+amR3X2lmX2FqYXg8L2gxPgoKCTxoMiBjbGFzcz0i
c2VjdGlvbiI+Q3JlZGl0PC9oMj4KCgk8cD5UaGlzIHBsdWdpbiBpcyBiYXNlZCB1cG9uIGR1
Yl9pZl9hamF4IChubyBsb25nZXIgYXZhaWxhYmxlKSBieSBKYW1pZSBXaWxraW5zb24uPGJy
IC8+Ckhvd2V2ZXI6IFRoaXMgcGx1Z2luIGhhcyBhIG5ldyB0YWc6IDxzcGFuIGNsYXNzPSJ0
YWciPmpkd19pZl9ub3RfYWpheDwvc3Bhbj4uPGJyIC8+Ckl0IHVzZXMgdGhlIHgtcmVxdWVz
dGVkLXdpdGggaGVhZGVyIHRvIGRlbGl2ZXIgZGlmZmVyZW50IGNvbnRlbnQgdG8gQWpheCBj
YWxscy48L3A+CgoJPGgyIGNsYXNzPSJzZWN0aW9uIj5UYWdzPC9oMj4KCgk8aDMgY2xhc3M9
InRhZyI+amR3X2lmX2FqYXg8L2gzPgoKCTxwIGNsYXNzPSJ0YW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