简体   繁体   English

Dreamweaver模板始终将绝对地址放在脚本src中

[英]dreamweaver templates keep putting absolute addresses in script src

I moved a set of templates to a new folder also named Templates so the instructional designer can see them in her "New page from Template" window. 我将一组模板移到也称为“模板”的新文件夹中,以便指导设计人员可以在她的“从模板新建页面”窗口中看到它们。 For some reason, I as the programmer can see the list if I try to make a new page from template, but the ID couldn't. 出于某种原因,如果我尝试从模板制作新页面,那么作为程序员,我可以看到列表,但ID无法显示。 While moving them allowed her to see them, it broke all the relative links to the js script src files. 当移动它们使她能够看到它们时,它断开了与js脚本src文件的所有相关链接。 And when she tries to save the template page, it tells her to try and copy files and the absolute links don't get reset to their relative paths. 当她尝试保存模板页面时,它告诉她尝试复制文件,并且绝对链接不会重置为它们的相对路径。

Is there a way to reset the relative links to those .dwt files? 有没有办法重置到那些.dwt文件的相对链接? When I open the .dwt files, the relative links look correct; 当我打开.dwt文件时,相对链接看起来正确; but when the ID makes a new page and then chooses a template to use, the links break at that point. 但是,当ID创建新页面,然后选择要使用的模板时,链接会在此时断开。

What do I need to do make the templates retain the relative links again? 我该怎么做才能使模板再次保留相对链接?

Thanks in advance! 提前致谢! Carlos 卡洛斯

When I moved the templates, it wasn't just in a new folder, but on a new level in the folder structure, so the old script src address "../../scripts/nav.js" wouldn't work because in its new location, it overshot the folder by one level and hence couldn't find the js file in question. 当我移动模板时,它不仅位于新文件夹中,而且位于文件夹结构中的新级别上,因此旧脚本src地址“ ../../scripts/nav.js”将不起作用,因为在新位置,它比文件夹高出一级,因此找不到相关的js文件。 Readjusting the relative links to compensate for its new location and structure level fixed this issue. 重新调整相对链接以补偿其新的位置和结构级别可以解决此问题。

Carlos 卡洛斯

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM