Thank you. I sincerely appreciate you using the plugin.
Regards
BrajeshHi,
hope you are doing well.
I have released an update. It is not exactly same as you request but it should help you achieve your goal.Under Settings->Theming->Lightbox you can disable “Link Media in lightbox to its single permalink page?” option. That would disable opening the single media page on clicking the photo.
People can still go to single page by clicking on the timestamp in the right side info box.Hope that helps.
Regards
BrajeshThank you.
I am looking forward to your feedback.Regards
BrajeshLooks pretty good. I wonder if maybe a link could be added to the lightbox which says “View Original” or something similar which would be the same link as the one behind the date link. It just doesn’t seem intuitive for a user to be able to know to click the date link to get to the original picture.
Also, I’d like the ability to click the original picture and have it open a lightbox.
Hi,
I am sorry for the delayed reply. You can overwrite the lightbox single template if needed to add any extra data. If you have suggestion about the position of the “View original”, Please let me know and I will add it.At the moment, we are sorry but we are unable to add support for your second request(ability to click on single image and open in lightbox). It does not add much value and the implementation will need significant amount of time. We can do it in one of the future major versions though.
Regards
BrajeshI’d suggest putting the “View Original” link under the date/time (which would be the same link as “View Original”).
Under the date/time is the “edit” link (for admins) to edit the title and description. I’d suggest right next to the edit link. If the user is not admin (or capable of editing the title and description), then, conditionally, the edit button would not show and it would just be the “View Original” link.
I updated media-info.php in my theme folder with the following changes to add a View Original link next to the conditional edit/cancel link. It seems to work fine. The only thing I didn’t do yet was to add a css class for the new link. Here it the code for the top row with my changes within the comments for it toward the bottom.
<div class="mpp-lightbox-media-uploader-meta mpp-clearfix"> <div class="mpp-lightbox-media-uploader-avatar"> <a href="<?php echo bp_core_get_user_domain( mpp_get_media_creator_id() ); ?>"> <?php echo bp_core_fetch_avatar( array( 'item_id' => mpp_get_media_creator_id(), 'object' => 'user', 'width' => bp_core_avatar_thumb_width(), 'height' => bp_core_avatar_thumb_height(), ) ); ?> </a> </div> <div class="mpp-lightbox-uploader-upload-details"> <div class="mpp-lightbox-uploader-link"> <?php echo bp_core_get_userlink( mpp_get_media_creator_id() ); ?> </div> <span class="mpp-lightbox-upload-time"> <a href="<?php mpp_media_permalink(); ?>" title="<?php echo esc_attr( mpp_get_media_title() ); ?>" class="mpp-lightbox-single-photo"> <?php echo bp_core_time_since( mpp_get_media_date_created( null, 'Y-m-d H:i:s', false ) ); ?> </a> </span> <div class="mpp-lightbox-action-links"> <?php do_action( 'mpp_lightbox_media_action_before_link', $media );?> <?php if ( mpp_user_can_edit_media( mpp_get_media_id() ) ) : ?> <a class="mpp-lightbox-media-action-link mpp-lightbox-edit-media-link" href="#" data-mpp-media-id="<?php mpp_media_id();?>"><?php _ex('Edit', 'lightbox edit media edit action label', 'mediapress' );?> </a> <a class="mpp-lightbox-media-action-link mpp-lightbox-edit-media-cancel-link" href="#" data-mpp-media-id="<?php mpp_media_id();?>"><?php _ex('Cancel', 'lightbox edit media cancel action label', 'mediapress' );?></a> <?php endif;?> <! -- added link to View Original image page next to the conditional 'edit' button --> <a href="<?php mpp_media_permalink(); ?>" title="<?php echo esc_attr( mpp_get_media_title() ); ?>" class="mpp-lightbox-single-photo">View Original </a> <! -- end of --added link to View Original image page next to the conditional 'edit' button --> <?php do_action( 'mpp_lightbox_media_action_after_link', $media );?> </div> </div> </div><!--end of the top row -->
I did it this way instead of adding another row so as to not mess up the alignment in the lightbox.
I added ” or ” right after the tag in the ‘Cancel’ link to make the links make more sense.
<a class="mpp-lightbox-media-action-link mpp-lightbox-edit-media-cancel-link" href="#" data-mpp-media-id="<?php mpp_media_id();?>"><?php _ex('Cancel', 'lightbox edit media cancel action label', 'mediapress' );?></a> or <?php endif;?>
This seems to work with the exception of creating a new CSS class for the “View Original” link.
You must be logged in to reply to this topic.