我正在尝试构建一个自定义指令,将其内容重新排列为网格.我想转换一个ng-repeat指令的结果,然后重新排序结果元素.
问题是当我element.children()在link函数中调用方法时,我有一个空数组,因为该ng-repeat指令尚未呈现并被解释为注释.
否则,如果其内容为"静态",则该指令的效果很好.
HTML
<grid n='6'>
<div ng-repeat="i in [1,2,3]"></div>
</grid>
Run Code Online (Sandbox Code Playgroud)
我的指令只包含有趣的代码:
app.directive('grid', [function () {
return {
restrict: 'E',
replace: true,
transclude: true,
template: "<div ng-transclude></div>",
link: function (scope, grid, attrs) {
// With an ngRepeat transcluded, els result in an empty array
var els = grid.children();
// ...
};
}]);
Run Code Online (Sandbox Code Playgroud)
我错过了什么?
所以这是我的“问题”,感谢vsftpd,我设置了一个FTP服务器,以便登录和数据传输均应加密。
这是我的vsftpd.conf文件中有趣的部分。
ssl_enable=YES
allow_anon_ssl=NO
require_ssl_reuse=NO
force_local_data_ssl=YES
force_local_logins_ssl=YES
ssl_tlsv1=YES
ssl_sslv2=YES
ssl_sslv3=YES
rsa_cert_file=/etc/vsftpd/vsftpd.pem
rsa_private_key_file=/etc/vsftpd/vsftpd.pem
ssl_ciphers=HIGH
Run Code Online (Sandbox Code Playgroud)
我使用Filezilla作为FTP客户端,连接配置如下:
Protocol : FTP - File Transfer Protocol
Encryption : Require explicit FTP over TLS
Logon type: Normal
Run Code Online (Sandbox Code Playgroud)
注意事项:
加密:普通FTP:不起作用,对此我感到满意。(响应:530非匿名会话必须使用加密。)
加密:要求通过TLS的隐式FTP:也不起作用,服务器拒绝连接。我猜这是因为我强制执行SSL连接。
现在,一旦(显式)连接建立,Filezilla将在窗口底部显示一个小锁图标,指示连接已加密。单击图标了解详细信息。
我想确保数据传输确实是加密的而不是简单的,所以我捕捉到了一切。将文件从我的服务器下载到我的计算机上时,请使用Wireshark卡。
除了找不到SSL协议的单个数据包外,其他所有内容都是TCP。
我没有关于如何确保传输的数据被加密的想法,即使filezilla如此说,并且每次我在Google上搜索“ vsftpd如何确保数据的传输被加密”时,我得到的唯一答案就是“ ssl_enable = YES”或“选中使用SSL复选框” ...
预先感谢您对我的帮助!
我目前正在尝试学习如何使用DBPedia上的资源使用SPARQL查询RDF数据并尝试使用Virtuoso SPARQL查询编辑器,但我似乎误解了一些东西.
例如,我试图找到Pulp Fiction的导演名称,使用这个资源:
http://dbpedia.org/resource/Pulp_Fiction,所以我的(简单)查询是:
SELECT ?dirName
FROM <http://dbpedia.org/resource/Pulp_Fiction>
WHERE
{
?s <http://dbpedia.org/property/director> ?dirName.
}
Run Code Online (Sandbox Code Playgroud)
它可以工作,但结果是一个URI资源:http://dbpedia.org/resource/Quentin_Tarantino.现在我想找回导演的出生名,所以我试过了
SELECT ?dirRes ?dirName
FROM <http://dbpedia.org/resource/Pulp_Fiction>
WHERE
{
?s <http://dbpedia.org/property/director> ?dirRes.
?dirRes <http://dbpedia.org/ontology/birthDate> ?dirName.
}
Run Code Online (Sandbox Code Playgroud)
没有成功,结果是一个空数组......
有人可以帮我弄这个吗 ?
谢谢 !