Skip to:
Content
Pages
Categories
Search
Top
Bottom

ERROR: Are you sure you wanted to do that?


  • frankimc
    Participant

    @frankimc

    Can someone please help. I have tried almost everything When ever I try to make a new topic I get the ERROR: Are you sure you wanted to do that? Same thing for replying. I can create forums and topics and replies manually but I can’t do it through the website. The issue still happens with the Twenty’s themes. and I also tried removing all other plugins. I am local hosting wordpress 5.2.3 using bbpress 2.5.14 and my website is craftnations.ddns.net (If you want to see for yourself). PLEASE HELP ME!!!

Viewing 12 replies - 1 through 12 (of 12 total)

  • Robin W
    Moderator

    @robin-w

    It could be a theme or plugin issue

    Themes

    As a test switch to a default theme such as twentyfifteen, and see if this fixes.

    Plugins

    If that doesn’t work, also deactivate all plugins apart from bbpress and see if this fixes. if it does, re-enable one at a time to see which is causing the error.

    Then come back


    frankimc
    Participant

    @frankimc

    Hey. I tried switching to tweentyfifteen (still the error persists) then I tried disabling all plugins except bbpress (still the error persists). What now??


    Robin W
    Moderator

    @robin-w

    hmm…

    Is this a new installation ?


    frankimc
    Participant

    @frankimc

    Well I got it installed a few hours ago.


    Robin W
    Moderator

    @robin-w

    ok, it is failing a request which checks that the new topic is coming form an authorised source.

    it may be that your url of craftnations.ddns.net is upsetting it – I’m just a volunteer helper here, not one of the authors so can’t say for sure

    will this be the final url?


    frankimc
    Participant

    @frankimc

    Ok so my wordpress address URL is http://host.ip/wordpress
    My site address URL is /wordpress
    And I’m using noip
    Now I haven’t tried the noip route and I think there might be a problem using noip as the site takes forever to load. But then I tried host-IP the loading was way faster then noip. (by the way my computer is on the same network as the device that’s hosting the website)


    frankimc
    Participant

    @frankimc

    Ok never mind it was the wordpress address url and site address url that was making noip not work so i fixed it so it should work but the error is still there when i try to make a topic or reply.


    frankimc
    Participant

    @frankimc

    Just a little heads up. This error is still occurring. Please! Anyone?!?!


    Robin W
    Moderator

    @robin-w

    I suspect it is that you are running it locally – previous tickets indicate that this is a problem.


    frankimc
    Participant

    @frankimc

    Ok well thanks. If anyone knows how to fix this. Please let me know.


    frankimc
    Participant

    @frankimc

    I found out how to fix it by using Multiple Domain plugin. I think the problem might have been the site address url because if i set it to craftnations.ddns.net i cant access the website on my network because i use a different ip to noip so if i have nothing in the site address url i guess the bbpress plugin cant get the response so using Multiple Domain plugin and setting the domains for my network and craftnations it now works. i dont know if that makes sense for you guys but trust me it now works. Thanks for the help and i hope others will find this helpfull. 🙂


    Robin W
    Moderator

    @robin-w

    thanks for the update

    essentially that part of the code is looking at urls, so that would make some sense

    it is this code returning ‘false’ that causes the error you see

    function bbp_verify_nonce_request( $action = '', $query_arg = '_wpnonce' ) {
    
    	/** Home URL **************************************************************/
    
    	// Parse home_url() into pieces to remove query-strings, strange characters,
    	// and other funny things that plugins might to do to it.
    	$parsed_home = parse_url( home_url( '/', ( is_ssl() ? 'https' : 'http' ) ) );
    
    	// Maybe include the port, if it's included
    	if ( isset( $parsed_home['port'] ) ) {
    		$parsed_host = $parsed_home['host'] . ':' . $parsed_home['port'];
    	} else {
    		$parsed_host = $parsed_home['host'];
    	}
    
    	// Set the home URL for use in comparisons
    	$home_url = trim( strtolower( $parsed_home['scheme'] . '://' . $parsed_host . $parsed_home['path'] ), '/' );
    
    	/** Requested URL *********************************************************/
    
    	// Maybe include the port, if it's included in home_url()
    	if ( isset( $parsed_home['port'] ) ) {
    		$request_host = $_SERVER['HTTP_HOST'] . ':' . $_SERVER['SERVER_PORT'];
    	} else {
    		$request_host = $_SERVER['HTTP_HOST'];
    	}
    
    	// Build the currently requested URL
    	$scheme        = is_ssl() ? 'https://' : 'http://';
    	$requested_url = strtolower( $scheme . $request_host . $_SERVER['REQUEST_URI'] );
    
    	/** Look for match ********************************************************/
    
    	// Filter the requested URL, for configurations like reverse proxying
    	$matched_url = apply_filters( 'bbp_verify_nonce_request_url', $requested_url );
    
    	// Check the nonce
    	$result = isset( $_REQUEST[$query_arg] ) ? wp_verify_nonce( $_REQUEST[$query_arg], $action ) : false;
    
    	// Nonce check failed
    	if ( empty( $result ) || empty( $action ) || ( strpos( $matched_url, $home_url ) !== 0 ) ) {
    		$result = false;
    	}
    
    	// Do extra things
    	do_action( 'bbp_verify_nonce_request', $action, $result );
    
    	return $result;
    }
Viewing 12 replies - 1 through 12 (of 12 total)
  • You must be logged in to reply to this topic.
Skip to toolbar