Adding tags to Status Plugin

Hello, Just purchased WPMU Status Plugin to enable Front-end posting. Could you please help me configure tags functionality to the status update? Thank you!

    lauren_gibbons8

    Ok, I figured it out with the help of this post http://www.cozmoslabs.com/5528-wordpress-post-from-front-end/

    dashboard-widget.php
    <p><label>Tags: </label><input id="fep-tags" name="tags" type="text" tabindex="2" autocomplete="off" value="<?php esc_attr_e( 'Add tags', 'simple-fep' ); ?>" onfocus="this.value=(this.value=='<?php echo esc_js( __( 'Add tags', 'simple-fep' ) ); ?>') ? '' : this.value;" onblur="this.value=(this.value=='') ? '<?php echo esc_js( __( 'Add tags', 'simple-fep' ) ); ?>' : this.value;" /></p>

    I wasn't sure where to put the simple-fep function so I just installed the plugin.

    class_wdqs_admin_pages.php

    function create_post ($data) {
    		//if (!current_user_can('publish_posts')) return false;
    		if (!$this->_check_permissions()) return false;
    		global $user_ID;
    		$send = array(
    			'image' => $data['thumbnail'],
    			'no_image' => (int)$data['no_thumbnail'],
    			'height' => (int)$data['height'],
    			'width' => (int)$data['width'],
    			'link_title' => @$data['link_title'],
    			'link_text' => @$data['link_text'],
    		);
    		$text = $this->generate_preview_html($data['data'], $send, true);
    		$title = @$data['title'] ? $data['title'] : $this->_get_default_title();
    		$category = $this->data->get('post_category-' . $this->_link_type);
    		$tags = @$_POST['tags'];
    		$post = array (
    			'post_title' => $title,
    			'post_content' => $text,
    			'post_date' => current_time('mysql'),
    			'post_status' => @$_POST['is_draft'] ? 'draft' : (current_user_can("publish_posts") ? 'publish' : 'pending'),
    			'post_author' => $user_ID,
    			'post_category' => array($category),
    			'tags_input'	=> $tags,
    		);

    widget.js

    var title = $("#wdqs-post-title").length ? $("#wdqs-post-title").val() : '';
    	var tags = $("#fep-tags").length ? $("#fep-tags").val() : '';
    	var thumbnail = ($(".wdqs-image-list li:visible:first").length) ? $(".wdqs-image-list li:visible:first img").attr("src") : '';
    	var no_thumbnail = ($("#wdqs-no-thumbnail").length && $("#wdqs-no-thumbnail").is(":checked")) ? 1 : 0;
    	var height = $("#wdqs-height").length ? $("#wdqs-height").val() : 0;
    	var width = $("#wdqs-width").length ? $("#wdqs-width").val() : 0;
    
    	var link_title = $(".wdqs-title-container h3 a").text();
    	var link_text = $(".wdqs-text-container p").html();
    
    	var is_draft = $(e.target).is("#wdqs-draft") ? 1 : 0;
    
    	var $root = $("#wdqs-dashboard-widget").parent();
    	$root.html('<div class="wdqs-waiting-for-response"></div>');
    
    	$.post(_wdqs_ajaxurl, {
    		"action": "wdqs_post",
    		"is_draft": is_draft,
    		"data": text,
    		"title": title,
    		"tags": tags,
    		"height": height,
    		"width": width,
    		"thumbnail": thumbnail,
    		"no_thumbnail": no_thumbnail,
    		"link_title": link_title,
    		"link_text": link_text
    	},
    function callPreviewUpdate () {
    	var title = $("#wdqs-post-title").length ? $("#wdqs-post-title").val() : '';
    	var tags = $("#fep-tags").length ? $("#fep-tags").val() : '';
    	var text = $("#wdqs-status").val();
    	var height = $("#wdqs-height").length ? $("#wdqs-height").val() : 0;
    	var width = $("#wdqs-width").length ? $("#wdqs-width").val() : 0;
    
    	$("#wdqs-preview-root").html('<div class="wdqs-waiting-for-response"></div>');
    	$.post(_wdqs_ajaxurl, {
    		"action": "wdqs_generate_preview",
    		"text": text,
    		"title": title,
    		"tags": tags,
    		"height": height,
    		"width": width
    	}

    Perhaps that will help someone. Apologies for dirty copy & paste. Also, I'm sure there is a better way to do that...

JOIN 396251 HAPPY MEMBERS

We pride ourselves on our level of customer support and responsiveness to member requests. Your WordPress experience will never be the same


Start free trial