定制GraffitiCMS

发布于 2024-08-18 15:02:14 字数 427 浏览 2 评论 0原文

前几天我下载了 GraffitiCMS(现已开源且免费),并且喜欢我所看到的很多内容,但我真正想用它的目的是将 CMS 功能添加到现有的 ASP.NET 数据库/应用程序中。

在不陷入我的应用程序的所有细节的情况下,有人可以给我向 Graffiti 添加自定义内容应采取的基本“方法”吗?不会是“帖子”的内容?

例如,我见过如何向 Graffiti 添加自定义小部件 - 基本上继承自小部件类,编译您的 dll 并将其放入正确的目录中,然后它就成为系统的一部分。有没有办法对主要内容区域做类似的事情?

为了简单起见,假设我有一个非涂鸦数据库,其中包含大量数据,我想使用标准的 asp.net 网格和表单在网站上显示这些数据。我意识到我可以直接分解源代码来集成我现有的应用程序,但这可能不是正确的方法。

她不是在寻找完整的解决方案,只是一个指针以及要调查的领域......谢谢。

I downloaded GraffitiCMS the other day(now open source and free), and like a lot of what I see, but what I really want to use it for, is to add CMS capabilities to an existing asp.net database/application.

Without getting bogged down with all the details of my app, can someone give me the basic 'approach' that should be taken to add custom content to Graffiti; content that won't be a 'post'?

I've seen for example, how to add custom-widgets to Graffiti - basically inherit from the widget class, compile your dll and plop it into the correct directory and it becomes part of the system. Is there a way to do something similar for the main content areas?

For simplicity sake, pretend I have a non-graffiti database with gig's of data that I want to display on the website using standard asp.net grid's and forms. I realize I could just go in and hack apart the source code to integrate my existing app, but that is likely not the correct approach.

Not looking for a complete solution her, just a pointer and what areas to investigate...thanks.

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

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

发布评论

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

评论(3

寄居人 2024-08-25 15:02:14

如果您查看 Graffiti 的最新源(或最近创建的 1.3 分支),则会添加支持将小部件放置在任何页面上的任何位置。有一个新的粉笔功能 - $macros.Widget - 为您提供了这种能力。 Dan Hounshell 撰写了一篇关于如何使用此新功能的博客文章:

http://danhounshell.com/blog/graffiti-cms-1-3-add-a-widget-anywhere-in-a-view- with-new-widget-macro/

如果您正在寻找与此不同的东西,请告诉我 - 我们正在努力使 Graffiti 更加适合您当前所处的情况。

If you check out the latest source of Graffiti (or the 1.3 branch that was recently created), support was added to put widgets anywhere you want on any page. There is a new chalk function - $macros.Widget - that provides you with this ability. Dan Hounshell wrote a blog post on how you can use this new functionality:

http://danhounshell.com/blog/graffiti-cms-1-3-add-a-widget-anywhere-in-a-view-with-new-widget-macro/

If you're looking for something different than that, just let me know - we're working to make Graffiti even better for situations just like you are currently in.

羞稚 2024-08-25 15:02:14

为了能够将 Graffiti CMS 与我们当前的 ASP.NET 项目集成,我们所做的就是在 Graffiti 中创建一个名为“隐藏”的帖子,然后使用我们的标准 .ASPX 页面,在渲染覆盖中调用一个类来拉取“隐藏” ” 发布(即:site.com/hidden/)并使用页眉和页脚将涂鸦主题包裹在我们的自定义 .ASPX 页面中。我们在“隐藏”帖子中使用一些 HTML 注释来解析页眉和页脚。这是一种黑客行为,但对我们来说效果非常好。

What we have done to be able to integrate Graffiti CMS with our current ASP.NET projects is to create a post in Graffiti called "hidden" and then with our standard .ASPX pages we call a class in our Render Override that pulls the "hidden" post (ie: site.com/hidden/) and uses the header and footer to wrap the Graffiti theme around our custom .ASPX page. We use some HTML comments in the "hidden" post to be able to parse the header and the footer. It is kind of a hack, but has worked out really well for us.

懒的傷心 2024-08-25 15:02:14

我认为您是想本末倒置 - 根据功能的大小和数量,我会在学习我选择的 CMS 系统的开发平台后寻求重建它。

我现在几乎处于同一条船上。我避免使用 Graffiti,因为我必须学习“Chalk”(无论它是什么)和 Umbraco(使用 XSLT 进行布局是迟缓的)。到目前为止,Sitefinity 一直是我的首选,而 Telerik 刚刚推出了免费版本!

我最终可能会选择一个非常基本的 CMS,它更容易定制。我知道这并不能直接回答你的问题,但它可能会给你一些思考:-)

I think you're trying to put the cart before the horse - depending on the size and amount of functionality, I would be looking to rebuild it after learning the development platform of my CMS system of choice.

I'm pretty much in the same boat right now. I have avoided Graffiti because I have to learn "Chalk" (whatever that is) and Umbraco (using XSLT for layouts is retarded). So far, this leaves me with Sitefinity at the top of my list and Telerik have just pulled the free version!

I may end up grabbing a very basic CMS which is easier to customize. I know this doesn't directly answer your question, but it may give you some food for thought :-)

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