Tag-it is a jquery UI plugin that allows assigning tags, exactly like tags system in stackoverflow. https://github.com/aehlke/tag-it/blob/master/README.markdown
My goal is to allow members of my wordpress site to post from front end. To do so, I have created a form with input fields. I get the input content using
$_POST['something'].To insert the post data (title, content, custom fields values), I use
wp_insert_post function, and it is working well.
And to insert tags for the specific post I use
wp_set_object_terms function (since I am using custom post type and a taxonomy for tags). This last function is working well if I assign some sample values to it but I cant get the input values of the tags input created by
tag-it. I tried my best to link between the plugin and the PHP code responsible of assigning tags to my post in WP DB.
In fact, in my code source I put:
<ul id="myTags"> </ul>
And this code is transformed by the plugin (after execution) to :
<ul id="myTags" class="tagit ui-widget ui-widget-content ui-corner-all"> <li class="tagit-new"> <input type="text" class="ui-widget-content ui-autocomplete-input" autocomplete="off" role="textbox" aria-autocomplete="list" aria-haspopup="true"> </li> </ul>
How can I retrieve the POST variable from this input field as an array, so that I can put it in the parameters of
Your usual help is always appreciated.\