- git status
- git add .
- git commit -m "GeekBrains > Yii2 > Lesson 4 > Complete"
- git push
- git pull
- git log
- git config --list
This file contains 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
/* Quick Dirty Patch for Recaptcha with Mootools 1.2 Compatability Layer | |
* | |
* Make sure that all your mootools core/more source is loaded before this | |
* fix is loaded. | |
* | |
* @author James Sleeman <james@gogo.co.nz> | |
* @see https://github.com/google/recaptcha/issues/374 | |
* | |
*/ |
This is a simple way of importing MySQL database in Docker.
-
In you Dockerfile you must have a shared folder. Shared folder is a directory in your host machine that is mounted to Docker instance.
-
Put the exported sql file in the shared folder.
-
Login to your Docker instance via
docker exec -it DOCKER_CONTAINER_ID bin/bash
. -
Login to MySQL via
mysql -u USERNAME -p
.
This file contains 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
//Шаг 2 - в компоненте добавляем проверку: | |
<? | |
$recaptcha = new \ReCaptcha\ReCaptcha(RE_SEC_KEY); | |
$resp = $recaptcha->verify($_REQUEST['g-recaptcha-response'], $_SERVER['REMOTE_ADDR']); | |
if (!$resp->isSuccess()){ | |
foreach ($resp->getErrorCodes() as $code) { | |
echo "Ошибка! Проверка не пройдена."; | |
echo $code; | |
return; |
This file contains 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 | |
# simple function to check http response code before downloading a remote file | |
# example usage: | |
# if `validate_url $url >/dev/null`; then dosomething; else echo "does not exist"; fi | |
function validate_url(){ | |
if [[ `wget -S --spider $1 2>&1 | grep 'HTTP/1.1 200 OK'` ]]; then echo "true"; fi | |
} |
People
:bowtie: |
😄 :smile: |
😆 :laughing: |
---|---|---|
😊 :blush: |
😃 :smiley: |
:relaxed: |
😏 :smirk: |
😍 :heart_eyes: |
😘 :kissing_heart: |
😚 :kissing_closed_eyes: |
😳 :flushed: |
😌 :relieved: |
😆 :satisfied: |
😁 :grin: |
😉 :wink: |
😜 :stuck_out_tongue_winking_eye: |
😝 :stuck_out_tongue_closed_eyes: |
😀 :grinning: |
😗 :kissing: |
😙 :kissing_smiling_eyes: |
😛 :stuck_out_tongue: |
This file contains 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
/** | |
* Настройка столбцов списка элементов ИБ в админке инфоблоков | |
* | |
* @param integer $IBlockID — ID инфоблока | |
* @param string $arIBlockListAdminColumns — символьные коды полей и свойств для показа в списке элементов ИБ | |
* @param string $orderByColumnName — наименования поля или свойства по которому нудно отсортировать | |
* @param string $orderDirection - направление сортировки | |
* @param integer $pageSize - количество элементов на страницу | |
* @param boolean $isToAllUsers - значение будет для всех, или для текущего пользователя | |
* @return boolean |