/* |-------------------------------------------------------------------------- | Elixir Asset Management |-------------------------------------------------------------------------- | | Elixir provides a clean, fluent API for defining some basic Gulp tasks | for your Laravel application. By default, we are compiling the Sass | file for our application, as well as publishing vendor resources. | */
classEncryptCookiesextendsBaseEncrypter { /** * The names of the cookies that should not be encrypted. * * @var array */ protected$except = [ 'cookie_for_js', ]; }
$(".js-data-example-ajax").select2({ ajax: { url: "https://api.github.com/search/repositories", dataType: 'json', delay: 250, data: function (params) { return { q: params.term, // search term page: params.page }; }, processResults: function (data, params) { // parse the results into the format expected by Select2 // since we are using custom formatting functions we do not need to // alter the remote JSON data, except to indicate that infinite // scrolling can be used params.page = params.page || 1; return { results: data.items, pagination: { more: (params.page * 30) < data.total_count } }; }, cache: true }, escapeMarkup: function (markup) { return markup; }, // let our custom formatter work minimumInputLength: 1, templateResult: formatRepo, // omitted for brevity, see the source of this page templateSelection: formatRepoSelection // omitted for brevity, see the source of this page });
禁用模式
1 2 3 4 5 6 7 8
$(".js-programmatic-enable").on("click", function () { $(".js-example-disabled").prop("disabled", false); $(".js-example-disabled-multi").prop("disabled", false); }); $(".js-programmatic-disable").on("click", function () { $(".js-example-disabled").prop("disabled", true); $(".js-example-disabled-multi").prop("disabled", true); });
如果有[ERROR]mysqld:Error while setting value ‘’ONLY_FULL_GROUP_BY,NO_AUTO_VALUE_ON_ZERO,STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,’to ‘sql_mode’ 在my.ini中添加
如果是错误:initialize specified but the data directory has files in it.aborting 管理员身份运行cmd,然后cd至mysql下的bin,运行mysql install,然后就成功了 或者mysql中的data目录已经有数据了, 清空重新执行 执行完后,重启phpstudy
错误四
此时登入 MySQL 报错:#1045 无法登录 MySQL 服务器, 打开 my.ini,找到 [mysqld],在下面添加:
1
skip-grant-tables #(此参数用于忘记mysql密码)并保存
此时使用 root 账号,密码处按回车即可登录。 如果想增加密码,在无密码的情况下进去mysql命令行,找到mysql数据库的user表:修改密码: update user set authentication_string=’新密码’ where user=’root’ ; 此时仍然用root密码仍登录不进去的话,在phpstudy修改密码,原来的密码为空
### 原文
If you don't put a die() or exit() after your header('Location: http://something') your script may continue resulting in unexpected behaviour. This may for example result in content being disclosed that you actually wanted to prevent with the redirect (HTTP 301). The aforementioned may not directly be visible for an end user as the browser may not render it (due to the 301). Conclusion, the exit() and die() functions stop the script from continuing.