嗨,我用http.get从数据库中获取文本.如何使用浏览器检测?如何使用if子句?我不想使用translate.toogle()
var mainCtrl = function ($scope, $http, $sce, $location,$timeout,$routeParams, toastr) {
$scope.showPage = false;
$timeout(function(){
$scope.showPage = true;
},2000);
$scope.trustedHtml = function (plainText) {
return $sce.trustAsHtml(plainText);
}
$http.get('admin/api/?s=getAbout').success(
##### if browser En_en
function(r){
$scope.about = r.text_en;
##### if browser De_de
function(r){
$scope.about = r.text_de;
}
);
};
Run Code Online (Sandbox Code Playgroud) 我想使用 shell 命令连接到外部服务器上的 mysql 数据库。Ubuntu 版本 16.04。
mysql -uXXXXXX -pYYYYYY -h domain.com
Run Code Online (Sandbox Code Playgroud)
我得到错误:
mysql: [Warning] Using a password on the command line interface can be insecure.
ERROR 2059 (HY000): Authentication plugin 'mysql_old_password' cannot be loaded: /usr/lib/mysql/plugin/mysql_old_password.so: cannot open shared object file: No such file or directory
Run Code Online (Sandbox Code Playgroud)