db.php 189 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817
  1. <?php
  2. /** Adminer - Compact database management
  3. * @link http://www.adminer.org/
  4. * @author Jakub Vrana, http://www.vrana.cz/
  5. * @copyright 2007 Jakub Vrana
  6. * @license http://www.apache.org/licenses/LICENSE-2.0 Apache License, Version 2.0
  7. * @license http://www.gnu.org/licenses/gpl-2.0.html GNU General Public License, version 2 (one or other)
  8. * @version 4.1.0
  9. */error_reporting(6135);$nc=!preg_match('~^(unsafe_raw)?$~',ini_get("filter.default"));if($nc||ini_get("filter.default_flags")){foreach(array('_GET','_POST','_COOKIE','_SERVER')as$X){$xg=filter_input_array(constant("INPUT$X"),FILTER_UNSAFE_RAW);if($xg)$$X=$xg;}}if(function_exists("mb_internal_encoding"))mb_internal_encoding("8bit");if(isset($_GET["file"])){if($_SERVER["HTTP_IF_MODIFIED_SINCE"]){header("HTTP/1.1 304 Not Modified");exit;}header("Expires: ".gmdate("D, d M Y H:i:s",time()+365*24*60*60)." GMT");header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT");if($_GET["file"]=="favicon.ico"){header("Content-Type: image/x-icon");echo
  10. lzw_decompress("\0\0\0` \0„\0\n @\0´C„è\"\0`EãQ¸àÿ‡?ÀtvM'”JdÁd\\Œb0\0Ä\"™ÀfÓˆ¤îs5›ÏçÑA�XPaJ“0„¥‘8„#RŠT©‘z`ˆ#.©ÇcíXÃþÈ€?À-\0¡Im? .«M¶€\0ȯ(̉ýÀ/(%Œ\0");}elseif($_GET["file"]=="default.css"){header("Content-Type: text/css; charset=utf-8");echo
  11. lzw_decompress("\n1̇“ÙŒÞl7œ‡B1„4vb0˜Ífs‘¼ên2BÌѱ٘Þn:‡#(¼b.\rDc)ÈÈa7E„‘¤Âl ¦Ã±”èi1ÌŽs˜´ç-4™‡fÓ ÈÎi7†³é† „ŽŒFé”vt2ž‚Ó!– r0Ïãã£t~½U�'3M€ÉW„B¦'cÍPÂ:6T\rc£A¾zr_îWK¶\r-¼VNFS%~Ãc²Ùí&›\\^ÊrÀ›­æu‚ŎÞôÙ‹4'7k¶è¯ÂãQÔæhš'g\rFB\ryT7SS¥PÐ1=ǤcIèÊ:�d”ºm>£S8L†J�œt.M¢�Š Ï‹`'C¡¼ÛÐ889¤È ŽQØýŒî2�#8Ð�­£’˜6mú²†ðjˆ¢h«<…Œ°«Œ9/ë˜ç:�Jê)Ê‚¤\0d>!\0Z‡ˆvì»në¾ð¼o(Úó¥ÉkÔ7½�sàù>Œ î†!ÐR\"*nSý\0@P\"Áè’(‹#[¶¥£@g ¹oü­’znþ9k¤8†nš™ª1´I*ˆô =Ín²¤ª�¸è0«c(ö;¾Ã Ðè!°üë*cì÷>ÎŽ¬E7DñLJ© 1ÊJ=ÓÚÞ1L‚û?Ðs=#`Ê3\$4ì€úÈuȱÌÎzGÑC YAt«?;×QÒk&Çï�YP¿uèåǯ}UaHV%G;ƒs¼”<A\0\\¼ÔPÑ\\Âœ&ªóV¦ð\n£SUÃtíÅÇrŒêˆÆ2¤ l^íZ6˜ej…Á­³A ·dó[ÝsÕ¶ˆJP”ªÊóˆÒ�ŒŠ8è=»ƒ˜à6 #Ë‚74*óŸ¨#eÈÀÞ!Õ7{Æ6“¿<oÍCª9v[–MôÅ-`Óõkö>ŽlÙÚ´‹åIªƒHÚ3�xú€›äw0t6¾Ã%MR%³½jhÚB˜<´\0ÉAQ<P<:šãu/¤;\\> Ë-¹„ʈÍÁ QH\nv¡L+vÖæì<ï\rèåvàöî¹\\* àÉçÓ´Ý¢gŒ�nË©¸ ¹TЩ2P•\r¨øß‹\"+z 8£ ¶:#€ÊèÃÎ2‹ºJ[�i—‚£¨;z˜ûÑô¡rÊ3 #¨Ù‰ :ãní\r㽃eÙpdÝ�Ý è2cˆê4²k¿Š£\rG•æE6_²ªÊØÞ‰b‹ž/Œ«HB%ò0ë¢>ÈÈðhoWÃnxlÖ� æµƒCQ^€°ÐÔÿßñ\r„Š¾¶4lK{þZÆü:†ÐÜß.¦p¨§Ä‚éJóB-Å+B”´‘(ëTòŸ%®µJ›0ªlØT¶`+É-Á¾@BÚáÛ„Vá’Ä\0ÂÏC¼,ì¯0tâàŒF‡‰å?Ä Ë\na@ÉŒ>‚âZEC“ôOŽ-曤^Q€&ßÖù)I)®¤ÄÀ�R„]\r¡”9”7_ˆ¢\rÉF80µObù €‘î>ºäý\nRý_ˆÑ8æ‚ØÙ«ä ov0¤bCA¸F!Ñt—–ă%0”/‘zAYO(4«‹¡ˆ¨Ò 'Ÿ] Iéí8hHÂ05˜3ò@x&nˆ’|TÓ³³)`�.“s6eY˜D¦z¸Œ®¥ƒJÑ“ôž.„ñ{GEb�¹Ó‹¡˜‹†2Õ×{\$**ý¾@ÝC�ž-:zYHZIôà5F]¦²YúùCªOêA�ÂÚó`x'´.*9t'{ÿ(êšwP¶¾ Ñ=¢*‰†ú*üxwråÔ*c‚žÌc|„DŸ“ÚV—–\r†V.‡0âÆ ™V¤dˆ?Ò€üê,EÍ�`T¦É6Ûˆ-“Åì¾ÅÚŽT[Ñ�ªz©‚.Ar±£Í€Pøºnƒc= aÔ9Fònß!ÙuáÎ A©Þƒ0iPó¬”îºJ6e äT]VØ[\rXÌáaŸ–v �kõ\n+Eˆ�áÜ•*\0¶~¶Æù@g\"ÌNCI\$�àÉŒƒ€êx@WÃy¼*vuDÙ\0ÞvœëŒ†V\0èV`Gç½uµE®Ö•ÂÁf“l˜h’@ï)0@šT•°7‹íÛ§RAÊÙ·ò´3ۘЫ/QÇ]ª,sÖ{VRž±¡ŽöF«¡�A˜„<¨v×¥î´%@9‚ÀF¢Õ5t‰%Ö+º /¢8;¾WÑäÚÇJïÐo:ÖNÿ`ø •ÿš´hìÁ{Ü£•î ËÔ�8ÔEuª&°W|Ɇ„‰®Uú&\r\"ÔÁ»‰|-udž…Në¶:nc²©fV­‹Â�Ãè# U20å>\"®²Ç>Ì`œk]î-¯ÇxùSØ͇Т©‰‚êcâ¡óB’—}Ø&`ˆîr+E­“\$œyNýŒ±b,†´´Wx þ�-9åÕrÓ,’ü`å+œïíËŠù’CœÓ)˜˜7Ûx\r¬þWµfMŒSR¼ \\èz¦ÙQ²Ì“�”u A¬ºê2Ž±õ4îL&ËHi µ°²¹S\$)e³“æg rÈŒ©ƒ\$]ZëiYs¤õ×kW–n>µ7E1k8ÐdÃró®škÁý¢ëEÞÙÛwÂwcmŽTy�¹•ë¿a›\$tx\rB´÷=�Šö¢*”<ȃ l¡ fôKœ‘N/¶¼� ÃlÕáükH“õ8 .‘‘ù?f÷›Úÿã6†Ñ‡¼{gi/\"à@�– K›ñ@2ãça|#,Z¤±‡ ³ñwˆd¬™“²…¼å6w™^&Áêt™çœP±…¥Äù]À¼›.àãÚí¡TìîkroÀ‰�÷\ro=—%æ×h`:\0᱂�ö «”|ꊣ«a “Ô®6*:ÍÓ*‡ÊrO-^–’ñén«Íó§MÆ}æ»÷ÆAya�±Ý\nƒu^ì–ÀrnO\r±»¡`þT~</ð¶wÄyþ}æ:›|£ÏÐûÖÌ¡6»¤×ø®Ÿvî \rc<·b#ûàô§†î– \$ùsµê|燇V)«h‹TCùñ(Ľñ£Ì]6¦Þ1´!1M±¸@a´/�`Û>Ù¸üߣðÕßÈÛC/ì6à´·#p@p á‘óÿ`Zÿôýchý°\0 ïë\0oæ€ð 4OýOø i\0-\n«îÿ/ý\0£Dð.ÿ ¾�ˆ.“Ä�\0fiŒÀÈ«£€˜\0Œ”IDüç\0§¬\rïý0f ßoã�ÿ€ÊG�üˆðeJ|\r€¿ýl ¨3ê~ ðiP›¦&“É¿/µ\0�9 ^\0r•0]¯õ ¾›oõ Ž.ý\"� °ÐÑM¥í ðvÿP€ZÐÕm pËP °ù�ÚœÐÞ�¹ïô{§†C ?²ÀkŽ“ϼ}ð®þdö ïÊ�°~=‘.�Ô- é Ðm1> hûÏÛЕ1;QI‘OPÈ\r�ºcßpApV«k\rQ* èQ}ÏçŸq>˜Ðu�15�BqQ[1fûñl«Â€apå¯ü\0Û‘*ŒJ©Q=ñãّGÜ äŠÕÁ±Ÿ±_ñ—ñbŒGHF.‚0Ôø = 2P™Àó æ òÏçP!ò#(3 \nÙ!1&72f�ª`Â/�å\0°‡\"PÁU õ\$ñ\r0Ì ð�,QrU&2fšÒ_²X àà ò]ð9\"’S'òƒ'²yð8\r¨ú§òkW)Oõ)’�*Ra%ã\\ i—%ò‰&Ò³+r…’3ðS`…,ñvý¦&2×L–&Pu*�›-ð˜0\"Á%HĬÔžïÏ@Ø“±°H‰B–P(ÃÉ\$p&ý,1M ªØ­Ã®;\rnÁ.¯Ê I­.Õ',1ò�)Ó4ý²å2°u+ó3æ� `È S ŽŠpL\nt§’_*²S3;6r�'h35¤55䜋d2q+6ñ�8‘O7sC\"pm8Ò­³“6³—9òm\n@e0É<8B�8©<,( �¨8²Û\0è Ó0šJÙ<@¦ÐI¤«ÀR6pÔ­mGË\"11¤6ËÐ.\"æÀ‚ï5Ì‚ûÇ:àÜ8bêA1±;ƒ';Â?<*\$È,³Ì�o= òTÓÖ/3Û#«ºÒ†¬");}elseif($_GET["file"]=="functions.js"){header("Content-Type: text/javascript; charset=utf-8");echo
  12. lzw_decompress("f:›ŒgCI¼Ü\n0›†S‘ Øa9œÅS`°Çˆ“Œ&Ó(°Ên0˜�†QIìÒf‰›\$±At^ s�G²Étf6eŒ§yŒÊ()LäSÁÀP'�…ÂáÌR'Ífq]\"˜s> )â‘`œH2ŠEq9ˆÊ?ˆ*)‰”t'°ŽÏ§Ø\n \ræs<ŒPi2INÆ�*(=2ÌgXá¸è.3™N„Y4èB<’L—üîi©Ì¥2Ý´z=š0HøžÐ'·êŒšÃuÆtt:œ�¡Èêe¹]`pX9ŒÞo5šgòóIœÜ,2O4ãÞ Ñ…�MÆS¸(ˆa…Š#¾Äàç’ïø|¹G‚bèôüxœ^Z[Çä™G¼ÎuTv ª(Ò�m@Vò¸( †¼ÈbN<ŠÈ`æâ Xä�1É+Œä9J8Â2\r£K¶9 ðhå  Áè`…�‹ÆëI8ä›± S�±ãt÷2ƒ+,£ÆIºã £�pæ9 aèØÅ< \\8Czôã\rŠ¨^ŽòÈ]Ä1\\7ŽC8_Ep^ÂÐÀéM1Àw\"'4fŽSX9ES|ä›…Ãk3ÄB@Êæ�Xa=No4t7�ƒdD3µpÞÑàæ:)\\;° ÐÔð\r)8HÔÅ44Pc=\nÔ!pdÇÕQN\rÌHï'�ô¸š2¢# \"Õ¥m-¶b,Ç ƒM.�¡‰-IKÓ)ÀÉe'Ž•\"ƒ ´¤>2XÑÅ“eÄj:9^²1c„»�È�Ž:YÉ@ËuËã“›4òXÇ& Ò|£)Ñ’´±-K‘xŒë ªÂSðè1Óó\$â¡@\\…!x]\0Œ£ÕÎÀÂñ¤áF†COÄ:à1K‡Å*†F4 aˆ»¼k˜ú ÈKÏš¾‘»ö2l¬pÌ3J<Èâ,2Øà8#ã †Õ\rŒÜášÜî ó¤h¬„·áF±ŒÝ‰2Pë茊l(È\$Ö°\nJÛ·-ÞÊÇ°cc~¹FžÔîrøátbÞû½m{hð.‡{ƒtkÛBµKc£z4ŒCª9…Û«~>ƒØúÈÚ`Æ“¹C Âs:âÝÔ!cÅÙ®Úµ”*WÉHX:WÌ�;Nà ¨j*Ž/(á_p3ª¡HIãKlÉn!trã£Gã­º¤tCƒ vƒ?m㤣¾ Ÿ¢–\0CÙö¨§oÜ¥cbf6Iþû'\ríbåÅ7h§`‚È9½iìd5’—taMè={É©ð»`NoK‰ !d4ЃzWXdmH°š*€ÆÛS ]ÏÐ3&\0Ú° d%A´-²… Âì(„�š��Ù ùQÐ}ø‚èU !t7 °ä‹†˜>x‹‘t{mY¹„0Þ@^±€\"Ñ= ‡³Î@t\r¡°ÎÄ+Y§.¼·¼X¿\n«I'KTŸ€^(ìD.@ö Üø++@¼3•ÒÔX‹ aEì!,�Yéö2-432ÔŒ õMOàÖI\$q% Ä‹G¦X9™‡Â[R\0n�Áи PŒJy\r òBÈp\\HÃpgSɼ±Faejk—.4¸†C.^ yi‘ˆ9‡PĈe\"ΔNYŽ¬¢BHÃ#8ÑB1\"¶j\\Ú©x‡ð#¾â@G 9†2¨Âf.ÐŒpsršTJ xÚk˜–È4KIlÈfù8z¤¥Kȇ>AKñŸ¡n^’Ø=&ŒƒA�À*?'� ³^%;ðî 4Ü€³†Œ9�¤Q’“hâN‡™>MÊ=['ŽvHIÝJ§‘ž“ÙvÆâ’RÊtƒó<Ÿ”Ò²Å^¢¼zÔ‰B^öhâ'µ‚É©Ð)-'#”¤9JTÁ)Ø@jO!¨Úc,e˜j–¤–‡@H,‰ÂØjˆa™©vžZŒ>­¡Ò·µ)E`\0\n‡áT�Pó8L<‰c•:F˜æ‰\$\nƒí휆ÃÏCHm\"�j‹y·AÛS¶ ÜSªžQ„ðœ�ÎÎ{ T']W�ªUÚ)_L¥˜i¬mˆOš‚¥è„þÔP: g¡{¸’ZÄ—ø.ÿ{”¨‡Dh\n»ÑÁ‡a­\r]9¥tÜà!XA½[È°¦ã—Cœ»×�\n:•”haœÎÚå\"Ý¢a2Lm ƒ·Í\\ ûëp5÷@ú«@m£ì|Wö•ÀÂ%È|u®áÈ+hKÃL&¢Ï Þ3ü.XW ÜÙººÈñ*qƒÛcÃé‡%�.K¿“�Š_”)®uÔ2W\$O]… d8’ê»gÁ?mFyúly ¢%Ó‰ö²ÍÜDQ�Ç.uIJñ‡Æ¹ø‚ÉÛL‚ý,Þ¬†è3ðæjƒ0t a”<¬\0Pr•mNs8ÙŒk>M9, †á±ëBÁþ±xÖუzo丙uB?`鬧�&ÂIÉ<¯¥ÍÑeÅYås�ÊzÔ‡*±.'t»µõ‚zÛ)m*4X=—tI=ýnѦyÌÞšééc2¥¡`öääØ .Y¬¿Ö:éÎK“N’µr06Ó_rJ‘ØkÃtOè|^͈¡çz\nϿ鱕ˆ<W‹1n.¨X·`•‚gúVG4Zÿ­rë!ÝÏÈ�Y[ÞÓÅz:LäDˆÂ@T ¡0Ô`܃˜pjSn\"YÁÈg á`÷}Äšð÷‘¬\n\nä4®ˆ\rg‚¹O7Ü¿b§è”y¡Ì)¹E¯Ãß)w>Ü~urš³Þ29h‚t�gB#¹•°²ôF‚p(é@¥`u0÷у(flG¥a0bZ7J@ÝI_PZ‹‹yq^Ëà7î°¸çG‰3dƒ˜ÐêÑ3¶é“„0ƒÛàŸïŸ{Ö¸»�øˆa6½P¾ƒ4W �d:¿ü„W\nêt4.ñþDÉy°È§»85‡«AMôL’Xw5Ùese³Ü÷C #ýÝËrrYë Ç®!žÂî€Â唟@/\rÌ ›0¥wEl\"›OéWŒ<Q‘ÄÛ ñEkÀŽSQiÿdŸý\\kÙ¬ëü8×ëþH�Œ�²\"ëbL}×%½ ¬Ñ-^ð _âh\nF�-. í2nj¬ÔËVMàxnj¾¦m\\\$°¨¬ñ*\n¶ÈÖ'¢~චZ@º €¶Ž V⺀L\"㈆p†Ø5€ðO, ��ÿ˹\0\nžª-0¥\r4”pÔäbÕ0fÕp¶mg¤i©þO�. (ÛP9ÐAPH+ÐNHpf¨§4?BàMð®·ãJF�¶.�îô\0èà°Èà«Ôi…jÆ€Pþ+(¯&æ»ãaŒÖ%l]'Üïl^@(œ5ƒN fsŽ˜Ðûãô bz ÃÏe>î�º¯p²¯øk éD�\r4aŽNéÂY ({ ïD­ŒnƆÏÕ¤>jĨ1€Ü ¨ž<çl-�x³�\rËGËO Qw°•qw«c‚Pñb\r¤Ì¶ç­ê‹ Á½‘§ âdñš6¢Ç€Ês‚ࢎéæÁ Ð¶±r½Äj>«¤Jž°âŽüÈ®±bâ3ê� (F¦ÑzÞ�¤Ðrª`Oñˆ¥ËX‘ÿ\rZ¶qü\r ì1\$ŸÏ¿gkìl­Ìr+° ñ†ækfì'ò5Ò8®4ë6Û\0Ê -´.i~4òE<\$²JÆlru2F;Bn<’%#lq%ˆû b=âå#Lë(HJ1b%\r縼ãz‹�ô‹èG2£±^8wêñŒ‚^%¯” îþ¾G­*g 7D\0^ ‘r²c„Ž p’ÆL, €ó°ï* Xr§\$ Ê8ð×,©*¨D‚ÓÀÔæ`Ð\n„Á’Z¬“©s1lÏ1Ç\\{àÂ.I~`‡*3 ÍÑ ì]1“FÍ‘1X -£%#ËÀÁS3LÓl6\$Cr‰C/Âô\rÓ%,È|†“€ Ȇnj–Ü Êsu8«J˜©Žä¬—9ò–æh�¸ìNÅëŽÛÒë.ðüÉPôFtïÃ\$¾3\nðFB/ó=4÷-ìÌÍ ÔÍ�9ì# O:I�ó]#Å7Bº—,:ÉÍ< N âDñ@ÖRˆ®\n€Ò#ˆžzÑ%8i:\0Úz“' Y‘*¯&Ôä¥/K¹Ö¦²«ÓU4 z€a>4‘\0 f*\0å*TK02Í<Í0S fòæÍ?Dôa4X-¶uÎj\$E6\0Næi´–ææ\nÿc9ñH’´² §HIb—ÈFÍÏÀ‹þs‚R~t»I”¾ 3úÒº‚Lè;% 0p.B ®FBnMKÅÀR¢sDÆ'èa”èÅÔìÅÔóD\r1ÍOì\0œ²˜És´gL^Ì…àÌâO>lÚÀC<DôHº-4<àä™\"V]`¦/BŒðU&±Ó¹-#w;Ñ^›MÐürŠq±0œ-œo¨~pKÀ׋ pš Îé\nqè,4ÁWÁ\$Fºnl\0ÙM‚Lš\n‰…-úm®\0¸)�Z@ÏZ‰†˜ï •¢^@Î  Â&Õ�dÖäý] `ž¬ÆÖât\r¯„'\$^Rü'àO]©æSЬØ3î5 ⓘF\"Q[uÉ[ÂH\$Ío`6Zuªðmo[•Í]ÍXÄTØ ™]µÒž•×\\c›b¶:–bæU\0ØW2�Vb ëeˆ2/ºd%<YRt7ì'f§0‘uìruòhÇU@cTsÛVãÇgFΖ{_-_P²E–‘T:{�ÍVÖdüÉÂþ-ˆIc¶þ°È�¯ÍMëþÿiv¯ÿ J¡\0m3@JXµRMU_²žðºˆp²5)kçkl-\$,Æ“\r&›\r�ÜýO§(oÈûk+rê Õ\\àP7\"*^å P˜\rc <>³‚t#~Ræ\"»en ‹ èƒsŠ„ã¶;·D —ItÀËu p t@À‚8d \0ž @ÔlTw×r —ww·~ bŽ ¨ŒJ æóu®\n€ , u;jÖ·7s¦Ã{*„oÂ>q†<-\0  à¦\n”œà‹|¹rcÆßv7µi7O{ECâ(èœ1Äp¶y�Ò‡nØàð¤²àZ‡à[r>8ÃX ‚âç·á{¨¯~j…~¤î(à°¸(Y`ȯ7_»z%vd™'‚%.‡\$w/.=Æpô&¶—¹…8V5R=ÃN„4†×(ˆøfuâç„øJlåjÜu`zXQ.–X! ¾‹´‹—Øk�q—rpû˜~¦¸~T£ÀæiÂcÂfn¢Žx¸¾@ŽS€Ë3*�6Û¤b ÷ÜûؤÝ�ûrçp pú¢n=)Æ­‹\0ðÈLú(L…ÆnË/§-88Çs\0z g½Ä\n‡ëL“�KÉS!mÃ&–æÞç\"ÌÈ×b8}BXZy,ͦd _X‹ð€^\r1 zõªñ‘BuWÞ7Õ;s8ly^BªÂÀð„fZ`Þ“ôä ø­‚FyYg–¬!–ñ Pl횣O8ó„f<Ió,˜  ª\n@’‰ÀÛ�dp4j\0*¤\r�l]œyÊ\rùÎ[=”Ý?+À,'N¼˜}TYs\$w®fØÉ› Ô\räD(àM#\$Ýh¹_ey‘…Ê+²\"K�4\0zYì DÆ]¢.Ê* xñÿ£Ï÷r LœÐ˜]\rj ^ç@éš)÷“¶\ròÀQrr'p0�À¸à\\P¦,\"ª-sÉ’PÊøŸqôo‹w‹¸ñ¡ÅŤ'�%y�cÏ�Óvó,\rK«îÜP…U@è ç�ˆÊAé2Ñå¢È¥q|ÒÒ 2\rœ\"ÃCi¯�†?.¨šÉ@è ‚<Ä €î0€ÜQôt‘ty=Dº[FÔpG\0RÙ³ü‚ÏÏ'Q@-6“2Á»*Á/@PÁÌÄd;7[ŠØ’!\"zÛS±-~o[„D!*–Æ®0N4 Š1ê—1ç8�ñžŸ{l\$ DÖ G¦|G\$v!ræ‚Ó- 3T�m•Ä™‚\r°ïq0̽N˜·né™H”SF dùQRóå»Úc’Â͇ղS\rcC.nÀäiBx-l”v�·@Üáᛎ!(“HçXÊc„g( žó#%ÁC nû(P‚G9Âì\"1Ü7ÀDG�Û²1ï€So8µÌSÄûqÜ.ˆ¤pôÏP h€e‚ª 0Ö¬k+¸@ cÁRG§hÙ ¸LÈû†/âç`V.FA^\\lܼöî5\0¸ `\0‚E|C®jImPtyÇAnGu'pÂd-åÄËÉ05püÓ&ÀIÄu%¢\nOÜ<|2\$úø@¨\rîFDRÎ^`1À±°f9Ð`è /÷Ï ÊVÌü†;eø\0<<ðü€eÏdϲç�Û1Ò²‹Ò讥kÏùêýD �4V¤YуÇÁ�Òì”åÂûw·¶ð¡¬kpÖÇ;þrÃÆŠö^\niŒ™\0‘¬…¨c:˜¯)¼y¸\0zYvz9Ö]Üèâ«¡`W�ÃYžÍ�ëÖƒ�…Í‹˜—‹Ø—Œpe�«#ØÛ1ûñfãõÝÚµÞ']ĵ€?]ĉ-’Ööï =ôÏú˜æ8˜oT¨W=õàâ\rÔþ�\\Ñ­lÍÍy¶þÝâœÕå¹àËÎÖŒq=!^„Ôâ�…äfqꪀZ˜³”\0Vç]=ÏFæÉxšn`˜\rä?‚tð XQÉ‘çþtZnq<ŽJ\$cöàÜã< €íþ’íàvñÝkÀ¤•èeÖ®Þ\$¯^uë^ç)i¢Ží矗ƒwÚnߪ¿ªSÉ<˜>ÜæGŠž¥3À. é<•ÀŽ7ÞÝáÄœßmÞ¥Vþiwמî ó0ÿ/\n\r%1”\0yèKë�ñ ¯EëÄ\ršúⳚñÞ íü‰§¨Þ¸™eíNLêÇùæ:CÈ'?ê~óéŽ6 €è\$}ýjf¬é•R\rõWD°÷.T\n¢èNÙTÿ}÷_�÷E|í“—UÌ}ÐO'ÀØIŒ,Ê–7Í¿½€…:h±ØÚÌì„Ô\$ªZ0¸èDV”`t XnÒvójGÒsë9l°ÉËÒªB¸ã“�€”rSF<;Øg%v(ªšÊ(Q¶�×¥P(�\nFlý�è?j\0oÝ€3±à{ÓdxìË¡‚üf—àbÄûW-Þ¸,QuÀ,+®Ëa.Y ”Àñ‹l[¬õ%ÈWSxò²\\� ¿D×G, „l”Ô]@LÄÂ\" ²|p…?l™Zaà8õÀ…0!Á/ôºoø\$�vïÖ�áî`rߣî�æG\0‚,Àë˜ Á0YPN€œ'0ˆÁUû�Wƒ0B˜ÄØ2Ag0gDÌMòB4Å&1�Éšˆüá™w÷¤µ¶†Šô!™0¶„`-­7 ›F)+‚·(\0007(rË\$9­ LÅ€†¢‰üTãÁ…L€=\"°ÑKQ.N<ŽX@¤}Í+ ˆ@‘�Ȧ¡,…ˆ·…”áñf˜ø~�½D/ŘjhZÇŠ…ÀCp©Aš§2C‘Àà f=`„*É|-ásÔK;,äê\rPxT\"}îöC5kÒ]OæµÓœ½ÎŽ ùý!âmç_ÀF P~ð¡BRí½˜@\0l’wßó‘’œeŒÛmDjÕö°¦0%¯ùÍÀÖ P´§”Jx€Ö&%ÈB’:8Ct \nÊ!B'#ø–ÜþC61ÔMb\\€u`õß\0ö&Š7x�Jîy€Dà\rL~3`L&Ÿ‘É’Ä`ÑBìP¢ˆ‘Ä!õNcüSW}ò!« ÈÍ\$ P\0^Ðé�Ä\rˆSŠàÀ^tq? ˜*GLèP™°úÎ+Âm tY\"âøµÄ,šñ\r¬CÓ,˜�Q¬IL Ðb*\"(‹Äê/ñˆ'PZĨ\nµ™­µFá‹„X¡Äò\nø£èî7š<~æƒ7U´”[y*ÇŽÿô–Ðå7\nh\nZ¾Ø• 1\0g-Ò8 \0#˜F(ÌåAlúKcfOäÃœÁú€œ@Ñ\0p:@\\zÑÂ8ñ¹áÂBcðM‘+afßƃô…²b©\n¯PŒ\$ž�µ‘Žðâ {”û�@%àw°í™TS²È0ÓX ‰œfê&=IÃÞŒ{\0äÀáš‹ÜahéX\\sŠò\$±@¸‚ò;È\$ ò)oCâ�rD¡œ·Ð‘‘©Êq×%K�cL\"vPž#�{+\0{¸±” ±±-Ä…DLïHÁD‚�T*ñD‚º Ú²D¤ÐZ9Z\n›æº?à”(<HÀ`D9�îI% š?€Ä™õ½8 €b~ÌQjÑÏUÒSE¡ÌÀÊE¥ð˲S’€ü›ìž ”INJªQ9˜Ìôp.†œßÇY´äÔ©6Má“‹@Fï aîI‘f,þ)¬™£¥¨f#Š\nX!i/Â\$”´ª‰T¡”n, ;ÉZM²{,Q•®où:�õnò™“Ì›™M)ÐòIRO2“Ô©äã'5lÉ1æçß?ZÕ�ÊBbp‡ b,1„Ñ£!\$/µÖRD�!ª·wÀð (*E€Êð€\n4Ár,\"ŠÝ]ö`î¿X‰17[JKJù!º©éÈ –ò…á!}\$}éÀgŠËÌL©G§#t@²Y�á;�ë(Ô�ä¼|?é­\r:(É~\"aŸªÊþÆ_\"qâ˜!�8 •\0¸Ñ‹ `cC}(­F_+�8LYcªŽ™ ^3.…U÷@]!�þÆë.P-Ì|fAU¬Éí.#Š2&PD zdîÀ¼àLHÀŠÀ)}\0X„µ\0Pû¦ÐÍc!¨™äÏ¡H7Rƒ^À(DdQÀJH(V*Æ[OœX1ÀØ9Áº„–WL¾I€JD†L\"kÓ7˜\nBë0ùˆ�àc3 yžÊjÌ0�Ø à|&›ˆ&ú@2¨ �v仞\0/‡ Aàâ»g\"&e1š µ¡€'\r.åYÂdé!˜â¯fU2Ê�²eɇ› p…3p-‰PXTŠ<ßÃ\\\0LµDI™ˆ%žá;2hÓ5áM@C5陎fÈÎ\ntØ¥»6D–\$ºv�(œ¸\"\\Ç Â‰R&Rò�ôðDÇTO\r†\0›¼l\\pä98‰êb˜QÅ%3C x9d8I°„Ìo`'sªË¸Dâ(Ih¯!¬—\0C\0Š¹À„•`\"§†Öhp0…T áPØp°Ð4“' €¦¢)©¢0z€o«á\0÷ÐDHÄƹ©„\\È ¼\0 ÀE˜½Æ˜5鬀€sZ#p¦\00000=ªœ]€Ë+cûLœ&x?3¾èFq\0ÞÍPg÷-²Ü€Zsý¬‡ñÑ�JâCøê…Pà[O¼Éöû£F'ÜoÀ—Œ3\0ç§Lžˆ¯—­#PЀìœ3�\\Û@À1!ŠMÆntnBÃ.š[1sjQ˜<©®\r=¤B!`PR�‚÷­Â2÷!ÐÐbÀ+¡°WBÂ,<¡“ 0ʬå<”—Æeú“Ÿ—ŒéÑœÙ�€É’£)ƒ\$ÊT>ð³E¹  s}*8é`)ªI\nò–ªÈ–,LʶUÒž?ü¬D¶)ReÌ8µÖ‚ˆÝ q¿ \nÉþ(>E@rŸøh7Z[„u­¡¦‰2'ý@.Sa´ÙVxJ)-0òÍdÃt‚aÀ@wJ�î�� +\"µ\\à8ñ ¸Ø”󖊳(p(xZt=>hžp3hg?£œÚ„\0¦¢\0.¨ˆèô1¦mK]éÈ/˜ü‘ÂÇJ�.€ü[c�N• fÏ 0-Ò©” ´©¸ÀN‚‡§-jBu d|2‹üiÁÝ—qÑÐï)ýW˜Ú9H»²ÀºAeÒÏš(ÆiÑÇñt¼¹å„Œ*¤Rõ“¨\n�<¾ gp HF‘§ªÒ°Zyò7I 9tÈPI\n²†Õ(¨¨,2e#iV²ð\"¬pγŒÕPŸì¶š§¤»XªSj‰W‰! ìrÕ8„d&ê±\$aÄKÕ!uUŽÚ2£UÔü/@_œÃ-8‘F °òÍP@ñV˜ÚUd·æv—z«ªéZÈU¸·Hªú@QV*²L„b ,«C+�A4ur@„ús|g�e©¡QvM«‘ß \"d«QYÇ3R¶À[:(D\0¿ˆ>\0ŸuÃBJ5S�VªÑ›l†LŒÕb ”Vï˜%ux[h�UÉ#Ÿ¦½CnÙ›%ÜÃJýKoJU eβ&\0ŸÕ0‡ÿRJ&T¼mcZ»-ÞtÿÓ hy^P›Ñ\0ÙrwÕ{@ó^øtÉeÙP?2]KN¶qŽ&~ä`.,¶dÿCºòÄ(/\$xùô*Y±š\\´T ÝFh±QšÖ9¬ ^AÈhñ[3=®®5ó|ÅÝxµ€ÔΡU7‰ÙT-P<‹\\;b”°ñ‹Ì¢j%…:ÞÄ\n %ŠÂ«ÎËrÎ<žÅ¶©-@`;{-‰ò‰À6¢‹p'8’2 2ÞªE/§³& àRJ«¼a\nW³i9¬ÞN˜OB“\$ù\n¨ÖåEã/25o(à›o)É“ìÊK\n<e Ï°+BÚñ,²e«�f“³Ý�µ™A’´Ll­Ëyg…�1–›e¥+¦ï\"€ÊŠ³¨a e�øÆÿM¼öŸ&À¡ÊÂÖsÂ’S‰*¢ÐÏ°:ç×d’Ï ¸ÇpÎv™FÊŠgë³HÓ-E�ŽYöº\n¢ôŒzgÙ²2•ßv¼¶�ĨñtZ\0‚PR ©dpÐ4¹˜A„lôm3jKN–âÒÍçµÜx@ËgЀˆL9Ãj·Œ à+s®Ýê)¸çpQ7@34IsŒ I1‚G[ñщø%V¦�•¼ÌÇg£\\Ùò‹aúËÃËoØ7Û”Ò6ç\r­º@_lR¡lÐuÊ+…j‹zJžÛ–÷¸Ø­‚:GŒÜr3ƒ�ÀgårV—PÚÒ·0Y(EP\$´[P  ö%ŠÈÀÑD.Üîßä^È€È7n™?ánRϵºí!h`�Z\"â…¸³8×NI3Ñ)BUŠS{† sj”ºÝ0 ÷N�zv°YÆÀÁ\rpª[5­¦\0Ýj2+ÛÅ,ü˜ã…îÔ¥*ÿݹ%©,åÞÖŵ¾Ó -¡åa\0F£û¼\n‡Žô‹+çè[±�Zl ?š…—hLɨQ9Ú²@ÈóøÀ9C ¤�\\/_›ÙÎÄ!.oãáRP:�”°þöF Cì’qIY,3Õ(´Išqã DG7=½æáÖû`¼]ÊéÐ:Mí Ãb«Í×Í\$ÉA�[qyº6^f³¤nõìhéÐ^†€@)½ B@u{€ÍB’NG#ÓPïiZÛÖÞÜ.³½cOœ‘{æ^Ìw¸¾áo‰}kjú‚”¼Þì‘d£Û±5 SiµB †E1»#8©1›nm]ï%P6Ÿ¬f”«ü\$Pt§ 5Ö.D�%µÔˆ+#Yµ¶X5�lXgSJkøHÞàW@.@G¹w'b†²PY‚²„Fã 4\$1ãCxÒ\\ÄŒ(±FáA&ØS|#ÑæBl\$¸+NMi}�¼ŸER€,=Uö@·Ù3P QÊ ‡ƒÑú€/�@œ¾€>Lñ|³»¼%š '#�ÁRRD@¢‘xC !\\üE˜�F®Ã/ÓÜ!tùsÔíüAW¿Õý­ø” _ÀÔá E€!Å&c൓]eFKG.+@Ý^iAÃʧ'òZåOaãS52O¼ÿ÷ãEF1r·t-ã\0Ò8§½ë®ï~¸;V•õ†D¤+ðÐ7T ôV>¡ýì ^òÉdþÅ©â×�¶õ­Š}òúDÂ\r*‡ƒª¢Ðø(òê¬R¥ïƒHá㶵(*¢5þæ Р™¡˜ú(-[)ô(p>ÔÍo˜ÌuÐÓ�x¸6&Ï W˜Ú>…Ýè‹�úøTǘ½Ç1÷Ž›\"î\\‹gÁlº1çUz£ÿ¶qÇÈØ+V#L~XÅôY‹’Kˆ…4 ¢9A]\\q8‚ü„J÷ÕwÁu^¡'’˜K?û%�ç„íq!9,Êê„â’Y4BŽMÐJ…W'¿ú�µÉ –B²A�ÇÂc:Š¹�èá…y+iícpé'GL*ì²q²R—£Çc¨Ùð‰€Ø?ª°D¤‰Ÿ0€ \\¯MMò\0Ê&I‡ÉƒKË)uË—”Ü')—úÈFÜa w»(Oåå\0Úe2èdùÁ!ŒÏ@#DG6ˆª½¢.LªÀFò!µ+ ]Ù>h½I\0ß�+-€x^gÐ�t¨‡P^Ë0ê –•°œÀ­™nȾ4«ÀÚe£jÎ[OÓŽÁ°]êŠä4Í*°\0ÓìÔ¡O5”]¥áÓ‡“èU”|ót˜³Œ& \$�8€EÀ…��ôUdýj¿£\0q’ѳd@'<í� —/ü�¹kpö\rf7*IŒ‘ôؘ@Ì-^j�—‡ýÂWòÉ�HÜæ44‹Nð&ZÊ–uóQ•Tå_'@;Ï€Úr~ƒ ¡h/@:\r¬ v2‘,ƒVHŽ°¤º[«ÀÐŽk|Ó!6aú ÉÆV\$°jε˜f3Ë­VqL„ãŸ#ù‚ ~a2†ÊmØèý™Æ¨]G&È)bä¥AA¦ÍBÈW}òC_Bàt˜¯]L.¹’¸ð§�Ae®™€¨®@È•W6ÅÞ›´àÂ8X§”\n\n†y':C@¨8K£(�è2\"Ã_PÃÖD`èôó�;ÁJ„Äü4ÌáHb§Z^l5âŽP( T(\0žf§�û\0t­  \0ó?¡îP´U~’é{\$‡—Þ'­¥÷`õv¡†4\0^ ÚJ Jɪ±ù€íè…tCmZá :LÍ ;²N³#€,ÞPȺÐséÄ¥\0D êÑ¢>>ºŠj)àðNSòt8\n©Øʢ秌Í#xi”è@¬â>zrªµèm{k`¯‰×Ød¤‘R¥ê¯E•F\n:B÷}F(Éa™HIž> h�Ôl£î<\0'‰(†}‚¶1¤IÑØ¡Ç€eð½~ã�ÎhÛ()_ÂÐtv¿e-DÙaÃDz“0éÑgY‰J”ò½š�Qèò�þÏ…s´Š•öA#è¶�gK×Ìó¤4{î¶\n¡¶@Dò€1숉PM ìÞ’@^:8 ¬nщäãDnhÚIAT¶a4íEO§ú7ÖÜT\0004 õ¡6_:<È\0[¯!vH‹h.'Ü\0’¶¶QX¤ù Eªu`v]çŠpôâŸÛþáÀO¸�­¥ÑÎ+ÛÈ—h•¸\0íôf@)Üȯš)­Âî\0[ˆh¥6ã°¼y\$\"X>’>éÂq¹!Omwu[¬®PØö \"‚�¢eœ¾¥ãã;²Tym„Æ»cvóvÍ6Ý´_ô+§G` 2uEÝmqUBÛm{5¹µm~'‘÷NŽÞÞëö¦ Ýðlm›‹ÛvÜÀË·\rÓ)l¬›ã:Þßd�ŠgÝ\0îú›°4Îã÷jâqT;nî, D•TüÁÚ¼ –þ÷yC?P{€w8\nz\rÌgs›zOÇo¾2@n'wàtÞ œUd=t8›ƒ©à–å÷ZPÝ…8Ÿ_ÛÛáv’±®0êÔ «/Pt(\n[NëªV¡~n»ÓP.º´…›gü)¼UÛ5ÄäS¤äcÒq®f½]­�‚ø‹ÜVÖ¾¾5ô#áÄp§]r±—”¢^\0§ò�§Šy@……è´>…T-à+àÜ»X‹´aÀ±þ±\0*D[–Qþ>¹d*¦ã¦ÞrE@Íñâ+ ãç¸ÿÈ„� Lïg#·Ùè�œQ&„úñŒFñƒ…Ñ¢§ç‡ŒAÚ£í}žD[•\0fÀ*€¼Ù�Òì,DêØ~D<\"�“VB>@àT\$¦î@�Ì€3Pä“F‹'¡ª×FHs«ñ««bLJGÂ56® ¢ØQ íÒ3*;L#cÛ(Ò×�^èË)ºH\\– Áaµ|ÍÀ!Å�3bHŽÔ±g)‚02Õ;1bÇ“Ø&ÂðjnŒX¾½·�V0XãÖ³µ¦××Fd\r ©‹HÈçgaL¢q 'S\n<¹¢8\n\nòööç7¹¥.x°º6í¸21¼P´J\"�Öè\nÂt6eU\0´kÁ€ 9ÑzK¾v†Š¤P¸¦LON±Óªà€È]éð �ŽP¸ï <×�B_…~•�³ZG•éxc÷AÓ0Ö\0ÿ¨šÐ‚íz·µL(tñ8�>ÂÐ Ý HpØ÷<Ò×9ù¬E^{|O<íæpïRa>nº²�ù4|9aÏœ�±õÅ›x±ç\"ÊÆnã~b£—°—Hxú’^GŸ¸±kΦ¤s¼Ð�ô");}elseif($_GET["file"]=="jush.js"){header("Content-Type: text/javascript; charset=utf-8");echo
  13. lzw_decompress("v0œ�F£©ÌÐ==˜ÎFS ÐÊ_6MƳ˜èèr:™E‡CI´Êo:�C„”Xc‚�\ræØ„J(:=ŸE†�¦a28¡xð¸?Ä'ƒi°SANN‘ùðxs…NBáÌVl0›ŒçS œËUl�(D|Ò„çÊP¦À>šE†ã©¶yH chäÂ-3Eb“å ¸b½ßpEÁpÿ9.Š�˜Ì~\nŽ?Kb±iw|È`Ç÷d.¼x8EN¦ã!”Í2™‡3©ˆá\r‡�ÑYŽÌèy6GFmYŽ8o7\n\r³0¤÷\0�DbcÓ!¾Q7Шd8‹Áì~‘¬N)ùEг`ôNsßð`ÆS)ÐOé— ·ç/º<�xÆ9Žo»ÔåµÁì3n«®2»!r¼:;ã+Â9ˆCȨ®‰Ã\n<ñ�`Èó¯bè\\š?�`†4\r#`È<¯Be ãB#¤N Üã\r.D`¬«jê4ÿŽŽpéar°ø 㢺÷>ò8Ó\$Éc ¾1Écœ ¡c êÝê{n7ÀáƒAðNÊRLi\r1À¾ø!£(æ j´®+Âê62ÀXÊ8+Êâàä.\rÍÎôƒÎ!x¼åƒhù' ãâˆ6Sð\0RïÔôñOÒ\n¼…1(W0…ãœÇ7qœë:NÃE:68n+ŽäÕ´5_(®s \rã”ê‰ /m�6PÔ@ÃEQ�àÄ9\n¨V-‹Áó\"¦.:åJ�Ï8weÎq½|؇³XÐ]µÝY XÁeåzWâü Ž7âûZ1�íhQfÙãu£jÑ4Z{p\\AUËJ<õ†káÁ@¼É�Ãà@„}&„�ˆL7 U°wuYh�Ô2¸È@ûu  Pà7ËA†hèÌò°Þ3 ÛêçXEÍ…Zˆ]­lá@MplvÂ)æ ÁÁHW‘‘Ôy>�Y�-øYŸè/«�›ªÁî hC [*‹ûFã­#~†!Ð`ô\r#0PïCË�—f ·¶ ¡îÃ\\‡É�^Ã%B<�\\½fˆÞ±ÅáÐÝã&/¦O‚ðL\\jF�¨jZ£1«\\:Æ´>�N¹¯XaFÃAÀ³²ðÃØÍf…h{\"s\n×64‡ÜøÒ…¼?Ä8Ü^p�\"ë�°ñȸ\\Úe(¸PƒNµìq[g¸Árÿ&Â}PhÊà¡ÀWÙí*Þír_sËP‡hà¼àÐ\nÛËÃomõ¿¥Ãê—Ó#�§¡.Á\0@épdW ² \$Òº°QÛ½Tl0† ¾ÃHdHë)š‡Û�Ù À)PÓÜØH�gàýUþ„�ªBèe\r†t:‡Õ\0)\"Åtô,´œ’ÛÇ[�(DøO\nR8!†Æ¬ÖšðÜlAüV…¨4 hà£Sq<žà@}ÃëÊgK±]®àè]â=90°�'€åâøwA<‚ƒÐÑaÁ~€òWšæƒD|A´††2ÓXÙU2àéyÅŠ�Š=¡p)«\0P ˜s€µn…3î�r„f\0¢F…·ºvÒÌG ®ÁI@é%¤”Ÿ+Àö_I`¶ ÌôÅ\r.ƒ N²ºËKI…[”Ê–SJò©¾aUf›Szûƒ«M§ô„ %¬·\"Q|9€¨Bc§aÁq\0©8Ÿ#Ò<a„³:z1Ufª·>îZ¹l‰‰¹�ÓÀe5#U@iUG‚™©n¨%Ò°s¦„Ë;gxL´pPš?BçŒÊQ�\\—b „ÿé¾’Q„=7�:¸¯Ý¡Qº\r:ƒtì¥:y(Å ×\nÛd)¹ÐÒ\nÁX; ‹ìŽêCaA¬\ráÝñŸP¨GHù!¡ ¢@È9\n\nAl~H úªV\nsªÉÕ«�ƯÕbBr£ªö„’­²ßû3ƒ\ržP¿% ¢Ñ„\r}b/‰Î‘\$“5§PëCä\"wÌB_çŽÉUÕgAtë¤ô…夅é^QÄåUÉÄÖj™Áí Bvhì¡„4‡)¹ã +ª)<–j^�<Lóà4U* õ�Bg ëÐæè*n�Ê–è-ÿÜõÓ 9 O\$´‰Ø·zyM™3„\\9Üè˜.oŠ¶šÌë¸E(iåàž œÄÓ7 tßšé�-&¢\nj!\r�ÀyœyàD1gðÒö]«ÜyRÔ7\"ð槷ƒˆ~ÀíàÜ)TZ0E9MåYZt Xe!Ýf†@ç{Ȭyl 8‡;�¦ƒR{„ë8‡Ä®ÁeØ+ULñ'‚F²1ýøæ8PE5- Ð_!Ô7…ó [2‰JËÁ;‡HR²éǹ€8p痲݇@™£0,Õ®psK0\r¿4”¢\$sJ¾�Ã4ÉDZ©ÕI¢™'\$cL”R�–MpY&ü½�Íiçz3GÍzÒšJ%ÁÌPÜ-„�[É/xç³T¾{p¶§z‹CÖvµ¥Ó:ƒV'�\\–’KJa¨ÃMƒ&º°£Ó¾\"à²e�o^Q+h^âÐiT�ð1ªORäl«,5[ݘ\$¹·)¬ôNô\n«ž[Ðb÷ƒà|;‘éîp»74Íܔ¢¨ÐIŠCË\\Þ�X°ç\n%øhØIäç4Ïg‹P:< ôõk¦1Q™+\\ÚÈ^å’ ™VèøCàòôWàÃ`83B-9F@ànÃT>»ÞÀlj-–¿öÊ&âÜ`9q¦…Çßä‘“PÜy6Üå\r.yñ&£ñ´ÎảÍÃE8Ÿ0 êÀõkAÁ×VÛT7ñpïÆxØ)Þ¡~¤M½ûÎ�ß!áEt§ÐùP\\èÄÏ—m~c½Bð\\\nímŠv{µÎù9`G[·¾~xsLî\\±Iõ®ïâXwy\nà¨çu¯áÁ™S£c»¬€1?A¼*‡ùÍ{ œã½ÿ´óÍ¿á|9Þ¾/–òþ¯Eúï4æÊ/¿Wÿ[ȳ>–á] ÄržÊý¯v¹~B£ PB`T¡H>0¤BÒ�)ð >¸N!4\"‡À¦xW-ÅX)„0�BhA0à½J2P@>ÈAA)„SÎôn¼ìnìO˜Q¢¬ÇÎÊb®rõŽÔÒ¦âöàøïhèí@È‹’î®(–ð\nì†Fì˜ñÏ–øÆ™…(ìγ¤ÛP\0÷NÂõo}¯‚l«<ønÞø®ˆâî�lëoq\0/Q\0of*Ê‘NÑ ½P�\r/îpA°Y\0p\\ãï~³ÐbÐLh °!Îã ÐPöîd÷.¿ïy\no\0á ÌËжöP ptùP¡ ov�ЂknŽ¸\0z+æ›l6÷°©¬Êø0’äð¹P½oF€NìÏFô¯Opý àN `Ü ÐÖ\rogðá 0}PÍ\n¬–@°”ö15\r±9\$M\r \\©\nggì À Ø\$Q \r‘“Dd‰ÆÊ8\$¶ªkþDâjÖ¢Ô†ö&€ÓÀÊ  ¶àbѬ˜ê°¿‰› ñ=\n0ÊÕÀúºÀPØ ~ج6eö½¬2%Íx\"pß@XŠ±~ «æ’?¬ цZelf\0ÒZ), ,^Ê`ß\0è8&´ì ¨Ù©‘Ñ r€© ©�ÃkFJÂÂP>VÆœÔ�p¨²8%2>ÂB mÎó Ø@ä’G(²ä¨s\$Ž dÕÌœv†\"Èp°wÇÆ6§æ}(V ÌKË ‚K¬L ¾¤éÄWñö qú\r‘þÃ̤ʀQòL%’PÔdJ¨¦HÀNxK:\n ¤ †%fn‹ã³%ÒŒ¿DÌM ü À[#¢T\r©ÀrÂ.¦LLè&W/>h6 @êE È ãLP‚vÆC’ß6O:Yh^ mn6£n¼j>7`z `Ní\\Ùj\rgô\rÈi2I\$\"@¾[`Â�¢hMý3q3d’ þ\0ÖµÈúys\$ `ÖDÀæ\$\0äQOf1ƒ&‚\"~0€¸ `ø £ \"@ZG¼) Y:S¨ê†D.S%͈’ Ð3¾à d¹ÀmÓU5‹æ ¬ ó<£SÒSZ3â %r “ÎãÆ{óe3Cu6³o73î—³ÀdÀL\"àc7ÄLN ÜY Ê÷k‘>²Ž‚Ç.æpäì2øQôÐ÷“¼åÓ3ÀVØ°WBðDt Cq#C@½I”P÷DT_D´:�ÔQ<”UF²=’1ô@\$‚‰6 <cÆrÅf%Ô¬,|“27#w7ÌTq´�6sþl-1cPÕmðqªÊ\n@Ê àŠ5\0P!`\\\r@Þ\"CÆ-\0RRˆtFH8µ|Ní Æ-€Ædòg€‡Ò\rÀ¾)FÆ*h—`ö €CK4Ã1‹Ê�kMKCRf@w4BßJÁ�2\"䌴Ó\r1Q4É2 ,\"ô¤'¼êx §Œy—R‚%RÄ“SÓ5K”¦IFz #XP‡>¨âf­É-WX\ršÜê¤pU´ÕDÔt&7@¶ÂÑô?’©ÀÑ ªµ£}O1½2†‡2Õ#UK*¤)ô긋Œ0o<> ]HŽš„Æ¿rè›LGNª›ê˜W%–™M^’Õ9X:ÕÉ¥N”òÕêÔséE¥­@xy’(HêÆ™Md×5<52B– ð–k!>\r^J`‹IžS N¡¥4'Æš*œ*`ø>€—`|¢0,™DJ£Fxbè µí4lTØ•û[¨§[é•\\‡¦¨Ô –\\{­Ò6\\Þ–’ öß(#mJÔ£,ý`©I³ûJ‚Õ­ÊÜèlß� ûj…jÖŸ?Ö£kG»k¬T9ÀÛ]3ohuJ©ê¢®ÑW•\rkÕÏ)\0Ý3Õ€@xè¹,³-Ê 5B”¡¶˜=ÂÔà£�#–gf¢¡&Üß·Z`ä#Äoí æXf È\r ìJhô˜“À´5rqnz õ§­sÁ,6’oÓtD´y‡äÂb´àhþ—Ctn˜9n‘ í`§X�&¨\r'tpLž7²Î—¤&—¨¼l¬Z-ͬw£{ r—¤@iUzM¿{rx×�—mÒSBÀ\r@ H*BD.7¹(‘3XCV Ç<WÔуÝ|d‡q*@”þ@ÞÀÊ+xø÷̼`á€Ï^™Ì˜ß¬__•�ND­X\0Q_D]}tõYÅúp¦f €wÔÚ\"â3øz¦n«MYñùZR\0 ÷¬Q¤?¸{†M3†•£*×1 ,¨\"Øg*U¡*²¯ˆÌ«zÒŒW5NV2O-|€¾É�Ó�ñ, ×]‚B×dí\rŠñ/OâtÎøÃ�ï‚Ì0‹xƆðŽ½Ð®OCë�8Þ-0Ò\r”ÿ�0à·õ„@]¤X ÌŠÐÎð\\\0¾0NÈï£Ñƒ4ëi¨;ƒØAtê¼8X—x¤\r†…Š“‘�ìÁ‡øÝŠ×Ê7¬<ö@SlÈ'LÒø9WŽ ÊθòϬÖËì¢Íı•ùRçÌðÌ\r¾Ï ÂÏò|ÜXÐÖa�÷ø7y€�Ù\rwe¸Œù„Y!ƒ˜Eƒù�’´šÂcRIdBOkË28[‡mÌJŒ+L ÈÅÙ¸OXpfø�Ó9Ñ�DÏ›·¦ßªw“@Ë“—Y—…¢��Õ÷\\yäAcÙ£ƒXgš™%šôó’Â1“ï“j œX†9Cc݇àR¡¹‡”QFÇpdÒ = C˜÷ý�š\n\r¥Õ‘ÔóšdjŽÙ«’xE¡Â2FX§¢x_¢ØÅ£Ú5£™—}q¨Åí¿¤M%¦ZM™:\nÏzWšX7¥åí¦:ÐZi¢npY;Žù>ʘí£ÙɆ:6Ú;£ZÎX0ƒ “Ì¢#ùýcàMyU…i2,q¹FËšÈb­J @ÓgGè|4ógÈÒmzWõäÊ ¬)™Èr|àX`Sc‚Õ§ÀË™„óc—¥‡û!²B²—±”»/}{4JÂ\0ÒÃ�n» Kuz @ÌmÚÑ®€ß­yÍžÒyÖ\"º)u¹ÊÂÙã¶Yç�˜s·c¶y둶š‡··y¼—Ž�¹7Á|·±|—Å{Ϙ*)°Ê4Y`ϵ[v¹‡¤­‡û^NX•†¸‰†ò‡W”©û·‚7†;¾_‚‹*x™ˆ¹Ú\rùß¼߉xm+¾mû¨Ú™ ´»¹‹\$\n¾l˜);™²„|Ù ßÚ™¡:œNÚ :„‚Š_È8N³¸Uœ5;¨p+U–L‡ ò\\‡9í¦Ùñ“› ¡»ýO:I’šû zQºœ¡ƒ¡TëšÜ)ªXG¡æ»ÅJ{w8“¾ûʼn¸UÆù\$ôàÃøü›PxTY¾pjh·¾J×À›˜JÙ{‹Âð@îÇ‚³ øðZ‡ÌÙs•¹h˘ç–XÌ\0Û–lÓ–ÌàÌÈθÎçìó‚Y}˜Ÿ�®ü^Ð@u2ÀSÚ#U‰ˆ;È|�¼¼•¥¼™P\\ŸÊ#ùÊ|ª<®Ý\\³À›žJÛ�‚,öœÀ•\\ÅÌšEÌú…‚]WÍlÁÎ,£ÍìÉ–<åÎŒÛ>YnÎ),ΙrÎüûÔ¼å—â�º]Èý ª\$õÐç½Íq„DJí=•Ù÷•X�I-ðÅ€äÅÌa‡ll�õ]\\“w(iÜCÄ׃tƒ‘<i-u[uVŽDÖ“¸Q¸€xb€kæLI­.kú›@ÞÀ„ÜN‹“[ñ¼l<o=-]1`蔼ªdš ÜMÌ7‡@Û%C=]�ú›êÀ/|-àÜ�ˆ¾ÉÞáqÃã•âíùâ*¾C¾òO~ÊQâòså`·ç(âòãDÉßɲ¿à[ãþæ>Éká¾R™uéÞ\\+>)3íûPÊßP§Óí6ÓËM%º¡¾pÔŒœ ÅAÐ3qmu2ÖfzƒÛ¯ì4s ‹ ´í`ÛŽ‘ì°-kÊS%6\"IT5½‹~Òì\"™íÂUt_ TuvàÖ½ä¶Yw¤†­0I7¤’�L‡\$ú¿1Mí?íe@3Ûq{,çÀÏó\"&Vi·àžÔIŸ?¾µmõˆ™¯UWR¾´\"uiT‹‘uƒq­Ÿj\"•GÃËõßò(™ï-½‚Byîê5øcÝõ?Œ àwñ®°ëTúî’`ei¾½Jtb‰gðU‹3ËëÉå@öá~ê+¾Íï\0MïGè7`ùïÍ\0¢_Ô-ùñ ?\rîVÿµ?øFOÔ6á`\no†ÏšInª¼*pà™öe�Ùí\"T{[Гp^÷ä\nlh@l0[/ö�„p oóJKÖX“ñ€ü<ª=€9{Ǿ6ç–<eß�AxãÀùÇ‚¼Éá4x[ÍžLò“~>!åOQxš{ZVFÔŽ`½éÈ~Ižß–“øL)�Q[ë�TûôM›àþ�T²*BC¤~ æâ‚ä\nƒò¡gÈŅp9zKÉ–ów��zO9di^›'‰+¹ßïDz4ägHAº¯Lyô¡\n�r€<IêjKQó¸Snô==\r.Âo7½Êé%a;‰kÏãmX¿›Zi%P¨iÏ\r­� €¾ýµ/©…L`pR0¤Ž&õ—�I (Øá\\.£ *m„*Ž(ÚÖŽõ—\$ä†ÆÀ÷\nw׊Х…8a“\n&´Â‘žÍUmª MÖ¨P+\"Ly„ó?¡M\n€2’ L\nbS ¥NäùÇr¶!w¥jw`¼Â\$îôƒ�ráè…Êaáv±^Ãq­F‰Ü6•Ó¨i*™Ÿæ„ì_xõØ\n‰fðIê:B&ù6@�É“KED¡úú·QD(V`.1\0Q\$íøF­¹H®’T�þ€zІ‹Ì\rªjkzM€ÐÀ®Y™À(61€”x‘+®%dj¸Æo\n¦¬\rg°ï\"�ÉŒ´ˆ—?Œ1- 3hÏXÖÁ)åyjÃ5r¢N±#Q¾¼Š¸w{_þ¡øG)ÂÎÙ1i‹Ì íç¤<�Z‹ºpX³¡Ö\$â?¥=%.´€Ò®&¾­%\\±8w­!¤µa4œ<JB[Ðĺ¦u4‡%êŠ×47‹Ä%gÑ�ä& ¸€Z(@ €E¢{@’Ð#¥–2Š h@Œ#ñŸø™ÑŸ�¥£@\$�8\n\0UŒìjãA(×�ž2ÀO€Š8Ú€ž5‘¸Œ¨ @†ð&'´\n€DŽ\$i#ŽÀ#Ÿt\n PŽTs#]P* àDÌuc› �PÀO|pc—øËP ÞŽ¼i#Ô}ˆæ:<ñí�\0\0¥À�ˆÅ¥lo#}ÏFÜR‰Tp @„À'� `Q¬ycTp(ÆŠ@€eh\0‹˜Õ�8\nrx› cþ<`NŽ ˆã:)DY\n*Dý‘2{dZ)A‹Ú4±²�¤€cZLð2ÈÊ<ñò�\\Œ\$r#ˆþÆö7ñÁŽ¥°!û€´ü€Nª{O¼@\$�< Ñ¢�ðVƒZÒÆž52.�Aù#D0 �\0´ÀI�¸û\"P'�H ²_)¼x@Š€*úàAOh£hI)I²L1¦’ìƒäµ%áJI‚B‘þ’g¤i\"p÷§K2}’ä–Å(CËÉÍ=²t”xCøÐ&FÄ r“�ÒoÙÉ@@'”ñ€% ÛHÞT±á�ˆ ãÔ˜:=¾)\0.ñ°]Îâ5 .ð æõ(pÈÀL!à8 ­\0ˆ¹ éR\0L‹YaÔbkÔ°ˆ6Ä)Y·éˆî •Ô®£ h³zZ¦õ±’IgÎVO3oœ­Lgà3ËY2ã�Û‰ÜDoPË`3̸ec-‰r7í‡2Ô—Dº‚ Þç‘B¼‰Z•¼¼%å/I{ MÃ\0pÐÀÌ�.`äÊÝo*•Ô¯%�T€ý\0 &–iR\n™+Éo€ì©–\rÀ^2q”Ë©\0\\¨I@‚ �KÀ#peC*!>€/á�%|È…Ì’ÁÞŽüô\$è)çÀ§1P30(\r¢+\nZÆ zž„))\0*®\0kà€ÙÅ2¼–Ï…(–E86å¶s—tºf&”™Š¡´ “+;”Ø76&ãK–_Ž(›9fÓ,@-ÃÉ4l\$Û‚e7\0ù±:l“LÝæM7�.\0ˆ ³|›ðo–JÛ©ÀÎZ³u•ÌºŠ'Èy{ÅH,#\0vU@9!¼¥ Ñ'†¨&„òGôøß@_-Ù¿³ºt�;Üê¡:©µ€²u¡<—ˆL†iÙΚ_ê€�Ø£@U6°Îù#ä_€L'~ùæ/Öm`\\Të']=Iäât°Çž¸Âà)ÔÏqùsÉ9Âa<RPº|�tžút&5°äs©lî@¾ ÞKÆwS®�èlÍ:9úN®wSø�|·göÉØOù�AП<ë‰BÈ€\0�/àz @´ ÍÏÁ•Òå†=?=iÞO‘ŽkÓŸ=\0E@iâÐ\$ B× hO\0Á>DÖP´ó‹Uäçцj¥H ìÂ9F¬BcCi‰é­BwMŽ§tÓx €PÀÙM‚?p“®=—äì8ÜÔý‘Ïlg~�¨˜tÁa©€%]b\$àØ\rˆr„èÄa,6ÅtŒàW)Ž\0U¨›F˜ |æì“¢ˆvh¦Qú*�¥Oƒl.C\$À\\ ÐÖ�RRÌ<lcù™&Cj3Ñý%ôZM¨öÀz9GpY’â¹£�\0i \$Dµ‡d‡ñzt[')[)Q¤ØêÞkÁpi0·#cþ‹ôNE¨ô(ºC2L Æ@9�hÑEJ5Ò,šh{&Jzö0 n€vª©>[€�j“£Û[œ] ƒK•ýRîJë>.;ù¨íF=RÚŒŽ<råÓM¡=—Ô’¤ÜhØ^Y\\RmnËÐð Nn*g‘¦ôÒÅB¬·5^QÒ‰@O¢°x¨¡HIÊT ´â9½)(‘œ&µ‡}A)PÊ\\/ê�ô…_Õ!Ì�H þÚ‘¥¤ù\0éBá­\$z4ÓTYu‚J’v\0ê�ƒ”¨…%@æ32\0Sôm€--�Gi@¸úQÅ%Ñj©YÝ+FuzlSž—”ÜW3ØÅ·OrŠU\$EÔè;¹M©¢\\€Ô±Äu/£õjeQªš¦§,#J¡ªXPÔ<UH •TVVé#Uê™ÔUbˆOU´DZ‘⢵ £Í8êÕUJuS � «À‘g)XDZK‚•¢Bî\n¼@2Š©ìx@d&�ü �½eÜ«Ià @ÊFwì¬8“©\$Ù'IºV‚V† U\$²ETÎ_ð*ˆd¸/áFCÓYdp§�vGƒ‰3‰ ‹Ñš‹L^(ù`áj”÷2S¸�ºcÛW¨ÜJQYiÖHB”£�ckœRè\nþ²U\$jê\n„ZAi€î»¢U*wKDRxW‰LÂò­ˆ€+fÚŒ�@ã¨A4¢àGz…R\n²5‚b¬\\_²Ÿ ­ô‡¡á0¼C@¤\$X\0+Å]¤ÑÂè\"?‡n¦€+QIj\n»x\r€ôB`S¸âM‚ÈÑûŠ\r o°@‚À6XÀ\"{±\0µãb ¯)–ÁM¨�cMðW ä¶D_áαÐv@{cÐ:¤®%[%�‰C²þ1¼Ù;Aƈ�ÌTn› \0º a²pážóe~ÙU5 s©V†Ýe|M9‡€9 hË@æ¦\0êÙ~É@.³ �l€· Jv]©ºD§f€7¨FÌá±³ËùŒ,/+:¾‹íÚXIi­\0U¢â@Nµá´\r Ê¢,².½i¶‡ª³m _ûFŒàÖõ�äÀYiUÔÓJ¯!©gûLj‹ãÑú¬D“iKA à�6�²õª-U«KfÖ_N€\0ö-3©ìÀã3+¥dãiûD \"ö¯µM¥ml‹L…XÜã㯸Œ�>‹&|UÕÑ�õ`Ïh¾ù2¦ÑÐn6Ý…·ÉI+ Øné-nDÃ×`„µ†®°É”°@ã¬B!;X™smȯ·†pC`‘p5Á°¬¡O‰%Z/Õè5”³é#CK`‚XˆªÂcb°Q#«§Qa»–Ž…ƒ¸q…èpÚÝ÷)™®G+~Û–ß÷\"ðlM_^zò©šæ!ÌÉàE«”�Ð¥’®šÀ‡ïa úØp86ì„åˆn+oì’Jâ¶ö¥¾,¹¡ó‡¢ºw\n¢]̓pëŠÛRÁõ'§eÖJÕq�µ'ܨ%£'€nlO‹h@>NBÈŠX5�,ˆ‡‹¢ÊrGr�¹ Z l\r(ªË‘jIù†±lŸ¬%b‡;s+±× ¤Wg7¨)’*e…¸1µ•ÞÑ3“L e@(»p\0 ÐÃŽèds�®AñÖD\0Ã�\\bD§\nuê/&1¬ÞXR×¥E楂5¡Tœ\r§}7õ§”ªîÔþ”AÙ¬�áÉkâ\\–øö͵�´ŸÇqà2Ü€ö�Z-wo�´“tßZùƒ‹¯]ó-yq2j+Õ†¾Õ­Ã«�¬€n¾XA«Û\0†\0º¾+S•+ïY6_BúV�7z®nZ@̆²Ô·Æ´]´-UMJc*¢ü¸´®í¢s\"ß+\0·ï¯x´B3^«öà0\r÷ÜÀÎïÁcðÖ\\jÆÆ*¬P-\\Q8ˆÊŽ�·…l•cË%XþÉVB‡}‘,€þ;(‰`*Qú \$áïÛrßÂ{ÁKøìCúÖ%¬\r¥ˆx ÞøQû�…,¶Ø¾¥×/‰vàä\" pÁã¶ð~ Ó áã ÅJ5eã ü�®Eš-^âX;c²\\©¶×¬m‹´7�£?˜6C*庮†,7®HfÄ/Â9eÌ0[@ñ¤!bê®íÅþUБ=›Äi.Jocñj;ø—B³\0¼ƒï]Õ”ÑúvÙGÃÜ8àO\\\0ÀÇŠüO©›\$Ž•.& p‘�\\‹ H1bØpø’:F\"8Ŷ…þ‰ŠøVx©ÅýµR®–x�ä=À3Æf1�Š+| Ò»\0ÂBÀ¼kbÌPÇLÑ’£ô\$zÌáàÎc ¢ÇÐi,Pcb,pÃn(¥Æ,¸ì`�'/»~êÙkÖµ‚Îp€q-›Áȱ¹VÀÜ܆�Ü\rÙ ž \0á‘ ‹dSˆÓÈÚÍ+º\"Šéˆ­1\0(Ä-’Ì1~útcªþfý¸àBÛ‘b}Ø ’Ã0<1\r°¨¨L’€»\$¸ˆ2d\"1ž&ì™Æ€BóN…Ô\r�àB\rrƒ«\"?vädäZá±.\".\0?wä¼9€oÃà\rÄ0¥Ñ�œ!¢ÍdR€‚뤶\0‘ÃÇHëÜra�%ЊØ+\0yrƒH¾sÏ’4W#œ,\$èô \0„*xBó\nPÌòü|„ 8@/ \0ø2U’°ábíÝè¢ÂÎΪxÀ! ¨d§°óúNÿ3SÔ?£ÑP»…€(òg\n8·‡ppŸˆü€S 9õ@‘' Ç\0úyµ�ÿ\0¦y4�6¡H<‚öÌ×ô\n`S’ˆ…¼ÈûCY¹’„”³jp:\0N(Ó�ŒáX4ŒkÌÈÓgßDy�‹<–n4™£ØrS<ÒÏýˆó¯?¥\nÀÇBãúf('™�Ì~dgÓ™SËÏ?<³ÓVg(1™éãæƒ2ù£ž­—²)ÕôŸf`éZ€¼a“>t{ÀœÉ Ÿô’>ñø\0ŠìPû`O¼�\\s Œ<õ?4äwÞ~³ÜÇf@z™ÿÍ~hBW Ìø³á´ŠxhA¡¡ÜO'=úP֌ײÜö±ë=óúc[ysèÌûgâ|¹‹Ï掳%™Mè,Q³ÆÒ8 'X žhlUs ®…§Ù¢ú é4ËÃqDýÂx*�8g§NLšBÈ–¨;§}%eû@YìŸv ho!\$æ›NcCXì³@Ð;YH'Á°�@^ à�·Rf^x„\0^osÜ_fª—“;¨Ópj]²:’Ô¤ïõ.mLêl\rš�®V¨\0ó@Ü€¶Ê\"ÓÕÄ1%Œ!_êô@-]8f�¤ç -Õþ±äa�]Y¯WšÏˆh`(‘¬äJë@…ÁÖ\rˆ—õ€Y kB(€xÖÂ:5˜B\\QkO[:Õ0˜¼¡­uk›X¥\\×P\0ë�[öx¹ÀÅ®�`ŠRIGÕÐk5°ðª�§YzÍ×PÒ™¬=†l=áõÖe€\0ç•2=k` Å[K¼‡Bê½�Ìû8ž¶C±Í}k«c{#ÖØ¢„ølŸdfF.̵ü-›AºÿÙ6º†K­�’•¤ÐÖ×Pàv„'�¢lHiAÝÚ8C¶“® G„`GbyÙ¾·Í- 0•Ä¬;[*_ˆ¡ãm�lH{(;Uo¶ÕÑ*Ä]Š,Ä‹åŒÖÆÈþôXË“¡80Cµ°K ­! N¼õÔ(I`¨³ V¾Dv½§íšwá·rpc,ð�åŒÃÓ\0ää 9~s»Xn㦇¢žŸr[ec·4dçpÅi \\…Èe2�âãl±ÄaZCk»gl÷bB„™¶7x%¿ê轞í€Å»�Ùk` ì\nÁ( @ź«®„5åݘ¥Ï­ċ#t›–Ü–éãE½}Å„sñ–Lvö÷E¹�ï\nQQÛ”Þæú76}õ‹Or»çj§b¯%@7‹˜àÛµßh³w͹÷n£kÙ`Víq·±Íòï³~›™ß~ø„�4��{Œßþå÷ë¾ó��Ë�;òßï8p2mP+ dÖaX8&,=Òn›}ü!�/øK&\rŠÿt´H™Ó)/�øYÜ”†6@å¯=}ðŠðEU�§lKÃü\\kÓb[×â1Gø�®­M­)™J¨ xXÚEïTä¾ /¸\"-‘ë…<4ßxDˆ¥ÅíÐpÄ(¼3ÞÊŸ·ß´�'È+Û\$\r†¶<rí×n`H\\t\"þ¶70=ä·Y×Wéhsð­\rÏw¼~°!ù0@6l‹\\† •§/þBò7’¼‰–ß Ï>Fÿ‘܉\\¶¼RÙ¾-Çn‡€þܧ\n¸?F~†œaÞ×+xÉÁýëñ¨\rœl,fúCß+­Žîw•i¢GøÛËî.X!¼_à71ymÌ~ñ „œDå¦È7åÊé ÷š¼ÆåîûÅG;gówƒàb/89¯ËxÑ@!R–9¸eÍ�Jq˜Y¼hß'3¹ÏÍĬ*÷ñXw‹Ë®^ —ÛË ¾7ŸÎî5óÀûåÖ`ö:î#�È+Û­0˜ž·œS¯ˆ@0óo7:&~r (Z·‘G1zÐþˆ€·¢pÝÎñd�NŒï“£›`ç¿/Fz@8Ñt0ŠZÌ_ ‰ªÎ0³™{Úè¿Lén•‡×‡oEËÃ�Ñâ=rû¡‚Gj]õ H•¥›² Ò·…»ÞAf+ªÈèVº•º­mžœ7ýåßB‹ÛÓî*q‚þ}cãwس=Û„g¥»wE¢-H·°€»·¦½&Rh4—ªMêž Z�Õ_L½©]W��V'ÁÕ¦§Íñ\"uŒ @-ÜaMÃsº@9êL:ÈÕ’]ù#‚ÝaëoybÝ\n\0[Øêrðp*}Qí‚bwßÛÓ¦?†ºâÿ;Vc�¾�Ê°›» «.Ûsç´¢XíÖ°ûy·R=§&d”ã·rûO«žçõ2Åj!Ïux¥ÜÎÔ§R{NÖ&øµÑ»®5ö„}£ßvyÛ°Ž1o8Z#žþ{�ÛNärû½ÝÑï‡Q:BÕHzW{òïW{:ìržÞ÷ó¶}D\$§j7)àP€÷ëÁÐÝCvV�¬X—¾ýdí¨D7óá�®€·¼,Ôh»÷á_ø]·^í—qσܟxO»]­ï�Šö¬?p{Æ\"ˆðOŠ8Qáµ?xw}ùJâ?�9kâÞüx½5buÛ&÷ø�Ï o›ÅÆ^ñ†õ¼Ÿ¬>õw“g]çíh¼#ä?+÷‹ mï(³¼¹àÿ/ngŒ é�5â5<ù;‡ñüòÈ…¼Ë³½œxÍ%‡³‘;ì(³ÞVóŸ–;Çço-ìó˽ëòÿ.eänkpËÂÀ_ËFäXõ9ÓWj�Q¥ÓàCB اåv3R=°ì†¦;aÙ][yËÈ»4Þ/¢|óÃ##v� @_Ç­}UçM>ùßÌþ1§�»\rC£Múq�ƒCÞÄÆåámc¿,kzy4Óí¡K˜�¦Þ„ùçÑ>˜a‚­!i1çp\nA` çŽJঠx V,‰\n}éKÚÀ+’”¦s¸JŸvÞî(S=Ö�#�:M>õ…°U¤ã zûŸÚžê À·� y4�&=@MöàXÃ0P'{b6 E È #Ÿ”ú@M‡¿ã6uOuüKÛ_\röñ)Eî°)�G9ì�úZ>‘o#äGÓäl@¬ð%ŸLê‚Þ´™Õîsñ0 Z/ºýôð+¥¤ú@_“ÀÀ…Þô=Ãïãý||0§ÖÑOÑ~ íy|OÛ~Þöï·ÃEî/rH�jŸ\\>Ï×€t-ï™ýŒ,!`ù7ÕÀVoˆG9¿k“™ô¾Cö‘ý“îžà÷è\nÀ }Ð!üQ-GÛ>ýõÿv;Þžð¼½éïoÈ|@ 2 ?(·¾ðÏjIÃÞ\0SÍì”>­øXØÈX |úïºþ6 4ÉÈ ?vø÷ã?öï¸~7‚ù/á½o||d\n_¬ûoºäÒ-ãëÆk7>ü÷_Áþð¿’Sáÿý×Å~/ñ�>~¿ö¿ ü‡Ü£÷P ~Cå?+Yÿ@‡òà*|À*ß2ýÑõ>mó��}Ûç¹Ý¡÷½üoÉ|OòŸ–øŸÝ¿R“{þ£î€ ýpþØ#P“öo¿¶ +Ü \"¨’z3à\$¾ˆú0 ï¤>”+é�\n¾žü� 塚ú£ôïß¾²ücù €’ø#íà«>ŽúKáP >›\0Ûê/©¤ 뀨“;Ýlâ£x>ƒô`\"³–ûÜHÔ3¦ûÓ:À«\0’š9ì³›\0ûÜi Àn?@\nïu¿>cîÈ瀪jCP'�ÒùBOÔ>2û³Ü #¾&%(0£ó�Òùˆ3ÿ€°ù«ú€,@|ãç ,‰KÔ\n/È@¦û³ðéÀ|šS )€©¤,ã@xó9Læ\$¤û´Ã쀫 3@ëKîà*¿@ý¤pFA `&@{ü“� 0J†¨÷C÷b0?Ãßé�Ì?pþ\0 ƒ #ì`¾¢“3ao#¢z:`>Aa úor©Ü¨Í¿HþXƒý¤ŽœO€ªÍÈýáo@Õ[ô Û3¤øÈ[ÃøÀý*O Û#~\\(ÍÁ´�P\np+Áº?+öð4\0u@ÿPUÚ?xþ ÂAÊ\n´`\$Áj\n´ð\\ÁÞÿ,¯šAîý¬oÄ�ªûè¡oAù¢BÈÍ�´�°ý¤´€„?(€'�·\0ÐtöÑpVƒÿ°\n´=ÊÑT#Ï>òΫCðŽ‚­Ëñ \"?xûÐÀ;¤ 0z#¤>ü\$P|\0¥ô%ŒÁƒó7°Bbþ\0ïáBkÿ£êBbÿ˜\ní\0°þR6 >=çX \0>#¢Î“ELÛ¾\"ŒØúƒ÷€˜>ú60 ´U\nÊN/мŒÐ\n°14>P 𤀗”I\0‚ÎÚãü¿<>ëါA¬÷KD`'ÂÖû€ÿ0ºÂï4\r°½BØX x\0ø�›ã–€W œ¯¨€¦Ñ36PÃ>d?Ì\"còÂ+l1ˆÔÁÇ ¨ü� >hþH �b®“<£þBé ú3�BC:÷#DÌæ=óä3ð.à ý«DÏ›¾r?2Bé!Ãh¤+ìß3€“â°G> � ý\0)C\rð*Ð\r¿e PðáÀ ôÂ4‘\$9P3‚¬?s7 ÝAb“8üÐåæŽD3°�C³�hã¤IR6‰4âÎô:p€B# „PVC)\$<0õBoü=ø¾ºùãçÐúC×L\"�÷A];Ü@'BÅ ”;@�¦>ì8PýB]\n„@¹CE, *ASÝ�3� ¼A¯Ã\0™ +1\n?Kç¨Í¾3Ì\"°“B©\"N1 DI\r<0Ãô@ýX/rDQTC/ÚÄgTB�ž?…È\né9\0œ�Œ90úÌ÷Ãè#ó\$â”7öDY4%1%Db?+óI\rBºÿ\$,±\0øüÒJQ+€¡DJþ†¨Ñ ûèÍÄžù«Ý/¶€ø¸ y?�3D\0&ú�0j�ä´SºD�y¨�³ï/â¿ þØðÄ�HlèÀ‡ô!q+#Žh ¯…ÁäÀ%Ào{öØ´T>ëôF¿~|‘HBÊûP0 ¤> \ncê�nD1ì °ÒÀT�L8qSCÂͺ5ëAyø0°\"€W 23Dµ>Úô0�D¶ûhjˆØØ�\$LQ ÃŽØü±_EO’5òC;\n  Á© ”X‘3¾@[ÏÎ@÷(ìéA tpò€¾�‹ë‰%Å`Dïš³iTP* X\n€+€Š÷(�}Ed]ÑxB“”Ñn>€ÈüÀ'�Ép\0±8\n�ÅÅð\n²Mñ‚A¼ZoäC¸Žœð\\>#<@\$¾sübÃòƬbàÂÆ6>»ã0£´M\n8¥3èyAtøˆ‰4€øÂM/µ¤Bÿ¬DªC�\0Cíd´Â  ñ.«Ô#o¦#?\$h F„ÍšN/ŽBêú¨ú1¡Æ–÷DhpDÆ”� qžÄͤhñ(\0©ªJ¤Ç(0±IAzú³Üà!¿üPµ¾+„ecè>†?(ÿ�]Û“ܬæ\$¡\rD!hñ�¯*<°¦€…ãê£öÂ×\$*OìC©l.�V\$>ªA\r#Ÿìˆä@®Ðü<@\">Îhú©)@ü�DRQÌÄê’dr 'A|ÑSöð€žÎ\\gðáF]”QÖ3”>Ø ,€¾?A-ØGeHúÑÓ£~’“â£üGn�Š6�†GbûüÑÞ¶�ü3±½½° PŽ\$/‹â‘ãÆæ�³Ý1DÄñ-CíÆ #‘퀜Ž\0û°¢Â0>ÜY°M°?tM­=Êq±èÀ|ú«EŠÆÑPÃè4D23‘ô=ç °\n€B• P\n€B•toPFô,H�¥Bá\nT]#é?E¨ûìÛ¾{‘4€Ž@ ñ¿Ÿäv€)\0¿Àû±âÆY ìƒñàµ!\$„OŠÄˆ÷Ü\r�Õ@Ù d\r�m@ÙÄ+i\rFë¼5I\0c`\n€Hxœ‡‘ÿE% RP‡@〰94F�„H%€ŒÑRS1DÈ øšNMÀÇ ôi`%Âë ¢A\0+È2KLƒo‹D ó9`&\0¿ò4ÑÙBƒð ïÄÄ‘#kp¦Å ˆÍÇ;´x2Çs!KâÒ@1#à ¨í£L“\$`ÐEE“Œ°>—{êÅãLe¯yC±ÈûÑx@!Kè‘–¾;Ä ) úe°Þ>i!¤e±à�©!¤†ã<s�ã\0D0oÄ?Ü0�ì@…%²>\rB× ZN`\"@-kDÑüÃ;DÑ14D?\n5-\$8ü°Ö’ÒŽDÑd4>KL‚íC& pvFã!L�RÇw`ÿ©\rHq “DìÜ@º?3ô°PÁ4ý\$•i1€†?3åRx#6Ãñ2MIJÿB0É>Uè\nQÈ(ÿéÏ|\0¿ üy²yHÚ>„j¨ñ¾!%ô|0á¾U þ/ÐJô ²2ÄŒ“’J³¢÷À�À/ÂÉ\nL6ê£bûkâ­?³t£ow>¥Óæ‘<D øŒ!ÏÍ?9¤T1:CTÎãâ°EÅ�쉰OÄ7|à)GΣ撠€³\"lMxJ“ÜaˆõDÏ\0¼eñ—\0²>ăÒ@¤I\nkèƒîÁi¢òD䀸\$3CŠd†Êø\"@<‚\$²\n?I€ù+H8 ¬–N\$¢Å³€øñt ºÊå+º”MwÊÖJÈ.‚˜\$\rž¼\$i*…á†:¨6£8 ´ ``Ž…¢˜f\0>'ØÝŠ`×–* 0¯æˈ’²<Ãs²Ï^Ëo�ª®à:Ó»þéµ\0€ËV̬€7\0ò×ø\rà1KbÈH’µ¤=-´·2º\0Ò ¬¶’ÛK| ¬·)*€Ï.“Àä4 �êY8m@º’¼¶›ÊääéÜà¶\$:È àäJæ¬H*M¯Ë¾E¨E ØK²l¼›€Ù.ä»ÒéºFäƒâ=¨ÞŒg )Fvü oáÆÂ*\rà\"\0„ø°0#�Æø°þ 4Ç\0˜\nÐ]J…LoΤ?DÏë�ËÂBÈÔ¥\0p0 &¾1 üÀ )�Æ£7±\$G/”oïäA¦üdÄ)(BAcýQŠÀý1£Å…1,;q\rÀ±dÅ3LXó6ãóÌa1ÅpâÌZ÷¢NSøDÇó@—2Ýs\"?†ü,!X3j 9ƒà7…¢ri•í墀�)‚è±D˪Q8,|­³.è€èp3/…I3Pp!ªÎJ Ï�Êö²ûÓ’®‚%ÇS0ʘ£ó< u09\rºÍ\0Ú˜JÀ;‰TYˆÒæ‘k.h5f˜:¨�é„]4Šà/“TŒÒ.™€ø0²”² ‰<;P“À×,‚¾ÂCÆt\0¾\rxÎ\r±ó.I bOo,Á¡g<\$ Å!;Í ‰\\³\0ë,ƒ5ð>³? àŲí)Á.ò[æW¶—+øò\0>–Þ¤ÙA{M�5œÙà …<N\nàSNÍ°\rb,À4ŒRY;æW™œY:-¢ÍÈ*]KRüÖÀ>\0ë5 5sNMÜPá%泂.s³7R_`…òŽ˜è!²·Nt‡ÁEZu2G éC7ìÐ ‚r[2ÐOSF øà8Y¢O:ð¹ 3È|ð\$€¶v*Ü»SX“ä]+\"U,,Ãy€ÖNPdåᎌÎ#øSò·Y4!}‚ä™Ó,Ñž2ÎÍ€I =Lü³J1Ë;,ÓÄ�é :ñ!‡tË6/sŒò¿Î˜\$³rØ8BÊPSª†~±; 4N´3£ 5ο- 3F.ÊœÒ)¥8jÔœí\$�ƒVH@°\0øœÕsM æø“ǵί+˜ãàØÍ_5À>³¹\"VPgN\\‰X.ƒθ<®eÇ€Ñ:ÉA ;‚Ø݈`³¦Ë0=8G¤ÄΔàÊkŠ?.�f2Ì„I£*Ë: ô®Œz\$³AòONÔœ³Rθ‰<Ûˆ’Ð ù=¨IÎaN�=ÂXÚ\nÁ;¨B_KE=LôaOŒ«:¸•@•Mu=•S·¼ý=ä´3°€ù; ïs°†;\"òì\0ù>Äì2Ó{4¢!ªuЋùÍæñ Taª9Èu\$ ¤ƒ\n �Žu:FY4þ†?œáĶ+{é…\0ÖËšØÈÈOì„ÿ0çYdÓù9Ù+˜ €͈a ƒÍ‹@‰ÛSѦY9Zrƒ‹?ÐOSæÐ\0Üìÿ`ØÍ„!X0©\$v@’€9NÄblÒ‚\n>J£œƒ1Ka/ƒ»SA¶Öè…3§ˆJ8<Ó\".*Ø•Aº6ܵ.»Œ~·‘dîé€Ã.€@Ž¨‚ <ûΠ–Pž¼…\nrÔ7©/”³,6+;œØ-±NÄ\r€J̱†;Cz\0•P–œÕ`…Œ2µ ãОLM Ó¾;PSøg™~²\nPCƒv²=€†„ðó(%“ƒ‚<ÝÄÃË0­Á;Œç9£®s7\0ì ýfN]DŒã4H€ñ8È`”\$Q2È`N°C;›yƒ.c4ñ¾M´¤ôTT5 c�&ÈÐè3à>V˜–Ü�O;F‰üµ­Ì¶/- ËaÎré¾rØθ\r`1LÜÁh@ñ\rþXH Â€ÚÚ­çùQžvØJe4JåF˜ ³Î…IFœ¬óh:Ÿ+˜[n°\rM?‚@ɘ•TiŽ\0`c´hÍ`P@“Š²ãF°;2æÑ´%Uª2Q¿G&“äÑÎfìúa²ÑÙ?P¡ O?9ø\0004:ú�% Ì£3 ³ëK¼í\r³¥\n>çTç%Ѓ±,4ÿë¤<å ŽŠ:F!‰dágK0�Ћ�\0Lºs ßÒV:cs£8M;-‚ºrëQê:û öRl6Ä»R³Îd¯½'t•¥ÑIXKÂË0¢ìÓÊ\0åJ/6¥Ðê}”¦…š—DÐá˜A̽ӬK\$ ¬½ÍÙ¨é\\¾ ¤‚W-Ë¥t±\0Û.(6³Kzäí-Ræ7:Úý-´dÒß/].+ ÒwK¬»Tº&•-È @2RæÍ/¾ËÕL/ræRÀ�ꉥQ‰-µ,´ÅQŠ\$õ-4ÇK…Ke2R¹ÒïL­/ô³SIè;4ÍSL3ÒÛRûLÍ2´ÁK·M\r\$.–\0ó/…\"S�ËÌ•Ô¼`ŽK±M„½òRƒM¨#”Á˺í(4݈ +®òù“À_,SP‰Lû \r…ÌÒY®Ä½£F0~ˆÝMZÅÈMÔ¤D¶ÎÌ€È!1�\0š2¨{’à4MÔw|Ì4ìO,ä8Z\"Ä-C¢C¯@±ËO+³F1¾ ºsu¸\r>íÓä P\"SÒP¼,=\0004íLL5!´ö4¤:ý=@–QŸOÍ@t‚€Í3èfôö±Èe}@C°–-J1Ò-…B´Q„¿PØI®ŒSIåB®+ÍVX1Oè”Ô=P %×7[DêòË ÌdTVE�I€ƒB±ÅFõzhAtQñ/å?SV=8ƒÍžTní=<Op°\"ï?'~ÚÕIbÿÓÔ8`µ…šQS¡‚8�PåH‚2fÊ6‡9ÔWOøô;ÔB+´Ô0Ñ\0  åþ€ÃP|ø%€Ý8åBµ';Ot5ÔÝSÓo¥ÑT)Sû4êT P�LõBÔ�OuPtóT�R0ÅäÕ:Á-Q 3½)E\rEÀ�TaQX’�?Tú6௠^€8ÕN<úSøK௠\níSˆ˜]BÕ'G%B­ÈýT…En€Øϱñ®²8ˆr½B£# ^ðà>´î„�QX6ƒÓMõ¥ õ7;BØNãŸ<<x\rHtó5S}Z´ø„Ž.Ñ15R–çULkT‚_Ýc.ü\r\\4øП3Ã,@1œ485�¤ˆaÀ\r’îŒyA@0 Öi‘*«yWà µ †©WÐ u€<X)‘/8X@ ¢åVQ¨Çµ}<=TµaT‘/]`týTœ0j�V»Ø«u†UüWÑÄ@•¦±*zí»À\rÍ6 4“°EôzÖ\$Ü\"14û…þ`H5Àú‰,¼èU‰ ɘJì ,íbSñÔZðháPÖ\$¾„×S—V%WX`€8JÌ\nÕ^€ÜÔ’3…iô?·\05f4<SõSMC\rµ\rˆj•ƒÖ\0é\ra†áXa1Õ† Úßô㵑%?P\"U'V~\rQ”STí[°Zõ¼UTíouBÕV|ôŽ�¼3sôû7Y½?µÅÑëY¥qA VnJ-_5�U\n°*g\r6¼\$°¼ ÂÖÌdMcÕ€V+9SkÂ?Ö:]•Ò‡X“b†•4ua�›Îi]}tÕÑ2•Dkµ†¿]Y‘5_‚C]Âĵ†\0æX*U†\n?U}s§øÔ0ñ´Úf=Rð£ç\r,;ÆÕ G‰1-m‚Tä…x\0‡«YPÿÕêÎÎ\rÛc²ºéidí<2}x`©Vº(ý8NÔVå9ut&DÍR%m-ÎÔû.ƒÐµ†SXèÑîrU,Õýy*†…_Ý€U´¼¹+ÝNíüÖÙ4Õ�aׄò½UýƒZL0T5s€óX`߆V exs ØVÜC\"=Wb/ýG‹ W„É›n@௠ô©>@6V8á*ó>\0å`�w€.Õ ô8SÖƒŒ(ý‡ ½ 3Ð 6Xp5]`ýŒïaÍHÓ¼‰Ì\nôï.<Wb6V^<ã5Ï€º(I6ÓSجdKy\ntÖ\0[ýa€‚Ÿ1X\\sŠØ´m•d5€XÃb©ôµ‡‚ä@ÌÓŽÍa]ˆYÁ„c(QÒµ3ÄWŒÀCË‚V뽆`ŽÊÆ�íÖ ù@¨•U[VØX5‰ûYK°…6Iœï4qdõ9ƒ5Xeu†8¯`4ÜJ¾Ù>dKp“¯OFÖõ“VS€º!qtE“׈…�e(£a�\r“sWÛe¥ŒnŒ›^ +VYW‹edVQNe%V6ØÀëÕƒuƒ7òY=\r“HƒXcz&W…;cê´+ =BÀ¹,oÔ§+‹\rÌÑ7+éAÅ\0¾7Åh,šQð\riÃ3ON�AÍ@ÝÙß<¹�SVMÌÖÝžÕª�ÜÁÃUDNW5Ð62Ùþ62'ã\\M\r5WÒcÕ€S]0þ%Q�uTÜʱE˜×RtÎV‹Õ\nE¡u‰ÔãcìÕæ5–ÿ8«J£*äÙJã Z:ؽN•ÑÚ;SH7BÏ’+öÓw~Ý…�52O§c˜‡5®Ø\0cÓÍvXXôó}¤AZ~óãÏÔzU\\A/.eÏH³Í…уƒU­akŸ©fy0À6BPÖ‰Öó`‹ª5± 4ÅíTYfCqaü:£I%[Ì£P‰g”æ–±T +uwó¦N¢² ÄŽ\"O�>‹¬6Í\n¡ñ¶»Ë Ë�V®#R¥ƒVÂÚák�M–ÁÕÑAv\0ŒÖò^\rgº£\\mrTz“�-\rc3NÖ%SbÿÍ#ReMfW™MX\ré‚SõYá'M;m=p\nÌý4Š2Õ[d -¶„¬×¢ð5”º£l<¬vÓ’<…¶V&ØaOMQåƒQ@è-C †Ú‘m�dà‡Ô÷TÓm®“VH\rc9ƒ‚pÃd¶êÖPÜ\\ÿvïË@-º!+»×o`S¬Y OôÊÅÐÙƒo+p˜×¼\nÐ6ôT\rkrôXB\"ý½¬ÛÑP¿ô]ÛÐã½UVý™_o-VÍ—ÛÐä£�6÷Û¬ÝÅ]õ¾Ün±>TÛËB5”„ļNíÂà‹ƒég8ÅBU[ËpUÄ`<‚Š tÓaœ\0é:͇իâ¸\"(\\[3íÅö¹õb\$ü—Mƒe—Ñu6\r¢´ž\\}5у¶LÃ[9Ò ÜˆG•”W|²\r©V‰\\hôƒ…Q8>Aº”üGEÊ£Z»r�=ötVïn•UUm„õnÔ³1\\%n½\r•¼ÜÕZÝ2Ã[R +<TSUUQ«[Jž€¦ô ¸\"€hRä·÷7U‰´/[PHY²ØZ0”¹5ª\\!m,Ö>ŽÕrÅ}—#1¹t�àõ«‚”5SÖ@:ý{6«MwU=®AR—[…p7µ[Õ±\$ÄÜÍRoVpÖ»[ÐD š]5[Íp®][R[—NÚ’ôoõS–“S©8\"?ÔY[Б­ÆPD…,÷Y×\0êÃU']‚óõ •8¥q¶À]‹3¤Ï7m ¹^z�N¨ƒZ\nœëÕÀY¯tÕ×Õ8²•CÕî1Võ`ýM÷gJÍEÝE”:QóuÅÞa[ŸvÝÒ—|§wÕyîêñM7|‚XØr·^Ex-ßà–]ùr•W*55xiy \"3œ³‰ÝéW[ `šK\$)½{ ©_]ÝËï5Lóy%[–Òœ¯yC¬÷YÞIw…ÉòÉ!Ã@|×®Ù¢VÇ+s\"V0ÊÇAR;áy½ÇU=˜Ow\$Ø—›=EÐàKØäˆhõM‰_½äµ¼Ý’€ù’—fÙÆ a�UíÓÚâ=#€Ô€Ê¨:·…MUAÍÑõ�W OýQGÜÇsœ¬wµ\\×<AS´7~²\ríÕ ^Óf`J÷5ÒI{­o\0;Óþ‘´\"Í_tx‘·³Vò¸­^�±\\ØÊ\rðá^£gõñÕ‹ËayH7DÄÞ!|k.v�lãÄÙÁûÕÑhðšµ.[€² ת]-eôµX_NpÕ”—>=fHõUƒ‹Oôï5ÝnH·ÔsÜM-×3¥’æ1 Ýp-¾–þW CLÚö\\öÓ1Sš¶y{Ë&wç[¶\"í‰v°Ü%~•\rwÆVÁl`¬+ Õ¯Uµúß°j‘aOÕÇ\r}—*]_VìÐ5ÕÁ5å%iƒY8UþÇñD\r¯VÁZõ~e¿“Ù‹(ñb³ä·;u½Qñ¶.é²Å\0ë_|n\0­‹WÊSõð¸ÚŸSÏÍÏ‚°üöc۶טÅôuÞز\rë–°¶²�.²7Q@’•’_�-Ëd¶TPŧu \\ŸXé¶U·P–Ù~ÄÌÙU�­`ENi�Æ ©B¼†D–¼\n99!ê¯BNÝ9ƒ^½8õcHÂC?HøÀƒ ‚¨”ËÑò");}else{header("Content-Type: image/gif");switch($_GET["file"]){case"plus.gif":echo"GIF89a\0\0�\0001îîî\0\0€™™™\0\0\0!ù\0\0\0,\0\0\0\0\0\0!„�©ËíMñÌ*)¾oú¯) q•¡eˆµî#ÄòLË\0;";break;case"cross.gif":echo"GIF89a\0\0�\0001îîî\0\0€™™™\0\0\0!ù\0\0\0,\0\0\0\0\0\0#„�©Ëí#\naÖFo~yÃ.�_wa”á1ç±Jî GÂL×6]\0\0;";break;case"up.gif":echo"GIF89a\0\0�\0001îîî\0\0€™™™\0\0\0!ù\0\0\0,\0\0\0\0\0\0 „�©ËíMQN\nï}ôža8ŠyšaŶ®\0Çò\0;";break;case"down.gif":echo"GIF89a\0\0�\0001îîî\0\0€™™™\0\0\0!ù\0\0\0,\0\0\0\0\0\0 „�©ËíMñÌ*)¾[Wþ\\¢ÇL&Ùœƶ•\0Çò\0;";break;case"arrow.gif":echo"GIF89a\0\n\0€\0\0€€€ÿÿÿ!ù\0\0\0,\0\0\0\0\0\n\0\0‚i–±‹ž”ªÓ²Þ»\0\0;";break;}}exit;}
  14. require_once '../inc/global.inc.php';
  15. if (!isset($_configuration['db_manager_enabled']) || !$_configuration['db_manager_enabled']) {
  16. die('Setting db_manager_enabled must be set to true in configuration.php to access this DB manager');
  17. }
  18. if (!api_is_global_platform_admin()) {
  19. die('Please connect as a global administrator to access this DB manager');
  20. }
  21. function
  22. connection(){global$e;return$e;}function
  23. adminer(){global$b;return$b;}function
  24. idf_unescape($Jc){$fd=substr($Jc,-1);return
  25. str_replace($fd.$fd,$fd,substr($Jc,1,-1));}function
  26. escape_string($X){return
  27. substr(q($X),1,-1);}function
  28. remove_slashes($Me,$nc=false){if(get_magic_quotes_gpc()){while(list($y,$X)=each($Me)){foreach($X
  29. as$Zc=>$W){unset($Me[$y][$Zc]);if(is_array($W)){$Me[$y][stripslashes($Zc)]=$W;$Me[]=&$Me[$y][stripslashes($Zc)];}else$Me[$y][stripslashes($Zc)]=($nc?$W:stripslashes($W));}}}}function
  30. bracket_escape($Jc,$_a=false){static$lg=array(':'=>':1',']'=>':2','['=>':3');return
  31. strtr($Jc,($_a?array_flip($lg):$lg));}function
  32. h($Ff){return
  33. htmlspecialchars(str_replace("\0","",$Ff),ENT_QUOTES);}function
  34. nbsp($Ff){return(trim($Ff)!=""?h($Ff):"&nbsp;");}function
  35. nl_br($Ff){return
  36. str_replace("\n","<br>",$Ff);}function
  37. checkbox($E,$Y,$Ma,$dd="",$Yd="",$Qa=""){$K="<input type='checkbox' name='$E' value='".h($Y)."'".($Ma?" checked":"").($Yd?' onclick="'.h($Yd).'"':'').">";return($dd!=""||$Qa?"<label".($Qa?" class='$Qa'":"").">$K".h($dd)."</label>":$K);}function
  38. optionlist($ce,$qf=null,$Dg=false){$K="";foreach($ce
  39. as$Zc=>$W){$de=array($Zc=>$W);if(is_array($W)){$K.='<optgroup label="'.h($Zc).'">';$de=$W;}foreach($de
  40. as$y=>$X)$K.='<option'.($Dg||is_string($y)?' value="'.h($y).'"':'').(($Dg||is_string($y)?(string)$y:$X)===$qf?' selected':'').'>'.h($X);if(is_array($W))$K.='</optgroup>';}return$K;}function
  41. html_select($E,$ce,$Y="",$Xd=true){if($Xd)return"<select name='".h($E)."'".(is_string($Xd)?' onchange="'.h($Xd).'"':"").">".optionlist($ce,$Y)."</select>";$K="";foreach($ce
  42. as$y=>$X)$K.="<label><input type='radio' name='".h($E)."' value='".h($y)."'".($y==$Y?" checked":"").">".h($X)."</label>";return$K;}function
  43. select_input($wa,$ce,$Y="",$_e=""){return($ce?"<select$wa><option value=''>$_e".optionlist($ce,$Y,true)."</select>":"<input$wa size='10' value='".h($Y)."' placeholder='$_e'>");}function
  44. confirm(){return" onclick=\"return confirm('".'Are you sure?'."');\"";}function
  45. print_fieldset($t,$kd,$Lg=false,$Yd=""){echo"<fieldset><legend><a href='#fieldset-$t' onclick=\"".h($Yd)."return !toggle('fieldset-$t');\">$kd</a></legend><div id='fieldset-$t'".($Lg?"":" class='hidden'").">\n";}function
  46. bold($Ga,$Qa=""){return($Ga?" class='active $Qa'":($Qa?" class='$Qa'":""));}function
  47. odd($K=' class="odd"'){static$s=0;if(!$K)$s=-1;return($s++%2?$K:'');}function
  48. js_escape($Ff){return
  49. addcslashes($Ff,"\r\n'\\/");}function
  50. json_row($y,$X=null){static$oc=true;if($oc)echo"{";if($y!=""){echo($oc?"":",")."\n\t\"".addcslashes($y,"\r\n\"\\/").'": '.($X!==null?'"'.addcslashes($X,"\r\n\"\\/").'"':'undefined');$oc=false;}else{echo"\n}\n";$oc=true;}}function
  51. ini_bool($Nc){$X=ini_get($Nc);return(preg_match('~^(on|true|yes)$~i',$X)||(int)$X);}function
  52. sid(){static$K;if($K===null)$K=(SID&&!($_COOKIE&&ini_bool("session.use_cookies")));return$K;}function
  53. set_password($Ig,$O,$V,$G){$_SESSION["pwds"][$Ig][$O][$V]=($_COOKIE["adminer_key"]&&is_string($G)?array(encrypt_string($G,$_COOKIE["adminer_key"])):$G);}function
  54. get_password(){$K=get_session("pwds");if(is_array($K))$K=($_COOKIE["adminer_key"]?decrypt_string($K[0],$_COOKIE["adminer_key"]):false);return$K;}function
  55. q($Ff){global$i;return$i->quote($Ff);}function
  56. get_vals($I,$c=0){global$e;$K=array();$J=$e->query($I);if(is_object($J)){while($L=$J->fetch_row())$K[]=$L[$c];}return$K;}function
  57. get_key_vals($I,$f=null,$bg=0){global$e;if(!is_object($f))$f=$e;$K=array();$f->timeout=$bg;$J=$f->query($I);$f->timeout=0;if(is_object($J)){while($L=$J->fetch_row())$K[$L[0]]=$L[1];}return$K;}function
  58. get_rows($I,$f=null,$j="<p class='error'>"){global$e;$db=(is_object($f)?$f:$e);$K=array();$J=$db->query($I);if(is_object($J)){while($L=$J->fetch_assoc())$K[]=$L;}elseif(!$J&&!is_object($f)&&$j&&defined("PAGE_HEADER"))echo$j.error()."\n";return$K;}function
  59. unique_array($L,$v){foreach($v
  60. as$u){if(preg_match("~PRIMARY|UNIQUE~",$u["type"])){$K=array();foreach($u["columns"]as$y){if(!isset($L[$y]))continue
  61. 2;$K[$y]=$L[$y];}return$K;}}}function
  62. where($Z,$l=array()){global$x;$K=array();$wc='(^[\w\(]+('.str_replace("_",".*",preg_quote(idf_escape("_"))).')?\)+$)';foreach((array)$Z["where"]as$y=>$X){$y=bracket_escape($y,1);$c=(preg_match($wc,$y)?$y:idf_escape($y));$K[]=$c.(($x=="sql"&&preg_match('~^[0-9]*\\.[0-9]*$~',$X))||$x=="mssql"?" LIKE ".q(addcslashes($X,"%_\\")):" = ".unconvert_field((isset($l[$y])?$l[$y]:null),q($X)));if($x=="sql"&&preg_match('~char|text~',(isset($l[$y])?$l[$y]["type"]:null))&&preg_match("~[^ -@]~",$X))$K[]="$c = ".q($X)." COLLATE utf8_bin";}foreach((array)(isset($Z["null"])?$Z["null"]:null)as$y)$K[]=(preg_match($wc,$y)?$y:idf_escape($y))." IS NULL";return
  63. implode(" AND ",$K);}function
  64. where_check($X,$l=array()){parse_str($X,$La);remove_slashes(array(&$La));return
  65. where($La,$l);}function
  66. where_link($s,$c,$Y,$Zd="="){return"&where%5B$s%5D%5Bcol%5D=".urlencode($c)."&where%5B$s%5D%5Bop%5D=".urlencode(($Y!==null?$Zd:"IS NULL"))."&where%5B$s%5D%5Bval%5D=".urlencode($Y);}function
  67. convert_fields($d,$l,$N=array()){$K="";foreach($d
  68. as$y=>$X){if($N&&!in_array(idf_escape($y),$N))continue;$ua=convert_field($l[$y]);if($ua)$K.=", $ua AS ".idf_escape($y);}return$K;}function
  69. cookie($E,$Y,$nd=2592000){global$ba;$qe=array($E,(preg_match("~\n~",$Y)?"":$Y),($nd?time()+$nd:0),preg_replace('~\\?.*~','',$_SERVER["REQUEST_URI"]),"",$ba);if(version_compare(PHP_VERSION,'5.2.0')>=0)$qe[]=true;return
  70. call_user_func_array('setcookie',$qe);}function
  71. restart_session(){if(!ini_bool("session.use_cookies"))session_start();}function
  72. stop_session(){if(!ini_bool("session.use_cookies"))session_write_close();}function&get_session($y){ if(isset($_GET["username"])) return $_SESSION[$y][DRIVER][SERVER][$_GET["username"]];}function
  73. set_session($y,$X){$_SESSION[$y][DRIVER][SERVER][$_GET["username"]]=$X;}function
  74. auth_url($Ig,$O,$V,$h=null){global$Db;preg_match('~([^?]*)\\??(.*)~',remove_from_uri(implode("|",array_keys($Db))."|username|".($h!==null?"db|":"").session_name()),$B);return"$B[1]?".(sid()?SID."&":"").($Ig!="server"||$O!=""?urlencode($Ig)."=".urlencode($O)."&":"")."username=".urlencode($V).($h!=""?"&db=".urlencode($h):"").($B[2]?"&$B[2]":"");}function
  75. is_ajax(){return((isset($_SERVER["HTTP_X_REQUESTED_WITH"])?$_SERVER["HTTP_X_REQUESTED_WITH"]:null)=="XMLHttpRequest");}function
  76. redirect($A,$C=null){if($C!==null){restart_session();$_SESSION["messages"][preg_replace('~^[^?]*~','',($A!==null?$A:$_SERVER["REQUEST_URI"]))][]=$C;}if($A!==null){if($A=="")$A=".";header("Location: $A");exit;}}function
  77. query_redirect($I,$A,$C,$Ue=true,$bc=true,$hc=false,$ag=""){global$e,$j,$b;if($bc){$Bf=microtime(true);$hc=!$e->query($I);$ag=format_time($Bf);}$Af="";if($I)$Af=$b->messageQuery($I,$ag);if($hc){$j=error().$Af;return
  78. false;}if($Ue)redirect($A,$C.$Af);return
  79. true;}function
  80. queries($I){global$e;static$Pe=array();static$Bf;if(!$Bf)$Bf=microtime(true);if($I===null)return
  81. array(implode("\n",$Pe),format_time($Bf));$Pe[]=(preg_match('~;$~',$I)?"DELIMITER ;;\n$I;\nDELIMITER ":$I).";";return$e->query($I);}function
  82. apply_queries($I,$S,$Xb='table'){foreach($S
  83. as$Q){if(!queries("$I ".$Xb($Q)))return
  84. false;}return
  85. true;}function
  86. queries_redirect($A,$C,$Ue){list($Pe,$ag)=queries(null);return
  87. query_redirect($Pe,$A,$C,$Ue,false,!$Ue,$ag);}function
  88. format_time($Bf){return
  89. sprintf('%.3f s',max(0,microtime(true)-$Bf));}function
  90. remove_from_uri($pe=""){return
  91. substr(preg_replace("~(?<=[?&])($pe".(SID?"":"|".session_name()).")=[^&]*&~",'',"$_SERVER[REQUEST_URI]&"),0,-1);}function
  92. pagination($F,$nb){return" ".($F==$nb?$F+1:'<a href="'.h(remove_from_uri("page").($F?"&page=$F".($_GET["next"]?"&next=".urlencode($_GET["next"]):""):"")).'">'.($F+1)."</a>");}function
  93. get_file($y,$ub=false){$lc=$_FILES[$y];if(!$lc)return
  94. null;foreach($lc
  95. as$y=>$X)$lc[$y]=(array)$X;$K='';foreach($lc["error"]as$y=>$j){if($j)return$j;$E=$lc["name"][$y];$ig=$lc["tmp_name"][$y];$eb=file_get_contents($ub&&preg_match('~\\.gz$~',$E)?"compress.zlib://$ig":$ig);if($ub){$Bf=substr($eb,0,3);if(function_exists("iconv")&&preg_match("~^\xFE\xFF|^\xFF\xFE~",$Bf,$af))$eb=iconv("utf-16","utf-8",$eb);elseif($Bf=="\xEF\xBB\xBF")$eb=substr($eb,3);$K.=$eb."\n\n";}else$K.=$eb;}return$K;}function
  96. upload_error($j){$xd=($j==UPLOAD_ERR_INI_SIZE?ini_get("upload_max_filesize"):0);return($j?'Unable to upload a file.'.($xd?" ".sprintf('Maximum allowed file size is %sB.',$xd):""):'File does not exist.');}function
  97. repeat_pattern($ye,$ld){return
  98. str_repeat("$ye{0,65535}",$ld/65535)."$ye{0,".($ld%65535)."}";}function
  99. is_utf8($X){return(preg_match('~~u',$X)&&!preg_match('~[\\0-\\x8\\xB\\xC\\xE-\\x1F]~',$X));}function
  100. shorten_utf8($Ff,$ld=80,$Jf=""){if(!preg_match("(^(".repeat_pattern("[\t\r\n -\x{FFFF}]",$ld).")($)?)u",$Ff,$B))preg_match("(^(".repeat_pattern("[\t\r\n -~]",$ld).")($)?)",$Ff,$B);return
  101. h($B[1]).$Jf.(isset($B[2])?"":"<i>...</i>");}function
  102. format_number($X){return
  103. strtr(number_format($X,0,".",','),preg_split('~~u','0123456789',-1,PREG_SPLIT_NO_EMPTY));}function
  104. friendly_url($X){return
  105. preg_replace('~[^a-z0-9_]~i','-',$X);}function
  106. hidden_fields($Me,$Kc=array()){while(list($y,$X)=each($Me)){if(!in_array($y,$Kc)){if(is_array($X)){foreach($X
  107. as$Zc=>$W)$Me[$y."[$Zc]"]=$W;}else
  108. echo'<input type="hidden" name="'.h($y).'" value="'.h($X).'">';}}}function
  109. hidden_fields_get(){echo(sid()?'<input type="hidden" name="'.session_name().'" value="'.h(session_id()).'">':''),(SERVER!==null?'<input type="hidden" name="'.DRIVER.'" value="'.h(SERVER).'">':""),'<input type="hidden" name="username" value="'.h($_GET["username"]).'">';}function
  110. table_status1($Q,$ic=false){$K=table_status($Q,$ic);return($K?$K:array("Name"=>$Q));}function
  111. column_foreign_keys($Q){global$b;$K=array();foreach($b->foreignKeys($Q)as$m){foreach($m["source"]as$X)$K[$X][]=$m;}return$K;}function
  112. enum_input($U,$wa,$k,$Y,$Rb=null){global$b;preg_match_all("~'((?:[^']|'')*)'~",$k["length"],$sd);$K=($Rb!==null?"<label><input type='$U'$wa value='$Rb'".((is_array($Y)?in_array($Rb,$Y):$Y===0)?" checked":"")."><i>".'empty'."</i></label>":"");foreach($sd[1]as$s=>$X){$X=stripcslashes(str_replace("''","'",$X));$Ma=(is_int($Y)?$Y==$s+1:(is_array($Y)?in_array($s+1,$Y):$Y===$X));$K.=" <label><input type='$U'$wa value='".($s+1)."'".($Ma?' checked':'').'>'.h($b->editVal($X,$k)).'</label>';}return$K;}function
  113. input($k,$Y,$p){global$e,$sg,$b,$x;$E=h(bracket_escape($k["field"]));echo"<td class='function'>";if(is_array($Y)&&!$p){$ta=array($Y);if(version_compare(PHP_VERSION,5.4)>=0)$ta[]=JSON_PRETTY_PRINT;$Y=call_user_func_array('json_encode',$ta);$p="json";}$cf=($x=="mssql"&&$k["auto_increment"]);if($cf&&!$_POST["save"])$p=null;$xc=(isset($_GET["select"])||$cf?array("orig"=>'original'):array())+$b->editFunctions($k);$wa=" name='fields[$E]'";if($k["type"]=="enum")echo
  114. nbsp($xc[""])."<td>".$b->editInput($_GET["edit"],$k,$wa,$Y);else{$oc=0;foreach($xc
  115. as$y=>$X){if($y===""||!$X)break;$oc++;}$Xd=($oc?" onchange=\"var f = this.form['function[".h(js_escape(bracket_escape($k["field"])))."]']; if ($oc > f.selectedIndex) f.selectedIndex = $oc;\" onkeyup='keyupChange.call(this);'":"");$wa.=$Xd;$Cc=(in_array($p,$xc)||isset($xc[$p]));echo(count($xc)>1?"<select name='function[$E]' onchange='functionChange(this);'".on_help("getTarget(event).value.replace(/^SQL\$/, '')",1).">".optionlist($xc,$p===null||$Cc?$p:"")."</select>":nbsp(reset($xc))).'<td>';$Pc=$b->editInput($_GET["edit"],$k,$wa,$Y);if($Pc!="")echo$Pc;elseif($k["type"]=="set"){preg_match_all("~'((?:[^']|'')*)'~",$k["length"],$sd);foreach($sd[1]as$s=>$X){$X=stripcslashes(str_replace("''","'",$X));$Ma=(is_int($Y)?($Y>>$s)&1:in_array($X,explode(",",$Y),true));echo" <label><input type='checkbox' name='fields[$E][$s]' value='".(1<<$s)."'".($Ma?' checked':'')."$Xd>".h($b->editVal($X,$k)).'</label>';}}elseif(preg_match('~blob|bytea|raw|file~',$k["type"])&&ini_bool("file_uploads"))echo"<input type='file' name='fields-$E'$Xd>";elseif(($Yf=preg_match('~text|lob~',$k["type"]))||preg_match("~\n~",$Y)){if($Yf&&$x!="sqlite")$wa.=" cols='50' rows='12'";else{$M=min(12,substr_count($Y,"\n")+1);$wa.=" cols='30' rows='$M'".($M==1?" style='height: 1.2em;'":"");}echo"<textarea$wa>".h($Y).'</textarea>';}elseif($p=="json")echo"<textarea$wa cols='50' rows='12' class='jush-js'>".h($Y).'</textarea>';else{$zd=(!preg_match('~int~',$k["type"])&&preg_match('~^(\\d+)(,(\\d+))?$~',$k["length"],$B)?((preg_match("~binary~",$k["type"])?2:1)*$B[1]+($B[3]?1:0)+($B[2]&&!$k["unsigned"]?1:0)):($sg[$k["type"]]?$sg[$k["type"]]+($k["unsigned"]?0:1):0));if($x=='sql'&&$e->server_info>=5.6&&preg_match('~time~',$k["type"]))$zd+=7;echo"<input".((!$Cc||$p==="")&&preg_match('~(?<!o)int~',$k["type"])?" type='number'":"")." value='".h($Y)."'".($zd?" maxlength='$zd'":"").(preg_match('~char|binary~',$k["type"])&&$zd>20?" size='40'":"")."$wa>";}}}function
  116. process_input($k){global$b;$Jc=bracket_escape($k["field"]);$p=$_POST["function"][$Jc];$Y=$_POST["fields"][$Jc];if($k["type"]=="enum"){if($Y==-1)return
  117. false;if($Y=="")return"NULL";return+$Y;}if($k["auto_increment"]&&$Y=="")return
  118. null;if($p=="orig")return($k["on_update"]=="CURRENT_TIMESTAMP"?idf_escape($k["field"]):false);if($p=="NULL")$Y=null;if($k["type"]=="set")return
  119. array_sum((array)$Y);if($p=="json"){$p="";$Y=json_decode($Y,true);if(!is_array($Y))return
  120. false;return$Y;}if(preg_match('~blob|bytea|raw|file~',$k["type"])&&ini_bool("file_uploads")){$lc=get_file("fields-$Jc");if(!is_string($lc))return
  121. false;return
  122. q($lc);}return$b->processInput($k,$Y,$p);}function
  123. fields_from_edit(){global$i;$K=array();foreach((array)$_POST["field_keys"]as$y=>$X){if($X!=""){$X=bracket_escape($X);$_POST["function"][$X]=$_POST["field_funs"][$y];$_POST["fields"][$X]=$_POST["field_vals"][$y];}}foreach((array)$_POST["fields"]as$y=>$X){$E=bracket_escape($y,1);$K[$E]=array("field"=>$E,"privileges"=>array("insert"=>1,"update"=>1),"null"=>1,"auto_increment"=>($y==$i->primary),);}return$K;}function
  124. search_tables(){global$b,$e;$_GET["where"][0]["op"]="LIKE %%";$_GET["where"][0]["val"]=$_POST["query"];$tc=false;foreach(table_status('',true)as$Q=>$R){$E=$b->tableName($R);if(isset($R["Engine"])&&$E!=""&&(!$_POST["tables"]||in_array($Q,$_POST["tables"]))){$J=$e->query("SELECT".limit("1 FROM ".table($Q)," WHERE ".implode(" AND ",$b->selectSearchProcess(fields($Q),array())),1));if(!$J||$J->fetch_row()){if(!$tc){echo"<ul>\n";$tc=true;}echo"<li>".($J?"<a href='".h(ME."select=".urlencode($Q)."&where[0][op]=".urlencode($_GET["where"][0]["op"])."&where[0][val]=".urlencode($_GET["where"][0]["val"]))."'>$E</a>\n":"$E: <span class='error'>".error()."</span>\n");}}}echo($tc?"</ul>":"<p class='message'>".'No tables.')."\n";}function
  125. dump_headers($Ic,$Fd=false){global$b;$K=$b->dumpHeaders($Ic,$Fd);$ne=$_POST["output"];if($ne!="text")header("Content-Disposition: attachment; filename=".$b->dumpFilename($Ic).".$K".($ne!="file"&&!preg_match('~[^0-9a-z]~',$ne)?".$ne":""));session_write_close();ob_flush();flush();return$K;}function
  126. dump_csv($L){foreach($L
  127. as$y=>$X){if(preg_match("~[\"\n,;\t]~",$X)||$X==="")$L[$y]='"'.str_replace('"','""',$X).'"';}echo
  128. implode(($_POST["format"]=="csv"?",":($_POST["format"]=="tsv"?"\t":";")),$L)."\r\n";}function
  129. apply_sql_function($p,$c){return($p?($p=="unixepoch"?"DATETIME($c, '$p')":($p=="count distinct"?"COUNT(DISTINCT ":strtoupper("$p("))."$c)"):$c);}function
  130. get_temp_dir(){$K=ini_get("upload_tmp_dir");if(!$K){if(function_exists('sys_get_temp_dir'))$K=sys_get_temp_dir();else{$mc=@tempnam("","");if(!$mc)return
  131. false;$K=dirname($mc);unlink($mc);}}return$K;}function
  132. password_file($jb){$mc=get_temp_dir()."/adminer.key";$K=@file_get_contents($mc);if($K||!$jb)return$K;$o=@fopen($mc,"w");if($o){$K=rand_string();fwrite($o,$K);fclose($o);}return$K;}function
  133. rand_string(){return
  134. md5(uniqid(mt_rand(),true));}function
  135. select_value($X,$_,$k,$Zf){global$b,$ba;if(is_array($X)){$K="";foreach($X
  136. as$Zc=>$W)$K.="<tr>".($X!=array_values($X)?"<th>".h($Zc):"")."<td>".select_value($W,$_,$k,$Zf);return"<table cellspacing='0'>$K</table>";}if(!$_)$_=$b->selectLink($X,$k);if($_===null){if(is_mail($X))$_="mailto:$X";if($Oe=is_url($X))$_=(($Oe=="http"&&$ba)||preg_match('~WebKit~i',$_SERVER["HTTP_USER_AGENT"])?$X:"$Oe://www.adminer.org/redirect/?url=".urlencode($X));}$K=$b->editVal($X,$k);if($K!==null){if($K==="")$K="&nbsp;";elseif($Zf!=""&&is_shortable($k)&&is_utf8($K))$K=shorten_utf8($K,max(0,+$Zf));else$K=h($K);}return$b->selectVal($K,$_,$k,$X);}function
  137. is_mail($Ob){$va='[-a-z0-9!#$%&\'*+/=?^_`{|}~]';$Cb='[a-z0-9]([-a-z0-9]{0,61}[a-z0-9])';$ye="$va+(\\.$va+)*@($Cb?\\.)+$Cb";return
  138. is_string($Ob)&&preg_match("(^$ye(,\\s*$ye)*\$)i",$Ob);}function
  139. is_url($Ff){$Cb='[a-z0-9]([-a-z0-9]{0,61}[a-z0-9])';return(preg_match("~^(https?)://($Cb?\\.)+$Cb(:\\d+)?(/.*)?(\\?.*)?(#.*)?\$~i",$Ff,$B)?strtolower($B[1]):"");}function
  140. is_shortable($k){return
  141. preg_match('~char|text|lob|geometry|point|linestring|polygon|string~',$k["type"]);}function
  142. count_rows($Q,$Z,$Vc,$r){global$x;$I=" FROM ".table($Q).($Z?" WHERE ".implode(" AND ",$Z):"");return($Vc&&($x=="sql"||count($r)==1)?"SELECT COUNT(DISTINCT ".implode(", ",$r).")$I":"SELECT COUNT(*)".($Vc?" FROM (SELECT 1$I$zc) x":$I));}function
  143. slow_query($I){global$b,$T;$h=$b->database();$bg=$b->queryTimeout();if(support("kill")&&is_object($f=connect())&&($h==""||$f->select_db($h))){$bd=$f->result("SELECT CONNECTION_ID()");echo'<script type="text/javascript">
  144. var timeout = setTimeout(function () {
  145. ajax(\'',js_escape(ME),'script=kill\', function () {
  146. }, \'token=',$T,'&kill=',$bd,'\');
  147. }, ',1000*$bg,');
  148. </script>
  149. ';}else$f=null;ob_flush();flush();$K=@get_key_vals($I,$f,$bg);if($f){echo"<script type='text/javascript'>clearTimeout(timeout);</script>\n";ob_flush();flush();}return
  150. array_keys($K);}function
  151. get_token(){$Se=rand(1,1e6);return($Se^$_SESSION["token"]).":$Se";}function
  152. verify_token(){list($T,$Se)=explode(":",$_POST["token"]);return($Se^$_SESSION["token"])==$T;}function
  153. lzw_decompress($Da){$_b=256;$Ea=8;$Sa=array();$df=0;$ef=0;for($s=0;$s<strlen($Da);$s++){$df=($df<<8)+ord($Da[$s]);$ef+=8;if($ef>=$Ea){$ef-=$Ea;$Sa[]=$df>>$ef;$df&=(1<<$ef)-1;$_b++;if($_b>>$Ea)$Ea++;}}$zb=range("\0","\xFF");$K="";foreach($Sa
  154. as$s=>$Ra){$Nb=$zb[$Ra];if(!isset($Nb))$Nb=$Pg.$Pg[0];$K.=$Nb;if($s)$zb[]=$Pg.$Nb[0];$Pg=$Nb;}return$K;}function
  155. on_help($Ya,$xf=0){return" onmouseover='helpMouseover(this, event, ".h($Ya).", $xf);' onmouseout='helpMouseout(this, event);'";}function
  156. edit_form($a,$l,$L,$_g){global$b,$x,$T,$j;$Of=$b->tableName(table_status1($a,true));page_header(($_g?'Edit':'Insert'),$j,array("select"=>array($a,$Of)),$Of);if($L===false)echo"<p class='error'>".'No rows.'."\n";echo'<div id="message"></div>
  157. <form action="" method="post" enctype="multipart/form-data" id="form">
  158. ';if(!$l)echo"<p class='error'>".'You have no privileges to update this table.'."\n";else{echo"<table cellspacing='0' onkeydown='return editingKeydown(event);'>\n";foreach($l
  159. as$E=>$k){echo"<tr><th>".$b->fieldName($k);$vb=(isset($_GET["set"])?$_GET["set"][bracket_escape($E)]:null);if($vb===null){$vb=$k["default"];if($k["type"]=="bit"&&preg_match("~^b'([01]*)'\$~",$vb,$af))$vb=$af[1];}$Y=($L!==null?(!empty($L[$E])&&$x=="sql"&&preg_match("~enum|set~",$k["type"])?(is_array($L[$E])?array_sum($L[$E]):+$L[$E]):$L[$E]):(!$_g&&$k["auto_increment"]?"":(isset($_GET["select"])?false:$vb)));if(empty($_POST["save"])&&is_string($Y))$Y=$b->editVal($Y,$k);$p=(!empty($_POST["save"])?(string)$_POST["function"][$E]:($_g&&$k["on_update"]=="CURRENT_TIMESTAMP"?"now":($Y===false?null:($Y!==null?'':'NULL'))));if(preg_match("~time~",$k["type"])&&$Y=="CURRENT_TIMESTAMP"){$Y="";$p="now";}input($k,$Y,$p);echo"\n";}if(!support("table"))echo"<tr>"."<th><input name='field_keys[]' onkeyup='keyupChange.call(this);' onchange='fieldChange(this);' value=''>"."<td class='function'>".html_select("field_funs[]",$b->editFunctions(array("null"=>isset($_GET["select"]))))."<td><input name='field_vals[]'>"."\n";echo"</table>\n";}echo"<p>\n";if($l){echo"<input type='submit' value='".'Save'."'>\n";if(!isset($_GET["select"]))echo"<input type='submit' name='insert' value='".($_g?'Save and continue edit'."' onclick='return !ajaxForm(this.form, \"".'Saving'.'...", this)':'Save and insert next')."' title='Ctrl+Shift+Enter'>\n";}echo($_g?"<input type='submit' name='delete' value='".'Delete'."'".confirm().">\n":($_POST||!$l?"":"<script type='text/javascript'>focus(document.getElementById('form').getElementsByTagName('td')[1].firstChild);</script>\n"));if(isset($_GET["select"]))hidden_fields(array("check"=>(array)$_POST["check"],"clone"=>$_POST["clone"],"all"=>$_POST["all"]));echo'<input type="hidden" name="referer" value="',h(isset($_POST["referer"])?$_POST["referer"]:$_SERVER["HTTP_REFERER"]),'">
  160. <input type="hidden" name="save" value="1">
  161. <input type="hidden" name="token" value="',$T,'">
  162. </form>
  163. ';}global$b,$e,$Db,$Kb,$Ub,$j,$xc,$_c,$ba,$Oc,$x,$ca,$ed,$Wd,$ze,$Gf,$Dc,$T,$ng,$sg,$zg,$ga;if(!$_SERVER["REQUEST_URI"])$_SERVER["REQUEST_URI"]=$_SERVER["ORIG_PATH_INFO"];if(!strpos($_SERVER["REQUEST_URI"],'?')&&$_SERVER["QUERY_STRING"]!="")$_SERVER["REQUEST_URI"].="?$_SERVER[QUERY_STRING]";$ba=(isset($_SERVER["HTTPS"])?true:false)&&strcasecmp($_SERVER["HTTPS"],"off");@ini_set("session.use_trans_sid",false);session_cache_limiter("");if(!defined("SID")){session_name("adminer_sid");$qe=array(0,preg_replace('~\\?.*~','',$_SERVER["REQUEST_URI"]),"",$ba);if(version_compare(PHP_VERSION,'5.2.0')>=0)$qe[]=true;call_user_func_array('session_set_cookie_params',$qe);session_start();}remove_slashes(array(&$_GET,&$_POST,&$_COOKIE),$nc);if(get_magic_quotes_runtime())set_magic_quotes_runtime(false);@set_time_limit(0);@ini_set("zend.ze1_compatibility_mode",false);@ini_set("precision",20);function
  164. get_langx(){return'en';}function
  165. lang($mg,$Nd=null){if(is_array($mg)){$Be=($Nd==1?0:1);$mg=$mg[$Be];}$mg=str_replace("%d","%s",$mg);$Nd=format_number($Nd);return
  166. sprintf($mg,$Nd);}if(extension_loaded('pdo')){class
  167. Min_PDO
  168. extends
  169. PDO{var$_result,$server_info,$affected_rows,$errno,$error;function
  170. __construct(){global$b;$Be=array_search("SQL",$b->operators);if($Be!==false)unset($b->operators[$Be]);}function
  171. dsn($Hb,$V,$G){try{parent::__construct($Hb,$V,$G);}catch(Exception$Zb){auth_error($Zb->getMessage());}$this->setAttribute(13,array('Min_PDOStatement'));$this->server_info=$this->getAttribute(4);}function
  172. query($I,$tg=false){$J=parent::query($I);$this->error="";if(!$J){list(,$this->errno,$this->error)=$this->errorInfo();return
  173. false;}$this->store_result($J);return$J;}function
  174. multi_query($I){return$this->_result=$this->query($I);}function
  175. store_result($J=null){if(!$J){$J=$this->_result;if(!$J)return
  176. false;}if($J->columnCount()){$J->num_rows=$J->rowCount();return$J;}$this->affected_rows=$J->rowCount();return
  177. true;}function
  178. next_result(){if(!$this->_result)return
  179. false;$this->_result->_offset=0;return@$this->_result->nextRowset();}function
  180. result($I,$k=0){$J=$this->query($I);if(!$J)return
  181. false;$L=$J->fetch();return$L[$k];}}class
  182. Min_PDOStatement
  183. extends
  184. PDOStatement{var$_offset=0,$num_rows;function
  185. fetch_assoc(){return$this->fetch(2);}function
  186. fetch_row(){return$this->fetch(3);}function
  187. fetch_field(){$L=(object)$this->getColumnMeta($this->_offset++);$L->orgtable=$L->table;$L->orgname=$L->name;$L->charsetnr=(in_array("blob",(array)$L->flags)?63:0);return$L;}}}$Db=array();class
  188. Min_SQL{var$_conn;function
  189. Min_SQL($e){$this->_conn=$e;}function
  190. quote($Y){return($Y===null?"NULL":$this->_conn->quote($Y));}function
  191. select($Q,$N,$Z,$r,$ee=array(),$z=1,$F=0,$Ie=false){global$b,$x;$Vc=(count($r)<count($N));$I=$b->selectQueryBuild($N,$Z,$r,$ee,$z,$F);if(!$I)$I="SELECT".limit(((isset($_GET["page"])?$_GET["page"]:null)!="last"&&+$z&&$r&&$Vc&&$x=="sql"?"SQL_CALC_FOUND_ROWS ":"").implode(", ",$N)."\nFROM ".table($Q),($Z?"\nWHERE ".implode(" AND ",$Z):"").($r&&$Vc?"\nGROUP BY ".implode(", ",$r):"").($ee?"\nORDER BY ".implode(", ",$ee):""),($z!=""?+$z:null),($F?$z*$F:0),"\n");$Bf=microtime(true);$K=$this->_conn->query($I);if($Ie)echo$b->selectQuery($I,format_time($Bf));return$K;}function
  192. delete($Q,$Qe,$z=0){$I="FROM ".table($Q);return
  193. queries("DELETE".($z?limit1($I,$Qe):" $I$Qe"));}function
  194. update($Q,$P,$Qe,$z=0,$sf="\n"){$Gg=array();foreach($P
  195. as$y=>$X)$Gg[]="$y = $X";$I=table($Q)." SET$sf".implode(",$sf",$Gg);return
  196. queries("UPDATE".($z?limit1($I,$Qe):" $I$Qe"));}function
  197. insert($Q,$P){return
  198. queries("INSERT INTO ".table($Q).($P?" (".implode(", ",array_keys($P)).")\nVALUES (".implode(", ",$P).")":" DEFAULT VALUES"));}function
  199. insertUpdate($Q,$M,$He){return
  200. false;}function
  201. begin(){return
  202. queries("BEGIN");}function
  203. commit(){return
  204. queries("COMMIT");}function
  205. rollback(){return
  206. queries("ROLLBACK");}}$Db=array("server"=>"MySQL")+$Db;if(!defined("DRIVER")){$Ee=array("MySQLi","MySQL","PDO_MySQL");define("DRIVER","server");if(extension_loaded("mysqli")){class
  207. Min_DB
  208. extends
  209. MySQLi{var$extension="MySQLi";function
  210. Min_DB(){parent::init();}function
  211. connect($O=null,$V=null,$G=null,$ignore1=null,$ignore2=null,$ignore3=null){mysqli_report(MYSQLI_REPORT_OFF);@list($Gc,$Ae)=explode(":",$O,2);$K=@$this->real_connect(($O!=""?$Gc:ini_get("mysqli.default_host")),($O.$V!=""?$V:ini_get("mysqli.default_user")),($O.$V.$G!=""?$G:ini_get("mysqli.default_pw")),null,(is_numeric($Ae)?$Ae:ini_get("mysqli.default_port")),(!is_numeric($Ae)?$Ae:null));if($K){if(method_exists($this,'set_charset'))$this->set_charset("utf8");else$this->query("SET NAMES utf8");}return$K;}function
  212. result($I,$k=0){$J=$this->query($I);if(!$J)return
  213. false;$L=$J->fetch_array();return$L[$k];}function
  214. quote($Ff){return"'".$this->escape_string($Ff)."'";}}}elseif(extension_loaded("mysql")&&!(ini_get("sql.safe_mode")&&extension_loaded("pdo_mysql"))){class
  215. Min_DB{var$extension="MySQL",$server_info,$affected_rows,$errno,$error,$_link,$_result;function
  216. connect($O,$V,$G){$this->_link=@mysql_connect(($O!=""?$O:ini_get("mysql.default_host")),("$O$V"!=""?$V:ini_get("mysql.default_user")),("$O$V$G"!=""?$G:ini_get("mysql.default_password")),true,131072);if($this->_link){$this->server_info=mysql_get_server_info($this->_link);if(function_exists('mysql_set_charset'))mysql_set_charset("utf8",$this->_link);else$this->query("SET NAMES utf8");}else$this->error=mysql_error();return(bool)$this->_link;}function
  217. quote($Ff){return"'".mysql_real_escape_string($Ff,$this->_link)."'";}function
  218. select_db($qb){return
  219. mysql_select_db($qb,$this->_link);}function
  220. query($I,$tg=false){$J=@($tg?mysql_unbuffered_query($I,$this->_link):mysql_query($I,$this->_link));$this->error="";if(!$J){$this->errno=mysql_errno($this->_link);$this->error=mysql_error($this->_link);return
  221. false;}if($J===true){$this->affected_rows=mysql_affected_rows($this->_link);$this->info=mysql_info($this->_link);return
  222. true;}return
  223. new
  224. Min_Result($J);}function
  225. multi_query($I){return$this->_result=$this->query($I);}function
  226. store_result(){return$this->_result;}function
  227. next_result(){return
  228. false;}function
  229. result($I,$k=0){$J=$this->query($I);if(!$J||!$J->num_rows)return
  230. false;return
  231. mysql_result($J->_result,0,$k);}}class
  232. Min_Result{var$num_rows,$_result,$_offset=0;function
  233. Min_Result($J){$this->_result=$J;$this->num_rows=mysql_num_rows($J);}function
  234. fetch_assoc(){return
  235. mysql_fetch_assoc($this->_result);}function
  236. fetch_row(){return
  237. mysql_fetch_row($this->_result);}function
  238. fetch_field(){$K=mysql_fetch_field($this->_result,$this->_offset++);$K->orgtable=$K->table;$K->orgname=$K->name;$K->charsetnr=($K->blob?63:0);return$K;}function
  239. __destruct(){mysql_free_result($this->_result);}}}elseif(extension_loaded("pdo_mysql")){class
  240. Min_DB
  241. extends
  242. Min_PDO{var$extension="PDO_MySQL";function
  243. connect($O,$V,$G){$this->dsn("mysql:charset=utf8;host=".str_replace(":",";unix_socket=",preg_replace('~:(\\d)~',';port=\\1',$O)),$V,$G);$this->query("SET NAMES utf8");return
  244. true;}function
  245. select_db($qb){return$this->query("USE ".idf_escape($qb));}function
  246. query($I,$tg=false){$this->setAttribute(1000,!$tg);return
  247. parent::query($I,$tg);}}}class
  248. Min_Driver
  249. extends
  250. Min_SQL{function
  251. insert($Q,$P){return($P?parent::insert($Q,$P):queries("INSERT INTO ".table($Q)." ()\nVALUES ()"));}function
  252. insertUpdate($Q,$M,$He){$d=array_keys(reset($M));$Fe="INSERT INTO ".table($Q)." (".implode(", ",$d).") VALUES\n";$Gg=array();foreach($d
  253. as$y)$Gg[$y]="$y = VALUES($y)";$Jf="\nON DUPLICATE KEY UPDATE ".implode(", ",$Gg);$Gg=array();$ld=0;foreach($M
  254. as$P){$Y="(".implode(", ",$P).")";if($Gg&&(strlen($Fe)+$ld+strlen($Y)+strlen($Jf)>1e6)){if(!queries($Fe.implode(",\n",$Gg).$Jf))return
  255. false;$Gg=array();$ld=0;}$Gg[]=$Y;$ld+=strlen($Y)+2;}return
  256. queries($Fe.implode(",\n",$Gg).$Jf);}}function
  257. idf_escape($Jc){return"`".str_replace("`","``",$Jc)."`";}function
  258. table($Jc){return
  259. idf_escape($Jc);}function
  260. connect(){global$b;$e=new
  261. Min_DB;$mb=$b->credentials();if($e->connect($mb[0],$mb[1],$mb[2])){$e->query("SET sql_quote_show_create = 1, autocommit = 1");return$e;}$K=$e->error;if(function_exists('iconv')&&!is_utf8($K)&&strlen($lf=iconv("windows-1250","utf-8",$K))>strlen($K))$K=$lf;return$K;}function
  262. get_databases($pc){global$e;$K=get_session("dbs");if($K===null){$I=($e->server_info>=5?"SELECT SCHEMA_NAME FROM information_schema.SCHEMATA":"SHOW DATABASES");$K=($pc?slow_query($I):get_vals($I));restart_session();set_session("dbs",$K);stop_session();}return$K;}function
  263. limit($I,$Z,$z,$Pd=0,$sf=" "){return" $I$Z".($z!==null?$sf."LIMIT $z".($Pd?" OFFSET $Pd":""):"");}function
  264. limit1($I,$Z){return
  265. limit($I,$Z,1);}function
  266. db_collation($h,$Wa){global$e;$K=null;$jb=$e->result("SHOW CREATE DATABASE ".idf_escape($h),1);if(preg_match('~ COLLATE ([^ ]+)~',$jb,$B))$K=$B[1];elseif(preg_match('~ CHARACTER SET ([^ ]+)~',$jb,$B))$K=$Wa[$B[1]][-1];return$K;}function
  267. engines(){$K=array();foreach(get_rows("SHOW ENGINES")as$L){if(preg_match("~YES|DEFAULT~",$L["Support"]))$K[]=$L["Engine"];}return$K;}function
  268. logged_user(){global$e;return$e->result("SELECT USER()");}function
  269. tables_list(){global$e;return
  270. get_key_vals($e->server_info>=5?"SELECT TABLE_NAME, TABLE_TYPE FROM information_schema.TABLES WHERE TABLE_SCHEMA = DATABASE() ORDER BY TABLE_NAME":"SHOW TABLES");}function
  271. count_tables($g){$K=array();foreach($g
  272. as$h)$K[$h]=count(get_vals("SHOW TABLES IN ".idf_escape($h)));return$K;}function
  273. table_status($E="",$ic=false){global$e;$K=array();foreach(get_rows($ic&&$e->server_info>=5?"SELECT TABLE_NAME AS Name, Engine, TABLE_COMMENT AS Comment FROM information_schema.TABLES WHERE TABLE_SCHEMA = DATABASE() ".($E!=""?"AND TABLE_NAME = ".q($E):"ORDER BY Name"):"SHOW TABLE STATUS".($E!=""?" LIKE ".q(addcslashes($E,"%_\\")):""))as$L){if($L["Engine"]=="InnoDB")$L["Comment"]=preg_replace('~(?:(.+); )?InnoDB free: .*~','\\1',$L["Comment"]);if(!isset($L["Engine"]))$L["Comment"]="";if($E!="")return$L;$K[$L["Name"]]=$L;}return$K;}function
  274. is_view($R){return$R["Engine"]===null;}function
  275. fk_support($R){return
  276. preg_match('~InnoDB|IBMDB2I~i',$R["Engine"]);}function
  277. fields($Q){$K=array();foreach(get_rows("SHOW FULL COLUMNS FROM ".table($Q))as$L){preg_match('~^([^( ]+)(?:\\((.+)\\))?( unsigned)?( zerofill)?$~',$L["Type"],$B);$K[$L["Field"]]=array("field"=>$L["Field"],"full_type"=>$L["Type"],"type"=>isset($B[1])?$B[1]:null,"length"=>isset($B[2])?$B[2]:null,"unsigned"=>ltrim((isset($B[3])?$B[3]:'').(isset($B[4])?$B[4]:'')),"default"=>($L["Default"]!=""||preg_match("~char|set~",$B[1])?$L["Default"]:null),"null"=>($L["Null"]=="YES"),"auto_increment"=>($L["Extra"]=="auto_increment"),"on_update"=>(preg_match('~^on update (.+)~i',$L["Extra"],$B)?$B[1]:""),"collation"=>$L["Collation"],"privileges"=>array_flip(preg_split('~, *~',$L["Privileges"])),"comment"=>$L["Comment"],"primary"=>($L["Key"]=="PRI"),);}return$K;}function
  278. indexes($Q,$f=null){$K=array();foreach(get_rows("SHOW INDEX FROM ".table($Q),$f)as$L){$K[$L["Key_name"]]["type"]=($L["Key_name"]=="PRIMARY"?"PRIMARY":($L["Index_type"]=="FULLTEXT"?"FULLTEXT":($L["Non_unique"]?"INDEX":"UNIQUE")));$K[$L["Key_name"]]["columns"][]=$L["Column_name"];$K[$L["Key_name"]]["lengths"][]=$L["Sub_part"];$K[$L["Key_name"]]["descs"][]=null;}return$K;}function
  279. foreign_keys($Q){global$e,$Wd;static$ye='`(?:[^`]|``)+`';$K=array();$kb=$e->result("SHOW CREATE TABLE ".table($Q),1);if($kb){preg_match_all("~CONSTRAINT ($ye) FOREIGN KEY \\(((?:$ye,? ?)+)\\) REFERENCES ($ye)(?:\\.($ye))? \\(((?:$ye,? ?)+)\\)(?: ON DELETE ($Wd))?(?: ON UPDATE ($Wd))?~",$kb,$sd,PREG_SET_ORDER);foreach($sd
  280. as$B){preg_match_all("~$ye~",$B[2],$zf);preg_match_all("~$ye~",$B[5],$Uf);$K[idf_unescape($B[1])]=array("db"=>idf_unescape($B[4]!=""?$B[3]:$B[4]),"table"=>idf_unescape($B[4]!=""?$B[4]:$B[3]),"source"=>array_map('idf_unescape',$zf[0]),"target"=>array_map('idf_unescape',$Uf[0]),"on_delete"=>($B[6]?$B[6]:"RESTRICT"),"on_update"=>($B[7]?$B[7]:"RESTRICT"),);}}return$K;}function
  281. view($E){global$e;return
  282. array("select"=>preg_replace('~^(?:[^`]|`[^`]*`)*\\s+AS\\s+~isU','',$e->result("SHOW CREATE VIEW ".table($E),1)));}function
  283. collations(){$K=array();foreach(get_rows("SHOW COLLATION")as$L){if($L["Default"])$K[$L["Charset"]][-1]=$L["Collation"];else$K[$L["Charset"]][]=$L["Collation"];}ksort($K);foreach($K
  284. as$y=>$X)asort($K[$y]);return$K;}function
  285. information_schema($h){global$e;return($e->server_info>=5&&$h=="information_schema")||($e->server_info>=5.5&&$h=="performance_schema");}function
  286. error(){global$e;return
  287. h(preg_replace('~^You have an error.*syntax to use~U',"Syntax error",$e->error));}function
  288. error_line(){global$e;if(preg_match('~ at line ([0-9]+)$~',$e->error,$af))return$af[1]-1;}function
  289. create_database($h,$Va){set_session("dbs",null);return
  290. queries("CREATE DATABASE ".idf_escape($h).($Va?" COLLATE ".q($Va):""));}function
  291. drop_databases($g){restart_session();set_session("dbs",null);return
  292. apply_queries("DROP DATABASE",$g,'idf_escape');}function
  293. rename_database($E,$Va){if(create_database($E,$Va)){$bf=array();foreach(tables_list()as$Q=>$U)$bf[]=table($Q)." TO ".idf_escape($E).".".table($Q);if(!$bf||queries("RENAME TABLE ".implode(", ",$bf))){queries("DROP DATABASE ".idf_escape(DB));return
  294. true;}}return
  295. false;}function
  296. auto_increment(){$za=" PRIMARY KEY";if($_GET["create"]!=""&&$_POST["auto_increment_col"]){foreach(indexes($_GET["create"])as$u){if(in_array($_POST["fields"][$_POST["auto_increment_col"]]["orig"],$u["columns"],true)){$za="";break;}if($u["type"]=="PRIMARY")$za=" UNIQUE";}}return" AUTO_INCREMENT$za";}function
  297. alter_table($Q,$E,$l,$qc,$ab,$Sb,$Va,$ya,$ue){$sa=array();foreach($l
  298. as$k)$sa[]=($k[1]?($Q!=""?($k[0]!=""?"CHANGE ".idf_escape($k[0]):"ADD"):" ")." ".implode($k[1]).($Q!=""?$k[2]:""):"DROP ".idf_escape($k[0]));$sa=array_merge($sa,$qc);$Cf="COMMENT=".q($ab).($Sb?" ENGINE=".q($Sb):"").($Va?" COLLATE ".q($Va):"").($ya!=""?" AUTO_INCREMENT=$ya":"").$ue;if($Q=="")return
  299. queries("CREATE TABLE ".table($E)." (\n".implode(",\n",$sa)."\n) $Cf");if($Q!=$E)$sa[]="RENAME TO ".table($E);$sa[]=$Cf;return
  300. queries("ALTER TABLE ".table($Q)."\n".implode(",\n",$sa));}function
  301. alter_indexes($Q,$sa){foreach($sa
  302. as$y=>$X)$sa[$y]=($X[2]=="DROP"?"\nDROP INDEX ".idf_escape($X[1]):"\nADD $X[0] ".($X[0]=="PRIMARY"?"KEY ":"").($X[1]!=""?idf_escape($X[1])." ":"")."(".implode(", ",$X[2]).")");return
  303. queries("ALTER TABLE ".table($Q).implode(",",$sa));}function
  304. truncate_tables($S){return
  305. apply_queries("TRUNCATE TABLE",$S);}function
  306. drop_views($Kg){return
  307. queries("DROP VIEW ".implode(", ",array_map('table',$Kg)));}function
  308. drop_tables($S){return
  309. queries("DROP TABLE ".implode(", ",array_map('table',$S)));}function
  310. move_tables($S,$Kg,$Uf){$bf=array();foreach(array_merge($S,$Kg)as$Q)$bf[]=table($Q)." TO ".idf_escape($Uf).".".table($Q);return
  311. queries("RENAME TABLE ".implode(", ",$bf));}function
  312. copy_tables($S,$Kg,$Uf){queries("SET sql_mode = 'NO_AUTO_VALUE_ON_ZERO'");foreach($S
  313. as$Q){$E=($Uf==DB?table("copy_$Q"):idf_escape($Uf).".".table($Q));if(!queries("\nDROP TABLE IF EXISTS $E")||!queries("CREATE TABLE $E LIKE ".table($Q))||!queries("INSERT INTO $E SELECT * FROM ".table($Q)))return
  314. false;}foreach($Kg
  315. as$Q){$E=($Uf==DB?table("copy_$Q"):idf_escape($Uf).".".table($Q));$Jg=view($Q);if(!queries("DROP VIEW IF EXISTS $E")||!queries("CREATE VIEW $E AS $Jg[select]"))return
  316. false;}return
  317. true;}function
  318. trigger($E){if($E=="")return
  319. array();$M=get_rows("SHOW TRIGGERS WHERE `Trigger` = ".q($E));return
  320. reset($M);}function
  321. triggers($Q){$K=array();foreach(get_rows("SHOW TRIGGERS LIKE ".q(addcslashes($Q,"%_\\")))as$L)$K[$L["Trigger"]]=array($L["Timing"],$L["Event"]);return$K;}function
  322. trigger_options(){return
  323. array("Timing"=>array("BEFORE","AFTER"),"Event"=>array("INSERT","UPDATE","DELETE"),"Type"=>array("FOR EACH ROW"),);}function
  324. routine($E,$U){global$e,$Ub,$Oc,$sg;$qa=array("bool","boolean","integer","double precision","real","dec","numeric","fixed","national char","national varchar");$rg="((".implode("|",array_merge(array_keys($sg),$qa)).")\\b(?:\\s*\\(((?:[^'\")]|$Ub)++)\\))?\\s*(zerofill\\s*)?(unsigned(?:\\s+zerofill)?)?)(?:\\s*(?:CHARSET|CHARACTER\\s+SET)\\s*['\"]?([^'\"\\s]+)['\"]?)?";$ye="\\s*(".($U=="FUNCTION"?"":$Oc).")?\\s*(?:`((?:[^`]|``)*)`\\s*|\\b(\\S+)\\s+)$rg";$jb=$e->result("SHOW CREATE $U ".idf_escape($E),2);preg_match("~\\(((?:$ye\\s*,?)*)\\)\\s*".($U=="FUNCTION"?"RETURNS\\s+$rg\\s+":"")."(.*)~is",$jb,$B);$l=array();preg_match_all("~$ye\\s*,?~is",$B[1],$sd,PREG_SET_ORDER);foreach($sd
  325. as$pe){$E=str_replace("``","`",$pe[2]).$pe[3];$l[]=array("field"=>$E,"type"=>strtolower($pe[5]),"length"=>preg_replace_callback("~$Ub~s",'normalize_enum',$pe[6]),"unsigned"=>strtolower(preg_replace('~\\s+~',' ',trim("$pe[8] $pe[7]"))),"null"=>1,"full_type"=>$pe[4],"inout"=>strtoupper($pe[1]),"collation"=>strtolower($pe[9]),);}if($U!="FUNCTION")return
  326. array("fields"=>$l,"definition"=>$B[11]);return
  327. array("fields"=>$l,"returns"=>array("type"=>$B[12],"length"=>$B[13],"unsigned"=>$B[15],"collation"=>$B[16]),"definition"=>$B[17],"language"=>"SQL",);}function
  328. routines(){return
  329. get_rows("SELECT ROUTINE_NAME, ROUTINE_TYPE, DTD_IDENTIFIER FROM information_schema.ROUTINES WHERE ROUTINE_SCHEMA = ".q(DB));}function
  330. routine_languages(){return
  331. array();}function
  332. last_id(){global$e;return$e->result("SELECT LAST_INSERT_ID()");}function
  333. explain($e,$I){return$e->query("EXPLAIN ".($e->server_info>=5.1?"PARTITIONS ":"").$I);}function
  334. found_rows($R,$Z){return($Z||$R["Engine"]!="InnoDB"?null:$R["Rows"]);}function
  335. types(){return
  336. array();}function
  337. schemas(){return
  338. array();}function
  339. get_schema(){return"";}function
  340. set_schema($nf){return
  341. true;}function
  342. create_sql($Q,$ya){global$e;$K=$e->result("SHOW CREATE TABLE ".table($Q),1);if(!$ya)$K=preg_replace('~ AUTO_INCREMENT=\\d+~','',$K);return$K;}function
  343. truncate_sql($Q){return"TRUNCATE ".table($Q);}function
  344. use_sql($qb){return"USE ".idf_escape($qb);}function
  345. trigger_sql($Q,$Hf){$K="";foreach(get_rows("SHOW TRIGGERS LIKE ".q(addcslashes($Q,"%_\\")),null,"-- ")as$L)$K.="\n".($Hf=='CREATE+ALTER'?"DROP TRIGGER IF EXISTS ".idf_escape($L["Trigger"]).";;\n":"")."CREATE TRIGGER ".idf_escape($L["Trigger"])." $L[Timing] $L[Event] ON ".table($L["Table"])." FOR EACH ROW\n$L[Statement];;\n";return$K;}function
  346. show_variables(){return
  347. get_key_vals("SHOW VARIABLES");}function
  348. process_list(){return
  349. get_rows("SHOW FULL PROCESSLIST");}function
  350. show_status(){return
  351. get_key_vals("SHOW STATUS");}function
  352. convert_field($k){if(preg_match("~binary~",$k["type"]))return"HEX(".idf_escape($k["field"]).")";if($k["type"]=="bit")return"BIN(".idf_escape($k["field"])." + 0)";if(preg_match("~geometry|point|linestring|polygon~",$k["type"]))return"AsWKT(".idf_escape($k["field"]).")";}function
  353. unconvert_field($k,$K){if(preg_match("~binary~",$k["type"]))$K="UNHEX($K)";if($k["type"]=="bit")$K="CONV($K, 2, 10) + 0";if(preg_match("~geometry|point|linestring|polygon~",$k["type"]))$K="GeomFromText($K)";return$K;}function
  354. support($jc){global$e;return!preg_match("~scheme|sequence|type|view_trigger".($e->server_info<5.1?"|event|partitioning".($e->server_info<5?"|routine|trigger|view":""):"")."~",$jc);}$x="sql";$sg=array();$Gf=array();foreach(array('Numbers'=>array("tinyint"=>3,"smallint"=>5,"mediumint"=>8,"int"=>10,"bigint"=>20,"decimal"=>66,"float"=>12,"double"=>21),'Date and time'=>array("date"=>10,"datetime"=>19,"timestamp"=>19,"time"=>10,"year"=>4),'Strings'=>array("char"=>255,"varchar"=>65535,"tinytext"=>255,"text"=>65535,"mediumtext"=>16777215,"longtext"=>4294967295),'Lists'=>array("enum"=>65535,"set"=>64),'Binary'=>array("bit"=>20,"binary"=>255,"varbinary"=>65535,"tinyblob"=>255,"blob"=>65535,"mediumblob"=>16777215,"longblob"=>4294967295),'Geometry'=>array("geometry"=>0,"point"=>0,"linestring"=>0,"polygon"=>0,"multipoint"=>0,"multilinestring"=>0,"multipolygon"=>0,"geometrycollection"=>0),)as$y=>$X){$sg+=$X;$Gf[$y]=array_keys($X);}$zg=array("unsigned","zerofill","unsigned zerofill");$ae=array("=","<",">","<=",">=","!=","LIKE","LIKE %%","REGEXP","IN","IS NULL","NOT LIKE","NOT REGEXP","NOT IN","IS NOT NULL","SQL");$xc=array("char_length","date","from_unixtime","lower","round","sec_to_time","time_to_sec","upper");$_c=array("avg","count","count distinct","group_concat","max","min","sum");$Kb=array(array("char"=>"md5/sha1/password/encrypt/uuid","binary"=>"md5/sha1","date|time"=>"now",),array("(^|[^o])int|float|double|decimal"=>"+/-","date"=>"+ interval/- interval","time"=>"addtime/subtime","char|text"=>"concat",));}define("SERVER",$_GET[DRIVER]);define("DB",$_GET["db"]);define("ME",preg_replace('~^[^?]*/([^?]*).*~','\\1',$_SERVER["REQUEST_URI"]).'?'.(sid()?SID.'&':'').(SERVER!==null?DRIVER."=".urlencode(SERVER).'&':'').(isset($_GET["username"])?"username=".urlencode($_GET["username"]).'&':'').(DB!=""?'db='.urlencode(DB).'&'.(isset($_GET["ns"])?"ns=".urlencode($_GET["ns"])."&":""):''));$ga="4.1.0";class
  355. Adminer{var$operators;function
  356. name(){return"<a href='http://www.adminer.org/' target='_blank' id='h1'>Adminer</a>";}function
  357. credentials(){return
  358. array(SERVER,$_GET["username"],get_password());}function
  359. permanentLogin($jb=false){return
  360. password_file($jb);}function
  361. bruteForceKey(){return$_SERVER["REMOTE_ADDR"];}function
  362. database(){return
  363. DB;}function
  364. databases($pc=true){return
  365. get_databases($pc);}function
  366. schemas(){return
  367. schemas();}function
  368. queryTimeout(){return
  369. 5;}function
  370. headers(){return
  371. true;}function
  372. head(){return
  373. true;}function
  374. loginForm(){global$Db;echo'<table cellspacing="0">
  375. <tr><th>System<td>',html_select("auth[driver]",$Db,DRIVER,"loginDriver(this);"),'<tr><th>Server<td><input name="auth[server]" value="',h(SERVER),'" title="hostname[:port]" placeholder="localhost" autocapitalize="off">
  376. <tr><th>Username<td><input name="auth[username]" id="username" value="',h((isset($_GET["username"])?$_GET["username"]:'')),'" autocapitalize="off">
  377. <tr><th>Password<td><input type="password" name="auth[password]">
  378. <tr><th>Database<td><input name="auth[db]" value="',h((isset($_GET["db"])?$_GET["db"]:''));?>" autocapitalize="off">
  379. </table>
  380. <script type="text/javascript">
  381. var username = document.getElementById('username');
  382. focus(username);
  383. username.form['auth[driver]'].onchange();
  384. </script>
  385. <?php
  386. echo"<p><input type='submit' value='".'Login'."'>\n",checkbox("auth[permanent]",1,(isset($_COOKIE["adminer_permanent"])?$_COOKIE["adminer_permanent"]:false),'Permanent login')."\n";}function
  387. login($qd,$G){return
  388. true;}function
  389. tableName($Nf){return
  390. h($Nf["Name"]);}function
  391. fieldName($k,$ee=0){return'<span title="'.h($k["full_type"]).'">'.h($k["field"]).'</span>';}function
  392. selectLinks($Nf,$P=""){echo'<p class="links">';$pd=array("select"=>'Select data');if(support("table")||support("indexes"))$pd["table"]='Show structure';if(support("table")){if(is_view($Nf))$pd["view"]='Alter view';else$pd["create"]='Alter table';}if($P!==null)$pd["edit"]='New item';foreach($pd
  393. as$y=>$X)echo" <a href='".h(ME)."$y=".urlencode($Nf["Name"]).($y=="edit"?$P:"")."'".bold(isset($_GET[$y])).">$X</a>";echo"\n";}function
  394. foreignKeys($Q){return
  395. foreign_keys($Q);}function
  396. backwardKeys($Q,$Mf){return
  397. array();}function
  398. backwardKeysPrint($Aa,$L){}function
  399. selectQuery($I,$ag){global$x;return"<p><code class='jush-$x'>".h(str_replace("\n"," ",$I))."</code> <span class='time'>($ag)</span>".(support("sql")?" <a href='".h(ME)."sql=".urlencode($I)."'>".'Edit'."</a>":"")."</p>";}function
  400. rowDescription($Q){return"";}function
  401. rowDescriptions($M,$rc){return$M;}function
  402. selectLink($X,$k){}function
  403. selectVal($X,$_,$k,$le){$K=($X===null?"<i>NULL</i>":(preg_match("~char|binary~",$k["type"])&&!preg_match("~var~",$k["type"])?"<code>$X</code>":$X));if(preg_match('~blob|bytea|raw|file~',$k["type"])&&!is_utf8($X))$K=lang(array('%d byte','%d bytes'),strlen($le));return($_?"<a href='".h($_)."'".(is_url($_)?" rel='noreferrer'":"").">$K</a>":$K);}function
  404. editVal($X,$k){return$X;}function
  405. selectColumnsPrint($N,$d){global$xc,$_c;print_fieldset("select",'Select',$N);$s=0;$N[""]=array();foreach($N
  406. as$y=>$X){$X=$_GET["columns"][$y];$c=select_input(" name='columns[$s][col]' onchange='".($y!==""?"selectFieldChange(this.form)":"selectAddRow(this)").";'",$d,$X["col"]);echo"<div>".($xc||$_c?"<select name='columns[$s][fun]' onchange='helpClose();".($y!==""?"":" this.nextSibling.nextSibling.onchange();")."'".on_help("getTarget(event).value && getTarget(event).value.replace(/ |\$/, '(') + ')'",1).">".optionlist(array(-1=>"")+array_filter(array('Functions'=>$xc,'Aggregation'=>$_c)),$X["fun"])."</select>"."($c)":$c)."</div>\n";$s++;}echo"</div></fieldset>\n";}function
  407. selectSearchPrint($Z,$d,$v){print_fieldset("search",'Search',$Z);foreach($v
  408. as$s=>$u){if($u["type"]=="FULLTEXT"){echo"(<i>".implode("</i>, <i>",array_map('h',$u["columns"]))."</i>) AGAINST"," <input type='search' name='fulltext[$s]' value='".h($_GET["fulltext"][$s])."' onchange='selectFieldChange(this.form);'>",checkbox("boolean[$s]",1,isset($_GET["boolean"][$s]),"BOOL"),"<br>\n";}}$_GET["where"]=(array)$_GET["where"];reset($_GET["where"]);$Ka="this.nextSibling.onchange();";for($s=0;$s<=count($_GET["where"]);$s++){list(,$X)=each($_GET["where"]);if(!$X||("$X[col]$X[val]"!=""&&in_array($X["op"],$this->operators))){echo"<div>".select_input(" name='where[$s][col]' onchange='$Ka'",$d,$X["col"],"(".'anywhere'.")"),html_select("where[$s][op]",$this->operators,$X["op"],$Ka),"<input type='search' name='where[$s][val]' value='".h($X["val"])."' onchange='".($X?"selectFieldChange(this.form)":"selectAddRow(this)").";' onkeydown='selectSearchKeydown(this, event);' onsearch='selectSearchSearch(this);'></div>\n";}}echo"</div></fieldset>\n";}function
  409. selectOrderPrint($ee,$d,$v){print_fieldset("sort",'Sort',$ee);$s=0;foreach((array)$_GET["order"]as$y=>$X){if($X!=""){echo"<div>".select_input(" name='order[$s]' onchange='selectFieldChange(this.form);'",$d,$X),checkbox("desc[$s]",1,isset($_GET["desc"][$y]),'descending')."</div>\n";$s++;}}echo"<div>".select_input(" name='order[$s]' onchange='selectAddRow(this);'",$d),checkbox("desc[$s]",1,false,'descending')."</div>\n","</div></fieldset>\n";}function
  410. selectLimitPrint($z){echo"<fieldset><legend>".'Limit'."</legend><div>";echo"<input type='number' name='limit' class='size' value='".h($z)."' onchange='selectFieldChange(this.form);'>","</div></fieldset>\n";}function
  411. selectLengthPrint($Zf){if($Zf!==null){echo"<fieldset><legend>".'Text length'."</legend><div>","<input type='number' name='text_length' class='size' value='".h($Zf)."'>","</div></fieldset>\n";}}function
  412. selectActionPrint($v){echo"<fieldset><legend>".'Action'."</legend><div>","<input type='submit' value='".'Select'."'>"," <span id='noindex' title='".'Full table scan'."'></span>","<script type='text/javascript'>\n","var indexColumns = ";$d=array();foreach($v
  413. as$u){if($u["type"]!="FULLTEXT")$d[reset($u["columns"])]=1;}$d[""]=1;foreach($d
  414. as$y=>$X)json_row($y);echo";\n","selectFieldChange(document.getElementById('form'));\n","</script>\n","</div></fieldset>\n";}function
  415. selectCommandPrint(){return!information_schema(DB);}function
  416. selectImportPrint(){return!information_schema(DB);}function
  417. selectEmailPrint($Pb,$d){}function
  418. selectColumnsProcess($d,$v){global$xc,$_c;$N=array();$r=array();foreach((array)(isset($_GET["columns"])?$_GET["columns"]:null)as$y=>$X){if($X["fun"]=="count"||($X["col"]!=""&&(!$X["fun"]||in_array($X["fun"],$xc)||in_array($X["fun"],$_c)))){$N[$y]=apply_sql_function($X["fun"],($X["col"]!=""?idf_escape($X["col"]):"*"));if(!in_array($X["fun"],$_c))$r[]=$N[$y];}}return
  419. array($N,$r);}function
  420. selectSearchProcess($l,$v){global$x;$K=array();foreach($v
  421. as$s=>$u){if($u["type"]=="FULLTEXT"&&$_GET["fulltext"][$s]!="")$K[]="MATCH (".implode(", ",array_map('idf_escape',$u["columns"])).") AGAINST (".q($_GET["fulltext"][$s]).(isset($_GET["boolean"][$s])?" IN BOOLEAN MODE":"").")";}foreach((array)(isset($_GET["where"])?$_GET["where"]:null)as$X){if("$X[col]$X[val]"!=""&&in_array($X["op"],$this->operators)){$cb=" $X[op]";if(preg_match('~IN$~',$X["op"])){$Lc=process_length($X["val"]);$cb.=" ".($Lc!=""?$Lc:"(NULL)");}elseif($X["op"]=="SQL")$cb=" $X[val]";elseif($X["op"]=="LIKE %%")$cb=" LIKE ".$this->processInput($l[$X["col"]],"%$X[val]%");elseif(!preg_match('~NULL$~',$X["op"]))$cb.=" ".$this->processInput($l[$X["col"]],$X["val"]);if($X["col"]!="")$K[]=idf_escape($X["col"]).$cb;else{$Xa=array();foreach($l
  422. as$E=>$k){$Xc=preg_match('~char|text|enum|set~',$k["type"]);if((is_numeric($X["val"])||!preg_match('~(^|[^o])int|float|double|decimal|bit~',$k["type"]))&&(!preg_match("~[\x80-\xFF]~",$X["val"])||$Xc)){$E=idf_escape($E);$Xa[]=($x=="sql"&&$Xc&&!preg_match('~^utf8~',$k["collation"])?"CONVERT($E USING utf8)":$E);}}$K[]=($Xa?"(".implode("$cb OR ",$Xa)."$cb)":"0");}}}return$K;}function
  423. selectOrderProcess($l,$v){$K=array();foreach((array)(isset($_GET["order"])?$_GET["order"]:null)as$y=>$X){if($X!="")$K[]=(preg_match('~^((COUNT\\(DISTINCT |[A-Z0-9_]+\\()(`(?:[^`]|``)+`|"(?:[^"]|"")+")\\)|COUNT\\(\\*\\))$~',$X)?$X:idf_escape($X)).(isset($_GET["desc"][$y])?" DESC":"");}return$K;}function
  424. selectLimitProcess(){return(isset($_GET["limit"])?$_GET["limit"]:"50");}function
  425. selectLengthProcess(){return(isset($_GET["text_length"])?$_GET["text_length"]:"100");}function
  426. selectEmailProcess($Z,$rc){return
  427. false;}function
  428. selectQueryBuild($N,$Z,$r,$ee,$z,$F){return"";}function
  429. messageQuery($I,$ag){global$x;restart_session();$Ec=&get_session("queries");$t="sql-".count($Ec[$_GET["db"]]);if(strlen($I)>1e6)$I=preg_replace('~[\x80-\xFF]+$~','',substr($I,0,1e6))."\n...";$Ec[$_GET["db"]][]=array($I,time(),$ag);return" <span class='time'>".@date("H:i:s")."</span> <a href='#$t' onclick=\"return !toggle('$t');\">".'SQL command'."</a>"."<div id='$t' class='hidden'><pre><code class='jush-$x'>".shorten_utf8($I,1000).'</code></pre>'.($ag?" <span class='time'>($ag)</span>":'').(support("sql")?'<p><a href="'.h(str_replace("db=".urlencode(DB),"db=".urlencode($_GET["db"]),ME).'sql=&history='.(count($Ec[$_GET["db"]])-1)).'">'.'Edit'.'</a>':'').'</div>';}function
  430. editFunctions($k){global$Kb;$K=($k["null"]?"NULL/":"");foreach($Kb
  431. as$y=>$xc){if(!$y||(!isset($_GET["call"])&&(isset($_GET["select"])||where($_GET)))){foreach($xc
  432. as$ye=>$X){if(!$ye||preg_match("~$ye~",$k["type"]))$K.="/$X";}if($y&&!preg_match('~set|blob|bytea|raw|file~',$k["type"]))$K.="/SQL";}}if($k["auto_increment"]&&!isset($_GET["select"])&&!where($_GET))$K='Auto Increment';return
  433. explode("/",$K);}function
  434. editInput($Q,$k,$wa,$Y){if($k["type"]=="enum")return(isset($_GET["select"])?"<label><input type='radio'$wa value='-1' checked><i>".'original'."</i></label> ":"").($k["null"]?"<label><input type='radio'$wa value=''".($Y!==null||isset($_GET["select"])?"":" checked")."><i>NULL</i></label> ":"").enum_input("radio",$wa,$k,$Y,0);return"";}function
  435. processInput($k,$Y,$p=""){if($p=="SQL")return$Y;$E=$k["field"];$K=q($Y);if(preg_match('~^(now|getdate|uuid)$~',$p))$K="$p()";elseif(preg_match('~^current_(date|timestamp)$~',$p))$K=$p;elseif(preg_match('~^([+-]|\\|\\|)$~',$p))$K=idf_escape($E)." $p $K";elseif(preg_match('~^[+-] interval$~',$p))$K=idf_escape($E)." $p ".(preg_match("~^(\\d+|'[0-9.: -]') [A-Z_]+$~i",$Y)?$Y:$K);elseif(preg_match('~^(addtime|subtime|concat)$~',$p))$K="$p(".idf_escape($E).", $K)";elseif(preg_match('~^(md5|sha1|password|encrypt)$~',$p))$K="$p($K)";return
  436. unconvert_field($k,$K);}function
  437. dumpOutput(){$K=array('text'=>'open','file'=>'save');if(function_exists('gzencode'))$K['gz']='gzip';return$K;}function
  438. dumpFormat(){return
  439. array('sql'=>'SQL','csv'=>'CSV,','csv;'=>'CSV;','tsv'=>'TSV');}function
  440. dumpDatabase($h){}function
  441. dumpTable($Q,$Hf,$Yc=0){if($_POST["format"]!="sql"){echo"\xef\xbb\xbf";if($Hf)dump_csv(array_keys(fields($Q)));}elseif($Hf){if($Yc==2){$l=array();foreach(fields($Q)as$E=>$k)$l[]=idf_escape($E)." $k[full_type]";$jb="CREATE TABLE ".table($Q)." (".implode(", ",$l).")";}else$jb=create_sql($Q,$_POST["auto_increment"]);if($jb){if($Hf=="DROP+CREATE"||$Yc==1)echo"DROP ".($Yc==2?"VIEW":"TABLE")." IF EXISTS ".table($Q).";\n";if($Yc==1)$jb=remove_definer($jb);echo"$jb;\n\n";}}}function
  442. dumpData($Q,$Hf,$I){global$e,$x;$ud=($x=="sqlite"?0:1048576);if($Hf){if($_POST["format"]=="sql"){if($Hf=="TRUNCATE+INSERT")echo
  443. truncate_sql($Q).";\n";$l=fields($Q);}$J=$e->query($I,1);if($J){$Qc="";$Ia="";$ad=array();$Jf="";$kc=($Q!=''?'fetch_assoc':'fetch_row');while($L=$J->$kc()){if(!$ad){$Gg=array();foreach($L
  444. as$X){$k=$J->fetch_field();$ad[]=$k->name;$y=idf_escape($k->name);$Gg[]="$y = VALUES($y)";}$Jf=($Hf=="INSERT+UPDATE"?"\nON DUPLICATE KEY UPDATE ".implode(", ",$Gg):"").";\n";}if($_POST["format"]!="sql"){if($Hf=="table"){dump_csv($ad);$Hf="INSERT";}dump_csv($L);}else{if(!$Qc)$Qc="INSERT INTO ".table($Q)." (".implode(", ",array_map('idf_escape',$ad)).") VALUES";foreach($L
  445. as$y=>$X){$k=$l[$y];$L[$y]=($X!==null?unconvert_field($k,preg_match('~(^|[^o])int|float|double|decimal~',$k["type"])&&$X!=''?$X:q($X)):"NULL");}$lf=($ud?"\n":" ")."(".implode(",\t",$L).")";if(!$Ia)$Ia=$Qc.$lf;elseif(strlen($Ia)+4+strlen($lf)+strlen($Jf)<$ud)$Ia.=",$lf";else{echo$Ia.$Jf;$Ia=$Qc.$lf;}}}if($Ia)echo$Ia.$Jf;}elseif($_POST["format"]=="sql")echo"-- ".str_replace("\n"," ",$e->error)."\n";}}function
  446. dumpFilename($Ic){return
  447. friendly_url($Ic!=""?$Ic:(SERVER!=""?SERVER:"localhost"));}function
  448. dumpHeaders($Ic,$Fd=false){$ne=$_POST["output"];$fc=(preg_match('~sql~',$_POST["format"])?"sql":($Fd?"tar":"csv"));header("Content-Type: ".($ne=="gz"?"application/x-gzip":($fc=="tar"?"application/x-tar":($fc=="sql"||$ne!="file"?"text/plain":"text/csv")."; charset=utf-8")));if($ne=="gz")ob_start('ob_gzencode',1e6);return$fc;}function
  449. homepage(){echo'<p class="links">'.(empty($_GET["ns"])&&support("database")?'<a href="'.h(ME).'database=">'.'Alter database'."</a>\n":""),(support("scheme")?"<a href='".h(ME)."scheme='>".(!empty($_GET["ns"])?'Alter schema':'Create schema')."</a>\n":""),(!empty($_GET["ns"])?'<a href="'.h(ME).'schema=">'.'Database schema'."</a>\n":""),(support("privileges")?"<a href='".h(ME)."privileges='>".'Privileges'."</a>\n":"");return
  450. true;}function
  451. navigation($Ed){global$ga,$x,$Db,$e;echo'<h1>
  452. ',$this->name(),' <span class="version">',$ga,'</span>
  453. <a href="http://www.adminer.org/#download" target="_blank" id="version">',(version_compare($ga,$_COOKIE["adminer_version"])<0?h($_COOKIE["adminer_version"]):""),'</a>
  454. </h1>
  455. ';if($Ed=="auth"){$oc=true;foreach((array)$_SESSION["pwds"]as$Ig=>$vf){foreach($vf
  456. as$O=>$Eg){foreach($Eg
  457. as$V=>$G){if($G!==null){if($oc){echo"<p id='logins' onmouseover='menuOver(this, event);' onmouseout='menuOut(this);'>\n";$oc=false;}$tb=$_SESSION["db"][$Ig][$O][$V];foreach(($tb?array_keys($tb):array(""))as$h)echo"<a href='".h(auth_url($Ig,$O,$V,$h))."'>($Db[$Ig]) ".h($V.($O!=""?"@$O":"").($h!=""?" - $h":""))."</a><br>\n";}}}}}else{if((isset($_GET["ns"])?$_GET["ns"]:null)!==""&&!$Ed&&DB!=""){$e->select_db(DB);$S=table_status('',true);}if(support("sql")){echo'<script type="text/javascript" src="',h(preg_replace("~\\?.*~","",ME))."?file=jush.js&amp;version=4.1.0&amp;driver=mysql",'"></script>
  458. <script type="text/javascript">
  459. ';if($S){$pd=array();foreach($S
  460. as$Q=>$U)$pd[]=preg_quote($Q,'/');echo"var jushLinks = { $x: [ '".js_escape(ME).(support("table")?"table=":"select=")."\$&', /\\b(".implode("|",$pd).")\\b/g ] };\n";foreach(array("bac","bra","sqlite_quo","mssql_bra")as$X)echo"jushLinks.$X = jushLinks.$x;\n";}echo'bodyLoad(\'',(is_object($e)?substr($e->server_info,0,3):""),'\');
  461. </script>
  462. ';}$this->databasesPrint($Ed);if(DB==""||!$Ed){echo"<p class='links'>".(support("sql")?"<a href='".h(ME)."sql='".bold(isset($_GET["sql"])&&!isset($_GET["import"])).">".'SQL command'."</a>\n<a href='".h(ME)."import='".bold(isset($_GET["import"])).">".'Import'."</a>\n":"")."";if(support("dump"))echo"<a href='".h(ME)."dump=".urlencode(isset($_GET["table"])?$_GET["table"]:$_GET["select"])."' id='dump'".bold(isset($_GET["dump"])).">".'Dump'."</a>\n";}if((isset($_GET["ns"])?$_GET["ns"]:null)!==""&&!$Ed&&DB!=""){echo'<a href="'.h(ME).'create="'.bold((isset($_GET["create"])?$_GET["create"]:null)==="").">".'Create table'."</a>\n";if(!$S)echo"<p class='message'>".'No tables.'."\n";else$this->tablesPrint($S);}}}function
  463. databasesPrint($Ed){global$b,$e;$g=$this->databases();echo'<form action="">
  464. <p id="dbs">
  465. ';hidden_fields_get();$rb=" onmousedown='dbMouseDown(event, this);' onchange='dbChange(this);'";echo"<span title='".'database'."'>DB</span>: ".($g?"<select name='db'$rb>".optionlist(array(""=>"")+$g,DB)."</select>":'<input name="db" value="'.h(DB).'" autocapitalize="off">'),"<input type='submit' value='".'Use'."'".($g?" class='hidden'":"").">\n";if($Ed!="db"&&DB!=""&&$e->select_db(DB)){}echo(isset($_GET["sql"])?'<input type="hidden" name="sql" value="">':(isset($_GET["schema"])?'<input type="hidden" name="schema" value="">':(isset($_GET["dump"])?'<input type="hidden" name="dump" value="">':(isset($_GET["privileges"])?'<input type="hidden" name="privileges" value="">':"")))),"</p></form>\n";}function
  466. tablesPrint($S){echo"<p id='tables' onmouseover='menuOver(this, event);' onmouseout='menuOut(this);'>\n";foreach($S
  467. as$Q=>$Cf){echo'<a href="'.h(ME).'select='.urlencode($Q).'"'.bold((isset($_GET["select"])?$_GET["select"]:null)==$Q||(isset($_GET["edit"])?$_GET["edit"]:null)==$Q).">".'select'."</a> ";$E=$this->tableName($Cf);echo(support("table")||support("indexes")?'<a href="'.h(ME).'table='.urlencode($Q).'"'.bold(in_array($Q,array(isset($_GET["table"])?$_GET["table"]:null,isset($_GET["create"])?$_GET["create"]:null,isset($_GET["indexes"])?$_GET["indexes"]:null,isset($_GET["foreign"])?$_GET["foreign"]:null,isset($_GET["trigger"])?$_GET["trigger"]:null)),(is_view($Cf)?"view":""))." title='".'Show structure'."'>$E</a>":"<span>$E</span>")."<br>\n";}}}$b=(function_exists('adminer_object')?adminer_object():new
  468. Adminer);if($b->operators===null)$b->operators=$ae;function
  469. page_header($dg,$j="",$Ha=array(),$eg=""){global$ca,$ga,$b,$Db,$x;page_headers();$fg=$dg.($eg!=""?": $eg":"");$gg=strip_tags($fg.(SERVER!=""&&SERVER!="localhost"?h(" - ".SERVER):"")." - ".$b->name());echo'<!DOCTYPE html>
  470. <html lang="en" dir="ltr">
  471. <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  472. <meta http-equiv="Content-Script-Type" content="text/javascript">
  473. <meta name="robots" content="noindex">
  474. <title>',$gg,'</title>
  475. <link rel="stylesheet" type="text/css" href="',h(preg_replace("~\\?.*~","",ME))."?file=default.css&amp;version=4.1.0&amp;driver=mysql",'">
  476. <script type="text/javascript" src="',h(preg_replace("~\\?.*~","",ME))."?file=functions.js&amp;version=4.1.0&amp;driver=mysql",'"></script>
  477. ';if($b->head()){echo'<link rel="shortcut icon" type="image/x-icon" href="',h(preg_replace("~\\?.*~","",ME))."?file=favicon.ico&amp;version=4.1.0&amp;driver=mysql",'">
  478. <link rel="apple-touch-icon" href="',h(preg_replace("~\\?.*~","",ME))."?file=favicon.ico&amp;version=4.1.0&amp;driver=mysql",'">
  479. ';if(file_exists("adminer.css")){echo'<link rel="stylesheet" type="text/css" href="adminer.css">
  480. ';}}echo'
  481. <body class="ltr nojs" onkeydown="bodyKeydown(event);" onclick="bodyClick(event);"',(isset($_COOKIE["adminer_version"])?"":" onload=\"verifyVersion('$ga');\""),'>
  482. <script type="text/javascript">
  483. document.body.className = document.body.className.replace(/ nojs/, \' js\');
  484. </script>
  485. <div id="help" class="jush-',$x,' jsonly hidden" onmouseover="helpOpen = 1;" onmouseout="helpMouseout(this, event);"></div>
  486. <div id="content">
  487. ';if($Ha!==null){$_=substr(preg_replace('~\b(username|db|ns)=[^&]*&~','',ME),0,-1);echo'<p id="breadcrumb"><a href="'.h($_?$_:".").'">'.$Db[DRIVER].'</a> &raquo; ';$_=substr(preg_replace('~\b(db|ns)=[^&]*&~','',ME),0,-1);$O=(SERVER!=""?h(SERVER):'Server');if($Ha===false)echo"$O\n";else{echo"<a href='".($_?h($_):".")."' accesskey='1' title='Alt+Shift+1'>$O</a> &raquo; ";if(!empty($_GET["ns"])||(DB!=""&&is_array($Ha)))echo'<a href="'.h($_."&db=".urlencode(DB).(support("scheme")?"&ns=":"")).'">'.h(DB).'</a> &raquo; ';if(is_array($Ha)){if(!empty($_GET["ns"]))echo'<a href="'.h(substr(ME,0,-1)).'">'.h($_GET["ns"]).'</a> &raquo; ';foreach($Ha
  488. as$y=>$X){$xb=(is_array($X)?$X[1]:h($X));if($xb!="")echo"<a href='".h(ME."$y=").urlencode(is_array($X)?$X[0]:$X)."'>$xb</a> &raquo; ";}}echo"$dg\n";}}echo"<h2>$fg</h2>\n";restart_session();page_messages($j);$g=get_session("dbs");if(DB!=""&&$g&&!in_array(DB,$g,true))$g=null;stop_session();define("PAGE_HEADER",1);}function
  489. page_headers(){global$b;header("Content-Type: text/html; charset=utf-8");header("Cache-Control: no-cache");if($b->headers()){header("X-Frame-Options: deny");header("X-XSS-Protection: 0");}}function
  490. page_messages($j){$Ag=preg_replace('~^[^?]*~','',$_SERVER["REQUEST_URI"]);$Cd=((isset($_SESSION["messages"]) && isset($_SESSION["messages"][$Ag]))?$_SESSION["messages"][$Ag]:false);if($Cd){echo"<div class='message'>".implode("</div>\n<div class='message'>",$Cd)."</div>\n";unset($_SESSION["messages"][$Ag]);}if($j)echo"<div class='error'>$j</div>\n";}function
  491. page_footer($Ed=""){global$b,$T;echo'</div>
  492. ';if($Ed!="auth"){echo'<form action="" method="post">
  493. <p class="logout">
  494. <input type="submit" name="logout" value="Logout" id="logout">
  495. <input type="hidden" name="token" value="',$T,'">
  496. </p>
  497. </form>
  498. ';}echo'<div id="menu">
  499. ';$b->navigation($Ed);echo'</div>
  500. <script type="text/javascript">setupSubmitHighlight(document);</script>
  501. ';}function
  502. int32($D){while($D>=2147483648)$D-=4294967296;while($D<=-2147483649)$D+=4294967296;return(int)$D;}function
  503. long2str($W,$Mg){$lf='';foreach($W
  504. as$X)$lf.=pack('V',$X);if($Mg)return
  505. substr($lf,0,end($W));return$lf;}function
  506. str2long($lf,$Mg){$W=array_values(unpack('V*',str_pad($lf,4*ceil(strlen($lf)/4),"\0")));if($Mg)$W[]=strlen($lf);return$W;}function
  507. xxtea_mx($Rg,$Qg,$Kf,$Zc){return
  508. int32((($Rg>>5&0x7FFFFFF)^$Qg<<2)+(($Qg>>3&0x1FFFFFFF)^$Rg<<4))^int32(($Kf^$Qg)+($Zc^$Rg));}function
  509. encrypt_string($Ef,$y){if($Ef=="")return"";$y=array_values(unpack("V*",pack("H*",md5($y))));$W=str2long($Ef,true);$D=count($W)-1;$Rg=$W[$D];$Qg=$W[0];$H=floor(6+52/($D+1));$Kf=0;while($H-->0){$Kf=int32($Kf+0x9E3779B9);$Jb=$Kf>>2&3;for($oe=0;$oe<$D;$oe++){$Qg=$W[$oe+1];$Gd=xxtea_mx($Rg,$Qg,$Kf,$y[$oe&3^$Jb]);$Rg=int32($W[$oe]+$Gd);$W[$oe]=$Rg;}$Qg=$W[0];$Gd=xxtea_mx($Rg,$Qg,$Kf,$y[$oe&3^$Jb]);$Rg=int32($W[$D]+$Gd);$W[$D]=$Rg;}return
  510. long2str($W,false);}function
  511. decrypt_string($Ef,$y){if($Ef=="")return"";if(!$y)return
  512. false;$y=array_values(unpack("V*",pack("H*",md5($y))));$W=str2long($Ef,false);$D=count($W)-1;$Rg=$W[$D];$Qg=$W[0];$H=floor(6+52/($D+1));$Kf=int32($H*0x9E3779B9);while($Kf){$Jb=$Kf>>2&3;for($oe=$D;$oe>0;$oe--){$Rg=$W[$oe-1];$Gd=xxtea_mx($Rg,$Qg,$Kf,$y[$oe&3^$Jb]);$Qg=int32($W[$oe]-$Gd);$W[$oe]=$Qg;}$Rg=$W[$D];$Gd=xxtea_mx($Rg,$Qg,$Kf,$y[$oe&3^$Jb]);$Qg=int32($W[0]-$Gd);$W[0]=$Qg;$Kf=int32($Kf-0x9E3779B9);}return
  513. long2str($W,true);}$e='';$Dc=$_SESSION["token"];if(!$Dc)$_SESSION["token"]=rand(1,1e6);$T=get_token();$ze=array();if(isset($_COOKIE["adminer_permanent"])?$_COOKIE["adminer_permanent"]:false){foreach(explode(" ",$_COOKIE["adminer_permanent"])as$X){list($y)=explode(":",$X);$ze[$y]=$X;}}function
  514. add_invalid_login(){global$b;$mc=get_temp_dir()."/adminer.invalid";$o=@fopen($mc,"r+");if(!$o){$o=@fopen($mc,"w");if(!$o)return;}flock($o,LOCK_EX);$Tc=unserialize(stream_get_contents($o));$ag=time();if($Tc){foreach($Tc
  515. as$Uc=>$X){if($X[0]<$ag)unset($Tc[$Uc]);}}$Sc=&$Tc[$b->bruteForceKey()];if(!$Sc)$Sc=array($ag+30*60,0);$Sc[1]++;$tf=serialize($Tc);rewind($o);fwrite($o,$tf);ftruncate($o,strlen($tf));flock($o,LOCK_UN);fclose($o);}$xa=(isset($_POST["auth"])?$_POST["auth"]:false);if($xa){$Tc=unserialize(@file_get_contents(get_temp_dir()."/adminer.invalid"));$Sc=$Tc[$b->bruteForceKey()];$Ld=($Sc[1]>30?$Sc[0]-time():0);if($Ld>0)auth_error(lang(array('Too many unsuccessful logins, try again in %d minute.','Too many unsuccessful logins, try again in %d minutes.'),ceil($Ld/60)));session_regenerate_id();$i=$xa["driver"];$O=$xa["server"];$V=$xa["username"];$G=(string)$xa["password"];$h=$xa["db"];set_password($i,$O,$V,$G);$_SESSION["db"][$i][$O][$V][$h]=true;if($xa["permanent"]){$y=base64_encode($i)."-".base64_encode($O)."-".base64_encode($V)."-".base64_encode($h);$Je=$b->permanentLogin(true);$ze[$y]="$y:".base64_encode($Je?encrypt_string($G,$Je):"");cookie("adminer_permanent",implode(" ",$ze));}if(count($_POST)==1||DRIVER!=$i||SERVER!=$O||$_GET["username"]!==$V||DB!=$h)redirect(auth_url($i,$O,$V,$h));}elseif(isset($_POST["logout"])?$_POST["logout"]:false){if($Dc&&!verify_token()){page_header('Logout','Invalid CSRF token. Send the form again.');page_footer("db");exit;}else{foreach(array("pwds","db","dbs","queries")as$y)set_session($y,null);unset_permanent();redirect(substr(preg_replace('~\b(username|db|ns)=[^&]*&~','',ME),0,-1),'Logout successful.');}}elseif($ze&&!$_SESSION["pwds"]){session_regenerate_id();$Je=$b->permanentLogin();foreach($ze
  516. as$y=>$X){list(,$Pa)=explode(":",$X);list($Ig,$O,$V,$h)=array_map('base64_decode',explode("-",$y));set_password($Ig,$O,$V,decrypt_string(base64_decode($Pa),$Je));$_SESSION["db"][$Ig][$O][$V][$h]=true;}}function
  517. unset_permanent(){global$ze;foreach($ze
  518. as$y=>$X){list($Ig,$O,$V,$h)=array_map('base64_decode',explode("-",$y));if($Ig==DRIVER&&$O==SERVER&&$V==$_GET["username"]&&$h==DB)unset($ze[$y]);}cookie("adminer_permanent",implode(" ",$ze));}function
  519. auth_error($j){global$b,$Dc;$wf=session_name();if(!$_COOKIE[$wf]&&$_GET[$wf]&&ini_bool("session.use_only_cookies"))$j='Session support must be enabled.';elseif(isset($_GET["username"])){if(($_COOKIE[$wf]||$_GET[$wf])&&!$Dc)$j='Session expired, please login again.';else{add_invalid_login();$G=get_password();if($G!==null){if($G===false)$j.='<br>'.sprintf('Master password expired. <a href="http://www.adminer.org/en/extension/" target="_blank">Implement</a> %s method to make it permanent.','<code>permanentLogin()</code>');set_password(DRIVER,SERVER,$_GET["username"],null);}unset_permanent();}}$qe=session_get_cookie_params();cookie("adminer_key",($_COOKIE["adminer_key"]?$_COOKIE["adminer_key"]:rand_string()),$qe["lifetime"]);page_header('Login',$j,null);echo"<form action='' method='post'>\n";$b->loginForm();echo"<div>";hidden_fields($_POST,array("auth"));echo"</div>\n","</form>\n";page_footer("auth");exit;}if(isset($_GET["username"])){if(!class_exists("Min_DB")){unset($_SESSION["pwds"][DRIVER]);unset_permanent();page_header('No extension',sprintf('None of the supported PHP extensions (%s) are available.',implode(", ",$Ee)),false);page_footer("auth");exit;}$e=connect();}$i=new
  520. Min_Driver($e);if(!is_object($e)||!$b->login($_GET["username"],get_password()))auth_error((is_string($e)?$e:'Invalid credentials.'));if($xa&&$_POST["token"])$_POST["token"]=$T;$j='';if($_POST){if(!verify_token()){$Nc="max_input_vars";$yd=ini_get($Nc);if(extension_loaded("suhosin")){foreach(array("suhosin.request.max_vars","suhosin.post.max_vars")as$y){$X=ini_get($y);if($X&&(!$yd||$X<$yd)){$Nc=$y;$yd=$X;}}}$j=(!$_POST["token"]&&$yd?sprintf('Maximum number of allowed fields exceeded. Please increase %s.',"'$Nc'"):'Invalid CSRF token. Send the form again.');}}elseif($_SERVER["REQUEST_METHOD"]=="POST"){$j=sprintf('Too big POST data. Reduce the data or increase the %s configuration directive.',"'post_max_size'");if(isset($_GET["sql"]))$j.=' '.'You can upload a big SQL file via FTP and import it from server.';}if(!ini_bool("session.use_cookies")||@ini_set("session.use_cookies",false)!==false)session_write_close();function
  521. select($J,$f=null,$he=array()){global$x;$pd=array();$v=array();$d=array();$Fa=array();$sg=array();$K=array();odd('');for($s=0;$L=$J->fetch_row();$s++){if(!$s){echo"<table cellspacing='0' class='nowrap'>\n","<thead><tr>";for($w=0;$w<count($L);$w++){$k=$J->fetch_field();$E=$k->name;$ge=$k->orgtable;$fe=$k->orgname;$K[$k->table]=$ge;if($he&&$x=="sql")$pd[$w]=($E=="table"?"table=":($E=="possible_keys"?"indexes=":null));elseif($ge!=""){if(!isset($v[$ge])){$v[$ge]=array();foreach(indexes($ge,$f)as$u){if($u["type"]=="PRIMARY"){$v[$ge]=array_flip($u["columns"]);break;}}$d[$ge]=$v[$ge];}if(isset($d[$ge][$fe])){unset($d[$ge][$fe]);$v[$ge][$fe]=$w;$pd[$w]=$ge;}}if($k->charsetnr==63)$Fa[$w]=true;$sg[$w]=$k->type;echo"<th".($ge!=""||$k->name!=$fe?" title='".h(($ge!=""?"$ge.":"").$fe)."'":"").">".h($E).($he?doc_link(array('sql'=>"explain-output.html#explain_".strtolower($E))):"");}echo"</thead>\n";}echo"<tr".odd().">";foreach($L
  522. as$y=>$X){if($X===null)$X="<i>NULL</i>";elseif($Fa[$y]&&!is_utf8($X))$X="<i>".lang(array('%d byte','%d bytes'),strlen($X))."</i>";elseif(!strlen($X))$X="&nbsp;";else{$X=h($X);if($sg[$y]==254)$X="<code>$X</code>";}if(isset($pd[$y])&&!$d[$pd[$y]]){if($he&&$x=="sql"){$Q=$L[array_search("table=",$pd)];$_=$pd[$y].urlencode($he[$Q]!=""?$he[$Q]:$Q);}else{$_="edit=".urlencode($pd[$y]);foreach($v[$pd[$y]]as$Ta=>$w)$_.="&where".urlencode("[".bracket_escape($Ta)."]")."=".urlencode($L[$w]);}$X="<a href='".h(ME.$_)."'>$X</a>";}echo"<td>$X";}}echo($s?"</table>":"<p class='message'>".'No rows.')."\n";return$K;}function
  523. referencable_primary($rf){$K=array();foreach(table_status('',true)as$Of=>$Q){if($Of!=$rf&&fk_support($Q)){foreach(fields($Of)as$k){if($k["primary"]){if($K[$Of]){unset($K[$Of]);break;}$K[$Of]=$k;}}}}return$K;}function
  524. textarea($E,$Y,$M=10,$Xa=80){global$x;echo"<textarea name='$E' rows='$M' cols='$Xa' class='sqlarea jush-$x' spellcheck='false' wrap='off'>";if(is_array($Y)){foreach($Y
  525. as$X)echo
  526. h($X[0])."\n\n\n";}else
  527. echo
  528. h($Y);echo"</textarea>";}function
  529. edit_type($y,$k,$Wa,$n=array()){global$Gf,$sg,$zg,$Wd;$U=$k["type"];echo'<td><select name="',$y,'[type]" class="type" onfocus="lastType = selectValue(this);" onchange="editingTypeChange(this);"',on_help("getTarget(event).value",1),'>';if($U&&!isset($sg[$U])&&!isset($n[$U]))array_unshift($Gf,$U);if($n)$Gf['Foreign keys']=$n;echo
  530. optionlist($Gf,$U),'</select>
  531. <td><input name="',$y,'[length]" value="',h($k["length"]),'" size="3" onfocus="editingLengthFocus(this);"',(!$k["length"]&&preg_match('~var(char|binary)$~',$U)?" class='required'":""),' onchange="editingLengthChange(this);" onkeyup="this.onchange();"><td class="options">';echo"<select name='$y"."[collation]'".(preg_match('~(char|text|enum|set)$~',$U)?"":" class='hidden'").'><option value="">('.'collation'.')'.optionlist($Wa,$k["collation"]).'</select>',($zg?"<select name='$y"."[unsigned]'".(!$U||preg_match('~((^|[^o])int|float|double|decimal)$~',$U)?"":" class='hidden'").'><option>'.optionlist($zg,$k["unsigned"]).'</select>':''),(isset($k['on_update'])?"<select name='$y"."[on_update]'".(preg_match('~timestamp|datetime~',$U)?"":" class='hidden'").'>'.optionlist(array(""=>"(".'ON UPDATE'.")","CURRENT_TIMESTAMP"),$k["on_update"]).'</select>':''),($n?"<select name='$y"."[on_delete]'".(preg_match("~`~",$U)?"":" class='hidden'")."><option value=''>(".'ON DELETE'.")".optionlist(explode("|",$Wd),$k["on_delete"])."</select> ":" ");}function
  532. process_length($ld){global$Ub;return(preg_match("~^\\s*\\(?\\s*$Ub(?:\\s*,\\s*$Ub)*+\\s*\\)?\\s*\$~",$ld)&&preg_match_all("~$Ub~",$ld,$sd)?"(".implode(",",$sd[0]).")":preg_replace('~^[0-9].*~','(\0)',preg_replace('~[^-0-9,+()[\]]~','',$ld)));}function
  533. process_type($k,$Ua="COLLATE"){global$zg;return" $k[type]".process_length($k["length"]).(preg_match('~(^|[^o])int|float|double|decimal~',$k["type"])&&in_array($k["unsigned"],$zg)?" $k[unsigned]":"").(preg_match('~char|text|enum|set~',$k["type"])&&$k["collation"]?" $Ua ".q($k["collation"]):"");}function
  534. process_field($k,$qg){global$x;$vb=$k["default"];return
  535. array(idf_escape(trim($k["field"])),process_type($qg),($k["null"]?" NULL":" NOT NULL"),(isset($vb)?" DEFAULT ".((preg_match('~time~',$k["type"])&&preg_match('~^CURRENT_TIMESTAMP$~i',$vb))||($k["type"]=="bit"&&preg_match("~^([0-9]+|b'[0-1]+')\$~",$vb))||($x=="pgsql"&&preg_match("~^[a-z]+\\(('[^']*')+\\)\$~",$vb))?$vb:q($vb)):""),(preg_match('~timestamp|datetime~',$k["type"])&&$k["on_update"]?" ON UPDATE $k[on_update]":""),(support("comment")&&$k["comment"]!=""?" COMMENT ".q($k["comment"]):""),($k["auto_increment"]?auto_increment():null),);}function
  536. type_class($U){foreach(array('char'=>'text','date'=>'time|year','binary'=>'blob','enum'=>'set',)as$y=>$X){if(preg_match("~$y|$X~",$U))return" class='$y'";}}function
  537. edit_fields($l,$Wa,$U="TABLE",$n=array(),$bb=false){global$e,$Oc;echo'<thead><tr class="wrap">
  538. ';if($U=="PROCEDURE"){echo'<td>&nbsp;';}echo'<th>',($U=="TABLE"?'Column name':'Parameter name'),'<td>Type<textarea id="enum-edit" rows="4" cols="12" wrap="off" style="display: none;" onblur="editingLengthBlur(this);"></textarea>
  539. <td>Length
  540. <td>Options
  541. ';if($U=="TABLE"){echo'<td>NULL
  542. <td><input type="radio" name="auto_increment_col" value=""><acronym title="Auto Increment">AI</acronym>',doc_link(array('sql'=>"example-auto-increment.html",'sqlite'=>"autoinc.html",'pgsql'=>"datatype.html#DATATYPE-SERIAL",'mssql'=>"ms186775.aspx",)),'<td>Default values
  543. ',(support("comment")?"<td".($bb?"":" class='hidden'").">".'Comment':"");}echo'<td>',"<input type='image' class='icon' name='add[".(support("move_col")?0:count($l))."]' src='".h(preg_replace("~\\?.*~","",ME))."?file=plus.gif&amp;version=4.1.0&amp;driver=mysql' alt='+' title='".'Add next'."'>",'<script type="text/javascript">row_count = ',count($l),';</script>
  544. </thead>
  545. <tbody onkeydown="return editingKeydown(event);">
  546. ';foreach($l
  547. as$s=>$k){$s++;$ie=$k[($_POST?"orig":"field")];$Ab=(isset($_POST["add"][$s-1])||(isset($k["field"])&&!$_POST["drop_col"][$s]))&&(support("drop_col")||$ie=="");echo'<tr',($Ab?"":" style='display: none;'"),'>
  548. ',($U=="PROCEDURE"?"<td>".html_select("fields[$s][inout]",explode("|",$Oc),$k["inout"]):""),'<th>';if($Ab){echo'<input name="fields[',$s,'][field]" value="',h($k["field"]),'" onchange="editingNameChange(this);',($k["field"]!=""||count($l)>1?'':' editingAddRow(this);" onkeyup="if (this.value) editingAddRow(this);'),'" maxlength="64" autocapitalize="off">';}echo'<input type="hidden" name="fields[',$s,'][orig]" value="',h($ie),'">
  549. ';edit_type("fields[$s]",$k,$Wa,$n);if($U=="TABLE"){echo'<td>',checkbox("fields[$s][null]",1,$k["null"],"","","block"),'<td><label class="block"><input type="radio" name="auto_increment_col" value="',$s,'"';if($k["auto_increment"]){echo' checked';}?> onclick="var field = this.form['fields[' + this.value + '][field]']; if (!field.value) { field.value = 'id'; field.onchange(); }"></label><td><?php
  550. echo
  551. checkbox("fields[$s][has_default]",1,$k["has_default"]),'<input name="fields[',$s,'][default]" value="',h($k["default"]),'" onkeyup="keyupChange.call(this);" onchange="this.previousSibling.checked = true;">
  552. ',(support("comment")?"<td".($bb?"":" class='hidden'")."><input name='fields[$s][comment]' value='".h($k["comment"])."' maxlength='".($e->server_info>=5.5?1024:255)."'>":"");}echo"<td>",(support("move_col")?"<input type='image' class='icon' name='add[$s]' src='".h(preg_replace("~\\?.*~","",ME))."?file=plus.gif&amp;version=4.1.0&amp;driver=mysql' alt='+' title='".'Add next'."' onclick='return !editingAddRow(this, 1);'>&nbsp;"."<input type='image' class='icon' name='up[$s]' src='".h(preg_replace("~\\?.*~","",ME))."?file=up.gif&amp;version=4.1.0&amp;driver=mysql' alt='^' title='".'Move up'."'>&nbsp;"."<input type='image' class='icon' name='down[$s]' src='".h(preg_replace("~\\?.*~","",ME))."?file=down.gif&amp;version=4.1.0&amp;driver=mysql' alt='v' title='".'Move down'."'>&nbsp;":""),($ie==""||support("drop_col")?"<input type='image' class='icon' name='drop_col[$s]' src='".h(preg_replace("~\\?.*~","",ME))."?file=cross.gif&amp;version=4.1.0&amp;driver=mysql' alt='x' title='".'Remove'."' onclick=\"return !editingRemoveRow(this, 'fields\$1[field]');\">":""),"\n";}}function
  553. process_fields(&$l){ksort($l);$Pd=0;if($_POST["up"]){$fd=0;foreach($l
  554. as$y=>$k){if(key($_POST["up"])==$y){unset($l[$y]);array_splice($l,$fd,0,array($k));break;}if(isset($k["field"]))$fd=$Pd;$Pd++;}}elseif($_POST["down"]){$tc=false;foreach($l
  555. as$y=>$k){if(isset($k["field"])&&$tc){unset($l[key($_POST["down"])]);array_splice($l,$Pd,0,array($tc));break;}if(key($_POST["down"])==$y)$tc=$k;$Pd++;}}elseif($_POST["add"]){$l=array_values($l);array_splice($l,key($_POST["add"]),0,array(array()));}elseif(!$_POST["drop_col"])return
  556. false;return
  557. true;}function
  558. normalize_enum($B){return"'".str_replace("'","''",addcslashes(stripcslashes(str_replace($B[0][0].$B[0][0],$B[0][0],substr($B[0],1,-1))),'\\'))."'";}function
  559. grant($q,$Le,$d,$Vd){if(!$Le)return
  560. true;if($Le==array("ALL PRIVILEGES","GRANT OPTION"))return($q=="GRANT"?queries("$q ALL PRIVILEGES$Vd WITH GRANT OPTION"):queries("$q ALL PRIVILEGES$Vd")&&queries("$q GRANT OPTION$Vd"));return
  561. queries("$q ".preg_replace('~(GRANT OPTION)\\([^)]*\\)~','\\1',implode("$d, ",$Le).$d).$Vd);}function
  562. drop_create($Eb,$jb,$Fb,$Xf,$Gb,$A,$Bd,$_d,$Ad,$Sd,$Jd){if($_POST["drop"])query_redirect($Eb,$A,$Bd);elseif($Sd=="")query_redirect($jb,$A,$Ad);elseif($Sd!=$Jd){$lb=queries($jb);queries_redirect($A,$_d,$lb&&queries($Eb));if($lb)queries($Fb);}else
  563. queries_redirect($A,$_d,queries($Xf)&&queries($Gb)&&queries($Eb)&&queries($jb));}function
  564. create_trigger($Vd,$L){global$x;$cg=" $L[Timing] $L[Event]".($L["Event"]=="UPDATE OF"?" ".idf_escape($L["Of"]):"");return"CREATE TRIGGER ".idf_escape($L["Trigger"]).($x=="mssql"?$Vd.$cg:$cg.$Vd).rtrim(" $L[Type]\n$L[Statement]",";").";";}function
  565. create_routine($if,$L){global$Oc;$P=array();$l=(array)$L["fields"];ksort($l);foreach($l
  566. as$k){if($k["field"]!="")$P[]=(preg_match("~^($Oc)\$~",$k["inout"])?"$k[inout] ":"").idf_escape($k["field"]).process_type($k,"CHARACTER SET");}return"CREATE $if ".idf_escape(trim($L["name"]))." (".implode(", ",$P).")".(isset($_GET["function"])?" RETURNS".process_type($L["returns"],"CHARACTER SET"):"").($L["language"]?" LANGUAGE $L[language]":"").rtrim("\n$L[definition]",";").";";}function
  567. remove_definer($I){return
  568. preg_replace('~^([A-Z =]+) DEFINER=`'.preg_replace('~@(.*)~','`@`(%|\\1)',logged_user()).'`~','\\1',$I);}function
  569. format_foreign_key($m){global$Wd;return" FOREIGN KEY (".implode(", ",array_map('idf_escape',$m["source"])).") REFERENCES ".table($m["table"])." (".implode(", ",array_map('idf_escape',$m["target"])).")".(preg_match("~^($Wd)\$~",$m["on_delete"])?" ON DELETE $m[on_delete]":"").(preg_match("~^($Wd)\$~",$m["on_update"])?" ON UPDATE $m[on_update]":"");}function
  570. tar_file($mc,$hg){$K=pack("a100a8a8a8a12a12",$mc,644,0,0,decoct($hg->size),decoct(time()));$Oa=8*32;for($s=0;$s<strlen($K);$s++)$Oa+=ord($K[$s]);$K.=sprintf("%06o",$Oa)."\0 ";echo$K,str_repeat("\0",512-strlen($K));$hg->send();echo
  571. str_repeat("\0",511-($hg->size+511)%512);}function
  572. ini_bytes($Nc){$X=ini_get($Nc);switch(strtolower(substr($X,-1))){case'g':$X*=1024;case'm':$X*=1024;case'k':$X*=1024;}return$X;}function
  573. doc_link($xe){global$x,$e;$Bg=array('sql'=>"http://dev.mysql.com/doc/refman/".substr($e->server_info,0,3)."/en/",'sqlite'=>"http://www.sqlite.org/",'pgsql'=>"http://www.postgresql.org/docs/".substr($e->server_info,0,3)."/static/",'mssql'=>"http://msdn.microsoft.com/library/",'oracle'=>"http://download.oracle.com/docs/cd/B19306_01/server.102/b14200/",);return($xe[$x]?"<a href='$Bg[$x]$xe[$x]' target='_blank' rel='noreferrer'><sup>?</sup></a>":"");}function
  574. ob_gzencode($Ff){return
  575. gzencode($Ff);}function
  576. db_size($h){global$e;if(!$e->select_db($h))return"?";$K=0;foreach(table_status()as$R)$K+=$R["Data_length"]+$R["Index_length"];return
  577. format_number($K);}function
  578. connect_error(){global$b,$e,$T,$j,$Db;if(DB!=""){header("HTTP/1.1 404 Not Found");page_header('Database'.": ".h(DB),'Invalid database.',true);}else{if($_POST["db"]&&!$j)queries_redirect(substr(ME,0,-1),'Databases have been dropped.',drop_databases($_POST["db"]));page_header('Select database',$j,false);echo"<p class='links'>\n";foreach(array('database'=>'Create new database','privileges'=>'Privileges','processlist'=>'Process list','variables'=>'Variables','status'=>'Status',)as$y=>$X){if(support($y))echo"<a href='".h(ME)."$y='>$X</a>\n";}echo"<p>".sprintf('%s version: %s through PHP extension %s',$Db[DRIVER],"<b>".h($e->server_info)."</b>","<b>$e->extension</b>")."\n","<p>".sprintf('Logged as: %s',"<b>".h(logged_user())."</b>")."\n";$g=$b->databases();if($g){$of=support("scheme");$Wa=collations();echo"<form action='' method='post'>\n","<table cellspacing='0' class='checkable' onclick='tableClick(event);' ondblclick='tableClick(event, true);'>\n","<thead><tr>".(support("database")?"<td>&nbsp;":"")."<th>".'Database'." - <a href='".h(ME)."refresh=1'>".'Refresh'."</a>"."<td>".'Collation'."<td>".'Tables'."<td>".'Size'." - <a href='".h(ME)."dbsize=1' onclick=\"return !ajaxSetHtml('".js_escape(ME)."script=connect');\">".'Compute'."</a>"."</thead>\n";$g=($_GET["dbsize"]?count_tables($g):array_flip($g));foreach($g
  579. as$h=>$S){$hf=h(ME)."db=".urlencode($h);echo"<tr".odd().">".(support("database")?"<td>".checkbox("db[]",$h,in_array($h,(array)$_POST["db"])):""),"<th><a href='$hf'>".h($h)."</a>";$Va=nbsp(db_collation($h,$Wa));echo"<td>".(support("database")?"<a href='$hf".($of?"&amp;ns=":"")."&amp;database=' title='".'Alter database'."'>$Va</a>":$Va),"<td align='right'><a href='$hf&amp;schema=' id='tables-".h($h)."' title='".'Database schema'."'>".($_GET["dbsize"]?$S:"?")."</a>","<td align='right' id='size-".h($h)."'>".($_GET["dbsize"]?db_size($h):"?"),"\n";}echo"</table>\n",(support("database")?"<fieldset><legend>".'Selected'." <span id='selected'></span></legend><div>\n"."<input type='hidden' name='all' value='' onclick=\"selectCount('selected', formChecked(this, /^db/));\">\n"."<input type='submit' name='drop' value='".'Drop'."'".confirm().">\n"."</div></fieldset>\n":""),"<script type='text/javascript'>tableCheck();</script>\n","<input type='hidden' name='token' value='$T'>\n","</form>\n";}}page_footer("db");}if(isset($_GET["status"]))$_GET["variables"]=$_GET["status"];if(isset($_GET["import"]))$_GET["sql"]=$_GET["import"];if(!(DB!=""?$e->select_db(DB):isset($_GET["sql"])||isset($_GET["dump"])||isset($_GET["database"])||isset($_GET["processlist"])||isset($_GET["privileges"])||isset($_GET["user"])||isset($_GET["variables"])||$_GET["script"]=="connect"||$_GET["script"]=="kill")){if(DB!=""||$_GET["refresh"]){restart_session();set_session("dbs",null);}connect_error();exit;}$Wd="RESTRICT|NO ACTION|CASCADE|SET NULL|SET DEFAULT";class
  580. TmpFile{var$handler;var$size;function
  581. TmpFile(){$this->handler=tmpfile();}function
  582. write($fb){$this->size+=strlen($fb);fwrite($this->handler,$fb);}function
  583. send(){fseek($this->handler,0);fpassthru($this->handler);fclose($this->handler);}}$Ub="'(?:''|[^'\\\\]|\\\\.)*'";$Oc="IN|OUT|INOUT";if(isset($_GET["select"])&&((isset($_POST["edit"])?$_POST["edit"]:null)||(isset($_POST["clone"])?$_POST["clone"]:null))&&!$_POST["save"])$_GET["edit"]=$_GET["select"];if(isset($_GET["callf"]))$_GET["call"]=$_GET["callf"];if(isset($_GET["function"]))$_GET["procedure"]=$_GET["function"];if(isset($_GET["download"])){$a=$_GET["download"];$l=fields($a);header("Content-Type: application/octet-stream");header("Content-Disposition: attachment; filename=".friendly_url("$a-".implode("_",$_GET["where"])).".".friendly_url($_GET["field"]));$N=array(idf_escape($_GET["field"]));$J=$i->select($a,$N,array(where($_GET,$l)),$N);$L=($J?$J->fetch_row():array());echo$L[0];exit;}elseif(isset($_GET["table"])){$a=$_GET["table"];$l=fields($a);if(!$l)$j=error();$R=table_status1($a,true);page_header(($l&&is_view($R)?'View':'Table').": ".h($a),$j);$b->selectLinks($R);$ab=$R["Comment"];if($ab!="")echo"<p>".'Comment'.": ".h($ab)."\n";if($l){echo"<table cellspacing='0'>\n","<thead><tr><th>".'Column'."<td>".'Type'.(support("comment")?"<td>".'Comment':"")."</thead>\n";foreach($l
  584. as$k){echo"<tr".odd()."><th>".h($k["field"]),"<td title='".h($k["collation"])."'>".h($k["full_type"]).($k["null"]?" <i>NULL</i>":"").($k["auto_increment"]?" <i>".'Auto Increment'."</i>":""),(isset($k["default"])?" [<b>".h($k["default"])."</b>]":""),(support("comment")?"<td>".nbsp($k["comment"]):""),"\n";}echo"</table>\n";}if(!is_view($R)){if(support("indexes")){echo"<h3 id='indexes'>".'Indexes'."</h3>\n";$v=indexes($a);if($v){echo"<table cellspacing='0'>\n";foreach($v
  585. as$E=>$u){ksort($u["columns"]);$Ie=array();foreach($u["columns"]as$y=>$X)$Ie[]="<i>".h($X)."</i>".($u["lengths"][$y]?"(".$u["lengths"][$y].")":"").($u["descs"][$y]?" DESC":"");echo"<tr title='".h($E)."'><th>$u[type]<td>".implode(", ",$Ie)."\n";}echo"</table>\n";}echo'<p class="links"><a href="'.h(ME).'indexes='.urlencode($a).'">'.'Alter indexes'."</a>\n";}if(fk_support($R)){echo"<h3 id='foreign-keys'>".'Foreign keys'."</h3>\n";$n=foreign_keys($a);if($n){echo"<table cellspacing='0'>\n","<thead><tr><th>".'Source'."<td>".'Target'."<td>".'ON DELETE'."<td>".'ON UPDATE'."<td>&nbsp;</thead>\n";foreach($n
  586. as$E=>$m){echo"<tr title='".h($E)."'>","<th><i>".implode("</i>, <i>",array_map('h',$m["source"]))."</i>","<td><a href='".h($m["db"]!=""?preg_replace('~db=[^&]*~',"db=".urlencode($m["db"]),ME):($m["ns"]!=""?preg_replace('~ns=[^&]*~',"ns=".urlencode($m["ns"]),ME):ME))."table=".urlencode($m["table"])."'>".($m["db"]!=""?"<b>".h($m["db"])."</b>.":"").($m["ns"]!=""?"<b>".h($m["ns"])."</b>.":"").h($m["table"])."</a>","(<i>".implode("</i>, <i>",array_map('h',$m["target"]))."</i>)","<td>".nbsp($m["on_delete"])."\n","<td>".nbsp($m["on_update"])."\n",'<td><a href="'.h(ME.'foreign='.urlencode($a).'&name='.urlencode($E)).'">'.'Alter'.'</a>';}echo"</table>\n";}echo'<p class="links"><a href="'.h(ME).'foreign='.urlencode($a).'">'.'Add foreign key'."</a>\n";}}if(support(is_view($R)?"view_trigger":"trigger")){echo"<h3 id='triggers'>".'Triggers'."</h3>\n";$pg=triggers($a);if($pg){echo"<table cellspacing='0'>\n";foreach($pg
  587. as$y=>$X)echo"<tr valign='top'><td>".h($X[0])."<td>".h($X[1])."<th>".h($y)."<td><a href='".h(ME.'trigger='.urlencode($a).'&name='.urlencode($y))."'>".'Alter'."</a>\n";echo"</table>\n";}echo'<p class="links"><a href="'.h(ME).'trigger='.urlencode($a).'">'.'Add trigger'."</a>\n";}}elseif(isset($_GET["schema"])){page_header('Database schema',"",array(),h(DB.($_GET["ns"]?".$_GET[ns]":"")));$Pf=array();$Qf=array();$E="adminer_schema";$ea=($_GET["schema"]?$_GET["schema"]:$_COOKIE[($_COOKIE["$E-".DB]?"$E-".DB:$E)]);preg_match_all('~([^:]+):([-0-9.]+)x([-0-9.]+)(_|$)~',$ea,$sd,PREG_SET_ORDER);foreach($sd
  588. as$s=>$B){$Pf[$B[1]]=array($B[2],$B[3]);$Qf[]="\n\t'".js_escape($B[1])."': [ $B[2], $B[3] ]";}$jg=0;$Ca=-1;$nf=array();$Ye=array();$jd=array();foreach(table_status('',true)as$Q=>$R){if(is_view($R))continue;$Be=0;$nf[$Q]["fields"]=array();foreach(fields($Q)as$E=>$k){$Be+=1.25;$k["pos"]=$Be;$nf[$Q]["fields"][$E]=$k;}$nf[$Q]["pos"]=($Pf[$Q]?$Pf[$Q]:array($jg,0));foreach($b->foreignKeys($Q)as$X){if(!$X["db"]){$hd=$Ca;if($Pf[$Q][1]||$Pf[$X["table"]][1])$hd=min(floatval($Pf[$Q][1]),floatval($Pf[$X["table"]][1]))-1;else$Ca-=.1;while($jd[(string)$hd])$hd-=.0001;$nf[$Q]["references"][$X["table"]][(string)$hd]=array($X["source"],$X["target"]);$Ye[$X["table"]][$Q][(string)$hd]=$X["target"];$jd[(string)$hd]=true;}}$jg=max($jg,$nf[$Q]["pos"][0]+2.5+$Be);}echo'<div id="schema" style="height: ',$jg,'em;" onselectstart="return false;">
  589. <script type="text/javascript">
  590. var tablePos = {',implode(",",$Qf)."\n",'};
  591. var em = document.getElementById(\'schema\').offsetHeight / ',$jg,';
  592. document.onmousemove = schemaMousemove;
  593. document.onmouseup = function (ev) {
  594. schemaMouseup(ev, \'',js_escape(DB),'\');
  595. };
  596. </script>
  597. ';foreach($nf
  598. as$E=>$Q){echo"<div class='table' style='top: ".$Q["pos"][0]."em; left: ".$Q["pos"][1]."em;' onmousedown='schemaMousedown(this, event);'>",'<a href="'.h(ME).'table='.urlencode($E).'"><b>'.h($E)."</b></a>";foreach($Q["fields"]as$k){$X='<span'.type_class($k["type"]).' title="'.h($k["full_type"].($k["null"]?" NULL":'')).'">'.h($k["field"]).'</span>';echo"<br>".($k["primary"]?"<i>$X</i>":$X);}foreach((array)$Q["references"]as$Vf=>$Ze){foreach($Ze
  599. as$hd=>$Ve){$id=$hd-$Pf[$E][1];$s=0;foreach($Ve[0]as$zf)echo"\n<div class='references' title='".h($Vf)."' id='refs$hd-".($s++)."' style='left: $id"."em; top: ".$Q["fields"][$zf]["pos"]."em; padding-top: .5em;'><div style='border-top: 1px solid Gray; width: ".(-$id)."em;'></div></div>";}}foreach((array)$Ye[$E]as$Vf=>$Ze){foreach($Ze
  600. as$hd=>$d){$id=$hd-$Pf[$E][1];$s=0;foreach($d
  601. as$Uf)echo"\n<div class='references' title='".h($Vf)."' id='refd$hd-".($s++)."' style='left: $id"."em; top: ".$Q["fields"][$Uf]["pos"]."em; height: 1.25em; background: url(".h(preg_replace("~\\?.*~","",ME))."?file=arrow.gif) no-repeat right center;&amp;version=4.1.0&amp;driver=mysql'><div style='height: .5em; border-bottom: 1px solid Gray; width: ".(-$id)."em;'></div></div>";}}echo"\n</div>\n";}foreach($nf
  602. as$E=>$Q){foreach((array)$Q["references"]as$Vf=>$Ze){foreach($Ze
  603. as$hd=>$Ve){$Dd=$jg;$wd=-10;foreach($Ve[0]as$y=>$zf){$Ce=$Q["pos"][0]+$Q["fields"][$zf]["pos"];$De=$nf[$Vf]["pos"][0]+$nf[$Vf]["fields"][$Ve[1][$y]]["pos"];$Dd=min($Dd,$Ce,$De);$wd=max($wd,$Ce,$De);}echo"<div class='references' id='refl$hd' style='left: $hd"."em; top: $Dd"."em; padding: .5em 0;'><div style='border-right: 1px solid Gray; margin-top: 1px; height: ".($wd-$Dd)."em;'></div></div>\n";}}}echo'</div>
  604. <p class="links"><a href="',h(ME."schema=".urlencode($ea)),'" id="schema-link">Permanent link</a>
  605. ';}elseif(isset($_GET["dump"])){$a=$_GET["dump"];if($_POST&&!$j){$ib="";foreach(array("output","format","db_style","routines","events","table_style","auto_increment","triggers","data_style")as$y)$ib.="&$y=".urlencode($_POST[$y]);cookie("adminer_export",substr($ib,1));$S=array_flip((array)$_POST["tables"])+array_flip((array)$_POST["data"]);$fc=dump_headers((count($S)==1?key($S):DB),(DB==""||count($S)>1));$Wc=preg_match('~sql~',$_POST["format"]);if($Wc){echo"-- Adminer $ga ".$Db[DRIVER]." dump\n\n";if($x=="sql"){echo"SET NAMES utf8;
  606. SET time_zone = '+00:00';
  607. ".($_POST["data_style"]?"SET foreign_key_checks = 0;
  608. SET sql_mode = 'NO_AUTO_VALUE_ON_ZERO';
  609. ":"")."
  610. ";$e->query("SET time_zone = '+00:00';");}}$Hf=$_POST["db_style"];$g=array(DB);if(DB==""){$g=$_POST["databases"];if(is_string($g))$g=explode("\n",rtrim(str_replace("\r","",$g),"\n"));}foreach((array)$g
  611. as$h){$b->dumpDatabase($h);if($e->select_db($h)){if($Wc&&preg_match('~CREATE~',$Hf)&&($jb=$e->result("SHOW CREATE DATABASE ".idf_escape($h),1))){if($Hf=="DROP+CREATE")echo"DROP DATABASE IF EXISTS ".idf_escape($h).";\n";echo"$jb;\n";}if($Wc){if($Hf)echo
  612. use_sql($h).";\n\n";$me="";if($_POST["routines"]){foreach(array("FUNCTION","PROCEDURE")as$if){foreach(get_rows("SHOW $if STATUS WHERE Db = ".q($h),null,"-- ")as$L)$me.=($Hf!='DROP+CREATE'?"DROP $if IF EXISTS ".idf_escape($L["Name"]).";;\n":"").remove_definer($e->result("SHOW CREATE $if ".idf_escape($L["Name"]),2)).";;\n\n";}}if($_POST["events"]){foreach(get_rows("SHOW EVENTS",null,"-- ")as$L)$me.=($Hf!='DROP+CREATE'?"DROP EVENT IF EXISTS ".idf_escape($L["Name"]).";;\n":"").remove_definer($e->result("SHOW CREATE EVENT ".idf_escape($L["Name"]),3)).";;\n\n";}if($me)echo"DELIMITER ;;\n\n$me"."DELIMITER ;\n\n";}if($_POST["table_style"]||$_POST["data_style"]){$Kg=array();foreach(table_status('',true)as$E=>$R){$Q=(DB==""||in_array($E,(array)$_POST["tables"]));$ob=(DB==""||in_array($E,(array)$_POST["data"]));if($Q||$ob){if($fc=="tar"){$hg=new
  613. TmpFile;ob_start(array($hg,'write'),1e5);}$b->dumpTable($E,($Q?$_POST["table_style"]:""),(is_view($R)?2:0));if(is_view($R))$Kg[]=$E;elseif($ob){$l=fields($E);$b->dumpData($E,$_POST["data_style"],"SELECT *".convert_fields($l,$l)." FROM ".table($E));}if($Wc&&$_POST["triggers"]&&$Q&&($pg=trigger_sql($E,$_POST["table_style"])))echo"\nDELIMITER ;;\n$pg\nDELIMITER ;\n";if($fc=="tar"){ob_end_flush();tar_file((DB!=""?"":"$h/")."$E.csv",$hg);}elseif($Wc)echo"\n";}}foreach($Kg
  614. as$Jg)$b->dumpTable($Jg,$_POST["table_style"],1);if($fc=="tar")echo
  615. pack("x512");}}}if($Wc)echo"-- ".$e->result("SELECT NOW()")."\n";exit;}page_header('Export',$j,($_GET["export"]!=""?array("table"=>$_GET["export"]):array()),h(DB));echo'
  616. <form action="" method="post">
  617. <table cellspacing="0">
  618. ';$sb=array('','USE','DROP+CREATE','CREATE');$Rf=array('','DROP+CREATE','CREATE');$pb=array('','TRUNCATE+INSERT','INSERT');if($x=="sql")$pb[]='INSERT+UPDATE';parse_str($_COOKIE["adminer_export"],$L);if(!$L)$L=array("output"=>"text","format"=>"sql","db_style"=>(DB!=""?"":"CREATE"),"table_style"=>"DROP+CREATE","data_style"=>"INSERT");if(!isset($L["events"])){$L["routines"]=$L["events"]=($_GET["dump"]=="");$L["triggers"]=$L["table_style"];}echo"<tr><th>".'Output'."<td>".html_select("output",$b->dumpOutput(),$L["output"],0)."\n";echo"<tr><th>".'Format'."<td>".html_select("format",$b->dumpFormat(),$L["format"],0)."\n";echo($x=="sqlite"?"":"<tr><th>".'Database'."<td>".html_select('db_style',$sb,$L["db_style"]).(support("routine")?checkbox("routines",1,$L["routines"],'Routines'):"").(support("event")?checkbox("events",1,$L["events"],'Events'):"")),"<tr><th>".'Tables'."<td>".html_select('table_style',$Rf,$L["table_style"]).checkbox("auto_increment",1,$L["auto_increment"],'Auto Increment').(support("trigger")?checkbox("triggers",1,$L["triggers"],'Triggers'):""),"<tr><th>".'Data'."<td>".html_select('data_style',$pb,$L["data_style"]),'</table>
  619. <p><input type="submit" value="Export">
  620. <input type="hidden" name="token" value="',$T,'">
  621. <table cellspacing="0">
  622. ';$Ge=array();if(DB!=""){$Ma=($a!=""?"":" checked");echo"<thead><tr>","<th style='text-align: left;'><label class='block'><input type='checkbox' id='check-tables'$Ma onclick='formCheck(this, /^tables\\[/);'>".'Tables'."</label>","<th style='text-align: right;'><label class='block'>".'Data'."<input type='checkbox' id='check-data'$Ma onclick='formCheck(this, /^data\\[/);'></label>","</thead>\n";$Kg="";$Sf=tables_list();foreach($Sf
  623. as$E=>$U){$Fe=preg_replace('~_.*~','',$E);$Ma=($a==""||$a==(substr($a,-1)=="%"?"$Fe%":$E));$Ie="<tr><td>".checkbox("tables[]",$E,$Ma,$E,"checkboxClick(event, this); formUncheck('check-tables');","block");if($U!==null&&!preg_match('~table~i',$U))$Kg.="$Ie\n";else
  624. echo"$Ie<td align='right'><label class='block'><span id='Rows-".h($E)."'></span>".checkbox("data[]",$E,$Ma,"","checkboxClick(event, this); formUncheck('check-data');")."</label>\n";$Ge[$Fe]++;}echo$Kg;if($Sf)echo"<script type='text/javascript'>ajaxSetHtml('".js_escape(ME)."script=db');</script>\n";}else{echo"<thead><tr><th style='text-align: left;'><label class='block'><input type='checkbox' id='check-databases'".($a==""?" checked":"")." onclick='formCheck(this, /^databases\\[/);'>".'Database'."</label></thead>\n";$g=$b->databases();if($g){foreach($g
  625. as$h){if(!information_schema($h)){$Fe=preg_replace('~_.*~','',$h);echo"<tr><td>".checkbox("databases[]",$h,$a==""||$a=="$Fe%",$h,"formUncheck('check-databases');","block")."\n";$Ge[$Fe]++;}}}else
  626. echo"<tr><td><textarea name='databases' rows='10' cols='20'></textarea>";}echo'</table>
  627. </form>
  628. ';$oc=true;foreach($Ge
  629. as$y=>$X){if($y!=""&&$X>1){echo($oc?"<p>":" ")."<a href='".h(ME)."dump=".urlencode("$y%")."'>".h($y)."</a>";$oc=false;}}}elseif(isset($_GET["privileges"])){page_header('Privileges');$J=$e->query("SELECT User, Host FROM mysql.".(DB==""?"user":"db WHERE ".q(DB)." LIKE Db")." ORDER BY Host, User");$q=$J;if(!$J)$J=$e->query("SELECT SUBSTRING_INDEX(CURRENT_USER, '@', 1) AS User, SUBSTRING_INDEX(CURRENT_USER, '@', -1) AS Host");echo"<form action=''><p>\n";hidden_fields_get();echo"<input type='hidden' name='db' value='".h(DB)."'>\n",($q?"":"<input type='hidden' name='grant' value=''>\n"),"<table cellspacing='0'>\n","<thead><tr><th>".'Username'."<th>".'Server'."<th>&nbsp;</thead>\n";while($L=$J->fetch_assoc())echo'<tr'.odd().'><td>'.h($L["User"])."<td>".h($L["Host"]).'<td><a href="'.h(ME.'user='.urlencode($L["User"]).'&host='.urlencode($L["Host"])).'">'.'Edit'."</a>\n";if(!$q||DB!="")echo"<tr".odd()."><td><input name='user' autocapitalize='off'><td><input name='host' value='localhost' autocapitalize='off'><td><input type='submit' value='".'Edit'."'>\n";echo"</table>\n","</form>\n",'<p class="links"><a href="'.h(ME).'user=">'.'Create user'."</a>";}elseif(isset($_GET["sql"])){if(!$j&&$_POST["export"]){dump_headers("sql");$b->dumpTable("","");$b->dumpData("","table",$_POST["query"]);exit;}restart_session();$Fc=&get_session("queries");$Ec=&$Fc[DB];if(!$j&&$_POST["clear"]){$Ec=array();redirect(remove_from_uri("history"));}page_header((isset($_GET["import"])?'Import':'SQL command'),$j);if(!$j&&$_POST){$o=false;if(!isset($_GET["import"]))$I=$_POST["query"];elseif($_POST["webfile"]){$o=@fopen((file_exists("adminer.sql")?"adminer.sql":"compress.zlib://adminer.sql.gz"),"rb");$I=($o?fread($o,1e6):false);}else$I=get_file("sql_file",true);if(is_string($I)){if(function_exists('memory_get_usage'))@ini_set("memory_limit",max(ini_bytes("memory_limit"),2*strlen($I)+memory_get_usage()+8e6));if($I!=""&&strlen($I)<1e6){$H=$I.(preg_match("~;[ \t\r\n]*\$~",$I)?"":";");if(!$Ec||reset(end($Ec))!=$H){restart_session();$Ec[]=array($H,time());set_session("queries",$Fc);stop_session();}}$_f="(?:\\s|/\\*.*\\*/|(?:#|-- )[^\n]*\n|--\r?\n)";$wb=";";$Pd=0;$Rb=true;$f=connect();if(is_object($f)&&DB!="")$f->select_db(DB);$Za=0;$Wb=array();$od=0;$re='[\'"'.($x=="sql"?'`#':($x=="sqlite"?'`[':($x=="mssql"?'[':''))).']|/\\*|-- |$'.($x=="pgsql"?'|\\$[^$]*\\$':'');$kg=microtime(true);parse_str($_COOKIE["adminer_export"],$la);$Ib=$b->dumpFormat();unset($Ib["sql"]);while($I!=""){if(!$Pd&&preg_match("~^$_f*DELIMITER\\s+(\\S+)~i",$I,$B)){$wb=$B[1];$I=substr($I,strlen($B[0]));}else{preg_match('('.preg_quote($wb)."\\s*|$re)",$I,$B,PREG_OFFSET_CAPTURE,$Pd);list($tc,$Be)=$B[0];if(!$tc&&$o&&!feof($o))$I.=fread($o,1e5);else{if(!$tc&&rtrim($I)=="")break;$Pd=$Be+strlen($tc);if($tc&&rtrim($tc)!=$wb){while(preg_match('('.($tc=='/*'?'\\*/':($tc=='['?']':(preg_match('~^-- |^#~',$tc)?"\n":preg_quote($tc)."|\\\\."))).'|$)s',$I,$B,PREG_OFFSET_CAPTURE,$Pd)){$lf=$B[0][0];if(!$lf&&$o&&!feof($o))$I.=fread($o,1e5);else{$Pd=$B[0][1]+strlen($lf);if($lf[0]!="\\")break;}}}else{$Rb=false;$H=substr($I,0,$Be);$Za++;$Ie="<pre id='sql-$Za'><code class='jush-$x'>".shorten_utf8(trim($H),1000)."</code></pre>\n";if(!$_POST["only_errors"]){echo$Ie;ob_flush();flush();}$Bf=microtime(true);if($e->multi_query($H)&&is_object($f)&&preg_match("~^$_f*USE\\b~isU",$H))$f->query($H);do{$J=$e->store_result();$ag=" <span class='time'>(".format_time($Bf).")</span>".(strlen($H)<1000?" <a href='".h(ME)."sql=".urlencode(trim($H))."'>".'Edit'."</a>":"");if($e->error){echo($_POST["only_errors"]?$Ie:""),"<p class='error'>".'Error in query'.($e->errno?" ($e->errno)":"").": ".error()."\n";$Wb[]=" <a href='#sql-$Za'>$Za</a>";if($_POST["error_stops"])break
  630. 2;}elseif(is_object($J)){$he=select($J,$f);if(!$_POST["only_errors"]){echo"<form action='' method='post'>\n","<p>".($J->num_rows?lang(array('%d row','%d rows'),$J->num_rows):"").$ag;$t="export-$Za";$ec=", <a href='#$t' onclick=\"return !toggle('$t');\">".'Export'."</a><span id='$t' class='hidden'>: ".html_select("output",$b->dumpOutput(),$la["output"])." ".html_select("format",$Ib,$la["format"])."<input type='hidden' name='query' value='".h($H)."'>"." <input type='submit' name='export' value='".'Export'."'><input type='hidden' name='token' value='$T'></span>\n";if($f&&preg_match("~^($_f|\\()*SELECT\\b~isU",$H)&&($dc=explain($f,$H))){$t="explain-$Za";echo", <a href='#$t' onclick=\"return !toggle('$t');\">EXPLAIN</a>$ec","<div id='$t' class='hidden'>\n";select($dc,$f,$he);echo"</div>\n";}else
  631. echo$ec;echo"</form>\n";}}else{if(preg_match("~^$_f*(CREATE|DROP|ALTER)$_f+(DATABASE|SCHEMA)\\b~isU",$H)){restart_session();set_session("dbs",null);stop_session();}if(!$_POST["only_errors"])echo"<p class='message' title='".h($e->info)."'>".lang(array('Query executed OK, %d row affected.','Query executed OK, %d rows affected.'),$e->affected_rows)."$ag\n";}$Bf=microtime(true);}while($e->next_result());$od+=substr_count($H.$tc,"\n");$I=substr($I,$Pd);$Pd=0;}}}}if($Rb)echo"<p class='message'>".'No commands to execute.'."\n";elseif($_POST["only_errors"]){echo"<p class='message'>".lang(array('%d query executed OK.','%d queries executed OK.'),$Za-count($Wb))," <span class='time'>(".format_time($kg).")</span>\n";}elseif($Wb&&$Za>1)echo"<p class='error'>".'Error in query'.": ".implode("",$Wb)."\n";}else
  632. echo"<p class='error'>".upload_error($I)."\n";}echo'
  633. <form action="" method="post" enctype="multipart/form-data" id="form">
  634. ';$bc="<input type='submit' value='".'Execute'."' title='Ctrl+Enter'>";if(!isset($_GET["import"])){$H=$_GET["sql"];if($_POST)$H=$_POST["query"];elseif($_GET["history"]=="all")$H=$Ec;elseif($_GET["history"]!="")$H=$Ec[$_GET["history"]][0];echo"<p>";textarea("query",$H,20);echo($_POST?"":"<script type='text/javascript'>focus(document.getElementsByTagName('textarea')[0]);</script>\n"),"<p>$bc\n";}else{echo"<fieldset><legend>".'File upload'."</legend><div>",(ini_bool("file_uploads")?'<input type="file" name="sql_file[]" multiple> (&lt; '.ini_get("upload_max_filesize").'B)':'File uploads are disabled.'),"\n$bc","</div></fieldset>\n","<fieldset><legend>".'From server'."</legend><div>",sprintf('Webserver file %s',"<code>adminer.sql".(extension_loaded("zlib")?"[.gz]":"")."</code>"),' <input type="submit" name="webfile" value="'.'Run file'.'">',"</div></fieldset>\n","<p>";}echo
  635. checkbox("error_stops",1,($_POST?$_POST["error_stops"]:isset($_GET["import"])),'Stop on error')."\n",checkbox("only_errors",1,($_POST?$_POST["only_errors"]:isset($_GET["import"])),'Show only errors')."\n","<input type='hidden' name='token' value='$T'>\n";if(!isset($_GET["import"])&&$Ec){print_fieldset("history",'History',$_GET["history"]!="");for($X=end($Ec);$X;$X=prev($Ec)){$y=key($Ec);list($H,$ag,$Mb)=$X;echo'<a href="'.h(ME."sql=&history=$y").'">'.'Edit'."</a>"." <span class='time' title='".@date('Y-m-d',$ag)."'>".@date("H:i:s",$ag)."</span>"." <code class='jush-$x'>".shorten_utf8(ltrim(str_replace("\n"," ",str_replace("\r","",preg_replace('~^(#|-- ).*~m','',$H)))),80,"</code>").($Mb?" <span class='time'>($Mb)</span>":"")."<br>\n";}echo"<input type='submit' name='clear' value='".'Clear'."'>\n","<a href='".h(ME."sql=&history=all")."'>".'Edit all'."</a>\n","</div></fieldset>\n";}echo'</form>
  636. ';}elseif(isset($_GET["edit"])){$a=$_GET["edit"];$l=fields($a);$Z=(isset($_GET["select"])?(count($_POST["check"])==1?where_check($_POST["check"][0],$l):""):where($_GET,$l));$_g=(isset($_GET["select"])?$_POST["edit"]:$Z);foreach($l
  637. as$E=>$k){if(!isset($k["privileges"][$_g?"update":"insert"])||$b->fieldName($k)=="")unset($l[$E]);}if($_POST&&!$j&&!isset($_GET["select"])){$A=$_POST["referer"];if($_POST["insert"])$A=($_g?null:$_SERVER["REQUEST_URI"]);elseif(!preg_match('~^.+&select=.+$~',$A))$A=ME."select=".urlencode($a);$v=indexes($a);$vg=unique_array($_GET["where"],$v);$Re="\nWHERE $Z";if(isset($_POST["delete"]))queries_redirect($A,'Item has been deleted.',$i->delete($a,$Re,!$vg));else{$P=array();foreach($l
  638. as$E=>$k){$X=process_input($k);if($X!==false&&$X!==null)$P[idf_escape($E)]=$X;}if($_g){if(!$P)redirect($A);queries_redirect($A,'Item has been updated.',$i->update($a,$P,$Re,!$vg));if(is_ajax()){page_headers();page_messages($j);exit;}}else{$J=$i->insert($a,$P);$gd=($J?last_id():0);queries_redirect($A,sprintf('Item%s has been inserted.',($gd?" $gd":"")),$J);}}}$L=null;if($_POST["save"])$L=(array)$_POST["fields"];elseif($Z){$N=array();foreach($l
  639. as$E=>$k){if(isset($k["privileges"]["select"])){$ua=convert_field($k);if(!empty($_POST["clone"])&&!empty($k["auto_increment"]))$ua="''";if($x=="sql"&&preg_match("~enum|set~",$k["type"]))$ua="1*".idf_escape($E);$N[]=($ua?"$ua AS ":"").idf_escape($E);}}$L=array();if(!support("table"))$N=array("*");if($N){$J=$i->select($a,$N,array($Z),$N,array(),(isset($_GET["select"])?2:1));$L=$J->fetch_assoc();if(!$L)$L=false;if(isset($_GET["select"])&&(!$L||$J->fetch_assoc()))$L=null;}}if(!support("table")&&!$l){if(!$Z){$J=$i->select($a,array("*"),$Z,array("*"));$L=($J?$J->fetch_assoc():false);if(!$L)$L=array($i->primary=>"");}if($L){foreach($L
  640. as$y=>$X){if(!$Z)$L[$y]=null;$l[$y]=array("field"=>$y,"null"=>($y!=$i->primary),"auto_increment"=>($y==$i->primary));}}}edit_form($a,$l,$L,$_g);}elseif(isset($_GET["create"])){$a=$_GET["create"];$se=array();foreach(array('HASH','LINEAR HASH','KEY','LINEAR KEY','RANGE','LIST')as$y)$se[$y]=$y;$Xe=referencable_primary($a);$n=array();foreach($Xe
  641. as$Of=>$k)$n[str_replace("`","``",$Of)."`".str_replace("`","``",$k["field"])]=$Of;$ke=array();$R=array();if($a!=""){$ke=fields($a);$R=table_status($a);if(!$R)$j='No tables.';}$L=$_POST;$L["fields"]=(array)$L["fields"];if($L["auto_increment_col"])$L["fields"][$L["auto_increment_col"]]["auto_increment"]=true;if($_POST&&!process_fields($L["fields"])&&!$j){if($_POST["drop"])queries_redirect(substr(ME,0,-1),'Table has been dropped.',drop_tables(array($a)));else{$l=array();$ra=array();$Cg=false;$qc=array();ksort($L["fields"]);$je=reset($ke);$pa=" FIRST";foreach($L["fields"]as$y=>$k){$m=$n[$k["type"]];$qg=($m!==null?$Xe[$m]:$k);if($k["field"]!=""){if(!$k["has_default"])$k["default"]=null;if($y==$L["auto_increment_col"])$k["auto_increment"]=true;$Ne=process_field($k,$qg);$ra[]=array($k["orig"],$Ne,$pa);if($Ne!=process_field($je,$je)){$l[]=array($k["orig"],$Ne,$pa);if($k["orig"]!=""||$pa)$Cg=true;}if($m!==null)$qc[idf_escape($k["field"])]=($a!=""&&$x!="sqlite"?"ADD":" ").format_foreign_key(array('table'=>$n[$k["type"]],'source'=>array($k["field"]),'target'=>array($qg["field"]),'on_delete'=>$k["on_delete"],));$pa=" AFTER ".idf_escape($k["field"]);}elseif($k["orig"]!=""){$Cg=true;$l[]=array($k["orig"]);}if($k["orig"]!=""){$je=next($ke);if(!$je)$pa="";}}$ue="";if($se[$L["partition_by"]]){$ve=array();if($L["partition_by"]=='RANGE'||$L["partition_by"]=='LIST'){foreach(array_filter($L["partition_names"])as$y=>$X){$Y=$L["partition_values"][$y];$ve[]="\n PARTITION ".idf_escape($X)." VALUES ".($L["partition_by"]=='RANGE'?"LESS THAN":"IN").($Y!=""?" ($Y)":" MAXVALUE");}}$ue.="\nPARTITION BY $L[partition_by]($L[partition])".($ve?" (".implode(",",$ve)."\n)":($L["partitions"]?" PARTITIONS ".(+$L["partitions"]):""));}elseif(support("partitioning")&&preg_match("~partitioned~",$R["Create_options"]))$ue.="\nREMOVE PARTITIONING";$C='Table has been altered.';if($a==""){cookie("adminer_engine",$L["Engine"]);$C='Table has been created.';}$E=trim($L["name"]);queries_redirect(ME.(support("table")?"table=":"select=").urlencode($E),$C,alter_table($a,$E,($x=="sqlite"&&($Cg||$qc)?$ra:$l),$qc,$L["Comment"],($L["Engine"]&&$L["Engine"]!=$R["Engine"]?$L["Engine"]:""),($L["Collation"]&&$L["Collation"]!=$R["Collation"]?$L["Collation"]:""),($L["Auto_increment"]!=""?+$L["Auto_increment"]:""),$ue));}}page_header(($a!=""?'Alter table':'Create table'),$j,array("table"=>$a),h($a));if(!$_POST){$L=array("Engine"=>$_COOKIE["adminer_engine"],"fields"=>array(array("field"=>"","type"=>(isset($sg["int"])?"int":(isset($sg["integer"])?"integer":"")))),"partition_names"=>array(""),);if($a!=""){$L=$R;$L["name"]=$a;$L["fields"]=array();if(!$_GET["auto_increment"])$L["Auto_increment"]="";foreach($ke
  642. as$k){$k["has_default"]=isset($k["default"]);$L["fields"][]=$k;}if(support("partitioning")){$vc="FROM information_schema.PARTITIONS WHERE TABLE_SCHEMA = ".q(DB)." AND TABLE_NAME = ".q($a);$J=$e->query("SELECT PARTITION_METHOD, PARTITION_ORDINAL_POSITION, PARTITION_EXPRESSION $vc ORDER BY PARTITION_ORDINAL_POSITION DESC LIMIT 1");list($L["partition_by"],$L["partitions"],$L["partition"])=$J->fetch_row();$ve=get_key_vals("SELECT PARTITION_NAME, PARTITION_DESCRIPTION $vc AND PARTITION_NAME != '' ORDER BY PARTITION_ORDINAL_POSITION");$ve[""]="";$L["partition_names"]=array_keys($ve);$L["partition_values"]=array_values($ve);}}}$Wa=collations();$Tb=engines();foreach($Tb
  643. as$Sb){if(!strcasecmp($Sb,$L["Engine"])){$L["Engine"]=$Sb;break;}}echo'
  644. <form action="" method="post" id="form">
  645. <p>
  646. ';if(support("columns")||$a==""){echo'Table name: <input name="name" maxlength="64" value="',h($L["name"]),'" autocapitalize="off">
  647. ';if($a==""&&!$_POST){?><script type='text/javascript'>focus(document.getElementById('form')['name']);</script><?php }echo($Tb?"<select name='Engine' onchange='helpClose();'".on_help("getTarget(event).value",1).">".optionlist(array(""=>"(".'engine'.")")+$Tb,$L["Engine"])."</select>":""),' ',($Wa&&!preg_match("~sqlite|mssql~",$x)?html_select("Collation",array(""=>"(".'collation'.")")+$Wa,$L["Collation"]):""),' <input type="submit" value="Save">
  648. ';}echo'
  649. ';if(support("columns")){echo'<table cellspacing="0" id="edit-fields" class="nowrap">
  650. ';$bb=($_POST?$_POST["comments"]:$L["Comment"]!="");if(!$_POST&&!$bb){foreach($L["fields"]as$k){if($k["comment"]!=""){$bb=true;break;}}}edit_fields($L["fields"],$Wa,"TABLE",$n,$bb);echo'</table>
  651. <p>
  652. Auto Increment: <input type="number" name="Auto_increment" size="6" value="',h($L["Auto_increment"]),'">
  653. ',checkbox("defaults",1,true,'Default values',"columnShow(this.checked, 5)","jsonly");if(!$_POST["defaults"]){echo'<script type="text/javascript">editingHideDefaults()</script>';}echo(support("comment")?"<label><input type='checkbox' name='comments' value='1' class='jsonly' onclick=\"columnShow(this.checked, 6); toggle('Comment'); if (this.checked) this.form['Comment'].focus();\"".($bb?" checked":"").">".'Comment'."</label>".' <input name="Comment" id="Comment" value="'.h($L["Comment"]).'" maxlength="'.($e->server_info>=5.5?2048:60).'"'.($bb?'':' class="hidden"').'>':''),'<p>
  654. <input type="submit" value="Save">
  655. ';}echo'
  656. ';if($a!=""){echo'<input type="submit" name="drop" value="Drop"',confirm(),'>';}if(support("partitioning")){$te=preg_match('~RANGE|LIST~',$L["partition_by"]);print_fieldset("partition",'Partition by',$L["partition_by"]);echo'<p>
  657. ',"<select name='partition_by' onchange='partitionByChange(this);'".on_help("getTarget(event).value.replace(/./, 'PARTITION BY \$&')",1).">".optionlist(array(""=>"")+$se,$L["partition_by"])."</select>",'(<input name="partition" value="',h($L["partition"]),'">)
  658. Partitions: <input type="number" name="partitions" class="size',($te||!$L["partition_by"]?" hidden":""),'" value="',h($L["partitions"]),'">
  659. <table cellspacing="0" id="partition-table"',($te?"":" class='hidden'"),'>
  660. <thead><tr><th>Partition name<th>Values</thead>
  661. ';foreach($L["partition_names"]as$y=>$X){echo'<tr>','<td><input name="partition_names[]" value="'.h($X).'"'.($y==count($L["partition_names"])-1?' onchange="partitionNameChange(this);"':'').' autocapitalize="off">','<td><input name="partition_values[]" value="'.h($L["partition_values"][$y]).'">';}echo'</table>
  662. </div></fieldset>
  663. ';}echo'<input type="hidden" name="token" value="',$T,'">
  664. </form>
  665. ';}elseif(isset($_GET["indexes"])){$a=$_GET["indexes"];$Mc=array("PRIMARY","UNIQUE","INDEX");$R=table_status($a,true);if(preg_match('~MyISAM|M?aria'.($e->server_info>=5.6?'|InnoDB':'').'~i',$R["Engine"]))$Mc[]="FULLTEXT";$v=indexes($a);$He=array();if($x=="mongo"){$He=$v["_id_"];unset($Mc[0]);unset($v["_id_"]);}$L=$_POST;if($_POST&&!$j&&!$_POST["add"]&&!$_POST["drop_col"]){$sa=array();foreach($L["indexes"]as$u){$E=$u["name"];if(in_array($u["type"],$Mc)){$d=array();$md=array();$yb=array();$P=array();ksort($u["columns"]);foreach($u["columns"]as$y=>$c){if($c!=""){$ld=$u["lengths"][$y];$xb=$u["descs"][$y];$P[]=idf_escape($c).($ld?"(".(+$ld).")":"").($xb?" DESC":"");$d[]=$c;$md[]=($ld?$ld:null);$yb[]=$xb;}}if($d){$cc=$v[$E];if($cc){ksort($cc["columns"]);ksort($cc["lengths"]);ksort($cc["descs"]);if($u["type"]==$cc["type"]&&array_values($cc["columns"])===$d&&(!$cc["lengths"]||array_values($cc["lengths"])===$md)&&array_values($cc["descs"])===$yb){unset($v[$E]);continue;}}$sa[]=array($u["type"],$E,$P);}}}foreach($v
  666. as$E=>$cc)$sa[]=array($cc["type"],$E,"DROP");if(!$sa)redirect(ME."table=".urlencode($a));queries_redirect(ME."table=".urlencode($a),'Indexes have been altered.',alter_indexes($a,$sa));}page_header('Indexes',$j,array("table"=>$a),h($a));$l=array_keys(fields($a));if($_POST["add"]){foreach($L["indexes"]as$y=>$u){if($u["columns"][count($u["columns"])]!="")$L["indexes"][$y]["columns"][]="";}$u=end($L["indexes"]);if($u["type"]||array_filter($u["columns"],'strlen'))$L["indexes"][]=array("columns"=>array(1=>""));}if(!$L){foreach($v
  667. as$y=>$u){$v[$y]["name"]=$y;$v[$y]["columns"][]="";}$v[]=array("columns"=>array(1=>""));$L["indexes"]=$v;}?>
  668. <form action="" method="post">
  669. <table cellspacing="0" class="nowrap">
  670. <thead><tr>
  671. <th>Index Type
  672. <th><input type="submit" style="left: -1000px; position: absolute;">Column (length)
  673. <th>Name
  674. <th><noscript><input type='image' class='icon' name='add[0]' src='" . h(preg_replace("~\\?.*~", "", ME)) . "?file=plus.gif&amp;version=4.1.0&amp;driver=mysql' alt='+' title='Add next'></noscript>&nbsp;
  675. </thead>
  676. <?php
  677. if($He){echo"<tr><td>PRIMARY<td>";foreach($He["columns"]as$y=>$c){echo
  678. select_input(" disabled",$l,$c),"<label><input disabled type='checkbox'>".'descending'."</label> ";}echo"<td><td>\n";}$w=1;foreach($L["indexes"]as$u){if(!$_POST["drop_col"]||$w!=key($_POST["drop_col"])){echo"<tr><td>".html_select("indexes[$w][type]",array(-1=>"")+$Mc,$u["type"],($w==count($L["indexes"])?"indexesAddRow(this);":1)),"<td>";ksort($u["columns"]);$s=1;foreach($u["columns"]as$y=>$c){echo"<span>".select_input(" name='indexes[$w][columns][$s]' onchange=\"".($s==count($u["columns"])?"indexesAddColumn":"indexesChangeColumn")."(this, '".js_escape($x=="sql"?"":$_GET["indexes"]."_")."');\"",($l?array_combine($l,$l):$l),$c),($x=="sql"||$x=="mssql"?"<input type='number' name='indexes[$w][lengths][$s]' class='size' value='".h($u["lengths"][$y])."'>":""),($x!="sql"?checkbox("indexes[$w][descs][$s]",1,$u["descs"][$y],'descending'):"")," </span>";$s++;}echo"<td><input name='indexes[$w][name]' value='".h($u["name"])."' autocapitalize='off'>\n","<td><input type='image' class='icon' name='drop_col[$w]' src='".h(preg_replace("~\\?.*~","",ME))."?file=cross.gif&amp;version=4.1.0&amp;driver=mysql' alt='x' title='".'Remove'."' onclick=\"return !editingRemoveRow(this, 'indexes\$1[type]');\">\n";}$w++;}echo'</table>
  679. <p>
  680. <input type="submit" value="Save">
  681. <input type="hidden" name="token" value="',$T,'">
  682. </form>
  683. ';}elseif(isset($_GET["database"])){$L=$_POST;if($_POST&&!$j&&!isset($_POST["add_x"])){restart_session();$E=trim($L["name"]);if($_POST["drop"]){$_GET["db"]="";queries_redirect(remove_from_uri("db|database"),'Database has been dropped.',drop_databases(array(DB)));}elseif(DB!==$E){if(DB!=""){$_GET["db"]=$E;queries_redirect(preg_replace('~\bdb=[^&]*&~','',ME)."db=".urlencode($E),'Database has been renamed.',rename_database($E,$L["collation"]));}else{$g=explode("\n",str_replace("\r","",$E));$If=true;$fd="";foreach($g
  684. as$h){if(count($g)==1||$h!=""){if(!create_database($h,$L["collation"]))$If=false;$fd=$h;}}queries_redirect(ME."db=".urlencode($fd),'Database has been created.',$If);}}else{if(!$L["collation"])redirect(substr(ME,0,-1));query_redirect("ALTER DATABASE ".idf_escape($E).(preg_match('~^[a-z0-9_]+$~i',$L["collation"])?" COLLATE $L[collation]":""),substr(ME,0,-1),'Database has been altered.');}}page_header(DB!=""?'Alter database':'Create database',$j,array(),h(DB));$Wa=collations();$E=DB;if($_POST)$E=$L["name"];elseif(DB!="")$L["collation"]=db_collation(DB,$Wa);elseif($x=="sql"){foreach(get_vals("SHOW GRANTS")as$q){if(preg_match('~ ON (`(([^\\\\`]|``|\\\\.)*)%`\\.\\*)?~',$q,$B)&&$B[1]){$E=stripcslashes(idf_unescape("`$B[2]`"));break;}}}echo'
  685. <form action="" method="post">
  686. <p>
  687. ',($_POST["add_x"]||strpos($E,"\n")?'<textarea id="name" name="name" rows="10" cols="40">'.h($E).'</textarea><br>':'<input name="name" id="name" value="'.h($E).'" maxlength="64" autocapitalize="off">')."\n".($Wa?html_select("collation",array(""=>"(".'collation'.")")+$Wa,$L["collation"]).doc_link(array('sql'=>"charset-charsets.html",'mssql'=>"ms187963.aspx",)):"");?>
  688. <script type='text/javascript'>focus(document.getElementById('name'));</script>
  689. <input type="submit" value="Save">
  690. <?php
  691. if(DB!="")echo"<input type='submit' name='drop' value='".'Drop'."'".confirm().">\n";elseif(!$_POST["add_x"]&&$_GET["db"]=="")echo"<input type='image' class='icon' name='add' src='".h(preg_replace("~\\?.*~","",ME))."?file=plus.gif&amp;version=4.1.0&amp;driver=mysql' alt='+' title='".'Add next'."'>\n";echo'<input type="hidden" name="token" value="',$T,'">
  692. </form>
  693. ';}elseif(isset($_GET["call"])){$da=$_GET["call"];page_header('Call'.": ".h($da),$j);$if=routine($da,(isset($_GET["callf"])?"FUNCTION":"PROCEDURE"));$Lc=array();$me=array();foreach($if["fields"]as$s=>$k){if(substr($k["inout"],-3)=="OUT")$me[$s]="@".idf_escape($k["field"])." AS ".idf_escape($k["field"]);if(!$k["inout"]||substr($k["inout"],0,2)=="IN")$Lc[]=$s;}if(!$j&&$_POST){$Ja=array();foreach($if["fields"]as$y=>$k){if(in_array($y,$Lc)){$X=process_input($k);if($X===false)$X="''";if(isset($me[$y]))$e->query("SET @".idf_escape($k["field"])." = $X");}$Ja[]=(isset($me[$y])?"@".idf_escape($k["field"]):$X);}$I=(isset($_GET["callf"])?"SELECT":"CALL")." ".idf_escape($da)."(".implode(", ",$Ja).")";echo"<p><code class='jush-$x'>".h($I)."</code> <a href='".h(ME)."sql=".urlencode($I)."'>".'Edit'."</a>\n";if(!$e->multi_query($I))echo"<p class='error'>".error()."\n";else{$f=connect();if(is_object($f))$f->select_db(DB);do{$J=$e->store_result();if(is_object($J))select($J,$f);else
  694. echo"<p class='message'>".lang(array('Routine has been called, %d row affected.','Routine has been called, %d rows affected.'),$e->affected_rows)."\n";}while($e->next_result());if($me)select($e->query("SELECT ".implode(", ",$me)));}}echo'
  695. <form action="" method="post">
  696. ';if($Lc){echo"<table cellspacing='0'>\n";foreach($Lc
  697. as$y){$k=$if["fields"][$y];$E=$k["field"];echo"<tr><th>".$b->fieldName($k);$Y=$_POST["fields"][$E];if($Y!=""){if($k["type"]=="enum")$Y=+$Y;if($k["type"]=="set")$Y=array_sum($Y);}input($k,$Y,(string)$_POST["function"][$E]);echo"\n";}echo"</table>\n";}echo'<p>
  698. <input type="submit" value="Call">
  699. <input type="hidden" name="token" value="',$T,'">
  700. </form>
  701. ';}elseif(isset($_GET["foreign"])){$a=$_GET["foreign"];$E=$_GET["name"];$L=$_POST;if($_POST&&!$j&&!$_POST["add"]&&!$_POST["change"]&&!$_POST["change-js"]){$C=($_POST["drop"]?'Foreign key has been dropped.':($E!=""?'Foreign key has been altered.':'Foreign key has been created.'));$A=ME."table=".urlencode($a);$L["source"]=array_filter($L["source"],'strlen');ksort($L["source"]);$Uf=array();foreach($L["source"]as$y=>$X)$Uf[$y]=$L["target"][$y];$L["target"]=$Uf;if($x=="sqlite")queries_redirect($A,$C,recreate_table($a,$a,array(),array(),array(" $E"=>($_POST["drop"]?"":" ".format_foreign_key($L)))));else{$sa="ALTER TABLE ".table($a);$Eb="\nDROP ".($x=="sql"?"FOREIGN KEY ":"CONSTRAINT ").idf_escape($E);if($_POST["drop"])query_redirect($sa.$Eb,$A,$C);else{query_redirect($sa.($E!=""?"$Eb,":"")."\nADD".format_foreign_key($L),$A,$C);$j='Source and target columns must have the same data type, there must be an index on the target columns and referenced data must exist.'."<br>$j";}}}page_header('Foreign key',$j,array("table"=>$a),h($a));if($_POST){ksort($L["source"]);if($_POST["add"])$L["source"][]="";elseif($_POST["change"]||$_POST["change-js"])$L["target"]=array();}elseif($E!=""){$n=foreign_keys($a);$L=$n[$E];$L["source"][]="";}else{$L["table"]=$a;$L["source"]=array("");}$zf=array_keys(fields($a));$Uf=($a===$L["table"]?$zf:array_keys(fields($L["table"])));$We=array_keys(array_filter(table_status('',true),'fk_support'));echo'
  702. <form action="" method="post">
  703. <p>
  704. ';if($L["db"]==""&&$L["ns"]==""){echo'Target table:
  705. ',html_select("table",$We,$L["table"],"this.form['change-js'].value = '1'; this.form.submit();"),'<input type="hidden" name="change-js" value="">
  706. <noscript><p><input type="submit" name="change" value="Change"></noscript>
  707. <table cellspacing="0">
  708. <thead><tr><th>Source<th>Target</thead>
  709. ';$w=0;foreach($L["source"]as$y=>$X){echo"<tr>","<td>".html_select("source[".(+$y)."]",array(-1=>"")+$zf,$X,($w==count($L["source"])-1?"foreignAddRow(this);":1)),"<td>".html_select("target[".(+$y)."]",$Uf,$L["target"][$y]);$w++;}echo'</table>
  710. <p>
  711. ON DELETE: ',html_select("on_delete",array(-1=>"")+explode("|",$Wd),$L["on_delete"]),' ON UPDATE: ',html_select("on_update",array(-1=>"")+explode("|",$Wd),$L["on_update"]),doc_link(array('sql'=>"innodb-foreign-key-constraints.html",'pgsql'=>"sql-createtable.html#SQL-CREATETABLE-REFERENCES",'mssql'=>"ms174979.aspx",'oracle'=>"clauses002.htm#sthref2903",)),'<p>
  712. <input type="submit" value="Save">
  713. <noscript><p><input type="submit" name="add" value="Add column"></noscript>
  714. ';}if($E!=""){echo'<input type="submit" name="drop" value="Drop"',confirm(),'>';}echo'<input type="hidden" name="token" value="',$T,'">
  715. </form>
  716. ';}elseif(isset($_GET["view"])){$a=$_GET["view"];$L=$_POST;if($_POST&&!$j){$E=trim($L["name"]);$ua=" AS\n$L[select]";$A=ME."table=".urlencode($E);$C='View has been altered.';if(!$_POST["drop"]&&$a==$E&&$x!="sqlite")query_redirect(($x=="mssql"?"ALTER":"CREATE OR REPLACE")." VIEW ".table($E).$ua,$A,$C);else{$Wf=$E."_adminer_".uniqid();drop_create("DROP VIEW ".table($a),"CREATE VIEW ".table($E).$ua,"DROP VIEW ".table($E),"CREATE VIEW ".table($Wf).$ua,"DROP VIEW ".table($Wf),($_POST["drop"]?substr(ME,0,-1):$A),'View has been dropped.',$C,'View has been created.',$a,$E);}}if(!$_POST&&$a!=""){$L=view($a);$L["name"]=$a;if(!$j)$j=$e->error;}page_header(($a!=""?'Alter view':'Create view'),$j,array("table"=>$a),h($a));echo'
  717. <form action="" method="post">
  718. <p>Name: <input name="name" value="',h($L["name"]),'" maxlength="64" autocapitalize="off">
  719. <p>';textarea("select",$L["select"]);echo'<p>
  720. <input type="submit" value="Save">
  721. ';if($_GET["view"]!=""){echo'<input type="submit" name="drop" value="Drop"',confirm(),'>';}echo'<input type="hidden" name="token" value="',$T,'">
  722. </form>
  723. ';}elseif(isset($_GET["event"])){$aa=$_GET["event"];$Rc=array("YEAR","QUARTER","MONTH","DAY","HOUR","MINUTE","WEEK","SECOND","YEAR_MONTH","DAY_HOUR","DAY_MINUTE","DAY_SECOND","HOUR_MINUTE","HOUR_SECOND","MINUTE_SECOND");$Df=array("ENABLED"=>"ENABLE","DISABLED"=>"DISABLE","SLAVESIDE_DISABLED"=>"DISABLE ON SLAVE");$L=$_POST;if($_POST&&!$j){if($_POST["drop"])query_redirect("DROP EVENT ".idf_escape($aa),substr(ME,0,-1),'Event has been dropped.');elseif(in_array($L["INTERVAL_FIELD"],$Rc)&&isset($Df[$L["STATUS"]])){$mf="\nON SCHEDULE ".($L["INTERVAL_VALUE"]?"EVERY ".q($L["INTERVAL_VALUE"])." $L[INTERVAL_FIELD]".($L["STARTS"]?" STARTS ".q($L["STARTS"]):"").($L["ENDS"]?" ENDS ".q($L["ENDS"]):""):"AT ".q($L["STARTS"]))." ON COMPLETION".($L["ON_COMPLETION"]?"":" NOT")." PRESERVE";queries_redirect(substr(ME,0,-1),($aa!=""?'Event has been altered.':'Event has been created.'),queries(($aa!=""?"ALTER EVENT ".idf_escape($aa).$mf.($aa!=$L["EVENT_NAME"]?"\nRENAME TO ".idf_escape($L["EVENT_NAME"]):""):"CREATE EVENT ".idf_escape($L["EVENT_NAME"]).$mf)."\n".$Df[$L["STATUS"]]." COMMENT ".q($L["EVENT_COMMENT"]).rtrim(" DO\n$L[EVENT_DEFINITION]",";").";"));}}page_header(($aa!=""?'Alter event'.": ".h($aa):'Create event'),$j);if(!$L&&$aa!=""){$M=get_rows("SELECT * FROM information_schema.EVENTS WHERE EVENT_SCHEMA = ".q(DB)." AND EVENT_NAME = ".q($aa));$L=reset($M);}echo'
  724. <form action="" method="post">
  725. <table cellspacing="0">
  726. <tr><th>Name<td><input name="EVENT_NAME" value="',h($L["EVENT_NAME"]),'" maxlength="64" autocapitalize="off">
  727. <tr><th title="datetime">Start<td><input name="STARTS" value="',h("$L[EXECUTE_AT]$L[STARTS]"),'">
  728. <tr><th title="datetime">End<td><input name="ENDS" value="',h($L["ENDS"]),'">
  729. <tr><th>Every<td><input type="number" name="INTERVAL_VALUE" value="',h($L["INTERVAL_VALUE"]),'" class="size"> ',html_select("INTERVAL_FIELD",$Rc,$L["INTERVAL_FIELD"]),'<tr><th>Status<td>',html_select("STATUS",$Df,$L["STATUS"]),'<tr><th>Comment<td><input name="EVENT_COMMENT" value="',h($L["EVENT_COMMENT"]),'" maxlength="64">
  730. <tr><th>&nbsp;<td>',checkbox("ON_COMPLETION","PRESERVE",$L["ON_COMPLETION"]=="PRESERVE",'On completion preserve'),'</table>
  731. <p>';textarea("EVENT_DEFINITION",$L["EVENT_DEFINITION"]);echo'<p>
  732. <input type="submit" value="Save">
  733. ';if($aa!=""){echo'<input type="submit" name="drop" value="Drop"',confirm(),'>';}echo'<input type="hidden" name="token" value="',$T,'">
  734. </form>
  735. ';}elseif(isset($_GET["procedure"])){$da=$_GET["procedure"];$if=(isset($_GET["function"])?"FUNCTION":"PROCEDURE");$L=$_POST;$L["fields"]=(array)$L["fields"];if($_POST&&!process_fields($L["fields"])&&!$j){$Wf="$L[name]_adminer_".uniqid();drop_create("DROP $if ".idf_escape($da),create_routine($if,$L),"DROP $if ".idf_escape($L["name"]),create_routine($if,array("name"=>$Wf)+$L),"DROP $if ".idf_escape($Wf),substr(ME,0,-1),'Routine has been dropped.','Routine has been altered.','Routine has been created.',$da,$L["name"]);}page_header(($da!=""?(isset($_GET["function"])?'Alter function':'Alter procedure').": ".h($da):(isset($_GET["function"])?'Create function':'Create procedure')),$j);if(!$_POST&&$da!=""){$L=routine($da,$if);$L["name"]=$da;}$Wa=get_vals("SHOW CHARACTER SET");sort($Wa);$jf=routine_languages();echo'
  736. <form action="" method="post" id="form">
  737. <p>Name: <input name="name" value="',h($L["name"]),'" maxlength="64" autocapitalize="off">
  738. ',($jf?'Language'.": ".html_select("language",$jf,$L["language"]):""),'<input type="submit" value="Save">
  739. <table cellspacing="0" class="nowrap">
  740. ';edit_fields($L["fields"],$Wa,$if);if(isset($_GET["function"])){echo"<tr><td>".'Return type';edit_type("returns",$L["returns"],$Wa);}echo'</table>
  741. <p>';textarea("definition",$L["definition"]);echo'<p>
  742. <input type="submit" value="Save">
  743. ';if($da!=""){echo'<input type="submit" name="drop" value="Drop"',confirm(),'>';}echo'<input type="hidden" name="token" value="',$T,'">
  744. </form>
  745. ';}elseif(isset($_GET["trigger"])){$a=$_GET["trigger"];$E=$_GET["name"];$og=trigger_options();$L=(array)trigger($E)+array("Trigger"=>$a."_bi");if($_POST){if(!$j&&in_array($_POST["Timing"],$og["Timing"])&&in_array($_POST["Event"],$og["Event"])&&in_array($_POST["Type"],$og["Type"])){$Vd=" ON ".table($a);$Eb="DROP TRIGGER ".idf_escape($E).($x=="pgsql"?$Vd:"");$A=ME."table=".urlencode($a);if($_POST["drop"])query_redirect($Eb,$A,'Trigger has been dropped.');else{if($E!="")queries($Eb);queries_redirect($A,($E!=""?'Trigger has been altered.':'Trigger has been created.'),queries(create_trigger($Vd,$_POST)));if($E!="")queries(create_trigger($Vd,$L+array("Type"=>reset($og["Type"]))));}}$L=$_POST;}page_header(($E!=""?'Alter trigger'.": ".h($E):'Create trigger'),$j,array("table"=>$a));echo'
  746. <form action="" method="post" id="form">
  747. <table cellspacing="0">
  748. <tr><th>Time<td>',html_select("Timing",$og["Timing"],$L["Timing"],"triggerChange(/^".preg_quote($a,"/")."_[ba][iud]$/, '".js_escape($a)."', this.form);"),'<tr><th>Event<td>',html_select("Event",$og["Event"],$L["Event"],"this.form['Timing'].onchange();"),(in_array("UPDATE OF",$og["Event"])?" <input name='Of' value='".h($L["Of"])."' class='hidden'>":""),'<tr><th>Type<td>',html_select("Type",$og["Type"],$L["Type"]),'</table>
  749. <p>Name: <input name="Trigger" value="',h($L["Trigger"]);?>" maxlength="64" autocapitalize="off">
  750. <script type="text/javascript">document.getElementById('form')['Timing'].onchange();</script>
  751. <p><?php textarea("Statement",$L["Statement"]);echo'<p>
  752. <input type="submit" value="Save">
  753. ';if($E!=""){echo'<input type="submit" name="drop" value="Drop"',confirm(),'>';}echo'<input type="hidden" name="token" value="',$T,'">
  754. </form>
  755. ';}elseif(isset($_GET["user"])){$fa=$_GET["user"];$Le=array(""=>array("All privileges"=>""));foreach(get_rows("SHOW PRIVILEGES")as$L){foreach(explode(",",($L["Privilege"]=="Grant option"?"":$L["Context"]))as$gb)$Le[$gb][$L["Privilege"]]=$L["Comment"];}$Le["Server Admin"]+=$Le["File access on server"];$Le["Databases"]["Create routine"]=$Le["Procedures"]["Create routine"];unset($Le["Procedures"]["Create routine"]);$Le["Columns"]=array();foreach(array("Select","Insert","Update","References")as$X)$Le["Columns"][$X]=$Le["Tables"][$X];unset($Le["Server Admin"]["Usage"]);foreach($Le["Tables"]as$y=>$X)unset($Le["Databases"][$y]);$Id=array();if($_POST){foreach($_POST["objects"]as$y=>$X)$Id[$X]=(array)$Id[$X]+(array)$_POST["grants"][$y];}$yc=array();$Td="";if(isset($_GET["host"])&&($J=$e->query("SHOW GRANTS FOR ".q($fa)."@".q($_GET["host"])))){while($L=$J->fetch_row()){if(preg_match('~GRANT (.*) ON (.*) TO ~',$L[0],$B)&&preg_match_all('~ *([^(,]*[^ ,(])( *\\([^)]+\\))?~',$B[1],$sd,PREG_SET_ORDER)){foreach($sd
  756. as$X){if($X[1]!="USAGE")$yc["$B[2]$X[2]"][$X[1]]=true;if(preg_match('~ WITH GRANT OPTION~',$L[0]))$yc["$B[2]$X[2]"]["GRANT OPTION"]=true;}}if(preg_match("~ IDENTIFIED BY PASSWORD '([^']+)~",$L[0],$B))$Td=$B[1];}}if($_POST&&!$j){$Ud=(isset($_GET["host"])?q($fa)."@".q($_GET["host"]):"''");if($_POST["drop"])query_redirect("DROP USER $Ud",ME."privileges=",'User has been dropped.');else{$Kd=q($_POST["user"])."@".q($_POST["host"]);$we=$_POST["pass"];if($we!=''&&!$_POST["hashed"]){$we=$e->result("SELECT PASSWORD(".q($we).")");$j=!$we;}$lb=false;if(!$j){if($Ud!=$Kd){$lb=queries(($e->server_info<5?"GRANT USAGE ON *.* TO":"CREATE USER")." $Kd IDENTIFIED BY PASSWORD ".q($we));$j=!$lb;}elseif($we!=$Td)queries("SET PASSWORD FOR $Kd = ".q($we));}if(!$j){$ff=array();foreach($Id
  757. as$Od=>$q){if(isset($_GET["grant"]))$q=array_filter($q);$q=array_keys($q);if(isset($_GET["grant"]))$ff=array_diff(array_keys(array_filter($Id[$Od],'strlen')),$q);elseif($Ud==$Kd){$Rd=array_keys((array)$yc[$Od]);$ff=array_diff($Rd,$q);$q=array_diff($q,$Rd);unset($yc[$Od]);}if(preg_match('~^(.+)\\s*(\\(.*\\))?$~U',$Od,$B)&&(!grant("REVOKE",$ff,$B[2]," ON $B[1] FROM $Kd")||!grant("GRANT",$q,$B[2]," ON $B[1] TO $Kd"))){$j=true;break;}}}if(!$j&&isset($_GET["host"])){if($Ud!=$Kd)queries("DROP USER $Ud");elseif(!isset($_GET["grant"])){foreach($yc
  758. as$Od=>$ff){if(preg_match('~^(.+)(\\(.*\\))?$~U',$Od,$B))grant("REVOKE",array_keys($ff),$B[2]," ON $B[1] FROM $Kd");}}}queries_redirect(ME."privileges=",(isset($_GET["host"])?'User has been altered.':'User has been created.'),!$j);if($lb)$e->query("DROP USER $Kd");}}page_header((isset($_GET["host"])?'Username'.": ".h("$fa@$_GET[host]"):'Create user'),$j,array("privileges"=>array('','Privileges')));if($_POST){$L=$_POST;$yc=$Id;}else{$L=$_GET+array("host"=>$e->result("SELECT SUBSTRING_INDEX(CURRENT_USER, '@', -1)"));$L["pass"]=$Td;if($Td!="")$L["hashed"]=true;$yc[(DB==""||$yc?"":idf_escape(addcslashes(DB,"%_\\"))).".*"]=array();}echo'<form action="" method="post">
  759. <table cellspacing="0">
  760. <tr><th>Server<td><input name="host" maxlength="60" value="',h($L["host"]),'" autocapitalize="off">
  761. <tr><th>Username<td><input name="user" maxlength="16" value="',h($L["user"]),'" autocapitalize="off">
  762. <tr><th>Password<td><input name="pass" id="pass" value="',h($L["pass"]),'">
  763. ';if(!$L["hashed"]){echo'<script type="text/javascript">typePassword(document.getElementById(\'pass\'));</script>';}echo
  764. checkbox("hashed",1,$L["hashed"],'Hashed',"typePassword(this.form['pass'], this.checked);"),'</table>
  765. ';echo"<table cellspacing='0'>\n","<thead><tr><th colspan='2'>".'Privileges'.doc_link(array('sql'=>"grant.html#priv_level"));$s=0;foreach($yc
  766. as$Od=>$q){echo'<th>'.($Od!="*.*"?"<input name='objects[$s]' value='".h($Od)."' size='10' autocapitalize='off'>":"<input type='hidden' name='objects[$s]' value='*.*' size='10'>*.*");$s++;}echo"</thead>\n";foreach(array(""=>"","Server Admin"=>'Server',"Databases"=>'Database',"Tables"=>'Table',"Columns"=>'Column',"Procedures"=>'Routine',)as$gb=>$xb){foreach((array)$Le[$gb]as$Ke=>$ab){echo"<tr".odd()."><td".($xb?">$xb<td":" colspan='2'").' lang="en" title="'.h($ab).'">'.h($Ke);$s=0;foreach($yc
  767. as$Od=>$q){$E="'grants[$s][".h(strtoupper($Ke))."]'";$Y=$q[strtoupper($Ke)];if($gb=="Server Admin"&&$Od!=(isset($yc["*.*"])?"*.*":".*"))echo"<td>&nbsp;";elseif(isset($_GET["grant"]))echo"<td><select name=$E><option><option value='1'".($Y?" selected":"").">".'Grant'."<option value='0'".($Y=="0"?" selected":"").">".'Revoke'."</select>";else
  768. echo"<td align='center'><label class='block'><input type='checkbox' name=$E value='1'".($Y?" checked":"").($Ke=="All privileges"?" id='grants-$s-all'":($Ke=="Grant option"?"":" onclick=\"if (this.checked) formUncheck('grants-$s-all');\""))."></label>";$s++;}}}echo"</table>\n",'<p>
  769. <input type="submit" value="Save">
  770. ';if(isset($_GET["host"])){echo'<input type="submit" name="drop" value="Drop"',confirm(),'>';}echo'<input type="hidden" name="token" value="',$T,'">
  771. </form>
  772. ';}elseif(isset($_GET["processlist"])){if(support("kill")&&$_POST&&!$j){$cd=0;foreach((array)$_POST["kill"]as$X){if(queries("KILL ".(+$X)))$cd++;}queries_redirect(ME."processlist=",lang(array('%d process has been killed.','%d processes have been killed.'),$cd),$cd||!$_POST["kill"]);}page_header('Process list',$j);echo'
  773. <form action="" method="post">
  774. <table cellspacing="0" onclick="tableClick(event);" ondblclick="tableClick(event, true);" class="nowrap checkable">
  775. ';$s=-1;foreach(process_list()as$s=>$L){if(!$s){echo"<thead><tr lang='en'>".(support("kill")?"<th>&nbsp;":"");foreach($L
  776. as$y=>$X)echo"<th>$y".doc_link(array('sql'=>"show-processlist.html#processlist_".strtolower($y),'pgsql'=>"monitoring-stats.html#PG-STAT-ACTIVITY-VIEW",'oracle'=>"../b14237/dynviews_2088.htm",));echo"</thead>\n";}echo"<tr".odd().">".(support("kill")?"<td>".checkbox("kill[]",$L["Id"],0):"");foreach($L
  777. as$y=>$X)echo"<td>".(($x=="sql"&&$y=="Info"&&preg_match("~Query|Killed~",$L["Command"])&&$X!="")||($x=="pgsql"&&$y=="current_query"&&$X!="<IDLE>")||($x=="oracle"&&$y=="sql_text"&&$X!="")?"<code class='jush-$x'>".shorten_utf8($X,100,"</code>").' <a href="'.h(ME.($L["db"]!=""?"db=".urlencode($L["db"])."&":"")."sql=".urlencode($X)).'">'.'Clone'.'</a>':nbsp($X));echo"\n";}echo'</table>
  778. <script type=\'text/javascript\'>tableCheck();</script>
  779. <p>
  780. ';if(support("kill")){echo($s+1)."/".sprintf('%d in total',$e->result("SELECT @@max_connections")),"<p><input type='submit' value='".'Kill'."'>\n";}echo'<input type="hidden" name="token" value="',$T,'">
  781. </form>
  782. ';}elseif(isset($_GET["select"])){$a=$_GET["select"];$R=table_status1($a);$v=indexes($a);$l=fields($a);$n=column_foreign_keys($a);$Qd="";if(!empty($R["Oid"])){$Qd=($x=="sqlite"?"rowid":"oid");$v[]=array("type"=>"PRIMARY","columns"=>array($Qd));}parse_str((isset($_COOKIE["adminer_import"])?$_COOKIE["adminer_import"]:null),$ma);$gf=array();$d=array();$Zf=null;foreach($l
  783. as$y=>$k){$E=$b->fieldName($k);if(isset($k["privileges"]["select"])&&$E!=""){$d[$y]=html_entity_decode(strip_tags($E),ENT_QUOTES);if(is_shortable($k))$Zf=$b->selectLengthProcess();}$gf+=$k["privileges"];}list($N,$r)=$b->selectColumnsProcess($d,$v);$Vc=count($r)<count($N);$Z=$b->selectSearchProcess($l,$v);$ee=$b->selectOrderProcess($l,$v);$z=$b->selectLimitProcess();$vc=($N?implode(", ",$N):"*".($Qd?", $Qd":"")).convert_fields($d,$l,$N)."\nFROM ".table($a);$zc=($r&&$Vc?"\nGROUP BY ".implode(", ",$r):"").($ee?"\nORDER BY ".implode(", ",$ee):"");if((isset($_GET["val"])?$_GET["val"]:false)&&is_ajax()){header("Content-Type: text/plain; charset=utf-8");foreach($_GET["val"]as$wg=>$L){$ua=convert_field($l[key($L)]);$N=array($ua?$ua:idf_escape(key($L)));$Z[]=where_check($wg,$l);$K=$i->select($a,$N,$Z,$N);if($K)echo
  784. reset($K->fetch_row());}exit;}if($_POST&&!$j){$Og=$Z;if(!$_POST["all"]&&is_array($_POST["check"])){$Na=array();foreach($_POST["check"]as$La)$Na[]=where_check($La,$l);$Og[]="((".implode(") OR (",$Na)."))";}$Og=($Og?"\nWHERE ".implode(" AND ",$Og):"");$He=$yg=null;foreach($v
  785. as$u){if($u["type"]=="PRIMARY"){$He=array_flip($u["columns"]);$yg=($N?$He:array());break;}}foreach((array)$yg
  786. as$y=>$X){if(in_array(idf_escape($y),$N))unset($yg[$y]);}if($_POST["export"]){cookie("adminer_import","output=".urlencode($_POST["output"])."&format=".urlencode($_POST["format"]));dump_headers($a);$b->dumpTable($a,"");if(!is_array($_POST["check"])||$yg===array())$I="SELECT $vc$Og$zc";else{$ug=array();foreach($_POST["check"]as$X)$ug[]="(SELECT".limit($vc,"\nWHERE ".($Z?implode(" AND ",$Z)." AND ":"").where_check($X,$l).$zc,1).")";$I=implode(" UNION ALL ",$ug);}$b->dumpData($a,"table",$I);exit;}if(!$b->selectEmailProcess($Z,$n)){if($_POST["save"]||$_POST["delete"]){$J=true;$na=0;$P=array();if(!$_POST["delete"]){foreach($d
  787. as$E=>$X){$X=process_input($l[$E]);if($X!==null&&($_POST["clone"]||$X!==false))$P[idf_escape($E)]=($X!==false?$X:idf_escape($E));}}if($_POST["delete"]||$P){if($_POST["clone"])$I="INTO ".table($a)." (".implode(", ",array_keys($P)).")\nSELECT ".implode(", ",$P)."\nFROM ".table($a);if($_POST["all"]||($yg===array()&&is_array($_POST["check"]))||$Vc){$J=($_POST["delete"]?$i->delete($a,$Og):($_POST["clone"]?queries("INSERT $I$Og"):$i->update($a,$P,$Og)));$na=$e->affected_rows;}else{foreach((array)$_POST["check"]as$X){$Ng="\nWHERE ".($Z?implode(" AND ",$Z)." AND ":"").where_check($X,$l);$J=($_POST["delete"]?$i->delete($a,$Ng,1):($_POST["clone"]?queries("INSERT".limit1($I,$Ng)):$i->update($a,$P,$Ng)));if(!$J)break;$na+=$e->affected_rows;}}}$C=lang(array('%d item has been affected.','%d items have been affected.'),$na);if($_POST["clone"]&&$J&&$na==1){$gd=last_id();if($gd)$C=sprintf('Item%s has been inserted.'," $gd");}queries_redirect(remove_from_uri($_POST["all"]&&$_POST["delete"]?"page":""),$C,$J);if(!$_POST["delete"]){edit_form($a,$l,(array)$_POST["fields"],!$_POST["clone"]);page_footer();exit;}}elseif(!$_POST["import"]){if(!$_POST["val"])$j='Ctrl+click on a value to modify it.';else{$J=true;$na=0;foreach($_POST["val"]as$wg=>$L){$P=array();foreach($L
  788. as$y=>$X){$y=bracket_escape($y,1);$P[idf_escape($y)]=(preg_match('~char|text~',$l[$y]["type"])||$X!=""?$b->processInput($l[$y],$X):"NULL");}$J=$i->update($a,$P," WHERE ".($Z?implode(" AND ",$Z)." AND ":"").where_check($wg,$l),!($Vc||$yg===array())," ");if(!$J)break;$na+=$e->affected_rows;}queries_redirect(remove_from_uri(),lang(array('%d item has been affected.','%d items have been affected.'),$na),$J);}}elseif(!is_string($lc=get_file("csv_file",true)))$j=upload_error($lc);elseif(!preg_match('~~u',$lc))$j='File must be in UTF-8 encoding.';else{cookie("adminer_import","output=".urlencode($ma["output"])."&format=".urlencode($_POST["separator"]));$J=true;$Xa=array_keys($l);preg_match_all('~(?>"[^"]*"|[^"\\r\\n]+)+~',$lc,$sd);$na=count($sd[0]);$i->begin();$sf=($_POST["separator"]=="csv"?",":($_POST["separator"]=="tsv"?"\t":";"));$M=array();foreach($sd[0]as$y=>$X){preg_match_all("~((?>\"[^\"]*\")+|[^$sf]*)$sf~",$X.$sf,$td);if(!$y&&!array_diff($td[1],$Xa)){$Xa=$td[1];$na--;}else{$P=array();foreach($td[1]as$s=>$Ta)$P[idf_escape($Xa[$s])]=($Ta==""&&$l[$Xa[$s]]["null"]?"NULL":q(str_replace('""','"',preg_replace('~^"|"$~','',$Ta))));$M[]=$P;}}$J=(!$M||$i->insertUpdate($a,$M,$He));if($J)$i->commit();queries_redirect(remove_from_uri("page"),lang(array('%d row has been imported.','%d rows have been imported.'),$na),$J);$i->rollback();}}}$Of=$b->tableName($R);if(is_ajax()){page_headers();ob_start();}else
  789. page_header('Select'.": $Of",$j);$P=null;if(isset($gf["insert"])||!support("table")){$P="";foreach((array)(isset($_GET["where"])?$_GET["where"]:null)as$X){if(count($n[$X["col"]])==1&&($X["op"]=="="||(!$X["op"]&&!preg_match('~[_%]~',$X["val"]))))$P.="&set".urlencode("[".bracket_escape($X["col"])."]")."=".urlencode($X["val"]);}}$b->selectLinks($R,$P);if(!$d&&support("table"))echo"<p class='error'>".'Unable to select the table'.($l?".":": ".error())."\n";else{echo"<form action='' id='form'>\n","<div style='display: none;'>";hidden_fields_get();echo(DB!=""?'<input type="hidden" name="db" value="'.h(DB).'">'.(isset($_GET["ns"])?'<input type="hidden" name="ns" value="'.h($_GET["ns"]).'">':""):"");echo'<input type="hidden" name="select" value="'.h($a).'">',"</div>\n";$b->selectColumnsPrint($N,$d);$b->selectSearchPrint($Z,$d,$v);$b->selectOrderPrint($ee,$d,$v);$b->selectLimitPrint($z);$b->selectLengthPrint($Zf);$b->selectActionPrint($v);echo"</form>\n";$F=(isset($_GET["page"])?$_GET["page"]:null);if($F=="last"){$uc=$e->result(count_rows($a,$Z,$Vc,$r));$F=floor(max(0,$uc-1)/$z);}$pf=$N;if(!$pf){$pf[]="*";if($Qd)$pf[]=$Qd;}$hb=convert_fields($d,$l,$N);if($hb)$pf[]=substr($hb,2);$J=$i->select($a,$pf,$Z,$r,$ee,$z,$F,true);if(!$J)echo"<p class='error'>".error()."\n";else{if($x=="mssql"&&$F)$J->seek($z*$F);$Qb=array();echo"<form action='' method='post' enctype='multipart/form-data'>\n";$M=array();while($L=$J->fetch_assoc()){if($F&&$x=="oracle")unset($L["RNUM"]);$M[]=$L;}if((isset($_GET["page"])?$_GET["page"]:null)!="last"&&+$z&&$r&&$Vc&&$x=="sql")$uc=$e->result(" SELECT FOUND_ROWS()");if(!$M)echo"<p class='message'>".'No rows.'."\n";else{$Ba=$b->backwardKeys($a,$Of);echo"<table id='table' cellspacing='0' class='nowrap checkable' onclick='tableClick(event);' ondblclick='tableClick(event, true);' onkeydown='return editingKeydown(event);'>\n","<thead><tr>".(!$r&&$N?"":"<td><input type='checkbox' id='all-page' onclick='formCheck(this, /check/);'> <a href='".h((isset($_GET["modify"])?$_GET["modify"]:null)?remove_from_uri("modify"):$_SERVER["REQUEST_URI"]."&modify=1")."'>".'Modify'."</a>");$Hd=array();$xc=array();reset($N);$Te=1;foreach((isset($M[0])?$M[0]:null)as$y=>$X){if($y!=$Qd){$X=(isset($_GET["columns"])?$_GET["columns"][key($N)]:null);$k=$l[$N?($X?$X["col"]:current($N)):$y];$E=($k?$b->fieldName($k,$Te):($X["fun"]?"*":$y));if($E!=""){$Te++;$Hd[$y]=$E;$c=idf_escape($y);$Hc=remove_from_uri('(order|desc)[^=]*|page').'&order%5B0%5D='.urlencode($y);$xb="&desc%5B0%5D=1";echo'<th onmouseover="columnMouse(this);" onmouseout="columnMouse(this, \' hidden\');">','<a href="'.h($Hc.((isset($ee[0])?$ee[0]:null)==$c||(isset($ee[0])?$ee[0]:null)==$y||(!$ee&&$Vc&&$r[0]==$c)?$xb:'')).'">';echo
  790. apply_sql_function($X["fun"],$E)."</a>";echo"<span class='column hidden'>","<a href='".h($Hc.$xb)."' title='".'descending'."' class='text'> ↓</a>";if(!$X["fun"])echo'<a href="#fieldset-search" onclick="selectSearch(\''.h(js_escape($y)).'\'); return false;" title="'.'Search'.'" class="text jsonly"> =</a>';echo"</span>";}$xc[$y]=$X["fun"];next($N);}}$md=array();if((isset($_GET["modify"])?$_GET["modify"]:null)){foreach($M
  791. as$L){foreach($L
  792. as$y=>$X)$md[$y]=max($md[$y],min(40,strlen(utf8_decode($X))));}}echo($Ba?"<th>".'Relations':"")."</thead>\n";if(is_ajax()){if($z%2==1&&$F%2==1)odd();ob_end_clean();}foreach($b->rowDescriptions($M,$n)as$D=>$L){$vg=unique_array($M[$D],$v);if(!$vg){$vg=array();foreach($M[$D]as$y=>$X){if(!preg_match('~^(COUNT\\((\\*|(DISTINCT )?`(?:[^`]|``)+`)\\)|(AVG|GROUP_CONCAT|MAX|MIN|SUM)\\(`(?:[^`]|``)+`\\))$~',$y))$vg[$y]=$X;}}$wg="";foreach($vg
  793. as$y=>$X){if(($x=="sql"||$x=="pgsql")&&strlen($X)>64){$y="MD5(".(strpos($y,'(')?$y:idf_escape($y)).")";$X=md5($X);}$wg.="&".($X!==null?urlencode("where[".bracket_escape($y)."]")."=".urlencode($X):"null%5B%5D=".urlencode($y));}echo"<tr".odd().">".(!$r&&$N?"":"<td>".checkbox("check[]",substr($wg,1),in_array(substr($wg,1),(array)(isset($_POST["check"])?$_POST["check"]:null)),"","this.form['all'].checked = false; formUncheck('all-page');").($Vc||information_schema(DB)?"":" <a href='".h(ME."edit=".urlencode($a).$wg)."'>".'edit'."</a>"));foreach($L
  794. as$y=>$X){if(isset($Hd[$y])){$k=$l[$y];if($X!=""&&(!isset($Qb[$y])||$Qb[$y]!=""))$Qb[$y]=(is_mail($X)?$Hd[$y]:"");$_="";if(preg_match('~blob|bytea|raw|file~',$k["type"])&&$X!="")$_=ME.'download='.urlencode($a).'&field='.urlencode($y).$wg;if(!$_&&$X!==null){foreach((array)(isset($n[$y])?$n[$y]:null)as$m){if(count($n[$y])==1||end($m["source"])==$y){$_="";foreach($m["source"]as$s=>$zf)$_.=where_link($s,$m["target"][$s],$M[$D][$zf]);$_=($m["db"]!=""?preg_replace('~([?&]db=)[^&]+~','\\1'.urlencode($m["db"]),ME):ME).'select='.urlencode($m["table"]).$_;if(count($m["source"])==1)break;}}}if($y=="COUNT(*)"){$_=ME."select=".urlencode($a);$s=0;foreach((array)$_GET["where"]as$W){if(!array_key_exists($W["col"],$vg))$_.=where_link($s++,$W["col"],$W["val"],$W["op"]);}foreach($vg
  795. as$Zc=>$W)$_.=where_link($s++,$Zc,$W);}$X=select_value($X,$_,$k,$Zf);$t=h("val[$wg][".bracket_escape($y)."]");$Y=(isset($_POST["val"])?$_POST["val"][$wg][bracket_escape($y)]:null);$Lb=!is_array($L[$y])&&is_utf8($X)&&$M[$D][$y]==$L[$y]&&!$xc[$y];$Yf=preg_match('~text|lob~',$k["type"]);if(((isset($_GET["modify"])?$_GET["modify"]:null)&&$Lb)||$Y!==null){$Ac=h($Y!==null?$Y:$L[$y]);echo"<td>".($Yf?"<textarea name='$t' cols='30' rows='".(substr_count($L[$y],"\n")+1)."'>$Ac</textarea>":"<input name='$t' value='$Ac' size='$md[$y]'>");}else{$rd=strpos($X,"<i>...</i>");echo"<td id='$t' onclick=\"selectClick(this, event, ".($rd?2:($Yf?1:0)).($Lb?"":", '".h('Use edit link to modify this value.')."'").");\">$X";}}}if($Ba)echo"<td>";$b->backwardKeysPrint($Ba,$M[$D]);echo"</tr>\n";}if(is_ajax())exit;echo"</table>\n";}if(($M||$F)&&!is_ajax()){$ac=true;if((isset($_GET["page"])?$_GET["page"]:null)!="last"){if(!+$z)$uc=count($M);elseif($x!="sql"||!$Vc){$uc=($Vc?false:found_rows($R,$Z));if($uc<max(1e4,2*($F+1)*$z))$uc=reset(slow_query(count_rows($a,$Z,$Vc,$r)));else$ac=false;}}if(+$z&&($uc===false||$uc>$z||$F)){echo"<p class='pages'>";$vd=($uc===false?$F+(count($M)>=$z?2:1):floor(($uc-1)/$z));if($x!="simpledb"){echo'<a href="'.h(remove_from_uri("page"))."\" onclick=\"pageClick(this.href, +prompt('".'Page'."', '".($F+1)."'), event); return false;\">".'Page'."</a>:",pagination(0,$F).($F>5?" ...":"");for($s=max(1,$F-4);$s<min($vd,$F+5);$s++)echo
  796. pagination($s,$F);if($vd>0){echo($F+5<$vd?" ...":""),($ac&&$uc!==false?pagination($vd,$F):" <a href='".h(remove_from_uri("page")."&page=last")."' title='~$vd'>".'last'."</a>");}echo(($uc===false?count($M)+1:$uc-$F*$z)>$z?' <a href="'.h(remove_from_uri("page")."&page=".($F+1)).'" onclick="return !selectLoadMore(this, '.(+$z).', \''.'Loading'.'...\');" class="loadmore">'.'Load more data'.'</a>':'');}else{echo'Page'.":",pagination(0,$F).($F>1?" ...":""),($F?pagination($F,$F):""),($vd>$F?pagination($F+1,$F).($vd>$F+1?" ...":""):"");}}echo"<p class='count'>\n",($uc!==false?"(".($ac?"":"~ ").lang(array('%d row','%d rows'),$uc).") ":"");$Bb=($ac?"":"~ ").$uc;echo
  797. checkbox("all",1,0,'whole result',"var checked = formChecked(this, /check/); selectCount('selected', this.checked ? '$Bb' : checked); selectCount('selected2', this.checked || !checked ? '$Bb' : checked);")."\n";if($b->selectCommandPrint()){echo'<fieldset',(!empty($_GET["modify"])?'':' class="jsonly"'),'><legend>Modify</legend><div>
  798. <input type="submit" value="Save"',(!empty($_GET["modify"])?'':' title="'.'Ctrl+click on a value to modify it.'.'"'),'>
  799. </div></fieldset>
  800. <fieldset><legend>Selected <span id="selected"></span></legend><div>
  801. <input type="submit" name="edit" value="Edit">
  802. <input type="submit" name="clone" value="Clone">
  803. <input type="submit" name="delete" value="Delete"',confirm(),'>
  804. </div></fieldset>
  805. ';}$sc=$b->dumpFormat();foreach((array)(isset($_GET["columns"])?$_GET["columns"]:null)as$c){if($c["fun"]){unset($sc['sql']);break;}}if($sc){print_fieldset("export",'Export'." <span id='selected2'></span>");$ne=$b->dumpOutput();echo($ne?html_select("output",$ne,$ma["output"])." ":""),html_select("format",$sc,$ma["format"])," <input type='submit' name='export' value='".'Export'."'>\n","</div></fieldset>\n";}echo(!$r&&$N?"":"<script type='text/javascript'>tableCheck();</script>\n");}if($b->selectImportPrint()){print_fieldset("import",'Import',!$M);echo"<input type='file' name='csv_file'> ",html_select("separator",array("csv"=>"CSV,","csv;"=>"CSV;","tsv"=>"TSV"),$ma["format"],1);echo" <input type='submit' name='import' value='".'Import'."'>","</div></fieldset>\n";}$b->selectEmailPrint(array_filter($Qb,'strlen'),$d);echo"<p><input type='hidden' name='token' value='$T'></p>\n","</form>\n";}}if(is_ajax()){ob_end_clean();exit;}}elseif(isset($_GET["variables"])){$Cf=isset($_GET["status"]);page_header($Cf?'Status':'Variables');$Hg=($Cf?show_status():show_variables());if(!$Hg)echo"<p class='message'>".'No rows.'."\n";else{echo"<table cellspacing='0'>\n";foreach($Hg
  806. as$y=>$X){echo"<tr>","<th><code class='jush-".$x.($Cf?"status":"set")."'>".h($y)."</code>","<td>".nbsp($X);}echo"</table>\n";}}elseif(isset($_GET["script"])){header("Content-Type: text/javascript; charset=utf-8");if($_GET["script"]=="db"){$Lf=array("Data_length"=>0,"Index_length"=>0,"Data_free"=>0);foreach(table_status()as$E=>$R){$t=js_escape($E);json_row("Comment-$t",nbsp($R["Comment"]));if(!is_view($R)){foreach(array("Engine","Collation")as$y)json_row("$y-$t",nbsp($R[$y]));foreach($Lf+array("Auto_increment"=>0,"Rows"=>0)as$y=>$X){if($R[$y]!=""){$X=format_number($R[$y]);json_row("$y-$t",($y=="Rows"&&$X&&$R["Engine"]==($Af=="pgsql"?"table":"InnoDB")?"~ $X":$X));if(isset($Lf[$y]))$Lf[$y]+=($R["Engine"]!="InnoDB"||$y!="Data_free"?$R[$y]:0);}elseif(array_key_exists($y,$R))json_row("$y-$t");}}}foreach($Lf
  807. as$y=>$X)json_row("sum-$y",format_number($X));json_row("");}elseif($_GET["script"]=="kill")$e->query("KILL ".(+$_POST["kill"]));else{foreach(count_tables($b->databases())as$h=>$X){json_row("tables-$h",$X);json_row("size-$h",db_size($h));}json_row("");}exit;}else{$Tf=array_merge((array)(isset($_POST["tables"])?$_POST["tables"]:null),(array)(isset($_POST["views"])?$_POST["views"]:null));if($Tf&&!$j&&!$_POST["search"]){$J=true;$C="";if($x=="sql"&&count($_POST["tables"])>1&&($_POST["drop"]||$_POST["truncate"]||$_POST["copy"]))queries("SET foreign_key_checks = 0");if($_POST["truncate"]){if($_POST["tables"])$J=truncate_tables($_POST["tables"]);$C='Tables have been truncated.';}elseif($_POST["move"]){$J=move_tables((array)$_POST["tables"],(array)$_POST["views"],$_POST["target"]);$C='Tables have been moved.';}elseif($_POST["copy"]){$J=copy_tables((array)$_POST["tables"],(array)$_POST["views"],$_POST["target"]);$C='Tables have been copied.';}elseif($_POST["drop"]){if($_POST["views"])$J=drop_views($_POST["views"]);if($J&&$_POST["tables"])$J=drop_tables($_POST["tables"]);$C='Tables have been dropped.';}elseif($x!="sql"){$J=($x=="sqlite"?queries("VACUUM"):apply_queries("VACUUM".($_POST["optimize"]?"":" ANALYZE"),$_POST["tables"]));$C='Tables have been optimized.';}elseif(!$_POST["tables"])$C='No tables.';elseif($J=queries(($_POST["optimize"]?"OPTIMIZE":($_POST["check"]?"CHECK":($_POST["repair"]?"REPAIR":"ANALYZE")))." TABLE ".implode(", ",array_map('idf_escape',$_POST["tables"])))){while($L=$J->fetch_assoc())$C.="<b>".h($L["Table"])."</b>: ".h($L["Msg_text"])."<br>";}queries_redirect(substr(ME,0,-1),$C,$J);}page_header((empty($_GET["ns"])?'Database'.": ".h(DB):'Schema'.": ".h(empty($_GET["ns"])?null:$_GET["ns"])),$j,true);if($b->homepage()){if((isset($_GET["ns"])?$_GET["ns"]:null)!==""){echo"<h3 id='tables-views'>".'Tables and views'."</h3>\n";$Sf=tables_list();if(!$Sf)echo"<p class='message'>".'No tables.'."\n";else{echo"<form action='' method='post'>\n";if(support("table")){echo"<fieldset><legend>".'Search data in tables'." <span id='selected2'></span></legend><div>","<input type='search' name='query' value='".h($_POST["query"])."'> <input type='submit' name='search' value='".'Search'."'>\n","</div></fieldset>\n";if($_POST["search"]&&$_POST["query"]!="")search_tables();}echo"<table cellspacing='0' class='nowrap checkable' onclick='tableClick(event);' ondblclick='tableClick(event, true);'>\n",'<thead><tr class="wrap"><td><input id="check-all" type="checkbox" onclick="formCheck(this, /^(tables|views)\[/);">','<th>'.'Table','<td>'.'Engine','<td>'.'Collation','<td>'.'Data Length','<td>'.'Index Length','<td>'.'Data Free','<td>'.'Auto Increment','<td>'.'Rows',(support("comment")?'<td>'.'Comment':''),"</thead>\n";$S=0;foreach($Sf
  808. as$E=>$U){$Jg=($U!==null&&!preg_match('~table~i',$U));echo'<tr'.odd().'><td>'.checkbox(($Jg?"views[]":"tables[]"),$E,in_array($E,$Tf,true),"","formUncheck('check-all');"),'<th>'.(support("table")||support("indexes")?'<a href="'.h(ME).'table='.urlencode($E).'" title="'.'Show structure'.'">'.h($E).'</a>':h($E));if($Jg){echo'<td colspan="6"><a href="'.h(ME)."view=".urlencode($E).'" title="'.'Alter view'.'">'.'View'.'</a>','<td align="right"><a href="'.h(ME)."select=".urlencode($E).'" title="'.'Select data'.'">?</a>';}else{foreach(array("Engine"=>array(),"Collation"=>array(),"Data_length"=>array("create",'Alter table'),"Index_length"=>array("indexes",'Alter indexes'),"Data_free"=>array("edit",'New item'),"Auto_increment"=>array("auto_increment=1&create",'Alter table'),"Rows"=>array("select",'Select data'),)as$y=>$_){$t=" id='$y-".h($E)."'";echo($_?"<td align='right'>".(support("table")||$y=="Rows"||(support("indexes")&&$y!="Data_length")?"<a href='".h(ME."$_[0]=").urlencode($E)."'$t title='$_[1]'>?</a>":"<span$t>?</span>"):"<td id='$y-".h($E)."'>&nbsp;");}$S++;}echo(support("comment")?"<td id='Comment-".h($E)."'>&nbsp;":"");}echo"<tr><td>&nbsp;<th>".sprintf('%d in total',count($Sf)),"<td>".nbsp($x=="sql"?$e->result("SELECT @@storage_engine"):""),"<td>".nbsp(db_collation(DB,collations()));foreach(array("Data_length","Index_length","Data_free")as$y)echo"<td align='right' id='sum-$y'>&nbsp;";echo"</table>\n";if(!information_schema(DB)){$Fg="<input type='submit' value='".'Vacuum'."'".on_help("'VACUUM'")."> ";$be="<input type='submit' name='optimize' value='".'Optimize'."'".on_help($x=="sql"?"'OPTIMIZE TABLE'":"'VACUUM OPTIMIZE'")."> ";echo"<fieldset><legend>".'Selected'." <span id='selected'></span></legend><div>".($x=="sqlite"?$Fg:($x=="pgsql"?$Fg.$be:($x=="sql"?"<input type='submit' value='".'Analyze'."'".on_help("'ANALYZE TABLE'")."> ".$be."<input type='submit' name='check' value='".'Check'."'".on_help("'CHECK TABLE'")."> "."<input type='submit' name='repair' value='".'Repair'."'".on_help("'REPAIR TABLE'")."> ":"")))."<input type='submit' name='truncate' value='".'Truncate'."'".confirm().on_help($x=="sqlite"?"'DELETE'":"'TRUNCATE".($x=="pgsql"?"'":" TABLE'"))."> "."<input type='submit' name='drop' value='".'Drop'."'".confirm().on_help("'DROP TABLE'").">\n";$g=(support("scheme")?$b->schemas():$b->databases());if(count($g)!=1&&$x!="sqlite"){$h=(isset($_POST["target"])?$_POST["target"]:(support("scheme")?$_GET["ns"]:DB));echo"<p>".'Move to other database'.": ",($g?html_select("target",$g,$h):'<input name="target" value="'.h($h).'" autocapitalize="off">')," <input type='submit' name='move' value='".'Move'."'>",(support("copy")?" <input type='submit' name='copy' value='".'Copy'."'>":""),"\n";}echo"<input type='hidden' name='all' value='' onclick=\"selectCount('selected', formChecked(this, /^(tables|views)\[/));".(support("table")?" selectCount('selected2', formChecked(this, /^tables\[/) || $S);":"")."\">\n";echo"<input type='hidden' name='token' value='$T'>\n","</div></fieldset>\n";}echo"</form>\n","<script type='text/javascript'>tableCheck();</script>\n";}echo'<p class="links"><a href="'.h(ME).'create=">'.'Create table'."</a>\n",(support("view")?'<a href="'.h(ME).'view=">'.'Create view'."</a>\n":"");if(support("routine")){echo"<h3 id='routines'>".'Routines'."</h3>\n";$kf=routines();if($kf){echo"<table cellspacing='0'>\n",'<thead><tr><th>'.'Name'.'<td>'.'Type'.'<td>'.'Return type'."<td>&nbsp;</thead>\n";odd('');foreach($kf
  809. as$L){echo'<tr'.odd().'>','<th><a href="'.h(ME).($L["ROUTINE_TYPE"]!="PROCEDURE"?'callf=':'call=').urlencode($L["ROUTINE_NAME"]).'">'.h($L["ROUTINE_NAME"]).'</a>','<td>'.h($L["ROUTINE_TYPE"]),'<td>'.h($L["DTD_IDENTIFIER"]),'<td><a href="'.h(ME).($L["ROUTINE_TYPE"]!="PROCEDURE"?'function=':'procedure=').urlencode($L["ROUTINE_NAME"]).'">'.'Alter'."</a>";}echo"</table>\n";}echo'<p class="links">'.(support("procedure")?'<a href="'.h(ME).'procedure=">'.'Create procedure'.'</a>':'').'<a href="'.h(ME).'function=">'.'Create function'."</a>\n";}if(support("event")){echo"<h3 id='events'>".'Events'."</h3>\n";$M=get_rows("SHOW EVENTS");if($M){echo"<table cellspacing='0'>\n","<thead><tr><th>".'Name'."<td>".'Schedule'."<td>".'Start'."<td>".'End'."<td></thead>\n";foreach($M
  810. as$L){echo"<tr>","<th>".h($L["Name"]),"<td>".($L["Execute at"]?'At given time'."<td>".$L["Execute at"]:'Every'." ".$L["Interval value"]." ".$L["Interval field"]."<td>$L[Starts]"),"<td>$L[Ends]",'<td><a href="'.h(ME).'event='.urlencode($L["Name"]).'">'.'Alter'.'</a>';}echo"</table>\n";$Yb=$e->result("SELECT @@event_scheduler");if($Yb&&$Yb!="ON")echo"<p class='error'><code class='jush-sqlset'>event_scheduler</code>: ".h($Yb)."\n";}echo'<p class="links"><a href="'.h(ME).'event=">'.'Create event'."</a>\n";}if($Sf)echo"<script type='text/javascript'>ajaxSetHtml('".js_escape(ME)."script=db');</script>\n";}}}page_footer();