我不明白...... call
它总是未定义的
创建模拟文件:
var mockFile = { name: "Filename", size: 12345 };
Run Code Online (Sandbox Code Playgroud)
调用默认的addedfile事件处理程序
myDropzone.options.addedfile.call(myDropzone, mockFile);
Run Code Online (Sandbox Code Playgroud)
并可选择显示文件的缩略图:
myDropzone.options. thumbnail.call(myDropzone, mockFile, "/image/url");
Run Code Online (Sandbox Code Playgroud) 我有一个用 ubuntu 16.04 构建的实例,它有 2 个应用程序(没有 bitnami)
我设置了指向两个不同网站的虚拟主机,它工作正常
但现在我正在尝试验证我一直在努力的 ssl 证书
首先,我想知道是否可以在不使用负载均衡器的情况下进行设置?
在 AWS Lightsail ssl 文档中,他们只提到了负载均衡器,但我也有一个带有 SSL 证书的域(我在 namecheap 上有我的域)
我尝试了 certbot,看起来人们没有使用负载均衡器进行设置,但使用了 bitnami 文档中的步骤..但我没有使用 bitnami
配置一切以下步骤从https://certbot.eff.org/lets-encrypt/ubuntuxenial-apache测试了上https://www.ssllabs.com/ssltest/但我不能让它工作,它只做http 重定向到 https...但 https 显示 herrorThis site can’t be reached
我没有设置任何 DNS 我没有看到任何 turials 在 aws lightail ssl 中使用它
运行apachectl configtest
没有错误
我在我的防火墙上创建了一个规则
http port 80
https port 443
Run Code Online (Sandbox Code Playgroud)
我还能看什么?我真的很困惑,不知道有什么问题
非常感谢
我最近更新了laster版本vue-cli 3
创建项目并运行它后,它将显示该消息
//eslint-disable-next-line
忽略下一行./* eslint-disable */
忽略文件中的所有警告.但是我应该在哪个文件中添加这些评论?
我的根文件夹上只有一个package.json/package-lock.json和.gitignore
我是否必须创建.eslintrc?
我基本上开始使用angular 4并使用ngChanges遇到此错误
类“ GalleryComponent”错误地实现了接口“ OnChanges”。类型“ GalleryComponent”中缺少属性“ ngOnChanges”。
我真的不知道该怎么办,我知道一个类可以有多个接口,但是仅使用一个接口就可以显示相同的错误
import { Component, OnInit, OnChanges, Input } from '@angular/core';
import { ImageService } from '../image/shared/image.service';
@Component({
selector: 'app-gallery',
templateUrl: './gallery.component.html',
styleUrls: ['./gallery.component.css']
})
export class GalleryComponent implements OnInit, OnChanges {
visibleImages: any[] = [];
constructor(private imageService: ImageService) {
this.visibleImages = this.imageService.getImages();
}
ngOnInit() {}
OnChanges(){}
}
Run Code Online (Sandbox Code Playgroud)
如果有人能提前注意到我所缺少的,我将非常感谢
我正在使用角度材料Sidenav它运作良好,但问题是选择一个选项后菜单仍然打开.这很奇怪,这意味着用作小型设备的导航,而doc没有任何使用链接的示例
App.component
<md-sidenav-container>
<md-sidenav #sidenav class="sidenav" mode="over">
<ul class="sidenav">
<li class="sidenav__list">
<a class="sidenav__list__link " [routerLink]="['about']" >about</a>
</li>
</ul>
</md-sidenav>
<header>
<div fxHide fxShow.lt-sm>
<button class="btn__sidenav" md-button (click)="sidenav.toggle()">
<i class="material-icons md-36">menu</i>
</button>
</div>
</ng-template>
</header>
<div class="container">
<router-outlet></router-outlet>
</div>
<wh-footer></wh-footer>
</md-sidenav-container>
Run Code Online (Sandbox Code Playgroud)
基本上,我必须加载关于页面的内容,并在点击链接时关闭菜单,我不知道我是否必须手动或是否有任何我可以使用的指令或属性
我正在使用材质角度选择组件.当我点击选择器时我可以看到图标,但问题是当我选择一个选项时它只显示值而不是图标.
目前代码正在重写<md-option>
删除<img>
标记并添加{{bodyStyle.viewValue}}
app.component.html
<div class="form-control form-control--center">
<md-select [(ngModel)]="selectedBodystyle" floatPlaceholder="never" name="bodyStyle">
<md-option *ngFor="let bodyStyle of bodyStyles" [value]="bodyStyle.value">
<img src="{{bodyStyle.icon}}" alt="{{bodyStyle.viewValue}}">
{{bodyStyle.viewValue}}
</md-option>
</md-select>
</div>
Run Code Online (Sandbox Code Playgroud)
app.component.ts
selectedBodystyle: string;
bodyStyles = [
{ value: 'Mercedez' , viewValue: 'Mercedez', icon: "http://lorempixel.com/50/50/transport/" },
{ value: 'Ferrari' , viewValue: 'Ferrari' , icon: "http://lorempixel.com/50/50/transport/" },
{ value: 'BMW' , viewValue: 'BMW' , icon: "http://lorempixel.com/50/50/transport/" }
];
Run Code Online (Sandbox Code Playgroud)
更新
我试图在viewValue
属性中添加图像
{ value: 'Ferrari' , viewValue: '<img src="http://lorempixel.com/50/50/transport/" alt="Ferrari">Ferrari' }
Run Code Online (Sandbox Code Playgroud)
但它以纯文本加载html,在选中后不会显示图像 …
问题是我正在使用RestAPI来展示电影但是如何找回"gd $ etag"的修道院呢?
foreach ($movies->feed->entry as $key => $value) {
echo "<iframe id='player' type='text/html' width='640' height='390'
src=" . $value->content->src. "
frameborder='0'></iframe>";
var_dump($value->gd$etag);
}
Run Code Online (Sandbox Code Playgroud)
我收到一个Parse错误:语法错误,意外的'$ etag'(T_VARIABLE)i
我一直在使用validator.w3.org作为HTML5收到此错误
"此时元素div上不允许属性ng-view"
如何通过div传递ng-view来解决这个问题?
<div ng-view></div>
Run Code Online (Sandbox Code Playgroud) angular ×3
angularjs ×1
dropzone.js ×1
implements ×1
javascript ×1
oop ×1
php ×1
ssl ×1
validation ×1
vue-cli ×1
vuejs2 ×1
w3c ×1