This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# | |
# Yandex.Disk backup script v1.0 by Sergey Lukonin (neblog.info) | |
# | |
# # # # # # # # # # НАСТРОЙКИ БЕКАПА MYSQL # # # # # # # # # # | |
# Сервер БД | |
MYSQL_SERVER=mysql.some-server.ru | |
# Юзер, под которым будем делать бекап доступных баз, руту mysql обычно доступны все БД, отдельному пользователю обычно доступна БД конкретного проекта |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* xml2array() will convert the given XML text to an array in the XML structure. | |
* Link: http://www.bin-co.com/php/scripts/xml2array/ | |
* Arguments : $contents - The XML text | |
* $get_attributes - 1 or 0. If this is 1 the function will get the attributes as well as the tag values - this results in a different array structure in the return value. | |
* $priority - Can be 'tag' or 'attribute'. This will change the way the resulting array sturcture. For 'tag', the tags are given more importance. | |
* Return: The parsed XML in an array form. Use print_r() to see the resulting array structure. | |
* Examples: $array = xml2array(file_get_contents('feed.xml')); | |
* $array = xml2array(file_get_contents('feed.xml', 1, 'attribute')); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<b>Update (2014):</b> Это статья 2007 года, которая, к моему удивлению, до сих пор пользуется спросом. По этой причине я обновил её в соответствии с новыми правилами оформления постов на Хабре, и добавил подсветку синтаксиса для примеров кода. Если кому-то захочется что-то добавить или исправить, исходник текста с хабра-разметкой выложен в открытый доступ: https://gist.github.com/dreikanter/2b4ee996d7a775e707d7 | |
<h4>Аннотация от переводчика</h4> | |
PHP — один из самых широко распространенных языков разработки веб-приложений и при этом один из самых спорных. Я очень часто видел негативное отношение к этой технологии, да и недостатки, провоцирующие это отношение — не для кого не являются секретом. Тем не менее, PHP активно эволюционирует и во многих отношениях постепенно становитс лучше. Одним из серьезных шагов его развития, на мой взгляд, является появление MVC-фреймворков, призванных систематизировать процесс разработки веб-приложений и приучить к порядку разработчиков, которым зачастую здорово не хватает силы |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
javascript: (function () { | |
function c() { | |
var e = document.createElement("link"); | |
e.setAttribute("type", "text/css"); | |
e.setAttribute("rel", "stylesheet"); | |
e.setAttribute("href", f); | |
e.setAttribute("class", l); | |
document.body.appendChild(e) | |
} | |
function h() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */ | |
/** | |
* MD5 hash lookup script that returns XML | |
* | |
* written by Ben Ramsey (ben at benramsey dot com) | |
* with code by Ilia Alshanetsky (ilia at ilia dot ws) | |
* | |
* Copyright (c) 2005, Ilia Alshanetsky | |
* Copyright (c) 2005, Ben Ramsey |