/* 
 * More info at: http://phpjs.org
 * 
 * This is version: 2.97
 * php.js is copyright 2009 Kevin van Zonneveld.
 * 
 * Portions copyright Brett Zamir (http://brett-zamir.me), Kevin van Zonneveld
 * (http://kevin.vanzonneveld.net), Onno Marsman, Michael White
 * (http://getsprink.com), Waldo Malqui Silva, Paulo Ricardo F. Santos, Jack,
 * Jonas Raoni Soares Silva (http://www.jsfromhell.com), Philip Peterson,
 * Legaev Andrey, Ates Goral (http://magnetiq.com), Ratheous, Alex, Martijn
 * Wieringa, Theriault, Nate, Philippe Baumann, lmeyrick
 * (https://sourceforge.net/projects/bcmath-js/), Enrique Gonzalez,
 * Webtoolkit.info (http://www.webtoolkit.info/), travc, Carlos R. L.
 * Rodrigues (http://www.jsfromhell.com), Jani Hartikainen, Ash Searle
 * (http://hexmen.com/blog/), Ole Vrijenhoek, stag019, d3x, Erkekjetter,
 * GeekFG (http://geekfg.blogspot.com), T.Wild, marrtins, Johnny Mast
 * (http://www.phpvrouwen.nl),
 * http://stackoverflow.com/questions/57803/how-to-convert-decimal-to-hex-in-javascript,
 * pilus, Andrea Giammarchi (http://webreflection.blogspot.com), Michael
 * Grier, WebDevHobo (http://webdevhobo.blogspot.com/), AJ, Thunder.m,
 * gettimeofday, Pellentesque Malesuada, Tyler Akins (http://rumkin.com),
 * Martin (http://www.erlenwiese.de/), Alfonso Jimenez
 * (http://www.alfonsojimenez.com), mdsjack (http://www.mdsjack.bo.it), Lars
 * Fischer, Arpad Ray (mailto:arpad@php.net), Caio Ariede
 * (http://caioariede.com), Michael White, Marc Palau, majak, Kankrelune
 * (http://www.webfaktory.info/), Public Domain
 * (http://www.json.org/json2.js), Joris, David, Steven Levithan
 * (http://blog.stevenlevithan.com), Aman Gupta, Steve Hilder, KELAN, Breaking
 * Par Consulting Inc
 * (http://www.breakingpar.com/bkp/home.nsf/0/87256B280015193F87256CFB006C45F7),
 * Mirek Slugen, Josh Fraser
 * (http://onlineaspect.com/2007/06/08/auto-detect-a-time-zone-with-javascript/),
 * gorthaur, Felix Geisendoerfer (http://www.debuggable.com/felix), Karol
 * Kowalski, Sakimori, Oleg Eremeev, Eugene Bulkin (http://doubleaw.com/), Der
 * Simon (http://innerdom.sourceforge.net/), JB, LH, echo is bad, Stoyan
 * Kyosev (http://www.svest.org/), HKM, Douglas Crockford
 * (http://javascript.crockford.com), ChaosNo1, metjay, nord_ua, strcasecmp,
 * strcmp, XoraX (http://www.xorax.info), Ozh, Francesco, Artur Tchernychev,
 * kenneth, David James, class_exists, Alan C, Raphael (Ao RUDLER), T. Wild,
 * Ole Vrijenhoek (http://www.nervous.nl/), Steve Clay, noname, Marco, Taras
 * Bogach, Frank Forte, Marc Jansen, J A R, uestla, madipta, Hyam Singer
 * (http://www.impact-computing.com/), Paul, Peter-Paul Koch
 * (http://www.quirksmode.org/js/beat.html), Alexander Ermolaev
 * (http://snippets.dzone.com/user/AlexanderErmolaev), 0m3r, Sanjoy Roy,
 * sankai, Norman "zEh" Fuchs, Subhasis Deb, kilops, duncan, Gilbert, Orlando,
 * hitwork, sowberry, Aidan Lister (http://aidanlister.com/), ejsanders, Nick
 * Callen, Philippe Jausions (http://pear.php.net/user/jausions), Brian Tafoya
 * (http://www.premasolutions.com/), Yves Sucaet, Denny Wardhana, Ulrich,
 * johnrembo, Bayron Guevara, dptr1988, T0bsn, DxGx, Soren Hansen, mktime,
 * MeEtc (http://yass.meetcweb.com), David Randall, Bryan Elliott, Tim Wiel,
 * Brad Touesnard, Pedro Tainha (http://www.pedrotainha.com), Chris, djmix,
 * Lincoln Ramsay, Le Torbi, James, lmeyrick
 * (https://sourceforge.net/projects/bcmath-js/this.), Pyerre, Jon Hohle,
 * Thiago Mata (http://thiagomata.blog.com), Linuxworld, Arno, john
 * (http://www.jd-tech.net), Dino, rem, Greenseed, Andrej Pavlovic, Garagoth,
 * Andreas, DtTvB (http://dt.in.th/2008-09-16.string-length-in-bytes.html),
 * Jamie Beck (http://www.terabit.ca/), Russell Walker
 * (http://www.nbill.co.uk/), mk.keck, Daniel Esteban, Kheang Hok Chin
 * (http://www.distantia.ca/), Luke Smith (http://lucassmith.name), Rival,
 * Diogo Resende, Jay Klehr, Amir Habibi (http://www.residence-mixte.com/),
 * Leslie Hoare, Ben Bryan, booeyOH, Cagri Ekin, Blues at
 * http://hacks.bluesmoon.info/strftime/strftime.js, YUI Library:
 * http://developer.yahoo.com/yui/docs/YAHOO.util.DateLocale.html, Mick@el,
 * rezna, Tomasz Wesolowski, Eric Nagel, Rick Waldron, Kirk Strobeck, Saulo
 * Vallory, Kristof Coomans (SCK-CEN Belgian Nucleair Research Centre),
 * Pierre-Luc Paour, Martin Pool, Bobby Drake, Pul, Philipp Lenssen,
 * penutbutterjelly, Christian Doebler, setcookie, Marco van Oort, Gabriel
 * Paderni, Luke Godfrey, Blues (http://tech.bluesmoon.info/), Anton Ongson,
 * Simon Willison (http://simonwillison.net), Howard Yeend, Allan Jensen
 * (http://www.winternet.no), vlado houba, Jalal Berrami, Itsacon
 * (http://www.itsacon.net/), Billy, stensi, Cord, fearphage
 * (http://http/my.opera.com/fearphage/), Victor, Matteo, date, Wagner B.
 * Soares, Nathan, nobbler, marc andreu, ger, Christoph, Mateusz "loonquawl"
 * Zalega, Francois, Scott Cariss, Slawomir Kaniecki, ReverseSyntax, Manish,
 * Matt Bradley, jakes, Yannoo, gabriel paderni, FGFEmperor, 3D-GRAF, daniel
 * airton wermann (http://wermann.com.br), Benjamin Lupton, davook, Maximusya,
 * Atli Þór, baris ozdil, Greg Frazier, Luis Salazar
 * (http://www.freaky-media.com/), Tim de Koning, taith, Robin, FremyCompany,
 * T.J. Leahy, Jason Wong (http://carrot.org/), Tod Gentille, Alexander M
 * Beedie, Valentina De Rosa
 * 
 * Dual licensed under the MIT (MIT-LICENSE.txt)
 * and GPL (GPL-LICENSE.txt) licenses.
 * 
 * Permission is hereby granted, free of charge, to any person obtaining a
 * copy of this software and associated documentation files (the
 * "Software"), to deal in the Software without restriction, including
 * without limitation the rights to use, copy, modify, merge, publish,
 * distribute, sublicense, and/or sell copies of the Software, and to
 * permit persons to whom the Software is furnished to do so, subject to
 * the following conditions:
 * 
 * The above copyright notice and this permission notice shall be included
 * in all copies or substantial portions of the Software.
 * 
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
 * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
 * IN NO EVENT SHALL KEVIN VAN ZONNEVELD BE LIABLE FOR ANY CLAIM, DAMAGES
 * OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
 * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
 * OTHER DEALINGS IN THE SOFTWARE.
 */ 


