Below you will find documentation on how to use our software. This contains easy-to-use steps by step guides with helpful screenshots on how to configure and get the best results.


Chapter 3: Using Ajax

The basis of how we implement read and update operations when we edit our inline editable content, is that we use Ajax to do this, more specifically, we use Joomla’s com_ajax component.

We shall, now, go into detail on how to use our framework, to implement read and update operations for your component.

Okay, if you remember when we created our folder structure for our package, for inline editing support, we created three files: one for each editable type.

+files_inlinemycck   [FILES_INLINE + COMPONENT NAME]
---+mycck            [COMPONENT NAME]
	   -----category.php  	[TYPE NAME as explained in XML]
	   -----item.php        [TYPE NAME as explained in XML]
	   -----blog.php        [TYPE NAME as explained in XML]
inlinemyck.xml  [INLINE +  COMPONENT NAME].xml

As you can see, we have three inline editable types in our component:

  1. Category
  2. Item
  3. Blog

In each file, we will create a class that extends the ArkContextsBase. This is the class provided to us by the inline editing framework, that will allow us to do what we discussed above:

  1. Read the data from the database, for the specified inline type
  2. Save any updates made by the end user, on inline editing
  3. render/transform the data back to the user, after saving as it was before any inline editing

The abstract ArkContextsBase contains three methods that will allow our extended class to read, update and render the content for our inline types. 

abstract class ArkContextsBase
	public function get()

	public function triggerContentPlugins($rawText)
	public function save($data,$type = 'body'){}

Let us now see how this works for our simple MyCCK component, in the next section.


WebxSolution Ltd and this site is not affiliated with or endorsed by The Joomla! Project™. Any products and services provided through this site are not supported or warrantied by The Joomla! Project or Open Source Matters, Inc. Use of the Joomla!® name, symbol, logo and related trademarks is permitted under a limited license granted by Open Source Matters, Inc.

Copyright © 2009 - 2018 WebxSolution Ltd
Powered by JoomlaWired

Cron Job Starts