WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] switch_to_blog does not properly set wp_upload_dir vars (5 posts)

  1. pmenard
    Member
    Posted 1 year ago #

    Testing out 3.5 Beta 1. Noticed something strange under Multisite. If I'm on the primary site and output the wp_upload_dir() returned array I note the basedir items is properly set to the '.../wp-content/uploads' path. Then if I call switch_to_blog(3) then call wp_upload_dir() again the basedir does not change.

    However if I'm on a subsite (not the main site) and call switch_to_blog() to some other subsite the basedir does properly update.

    In WP 3.4.2 the basedir item would change to the proper blog media upload path.

  2. Related ticket: #21459

  3. Ticket resolved :)

  4. pmenard
    Member
    Posted 1 year ago #

    Perfect. Thanks!

  5. Elan42.com
    Member
    Posted 1 year ago #

    Sorry but .... WHERE is the "upload_path" option in 3.5 beta 2 ????

    It was under settings -> media in 3.4.X, now it's gone !

    Is there some other way to change it like wp-config constants ??

Topic Closed

This topic has been closed to new replies.

About this Topic