如何从主题文件夹访问资源文件(css,js文件)并从FTL获取链接?(How to access resources file (css, js files from theme folder) and get link from FTL?)
我有“Neon - Bootstrap Admin Theme”( https://themeforest.net/item/neon-bootstrap-admin-theme/6434477 )。 我的职责是将这个引导主题整合到Ofbiz 16.11.02中。 我尝试了3天,但我坚持了下来。
这是我的完整源代码: https ://gitlab.com/Donhu/ofbiz我已经创建了一个新的主题,命名为“BOOTSTRAP”,基于主题“TOMAHAWK”。
我不知道如何访问静态资源文件(css,js,image)
我已将更多信息添加到https://gitlab.com/Donhu/ofbiz/blob/master/framework/common/config/CommonEntityLabels.xml https://gitlab.com/Donhu/ofbiz/tree/master/themes/bootstrap (第一步,我从TOMAHAWK克隆)。
这些文件( https://gitlab.com/Donhu/ofbiz/tree/master/themes/bootstrap/webapp/bootstrap/assets )来自“Neon - Bootstrap Admin Theme”。 我不知道如何访问,如何获取其相关链接,并放入FTL文件(例如: https : //gitlab.com/Donhu/ofbiz/blob/master/themes/bootstrap/template/Header.ftl #L47当前,它不起作用)
<#if layoutSettings.VT_HDR_JAVASCRIPT?has_content> <#list layoutSettings.VT_HDR_JAVASCRIPT as javaScript> <script src="<@ofbizContentUrl>${StringUtil.wrapString(javaScript)}</@ofbizContentUrl>" type="text/javascript"></script> </#list> </#if>
我的问题:如何从自定义主题文件夹访问静态文件,把它放到FTL文件?
I have "Neon - Bootstrap Admin Theme" (https://themeforest.net/item/neon-bootstrap-admin-theme/6434477 ). My duty is integrating this bootstrap theme into Ofbiz 16.11.02. I tried 3 days, but I stucked.
This is my full source code: https://gitlab.com/Donhu/ofbiz I have been create a new theme, named it is "BOOTSTRAP", based on theme "TOMAHAWK".
I don't know how to access static resource files (css, js, image)
I have add more information to https://gitlab.com/Donhu/ofbiz/blob/master/framework/common/config/CommonEntityLabels.xml https://gitlab.com/Donhu/ofbiz/tree/master/themes/bootstrap (first step, I cloned from TOMAHAWK).
These files (https://gitlab.com/Donhu/ofbiz/tree/master/themes/bootstrap/webapp/bootstrap/assets) come from "Neon - Bootstrap Admin Theme". I don't know how to access, how to get its relative links, and put inside FTL file (for example: https://gitlab.com/Donhu/ofbiz/blob/master/themes/bootstrap/template/Header.ftl#L47 Current, it doesn't work)
<#if layoutSettings.VT_HDR_JAVASCRIPT?has_content> <#list layoutSettings.VT_HDR_JAVASCRIPT as javaScript> <script src="<@ofbizContentUrl>${StringUtil.wrapString(javaScript)}</@ofbizContentUrl>" type="text/javascript"></script> </#list> </#if>
My question: How to access static files from customize theme folder, put it to FTL file?
原文:https://stackoverflow.com/questions/44562497
最满意答案
StoreKey.pfx是否意味着要取代TemporaryKey.pfx?
TemporaryKey.pfx
由Visual Studio提供,用于测试您的应用程序。 当您创建不用于发布的包时,它将用于对您的包进行签名,并且您可能需要在需要在另一个设备上侧载包时导出该证书文件。当您将应用程序与Store关联时,它会为您
StoreKey.pfx
准备发布的StoreKey.pfx
,这并不意味着要替换TemporaryKey.pfx
。 它们都存在于您的应用项目中。 您可以选择每个人来签署您的包裹。但要上传您的商店提交包,您必须使用
StoreKey.pfx
,以便开发中心可以识别您的包,因为他们需要接受包含与开发者帐户相同的发布者信息和其他身份信息的包。这是为什么我们在提交UWP应用程序时不需要从赛门铁克等人那里购买经过验证的证书?
是的,当使用Symantec等证书签署侧载软件包时,它可以提供更高的安全性和更长的到期时间。 因此,在大多数情况下,大型企业购买它以签署他们的业务应用程序,该应用程序只能在内部安装。 但是,对于商店提交,我们不需要购买它,因为我们有商店提供的商品。
Is the StoreKey.pfx meant to replace the TemporaryKey.pfx?
The
TemporaryKey.pfx
is offered by Visual Studio for testing your app. When you create package not for publishing, it will be used to sign your package and you may need to export that certificate file when you need to sideload your package on another device.When you associate your app with Store, it gives you
StoreKey.pfx
prepared for publishing, which is not meant to replace theTemporaryKey.pfx
. Both of them exist in your app project. You can choose each of them to sign your package.But to upload your package for Store submission, you must use
StoreKey.pfx
in order that Dev Center can identify your package since they need to accept the package with same publisher info and other identity info as the developer account.Is this is why we don't need to buy a verisigned certificate from someone such as Symantec when submitting UWP applications?
Yes, when using certificate like Symantec to sign a sideloaded package, it can provide more security and longer expiration time. So in most case, big enterprise purchases it to sign their line of business app which can only be installed internally. However, for Store submission, we do not need to purchase it as we have one provided by Store.
相关问答
更多-
是的,但我认为它还没有正式,或者可能没有完成/测试。 它是在微软开发的,现在大部分都应该合并到OpenCV的主分支中。 资料来源: https : //msopentech.com/blog/2014/08/20/opencv-support-for-windows-universal-apps-now-available-on-github/# WinRT支持的初始拉取请求: https : //github.com/Itseez/opencv/pull/3700 Yes there is, but I ...
-
不支持在Windows 10S上自行加载自签名应用程序。 要在通过Windows应用商店发布之前测试应用程序的Win10 S配置,请遵循此指南 。 Sideloading of self-signed apps on Windows 10S is not supported. To test your app for the Win10 S configuration before releasing it via Windows Store, please follow this guidance.
-
StoreKey.pfx是否意味着要取代TemporaryKey.pfx? TemporaryKey.pfx由Visual Studio提供,用于测试您的应用程序。 当您创建不用于发布的包时,它将用于对您的包进行签名,并且您可能需要在需要在另一个设备上侧载包时导出该证书文件。 当您将应用程序与Store关联时,它会为您StoreKey.pfx准备发布的StoreKey.pfx ,这并不意味着要替换TemporaryKey.pfx 。 它们都存在于您的应用项目中。 您可以选择每个人来签署您的包裹。 但要上传您 ...
-
如果确实存在所需的尺寸,请检查图像。 例如,如果图片大小应为150x150并且您有151x151,则会出现错误。 添加package.manifest中的图像,不要更改它们的名称,只需替换以前的图像。 确保添加了所有这些图片尺寸: 300×300 620x300 88x88 24×24 50×50 1240x600(飞溅) 您还可以运行Windows app认证工具包来检查应用程序是否存在错误。 希望能帮助到你 Check images if there are exactly the dimensions ...
-
用于为商店构建Cordova UWP应用程序的证书(Certificate to use for building a Cordova UWP application for the Store)[2024-03-19]
我现在使用商店提供的CordovaApp.Windows10_StoreKey.pfx吗? 此证书将用于签署您的应用包。 如何将此证书安装到用户计算机上(或者当用户从商店下载时会发生这种情况) 当您从Windows应用商店安装应用程序时,将自动安装证书。 do I now use the CordovaApp.Windows10_StoreKey.pfx supplied by the store? This certificate would be used to sign your app packag ... -
如何使用可以侧载的证书创建UWP应用程序(How to created a UWP app with a certificate that can be sideloaded)[2022-04-26]
事实证明我没有安装依赖项。 我将证书添加到“ Trusted Root Authorities Section的Local Computer (非当前用户)。 在此之后,我仍然得到错误,包依赖于未安装的东西。 事实证明这是真的! 根据App Installer页面 App Installer不会自动安装框架依赖项。 在大多数情况下,您的设备已经具有依赖关系,但是在某些开发人员或企业方案中您需要一个额外的框架。 在这种情况下,只需使用您的应用程序浏览依赖项文件夹,并使用App Installer安装依赖框架, ... -
本节中生成的ID适用于所有uwp应用程序,Windows 10桌面,Windows 10移动版和Xbox? 是。 目前,仪表板中的可用选项是UWP(Windows 10),PC / Tablet(Windows 8.1)或Mobile(Windows Phone 8.x)。 对于UWP应用程序,该ID适用于您的程序包所针对的所有设备系列。 您可以参考应用中的设置广告单元 。 也就是说,我只需要一个id(并根据每个设备调整横幅大小),它适用于所有类型的设备(桌面,平板电脑,移动设备和Xbox)? 是的,您只需 ...
-
我遇到了同样的问题,我相信这是因为Package.StoreAssociation.xml没有正确下载/构建,然后如果你在Package.appmanifest中更改你的发布者名称,那么两者就不对齐了。 要解决这个问题,请确保
Package.StoreAssociation.xml文件中的元素(通常位于项目的根目录中)设置为与 开发中心 - >帐户设置 - >公共信息 - >出版商显示名称 它也与您的“发布商显示 ... -
我可以将该信息提交到公共git存储库(证书必须在存储库中,因为我想使用AppVeyor构建包)吗? 对于公共git存储库,不应提交Store密钥.pfx文件(添加到.gitignore文件)。 如果要使用CI系统,请创建私有存储库或将.pfx文件附加到CI后端的克隆项目中。 我应该加密吗? 此文件已加密,用于在提交到Windows应用商店之前对应用进行签名,另请参阅如何创建应用包签名证书 如果泄露证书,我可以撤销证书吗? 您需要保留一个新的应用名称,请参阅此处 appxmanifest的变化是否敏感? 取决 ...
-
Windows 10 IoT上的UWP(UWP on windows 10 IoT)[2022-04-08]
我的想法是在Raspberry上同时运行UWP和asp.Net Web应用程序。 可能吗? Windows IoT核心不支持.Net Framework。 因此,Windows IoT Core不支持全翼ASP.NET。 Windows ARM支持ASP.NET Core,但它仍处于测试阶段。 ASP.NET Core是.NET Core的一部分,因此.NET Core应安装在PC上,ASP.NET Core Web Application需要Windows arm平台才能在raspberry pi上运行。 ...