Various Append and Prepend

If you want to append or prepend attribute values to an html attribute or somewhere, you are in the right place here. Make sure, that other methods does not already do the job.

Add a new string to the attribute of the specified html-id.

This method is a dirty method, in which virtually any Html attributes can be controlled.

Factory::getResponseInstance()->append('htmlElementId','id', 'the_new_id');
or
Factory::getResponseInstance()->append('htmlElementId','innerHTML','<input type="text" />');

As Jybrid-script javascript append

Also you can use class name handling in your javascript files like in other javascript-frameworks.

jybrid.append()
jybrid.append('id','element-attribute','string')
xajax was xajax.append()
xajax.append('html_id','element-attribute','string');

The xajax method loses the form field values already entered during the response.

Prepend new string into the given html-id's attribute

Factory::getResponseInstance()->prepend('htmlElementId','element-attribute', 'myAttribValue');
or
Factory::getResponseInstance()->prependHtml('htmlElementId','innerHTML, '<input type="text" />');

As Jybrid-script javascript prepend

Also you can use class name handling in your javascript files like in other javascript-frameworks.

jybrid.prepend
jybrid.prepend('id','element-attribute','string')
// or
jybrid.prepend('id','innerHTML','<p>something</p>')
xajax was xajax.prepend()
xajax.prepend('html_id','element-attribute','string');

Alternative or similar jybrid/xajax methods

Perhaps you are looking for specific actions have a look into:

Html Append and Prepend

ClassNames Append and Prepend

further reading append and prepend examples

@see simple schematic schematic-html-append-prepend.php