打印网页时必须将页码放在"页脚图像标识"上

Den*_*ish 4 html css

我使用此代码在打印页面中设置了页脚图像.

@media print {
    div.divFooter {
        position: fixed;
        background: url(http://path/to/image.png);
        height: 100px; /* put the image height here */
        width: 100px; /* put the image width here */
        bottom: 0;
    }
}
Run Code Online (Sandbox Code Playgroud)

我必须把动态页面没有.像1/5,2/5,3/5 ..等等,其中5是页面的总数.我可以这样做吗?

ale*_*lex 7

@page {
  @bottom-left {
    content: counter(page) "/" counter(pages);
  }
}
Run Code Online (Sandbox Code Playgroud)