Function Reference: geodir_payment_publish_listing_form_action


Get the URL for the publish listing form on the preview page.

Global Values

(object) (required) The current post object.

Default: None


(string) (required) The URL for the form.

Default: None

Return Values

  • listing form url.

Change Log

Since: 1.0.0

Source Code

function geodir_payment_publish_listing_form_action($form_action_url) {
	global $post;
	$post_type = $post->listing_type;
	$package_price_info = geodir_get_post_package_info($_REQUEST['package_id']);
	$payable_amount = $package_price_info['amount'];
	if ($payable_amount > 0) {
		$form_action_url = geodir_get_ajax_url().'&geodir_ajax=add_listing&ajax_action=pre-checkout&listing_type=' . $post_type;	

	return $form_action_url;