Support » Networking WordPress » Where is Multisite data?

  • Resolved fredericch


    A bug in the program caused me to lose one of my websites. I would like to use Time Machine to restore to a previous state, but where is the actual multisite data file? If I restore that file, will all my website be restored, or are there multiple files that i need to restore?

Viewing 2 replies - 1 through 2 (of 2 total)
  • As you know the main deference between developing a single WordPress plugin vs. a multisite plugin is where data is written. According to this article since plugins normally have complete reign over one database, and in some cases the plugins local pages files you must be sure to only call the $wpdb global object instead of a hard-coded reference to a table.

    For example, if you need to execute an SQL command on the posts table, then do not use wp_posts as the table name $post_count = $wpdb->get_var($wpdb->prepare(“SELECT COUNT(*) FROM wp_posts”));

    use this

    $post_count = $wpdb->get_var($wpdb->prepare(“SELECT COUNT(*) FROM $wpdb->posts”));

    [signature moderated]

    Moderator Ipstenu (Mika Epstein)


    🏳️‍🌈 Halfelf Rogue & Plugin Review Team Rep

    fredericch – Same place WordPress Single Site is stored.

    Files are on your server, and house your themes, your plugins, and your uploaded media.

    SQL Database houses your post contents, site settings, users, etc.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Where is Multisite data?’ is closed to new replies.