Support » Networking WordPress » Backend multisite search with Domain mapping

  • eichelmann

    (@eichelmann)


    Hi,

    I have set up a multisite (with subdirectories) and created a page (e.g. http://www.mydomain.com/page1). In the backend (on “… wp-admin / network / sites.php”) I can search for this page normally.

    But as soon as I assign a domain to this page (e.g. “www.page1.com” instead of “www.mydomain.com/page1”) this page is no longer displayed in the search results when searching for “page1”.

    Is there a solution for this? Unfortunately I did not find anything on Google.

    I use the latest WP version

Viewing 1 replies (of 1 total)
  • Moderator bcworkz

    (@bcworkz)

    Your search fails because WP has no idea that it should be looking at domain names to match search terms. It knows about subdirectories and subdomains, but not domains. WP assumes all sites are under one domain such as example.com.

    You can alter the various SQL clauses used to query for sites through the ‘sites_clauses’ filter. As long as the values to match against search terms exists in the DB somewhere, a query can be composed to find them.

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