小编psc*_*ler的帖子

CSS counter-reset在伪元素中不起作用

以下CSS计数器示例无法按预期工作.子标题的计数器应在每个主标题后重置:

body {
  font: smaller sans-serif;
  counter-reset: h1 h2;
}
h1:before {
  counter-reset: h2;
  content: counter(h1) ". ";
  counter-increment: h1;
}
h2:before {
  content: counter(h1) "." counter(h2) ". ";
  counter-increment: h2;
}
Run Code Online (Sandbox Code Playgroud)
<h1>Heading</h1>
<h2>Sub-heading</h2>
<h2>Sub-heading</h2>
<h1>Heading</h1>
<h2>Sub-heading</h2>
<h2>Sub-heading</h2>
Run Code Online (Sandbox Code Playgroud)

但是,以下工作符合预期:

body {
  font: smaller sans-serif;
  counter-reset: h1 h2;
}
h1:before {
  content: counter(h1) ". ";
  counter-increment: h1;
}
h1 {
  counter-reset: h2;
}
h2:before {
  content: counter(h1) "." counter(h2) ". ";
  counter-increment: h2;
}
Run Code Online (Sandbox Code Playgroud)
<h1>Heading</h1>
<h2>Sub-heading</h2>
<h2>Sub-heading</h2>
<h1>Heading</h1>
<h2>Sub-heading</h2>
<h2>Sub-heading</h2>
Run Code Online (Sandbox Code Playgroud)

我的问题是,为什么 …

html css pseudo-element css-counter

10
推荐指数
1
解决办法
1401
查看次数

ShareKit ios的链接器错误

我花了3天时间来搜索解决方案.我不知道该怎么做...我需要SDWebImage库的-ObjC标志(我认为也是AFNetworking).我可以删除它,ShareKit一切都很好,但SDwebImage不行.

