在 Wincm 中构建帮助项目时与文件夹位置相关

发布于 2024-12-22 07:40:48 字数 800 浏览 4 评论 0原文

我正在使用 Winchm 来构建 CHM 文件。我有一个关于 Winchm 的问题,而不是关于 html 或一般构建帮助文件的问题。 更具体地说,问题与构建 chm 文件时的目录结构有关。

如果阅读本文的任何人特别有 Wincmm 的经验,那么请帮助我解决问题。

我有以下目录结构(我觉得这是不言自明的)

htmlfiles

图像

样式表

脚本

无论适用于我的 ht ml 文件引用了要使用的图像/样式表/脚本,如下所示“../imagefilename.jpg”或“../scriptfilename.js”等

当我打开项目时,我注意到 html 页面加载图像正常。当我编译我的文件时,情况有所不同。尽管有文件路径的相对引用,输出 chm 不使用样式表或拾取图像。

但是,当我将文件夹(图像、样式表和脚本)移动到 html 文件文件夹时,输出 chm 按预期工作。

我得出的结论是,相对引用对编译器不起作用,这三个文件夹应该位于 htmlfiles 目录中(或与 html 文件位于同一文件夹中)

问题

  1. 上述结论是否正确?< /p>

  2. 如果不正确,可能是什么问题?

  3. 这是一种通用的东西,即适用于所有 html 文件构建创建工具/套件吗?或者这是 Winchm 特有的?

  4. 是否有任何特定工具不需要将这三个文件夹与 html 文件放在同一目录中?

如果您有任何可以帮助的答案,请告诉我祝您

有美好的一天! 罗米

I am using Winchm for building CHM files. I have a question about Winchm and not about html or building help files in general.
More specifically the question relates to directory structure when building a chm file.

If any body reading this has experience with Winchm in particular, then please help me to solve the problem.

I have the following directory structure (which i feel is self-explanatory)

htmlfiles

images

stylesheets

scripts

Wherever applicable my ht
ml files have a reference to the image/stylesheet/script to be used as follows "../imagefilename.jpg" or "../scriptfilename.js" etc

When i open the project I notice that the html page loads the image okay. Different story when I compile my files. In spite of the relative referencing of the file path the output chm does not use the stylesheet or pick up the image.

However when i move the folders (images, stylesheets & scripts) to the html files folder the output chm works as expected.

The conclusion that I have drawn is that the relative referencing does not work for the compiler and that the three folders should be in the htmlfiles directory (or in the same folder as the html files)

Questions

  1. Is the above conclusion correct?

  2. If it is not correct, what might be the problem?

  3. Is this a generic sort of thing i.e. applicable to all html file building creation tools/ suites? Or is this specific to Winchm?

  4. Are there any specific tools that do not require to have the three folders in the same directory as the html files?

In case you have any answers that can help, please let me know

Have a great day!
Romi

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

半衾梦 2024-12-29 07:40:48

我不知道 winchm,但使用不同的转储工具将 CHM 提取回 HTML 可能会揭示 winchm 如何将其项目转换为 CHM 内部文件系统。

也许它将“htmlfiles”放在文件系统的根目录中。

I don't know winchm, but use a different dumping tool to extract the CHM back to HTML might reveal how winchm transforms its projects to the CHM internal filesystem.

Maybe it puts the "htmlfiles" in the root of the filesystem.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文