Ask your WordPress questions! Pay money and get answers fast! Comodo Trusted Site Seal
Official PayPal Seal

Inline editor WordPress


I would like to use the script at my WP website as a simple inline post editor. Now I need a function that allow certain users edit their posts (via current_user_can( 'edit_post', $post->ID )) and a function that will update db field with the new value of the editable entry. Someone can help me to create these functions? My website built with html5.

Answers (3)


Julian Lannigan answers:

I would suggest trying out this plugin: [[LINK href=""]][[/LINK]]

Julian Lannigan comments:

Then if you want to control who can edit. Add this to your functions.php file:

function fee_allow_edit( $allow, $data ) {
return $allow && current_user_can( 'edit_post', $data['post_id'] );
add_filter( 'front_end_editor_allow_post', 'fee_allow_edit', 10, 2 );

Dmitriy Son comments:

Julian, I know about this plugin. I don't want to use it.

Julian Lannigan comments:

Any particular reason? Just curious.

Dmitriy Son comments:

at least two reasons:
(1) FEE ajax loading hangs until page reloaded. Of course, I can't edit via plugin.
(2) Instead of normal title the plugin shows something like this:
<span data-type="input" data-term_id="7" data-taxonomy="category" class="fee-field fee-filter-single_cat_title">Category title</span>

Within a day I can't see what's wrong with this... i've tried to change templates and deactivate plugins. nothing helps.


Victor Teixeira answers:

I suggwst that you use the front end editor plugin:

Victor Teixeira comments:

Julian was one minute earlier...


Joe Jenkins answers:

I like this plugin:

I find it does a much better job than the previously mentioned plugin, and gives many more options.

Dmitriy Son comments:

Joe, I like it too, but it doesnt work with html5. I gonna make something similar. Just one problem: i don't know how to update mysql table with new value.

Joe Jenkins comments:

Ah, I see.

Maybe you could take a look at the plugin, then see how they do it.