Changeset 438973
- Timestamp:
- 09/16/2011 09:52:26 AM (14 years ago)
- File:
-
- 1 edited
-
nextgen-gallery-comments/tags/0.1.5/readme.txt (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
nextgen-gallery-comments/tags/0.1.5/readme.txt
r438970 r438973 64 64 If you want to customize it, copy it and paste in your theme inside `nggallery` folder (if this not exists, create it. This folder is needed to customize [NextGEN Gallery templates](http://nextgen-gallery.com/templates/)) 65 65 66 = If i click the logout button in gallery comment form, the page is bad redirected. How can i fix it? = 67 68 You have to use a filter to change the logout url: 69 70 add_filter('your_function','rcwd_comment_form_defaults'); 71 function your_function($defaults){ 72 global $user_identity, $post_id; 73 if(get_query_var('gallery') != ''){ 74 $logout_url = esc_attr($_SERVER["REQUEST_URI"]); 75 }else{ 76 $logout_url = get_permalink($post_id); 77 } 78 $defaults['logged_in_as'] = '<p class="logged-in-as">' . sprintf( __( 'Logged in as <a href="%1$s">%2$s</a>. <a href="%3$s" title="Log out of this account">Log out?</a>' ), admin_url( 'profile.php' ), $user_identity, wp_logout_url( apply_filters( 'the_permalink', $logout_url ) ) ) . '</p>'; 79 80 } 81 66 82 == Changelog == 67 83
Note: See TracChangeset
for help on using the changeset viewer.