This topic contains 7 reply and 2 voices, and was last updated by hatchmedia 4 years ago
Viewing 7 Posts - 1 through 7 (of 7 total)
Author Posts
August 20, 2015 at 4:33 pm 68302
hatchmedia Hey guys, When a user deletes a post from their dashboard, the site gets caught in a Redirection Loop. The following is appended to the URL and it repeats this in the Network tab of Web Dev Tools until the redirection loop error occurs. ?action=del&pid=12301&_wpnonce=7d079c5504&msg=deleted Any ideas? Damien
August 20, 2015 at 5:46 pm 68313
towhid towhid

Hello Damien,

I have tried to reproduce this issue but failed. It could be a has a chance of theme or plugin conflicts. You can disable all your plugins except User Frontend and switch to a default theme of WordPress like- Twenty Twelve, Twenty Thirteen, Twenty Fourteen and let me know the results.

Thanks

August 20, 2015 at 7:21 pm 68340
hatchmedia hatchmedia

Hi Towhid,

Thanks for the response.

Removing all the plugins did not resolve the issue but swapping the theme did. It also seemed to resolve another open issue I have open here.

So, obviously the issue must be somewhere in my theme’s code, but could you give me any clues as to where it might be? The only thing I have done with the dashboard area is add code that allows for multiple post types and also, a redirect after upload:

/*
==========================================================
Multiple Post Types for the Dashboard
==========================================================
*/
function wpufe_dashboard_post_type( $args ) {
    $args['post_type'] = array( 'dogs', 'cats', 'others', 'post' );
 
    return $args;
}
 
add_filter( 'wpuf_dashboard_query', 'wpufe_dashboard_post_type' );

<?php
/*
=========================================================================
WP User Frontend Redirect after upload
=========================================================================
*/

function wpuf_redirect_to_profile( $response ) {
$response['redirect_to'] = bp_core_get_user_domain( get_current_user_id() );

return $response;
}

add_filter( 'wpuf_add_post_redirect', 'wpuf_redirect_to_profile' );
add_filter( 'wpuf_edit_post_redirect', 'wpuf_redirect_to_profile' );
?>

Damien

August 21, 2015 at 3:39 pm 68400
hatchmedia hatchmedia

Just to give an update to this.

I have my dashboard set up to go to the users BuddyPress profile. So it works as http://mysite.ie/USERNAME/my-posts. If I remove the USERNAME element, then the posts will delete without an issue.

When I delete from USERNAME/my-posts, the following is added to the URL:
?action=del&pid=12301&_wpnonce=7d079c5504&msg=deleted

When I delete form just /my-posts, then this is added to the URL:
/?msg=deleted

Is there anything that you can think of that would cause this to stop working? It had worked on a previous version of WPUF before.

Cheers

Damien

August 24, 2015 at 12:36 pm 68804
towhid towhid

Hello Damien,

Literally speaking, do not do anythings unusual. Just create a page then insert a shortcode [wpuf_dashboard]. Now access the page from the website’s frontend. You will get all the post you have created. If you want to delete any post just click delete.

You will get a URL on the browser address field like it is – http://yoursite.com/dashboard

Thanks

August 24, 2015 at 1:32 pm 68812
hatchmedia hatchmedia

Thanks Twohid,

As mentioned though in my last email, that does work, but I have it set up to go to a user account which includes their username.

This has worked before without any issues. It has worked for probably about a year now, but since the updating, it seems to have stopped.

Please see this post from 2 years ago where I set this up with Tareq.

Is there anything that you can think of for where I should be looking?

Damien

August 24, 2015 at 5:52 pm 68858
towhid towhid

Hello Damien,

Please allow me some time. I will check this matter. Hope I will come back to you with a right solution.

Thanks

August 24, 2015 at 5:53 pm 68859
hatchmedia hatchmedia

Thanks Towhid, appreciate the help.

Damien

Viewing 7 Posts - 1 through 7 (of 7 total)