Razor (MVC):在 Dreamweaver 5.5 中将 razor 文件视为普通 HTML 文件不起作用
.CSHTML 文件在 DW 5.5 中不显示 SPLIT / Design 选项卡
我按照有关如何向 DW 5.5 添加文件扩展名以允许我打开它的教程进行操作,它将其视为 HTML,但它不起作用。
这是我更改的行。注意 cshtml 的附加
<documenttype id="HTML" internaltype="HTML" winfileextension="html,htm,shtml,shtm,stm,tpl,lasso,xhtml,cshtml"
文件存储在这里:
C:\Program Files (x86)\Adobe\Adobe Dreamweaver CS5.5\配置\文档类型
我做错了什么?
我的文件类型基本上是带有 Div 等的 HTML 文件类型,但有一些自定义的 .NET 代码,可以将其视为文本。
我在 Dreamweaver 中打开该文件,它只显示代码选项卡,设计或分割仍然被禁用。
例如,div 标签上没有颜色编码......
.CSHTML files doesn't show the SPLIT / Design tabs in DW 5.5
I followed a tutorial of how to add a file extension to DW 5.5 to allow me to open it and it treats it as HTML but it isn't functioning.
Here is the line I changed. notice the addtional of cshtml
<documenttype id="HTML" internaltype="HTML" winfileextension="html,htm,shtml,shtm,stm,tpl,lasso,xhtml,cshtml"
The file is stored here:
C:\Program Files (x86)\Adobe\Adobe Dreamweaver
CS5.5\configuration\DocumentTypes
What am I doing wrong?
My file type is basically a HTML file type with Divs etc etc but has some custom .NET code which its fine to treat as TEXT.
I open the file in Dreamweaver and it only shows the code tab, the DESIGN or SPLIT are still disabled.
And there is no color coding on, for example, a div tag...
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
请阅读此处有关添加文件扩展名的信息:
http://kb2.adobe.com/cps/164/tn_16410.html
特别要确保您编辑的是用户配置文件夹中的副本,而不是应用程序文件夹中的副本。如果用户文件夹中没有副本,请在适当的位置创建副本。我只是按照这些指示将 CSHTML 文件扩展名添加到文档类型和扩展文件中,一旦 Dreamweaver 重新启动,就会打开一个 .cshtml 文件,并且能够在设计视图中查看。
Take a read here about adding file extensions:
http://kb2.adobe.com/cps/164/tn_16410.html
In particular make sure you edit the copy in the user configuration folder, not the one in the application folder. If there isn't a copy in the user folder, create a copy in the appropriate location. I just followed those directions adding a CSHTML file extension to the document types and extensions file, and once Dreamweaver is restarted, a .cshtml file opened with the ability to view in design view.