Undefined symbols for architecture i386:
  "_ABAddressBookCopyArrayOfAllPeople", referenced from:
      ___48+[GPPAddressBook loadDeviceContactsWithHandler:]_block_invoke in GooglePlus(GPPAddressBook.o)
  "_ABAddressBookCreateWithOptions", referenced from:
      +[GPPAddressBook loadDeviceContactsWithHandler:] in GooglePlus(GPPAddressBook.o)
  "_ABAddressBookGetPersonCount", referenced from:
      ___48+[GPPAddressBook loadDeviceContactsWithHandler:]_block_invoke in GooglePlus(GPPAddressBook.o)
  "_ABAddressBookRequestAccessWithCompletion", referenced from:
      +[GPPAddressBook loadDeviceContactsWithHandler:] in GooglePlus(GPPAddressBook.o)
  "_ABMultiValueCopyValueAtIndex", referenced from:
      ___48+[GPPAddressBook loadDeviceContactsWithHandler:]_block_invoke in GooglePlus(GPPAddressBook.o)
  "_ABMultiValueGetCount", referenced from:
      ___48+[GPPAddressBook loadDeviceContactsWithHandler:]_block_invoke in GooglePlus(GPPAddressBook.o)
  "_ABPersonCopyImageDataWithFormat", referenced from:
      ___48+[GPPAddressBook loadDeviceContactsWithHandler:]_block_invoke in GooglePlus(GPPAddressBook.o)
  "_ABPersonHasImageData", referenced from:
      ___48+[GPPAddressBook loadDeviceContactsWithHandler:]_block_invoke in GooglePlus(GPPAddressBook.o)
  "_ABRecordCopyValue", referenced from:
      ___48+[GPPAddressBook loadDeviceContactsWithHandler:]_block_invoke in GooglePlus(GPPAddressBook.o)
  "_ACAccountTypeIdentifierFacebook", referenced from:
      -[SHKiOSFacebook accountTypeIdentifier] in libShareKit.a(SHKiOSFacebook.o)
  "_ACAccountTypeIdentifierSinaWeibo", referenced from:
      -[SHKSinaWeibo …
Run Code Online (Sandbox Code Playgroud)

linker objective-c ios sharekit sdwebimage

9
推荐指数
2
解决办法
1万
查看次数

通过OleDb ACE访问Excel 2007二进制文件(.xlsb)

我发现Excel 2007二进制格式(扩展名为.xlsb)完全适合我的需要,因为它加载速度快,非常紧凑.我在Excel中提供了大量带有大量数据的报告,这些报告实际上正在加载IS包.

所以我假设转换为这种格式,阅读Access Ole DB Provider 12上的文档,其中写道xlsb受此提供程序支持.我在Excel中转​​换了文件,然后在尝试在包中更改它们时(只需通过添加"b"后缀来更改文件的路径),我收到以下错误消息:

"Test connection failed because of an error in initializing provider. This 
file was created in a previous beta version of Excel 2007.  Open the file 
with Excel 2007 to save it to the most recent version of the Excel 2007 file 
format before opening the file in Access 2007."
Run Code Online (Sandbox Code Playgroud)

好吧,我认为这可能是文件转换的一些问题,所以我选了一个全新的文件,并填写了一些信息.再试一次,同样的错误!!

然后我用".udl"文件尝试了这个方法,同样的错误!然后我尝试在不同的机器上进行测试: - 我自己的(Windows Vista SP1) - 我的同事(Windows XP SP2) - IS服务器(Windows Server 2003 x64 SP2)

错误仍然存​​在.我发现重现错误很容易,我有点惊讶,我没有通过谷歌搜索找到任何关于它的东西!

有人能帮助我吗?

谢谢,拉斐尔

oledb ssis excel-2007

8
推荐指数
1
解决办法
4804
查看次数

如何定位DIV以填充标题DIV和页脚DIV之间的所有可用空间?

假设我有父DIV.在里面,有三个子DIV:标题,内容和页脚.标题附加到父级的顶部并水平填充.页脚连接到父级的底部并且也水平填充.内容应该填充页眉和页脚之间的所有空间.

父母必须有固定的宽度和高度.内容DIV必须填充页眉和页脚之间的所有可用空间.当内容DIV的内容大小超过页眉和页脚之间的空间时,内容DIV应显示滚动条并允许适当的滚动,以使页脚内容不应被遮挡,页脚内容也不会模糊.

现在是困难的部分:你事先不知道页眉或页脚的高度(例如,页眉和页脚是动态填充的).如何在不使用JavaScript的情况下定位内容?

例:

<div style="position : relative; width : 200px; height : 200px; background-color : #e0e0ff; overflow : hidden;">
    <div style="background-color: #80ff80; position : absolute; left : 0; right : 0; top : 0;">
    header 
    </div>
    <div style="background-color: #8080ff; overflow : auto; position : absolute;">
    content (how to position it?)
    </div>
    <div style="background-color: #ff8080; position : absolute; bottom : 0px; left :0; right : 0;">
    footer 
    </div>    
</div>
Run Code Online (Sandbox Code Playgroud)

为了进一步澄清此事件 - 我正在尝试实现的目标布局将用于业务Web应用程序.父DIV将具有固定但未知的大小(例如,它将与浏览器视口的大小完全相同,自身大小调整以及用户调整浏览器窗口的大小).让我们将父DIV称为"屏幕". …

html css

7
推荐指数
1
解决办法
2万
查看次数

Logistic Regression Scikit-Learn 获取分类系数

我正在做多类分类并对其应用逻辑回归

当我通过调用拟合数据时

logistic.fit(InputDATA,OutputDATA)
Run Code Online (Sandbox Code Playgroud)

估算器“logistic”适合数据。

现在,当我调用logistic.coef_它时,它会打印一个 4 行(我有四类)和 n 列(每个功能一个)的二维数组

这是我在 SCIKIT 学习网站上看到的:

coef_ : 数组、形状 (n_features, ) 或 (n_targets, n_features) 线性回归问题的估计系数。如果在拟合期间传递了多个目标(y 2D),则这是一个形状为 (n_targets, n_features) 的二维数组,而如果仅传递一个目标,则这是一个长度为 n_features 的一维数组。

现在我的问题是:为什么不同的类有不同的系数,因为我只需要一个可以预测输出的假设。

machine-learning scikit-learn logistic-regression

7
推荐指数
1
解决办法
3650
查看次数

如何使用经度和纬度在世界地图上查找城市的像素坐标?

我的世界地图宽800像素,高340像素.我怎样才能找到像纽约这样的城市的位置,如北纬40.75和经度-73.98?我想在这一点上标记一个标记.

到目前为止,我一直在手动添加城市,这是有问题的.

有没有办法将纬度和经度值转换为x和y坐标?

谢谢

maps coordinates

5
推荐指数
1
解决办法
3689
查看次数