创建“网站建设者' - 我将如何建筑师吗? [英] Creating a 'website builder' - How would I architect it?

查看:179
本文介绍了创建“网站建设者' - 我将如何建筑师吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在负责添加一个网站建设者给我们的应用程序套件。我们的大多数客户都是非技术性小企业业主(实体店,夫妻老婆店)。有人告诉我,我应该看 Blogger模板编辑器并想看看是否我可以使一些功能齐全,使用方便。这个想法是,我们的客户应该能够把自己的网上业务,而无需了解Web开发任何东西。

I've been tasked with adding a website builder to our suite of applications. Most of our clients are non technical small business owners (brick and mortar stores, mom and pop shops). I've been told that I should be looking at Blogger Template Editor and trying to see if I can make something that fully featured and easy to use. The idea being that our customers should be able to bring their business online without knowing anything about web development.

我主要是用C#和Silverlight在日常基础工作。因此,与.NET将很可能对我来说是最好的方式。 ASP.NET MVC和SPARK看起来很诱人,但我不太清楚,我将如何完成以下事项

I mostly work with c# and silverlight on a day to day basis. So going with .net is likely the best way for me. ASP.NET MVC and SPARK look very attractive, but I am not too sure about how I will accomplish the following things

1 - 我如何建立一个模板系统,允许设计人员创建使用特定的格式,并与我的应用程序兼容的模板。有没有通用的框架在那里了呢?

1- How do I build a templating system that allows a designer to create templates that use a certain format and are compatible with my app. Is there any generic framework out there for this?

2 - 我怎么会坚持客户端向他/她的站点(例如客户端更改背景颜色,并添加成分列表的页面上)的变化。

2- How would I persist the changes the client makes to his/her site (for example the client changes the background color and adds a list of ingredients on a page).

编辑:是的,我知道这是一项艰巨的任务,我可能看写的睡CMS,但是我们的客户需要非常有限的,基本功能开始,我想这将是一个反复的过程,或许更开发商今后对后世如果产品被证明是成功的。我将这些问题知道我们的经理虽然。

Yes I am aware this is a big task and I am potentially looking at writing a fullblown CMS, however our clients need very limited and basic functionality to begin with and I imagine this would be an iterative process, with perhaps more developers coming on later if the product proves to be successful. I will make these concerns known to our manager though.

起初我打算只给他们一些模板布局,并允许他们自定义的各个部分以及颜色和图像CSS发生的事情。 HAML 萨斯看起来像他们可能是有用的,我可以坚持数据库中的所有用户自定义的参数。

Initially I am planning on just giving them a few templated layouts and allow them to customize what goes in the various sections as well as the colors and images with CSS. HAML and Sass look like they could be useful and I could persist all user customizable parameters in a database.

我是沿着正确的方向或完全没谱这里想什么?

Am I thinking along the right lines or completely off the mark here?

推荐答案

这在很大程度上取决于你的需求。

It depends a lot on your requirements.

有一个简单的解决办法是有几个基本的模板有占位符得到填补与内容/其他模板后。

A simple solution would be to have several base-templates with placeholders that get filled with content/other templates later.

即。模板可能是这样的:

I.e. a template might look like this:

<html>
  <head><title>foo</title></head>
  <body>
    <div id="menu">{auto_generated_menu}</div>
    <h1>{page_header}</h1>
    <div id="content">
      {page_content}
    </div>
  </body>
</html>

然后就为用户提供了一种简单的方法来定义页眉和page_contents,即第一可能只是一个文本框,内容是通过使用类似TinyMCE的填补。
如果需要的话,客户端可以使用其他的占位符中的内容,但是可能不neccessary

Then you provide the users with a simple way to define page headers and page_contents, i.e. the first might just be a textbox, the content is filled by using something like TinyMCE. If necessary, the clients can use other placeholders in the content, but that might not be neccessary.

之后,你只需添加一个自动生成的菜单,创建替换用户输入的内容(沿东西 template.Content = template.Content.Replace的行占位符逻辑( {} PAGE_CONTENT,customer.Pages ['富'] GetTemplateContent。(PAGE_CONTENT)); ),并可能添加CSS样式表由客户提供的颜色和字体设置

After that you just add an auto-generated menu, create the logic that replaces the placeholders with the user-entered content (something along the lines of template.Content = template.Content.Replace("{page_content}", customer.Pages['foo'].GetTemplateContent("page_content")); )and maybe add a CSS stylesheet with color and font settings provided by the customers.

中最复杂的部分是后端和用户认证方式。

The most complex part is the backend and user-authentification.

此解决方案是实现简单,具有根本没有真正的灵活性,但它允许客户快速写几个文字,并添加一些花哨的图像,而不必关心其他东西。

This solution is simple to implement and has no real flexibility at all but it allows customers to quickly write a few texts and add some fancy images without having to care about anything else.

要坚持颜色设置,把它们写入到数据库中,并创建他们正在改变一个新的CSS样式表每次。对于其他的内容只使用一个数据库表内容与列键和价值,你可能想生成的每一个变化的静态HTML页面。

To persist color settings, write them into the database and create a new CSS stylesheet everytime they are changed. For other content just use a Database table "content" with the columns "key" and "value" and you might want to generate static HTML pages on every change.

这篇关于创建“网站建设者' - 我将如何建筑师吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