Allows edit text content in special containers on front-end via Ajax. Used special visual menu with links for fast editing, saving and link to edit in admin panel.
Use pencil icon in visual menu for edit.
Open a developers console in you browser and try press on save icon - you'll see an Ajax request to same page with all important data.
You should create a custom action in your controller for store obtained data or use on a page some PHP module which can work with "fast_edit".
Some text for block content.
As you see, editable can be all of containers which has `data-m-field` attribute.
Editable containers can be included inside of several levels of child elements. JS module fast_edit will search all of them in parent container of the initiator.
<div class="block">
<h3 data-m-field="title">Block title</h3>
<p data-m-field="text">Some text for block content.</p>
<hr>
<small data-m-field="annotation"></small>
<div class="edit-bar"
data-m-action="fast_edit"
data-m-model="some-encryped-model"
data-m-module="special_blocks"
data-m-id="12345"><!--
--><a class="fa fa-ellipsis-v hover-toggle"></a><!--
--><a class="fa fa-pencil edit" title="Edit right here"></a><!--
--><a class="fa fa fa-edit" href="/admin/special_blocks/edit/12345" title="Edit in admin panel"></a><!--
--><a class="fa fa-trash delete" title="Delete"></a></div>
</div>
Users comments
Sorry you cant to leave a comment. Try to authorize yourself via login and password or use a one of social networks below: