The MU forums have moved to WordPress.org

1.1.1 soon (51 posts)

  1. lunabyte
    Member
    Posted 16 years ago #

    Nice D. Real nice.

    I do have a question though.

    The "do_action_ref_array" function, specifically in relation to the new wp_mail function.

    The way I'm "understanding this", is that the $phpmailer vars being set are passed through this function for additional processing.

    Then the additional function can add to that array of vars, and unset one if need be, before returning it back to the wp_mail function, similar to running a filter?

    I'm curious because that would be super sweet, as I can drop a quick function in as mu-plugin, unset IsMail, set IsSMTP, pass the connection information, and enable SMTP vice php's mail function.

    :D

  2. trackers
    Member
    Posted 16 years ago #

    Hey donncha just wanna say thanks heaps for your effort, and keep up the good work :)

  3. donncha
    Key Master
    Posted 16 years ago #

    lunabyte - I thought someone might ask. I dropped this into a file in mu-plugins on WordPress.com:

    function phpmailer_config( $phpmailer ) {
    $phpmailer->FromName = "Support!";
    $phpmailer->IsSMTP();
    $phpmailer->Host = "127.0.0.1";
    }
    add_action( 'phpmailer_init', 'phpmailer_config' );

  4. lunabyte
    Member
    Posted 16 years ago #

    That's pretty much what I have, minus trying to unset IsMail, plus I added a username and pass as well.

    I was going to test it out last night and then I got sidetracked with writing a new plugin. Well, not necessarily new, it adds a new, separate feature to an existing plugin I already had written for my system.

    Funny how that works, huh? :D

  5. orvar
    Member
    Posted 16 years ago #

    I might know what the "backend blog creation" problem might be. I just experienced something similar for the first time today. wpmu-blogs.php died somewhere around line 308 when creating a new blog. When the new blog has been registered but its tables are yet to be created. The log showed that php was running out of memory.

    [Wed Feb 28 19:51:14 2007] [error] [client XXX]
    PHP Fatal error:  Allowed memory size of 8388608
    bytes exhausted (tried to allocate 58368 bytes)
    in /srv/www/htdocs/wp-admin/upgrade-schema.php on
    line 308, referer:
    http://XXX/wp-admin/wpmu-blogs.php

    This just started today as I said and occurred consistently. I "fixed it" by allocating php more memory in php.ini. Regular WP seems to have the same issue, see http://wordpress.org/support/topic/92454?replies=3

  6. lunabyte
    Member
    Posted 16 years ago #

    Hmmm. Only 8M of mem for PHP?
    That could cause a problem I suppose.

    I set mine higher by default, so I'm no help there.

  7. orvar
    Member
    Posted 16 years ago #

    8M is the default. I'm using a month old version (rev 863) and this hasn't happened before. Maybe there is something earlier in the script that builds up with time until it consistently exceeds the memory limit. Anyway 8M should be enough for creating a new blog in admin.

  8. lunabyte
    Member
    Posted 16 years ago #

    I know the default is 8, which is why I said I set mine higher by default. I do a lot of image stuff sometimes when I play around, and PHP really likes the additional mem. :D

    So the question is why are a few experiencing this, yet others aren't, and what's causing it. Which could be anything, really. Something is causing it to eat up a little more mem, at least in your case.

    James, Quenting, any light on what you guys have PHP's mem limit set to in php.ini? On my production boxes, mine is 32M, 16M on my dev boxes.

  9. enseignement
    Member
    Posted 16 years ago #

    where is the pot for this version ?
    Is everything "translatable" ?

  10. drmike
    Member
    Posted 16 years ago #

    Just use poedit and create your own.

  11. quenting
    Member
    Posted 16 years ago #

    > James, Quenting, any light on what you guys have PHP's mem limit set to in php.ini? On my production boxes, mine is 32M, 16M on my dev boxes.

    I have 32megs everywhere. I use APC too, not if sure that makes any difference as per php memory usage. I remember having to up this value (8 by default ?) early on due to outofmemory errors.

    It'd be interesting to know what part of the script uses so much memory. Not that it's a big deal to have PHP get 32megs, but rather that a script eating 32megs can probably be improved quite a bit.

  12. lunabyte
    Member
    Posted 16 years ago #

    That's what I'm using, as I noted.

    I've seen some scripts need a little more, like if they use jGraph or something, but that's about it really. So far, I can't really see why something would need so much, but I guess it probably comes down to how much stuff's being loaded and parsed.

    I use APC as well, and would love to have a dedicated box strictly for memcached as well. Of course after seeing Ryan's new reef tank, my "I want" list is getting longer and longer. lol

  13. Farms2
    Member
    Posted 16 years ago #

  14. kingler
    Member
    Posted 16 years ago #

    I guess the upgrade script of WPMU will use a lot of memory, if you have many blogs. Other than that, 32MB per php process should be enough. The PHP default 8M is just way too small.

  15. lunabyte
    Member
    Posted 16 years ago #

    Pssst, James...

    Php.ini, not mysql.conf. ;)

  16. Farms2
    Member
    Posted 16 years ago #

    tum te tum, I do know what I'm doing... really :D

  17. Farms2
    Member
    Posted 16 years ago #

    http://edublogs.org/phpinfo.php

    Feedback as to optimisation etc. would be great!

  18. lunabyte
    Member
    Posted 16 years ago #

    Reminds me of a quote from a Dave Chapelle skit. You know, the one where he's doing a commercial for "Samuel L. Jackson" beer...

    Drink, b**ch!

  19. Farms2
    Member
    Posted 16 years ago #

    Heh - I think :)

  20. lunabyte
    Member
    Posted 16 years ago #

    I figured you might not "get it".

    I do though, so it's all good. :D

  21. Farms2
    Member
    Posted 16 years ago #

    Hurrah :)

About this Topic