Inline editing

From Kooboo document
Jump to: navigation, search

Inline editing enable you to edit content directly in the front end of the website. Inline editing is turn on by default.

Enable inline editing for label and static page.

To edit label text and HTML block within a page, make sure that the Enable inline editing is checked at system setting.

Inline edit enable.png

When it is checked, hover your mouse over static html block or label, you can see an edit icon next to your mouse,

Inline editing mousehover.png

Enable inline editing for dynamic content.

For dynamic content like article list or detail page. You need to manually define which fileds that block of content it is. This is can be done by insert an additional html attributes to the tag that contains the content item field or content item.

If you are using datarule, the code with inline editing enable is auto generated. See below screen.

Inline edit content field.png

If you are write the view implementation yourself, you can find the inline edit field in the code helper.

The code helper provides two methods:

To edit on one single field, use: @ViewHelper.Edit(item,"fieldName")

To edit on a list of items,use: @ViewHelper.Edit(item)

Pleaser refer to the code example generated by data rule.