如何制作完全可自定义的托管ASP.NET MVC应用程序

时间:2021-09-17 04:09:59

This is related to my previous question regarding serving static html files but that doesn't seem to be a good solution,

这与我之前关于提供静态html文件的问题有关,但这似乎不是一个好的解决方案,

I want to make a fully customizable ASP.NET MVC application as a hosted service. See allowing the user to customize the look/feel of their own page but it is still dynamic, meaning the data is hosted in the central database.

我想将完全可自定义的ASP.NET MVC应用程序作为托管服务。请参阅允许用户自定义其自己页面的外观,但它仍然是动态的,这意味着数据托管在*数据库中。

I looked at the "theme" or "skin" in ASP.NET but I don't think it is customizable enough. It seems only the developer can add new themes. I want to have something like the theme editor in WordPress so you can just change the look in anyway you want from a web-based interface.

我查看了ASP.NET中的“主题”或“皮肤”,但我认为它不够可定制。似乎只有开发人员才能添加新主题。我想在WordPress中使用类似主题编辑器的东西,这样你就可以从基于Web的界面改变你想要的外观。

I wonder how the theme files will be stored for the popular blogging platform? Are they stored in database or a file in filesystem? I prefer to store it in database, because if it is in filesystem it will have scalability problem. Each user will be tired to a particular web server and I have to determine how much disk space for each webserver.

我想知道如何为流行的博客平台存储主题文件?它们存储在数据库中还是文件系统中的文件中?我更喜欢将它存储在数据库中,因为如果它在文件系统中,它将具有可伸缩性问题。每个用户都会对特定的Web服务器感到厌倦,我必须确定每个Web服务器的磁盘空间。

I thought of doing something like the old MovableType, to generate static HTML when you add new post. This solution is problematic as well, because the flexibility depends on the complexity of the template engine.

我想过做一些像旧的MovableType,在你添加新帖子时生成静态HTML。该解决方案也存在问题,因为灵活性取决于模板引擎的复杂性。

Ideas? Suggestions?

Thanks!

2 个解决方案

#1


1  

"Fully customizable" is the most elusive of the white whales ;-)

“完全可定制”是白鲸中最难以捉摸的;-)

I see your question is old, but none the less; first I'd recommend defining some very clear,
and cohesive rules governing just what the "bottom-line" is, or an inheritable template of sorts.
You get a pretty good impression of what might be useful during developing, I'd guess.

我看到你的问题是陈旧的,但也是如此;首先,我建议定义一些非常清晰,有凝聚力的规则来管理“底线”是什么,或者是一种可继承的模板。我猜你会对开发过程中可能有用的东西有一个很好的印象。

Next; just what and how is the customizing supposed to be presented and achieved?

下一个;应该提供和实现定制的内容和方式是什么?

The inherit ASP.NET custom custard, Web Parts, need quite some cajoling to behave in MVC views :
https://*.com/questions/1106629/using-webparts-in-an-mvc-application

继承ASP.NET自定义问候语,Web部件,在MVC视图中需要相当多的哄骗行为:https://*.com/questions/1106629/using-webparts-in-an-mvc-application

If you're leaning more towards customizable appearance (theme's n' skin's),
how about having a CSS file for each user, saves like a charm as VARCHAR(MAX), and can easily be inserted in e.g. your Master Page's head.

如果你更倾向于可定制的外观(主题的'皮肤'),如何为每个用户创建一个CSS文件,像VARCHAR(MAX)一样保存,并且可以很容易地插入到例如你的母版头。

#2


0  

The theme editor in WordPress simply allows you to edit Theme PHP files... You can do it exactly like in wordpress but instead of editing PHP files your theme is composed of a set of aspx\ascx files without code-behinds...

WordPress中的主题编辑器只允许您编辑主题PHP文件...您可以像在wordpress中一样完成它,但不是编辑PHP文件,而是主题由一组没有代码隐藏的aspx \ ascx文件组成...

#1


1  

"Fully customizable" is the most elusive of the white whales ;-)

“完全可定制”是白鲸中最难以捉摸的;-)

I see your question is old, but none the less; first I'd recommend defining some very clear,
and cohesive rules governing just what the "bottom-line" is, or an inheritable template of sorts.
You get a pretty good impression of what might be useful during developing, I'd guess.

我看到你的问题是陈旧的,但也是如此;首先,我建议定义一些非常清晰,有凝聚力的规则来管理“底线”是什么,或者是一种可继承的模板。我猜你会对开发过程中可能有用的东西有一个很好的印象。

Next; just what and how is the customizing supposed to be presented and achieved?

下一个;应该提供和实现定制的内容和方式是什么?

The inherit ASP.NET custom custard, Web Parts, need quite some cajoling to behave in MVC views :
https://*.com/questions/1106629/using-webparts-in-an-mvc-application

继承ASP.NET自定义问候语,Web部件,在MVC视图中需要相当多的哄骗行为:https://*.com/questions/1106629/using-webparts-in-an-mvc-application

If you're leaning more towards customizable appearance (theme's n' skin's),
how about having a CSS file for each user, saves like a charm as VARCHAR(MAX), and can easily be inserted in e.g. your Master Page's head.

如果你更倾向于可定制的外观(主题的'皮肤'),如何为每个用户创建一个CSS文件,像VARCHAR(MAX)一样保存,并且可以很容易地插入到例如你的母版头。

#2


0  

The theme editor in WordPress simply allows you to edit Theme PHP files... You can do it exactly like in wordpress but instead of editing PHP files your theme is composed of a set of aspx\ascx files without code-behinds...

WordPress中的主题编辑器只允许您编辑主题PHP文件...您可以像在wordpress中一样完成它,但不是编辑PHP文件,而是主题由一组没有代码隐藏的aspx \ ascx文件组成...