WordPress.org

Support

Support » Plugins and Hacks » Page Not Found

Page Not Found

  • The below (line 2) is the line that causes my save to become a 404. I saw the other page not found post and do have a custom permalink set. I did change it to the default wordpress sets and tried that, but it still did the same thing. I’ve also deactivated every plugin with exception of this one, and it also continues to throw me to the 404 page.

    $pattern = '/[^0-9x]/i';
    $phone = preg_replace($pattern, '',$phone);
    <?php
    //This will save
    preg_replace
    ?>
    <?php
    //This will not
    preg_replace()
    ?>

    http://wordpress.org/plugins/php-code-for-posts/

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Jamie

    @themissingcode

    Hi Bauzer,

    I have tested every combination and cannot recreate your issue.

    Please can you provide more information

    I have tried everything and continue to have the error with preg_replace(). I can’t attribute it to anything and it’s a really weird bug. I ended up just making my own function pregReplace() and then using that function in functions.php to get around it. I wish I could provide more details, but frankly – as a developer as well – I’m baffled what would be causing it.

    Plugin Author Jamie

    @themissingcode

    Is the preg_replace issue within the addition or display of the code?

    In my test i was able to add a snippet within the menu and successfully display it on a page using the shortcode, this is indeed a very strange problem

    It’s with the addition of code. I can take my entire code snippet with pregReplace [my function] and then just replace for preg_replace [php function] and hit save and it’ll go to the 404 page upon hitting save.

    Plugin Author Jamie

    @themissingcode

    Sadly, i have not been able to recreate the issue. do your server error logs show anything?

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Page Not Found’ is closed to new replies.