BuddyDev

Search

[Resolved] A Couple of problems

  • Participant
    Level: Master
    Posts: 413
    Venutius on #12849

    Hi Brajesh,

    Sorry about this but I’m having some problems. With the code below I can set the Gallery status to Public and private, but not logged users only. In addition I can set the upload option to members only. can you check my syntax etc?

    	$status = 'public';
    	
    	$privacy = sanitize_text_field( $_POST[ 'gallery_visibility' ] );
    	if ($privacy == "Me") {
    		$status = 'private';
    	}
    	if ($privacy == "Members") {
    		$status = 'loggedin';
    	}
    	if ($privacy == "Public") {
    		$status = 'public';
    	}
    
    	mpp_update_gallery_status( $associated_gallery_id, $status );
    
    	$upload_option = sanitize_text_field( $_POST[ 'gallery_member_upload' ] );
    	
    	if ($upload_option == "Members") {
    		mpp_update_gallery_meta( $associated_gallery_id, '_mpp_is_all_upload_allowed', 1);
    	}	
    	if ($upload_option == "Me") {
    		mpp_delete_gallery_meta( $associated_gallery_id, '_mpp_is_all_upload_allowed' );
    	}	
    	
  • Keymaster
    (BuddyDev Team)
    Posts: 21463
    Brajesh Singh on #12850

    Hi George,
    1. Please visit Dashboard->MediaPress->settings->Sitewide tab and make sure tha Logged In status is enabled.

    If that is the case, please do let me know.

  • Participant
    Level: Master
    Posts: 413
    Venutius on #12857

    Hi Brajesh,

    I’m not sure what happened but today it’s all working! maybe I forgot to save my edit before transferring it to the server? I’m not sure. But anyway, issue resolved.

  • Keymaster
    (BuddyDev Team)
    Posts: 21463
    Brajesh Singh on #12872

    Glad that it is resolved.

    Best Regards
    Brajesh

The topic ‘ [Resolved] A Couple of problems’ is closed to new replies.

This topic is: resolved