Skip to:
Content
Pages
Categories
Search
Top
Bottom

a POST in activity generates always a 404 on “edit-account”


  • philippehenri
    Participant

    @philippehenri

    Hi
    Hope someone can help here. I get plenty of 404. I could reproduce it. Here is how:

    I make a post in mysite/activity… (with no attachment !!)

    when debugging I see that after the post, “wp-includes/class_wp_rewrite.php” adds this rule :

    [^/]+/([^/]+)/?$ index.php?attachment=$matches[1]

    then I paste (or click) to get this url : “…mysite/my-account/edit-account” and it generates a 404 error.

    when debugging i find that the urls are being transformed by the above rewrite rule and become:

    http://mysite/my-account/edit-account/?attachment=edit-account

    which generates a 404 🙁 🙁
    ???
    Can someone help, it happen all the time when doing this sequence !! ps: the line adding the wrong regex in is : “$subquery = $index . ‘?attachment=’ . $this->preg_index(1);”

    thanks !
    philippe

Viewing 1 replies (of 1 total)

  • philippehenri
    Participant

    @philippehenri

    PS: if i reset the following line (from wp-includes/class_wp_rewrite.php, function rewrite_rules() )

    $post_rewrite = $this->generate_rewrite_rules( $this->permalink_structure, EP_PERMALINK );

    by adding “$post_rewrite=array();” after it , then the problem disappear. So this is clearly the rewrite rule created after the POST in activity that is causing the problem

Viewing 1 replies (of 1 total)
  • You must be logged in to reply to this topic.
Skip to toolbar