// Compression: minified


function strip_tags(str,allowed_tags){var key='',allowed=false;var matches=[];var allowed_array=[];var allowed_tag='';var i=0;var k='';var html='';var replacer=function(search,replace,str){return str.split(search).join(replace);};if(allowed_tags){allowed_array=allowed_tags.match(/([a-zA-Z0-9]+)/gi);}
str+='';matches=str.match(/(<\/?[\S][^>]*>)/gi);for(key in matches){if(isNaN(key)){continue;}
html=matches[key].toString();allowed=false;for(k in allowed_array){allowed_tag=allowed_array[k];i=-1;if(i!=0){i=html.toLowerCase().indexOf('<'+allowed_tag+'>');}
if(i!=0){i=html.toLowerCase().indexOf('<'+allowed_tag+' ');}
if(i!=0){i=html.toLowerCase().indexOf('</'+allowed_tag);}
if(i==0){allowed=true;break;}}
if(!allowed){str=replacer(html,"",str);}}
return str;}
function trim(str,charlist){var whitespace,l=0,i=0;str+='';if(!charlist){whitespace=" \n\r\t\f\x0b\xa0\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u200b\u2028\u2029\u3000";}else{charlist+='';whitespace=charlist.replace(/([\[\]\(\)\.\?\/\*\{\}\+\$\^\:])/g,'$1');}
l=str.length;for(i=0;i<l;i++){if(whitespace.indexOf(str.charAt(i))===-1){str=str.substring(i);break;}}
l=str.length;for(i=l-1;i>=0;i--){if(whitespace.indexOf(str.charAt(i))===-1){str=str.substring(0,i+1);break;}}
return whitespace.indexOf(str.charAt(0))===-1?str:'';}
