diff --git a/includes/core/um-actions-profile.php b/includes/core/um-actions-profile.php
index 302e9e90..500b969b 100644
--- a/includes/core/um-actions-profile.php
+++ b/includes/core/um-actions-profile.php
@@ -595,13 +595,28 @@ function um_profile_header_cover_area( $args ) {
$hide_remove = um_profile( 'cover_photo' ) ? false : ' style="display:none;"';
+ $text = ! um_profile( 'cover_photo' ) ? __( 'Upload a cover photo', 'ultimate-member' ) : __( 'Change cover photo', 'ultimate-member' ) ;
+
$items = array(
- '' . __( 'Change cover photo', 'ultimate-member' ) . '',
+ '' . $text . '',
'' . __( 'Remove', 'ultimate-member' ) . '',
'' . __( 'Cancel', 'ultimate-member' ) . '',
);
UM()->profile()->new_ui( 'bc', 'div.um-cover', 'click', $items );
+ } else {
+
+ if ( ! isset( UM()->user()->cannot_edit ) && ! um_profile( 'cover_photo' ) ) {
+
+ $items = array(
+ '' . __( 'Upload a cover photo', 'ultimate-member' ) . '',
+ '' . __( 'Cancel', 'ultimate-member' ) . '',
+ );
+
+ UM()->profile()->new_ui( 'bc', 'div.um-cover', 'click', $items );
+
+ }
+
}
UM()->fields()->add_hidden_field( 'cover_photo' ); ?>
@@ -724,7 +739,7 @@ function um_profile_header( $args ) {
user()->cannot_edit )) {
+ if ( ! isset( UM()->user()->cannot_edit ) ) {
UM()->fields()->add_hidden_field( 'profile_photo' );
@@ -760,7 +775,7 @@ function um_profile_header( $args ) {
echo UM()->profile()->new_ui( 'bc', 'div.um-profile-photo', 'click', $items );
- } else if (UM()->fields()->editing == true) {
+ } elseif ( UM()->fields()->editing == true ) {
$items = array(
'' . __( 'Change photo', 'ultimate-member' ) . '',