CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Installing CiviCRM »
  • WordPress Installations (Moderators: Kurund Jalmi, Coleman Watts) »
  • Issues with CiviCRM on WPMU: Can't create or edit posts or pages
Pages: [1]

Author Topic: Issues with CiviCRM on WPMU: Can't create or edit posts or pages  (Read 940 times)

databell

  • I post occasionally
  • **
  • Posts: 32
  • Karma: -1
  • CiviCRM version: 4.5
  • CMS version: WordPress 4.0.1
  • MySQL version: 5.5.37-cll
  • PHP version: 5.3.25
Issues with CiviCRM on WPMU: Can't create or edit posts or pages
December 05, 2014, 12:10:36 am
I recently installed Civi on a WPMU site. Six sites in one and five use the Civi plugin.

Since the install, I’ve noticed strange issues. Like even though I’m a Super Admin, if I go to create or edit a pot or page, I can’t. I just got the title area and very little else. No text area. No Tags. No Categories. No Featured Image. You get the idea.

And if I create a new user and try to make them a Super Admin, I can’t. I check the box, hit submit and I get the white screen of death. Frustrating.

After turning Civi off in Plugins, everything came back!

So Civi is the cause and I’m wondering if it’s meant for Multi-Site at all. Or if the hosting plan is just too weak or combination of these factors. It's a LunarPages shared hosting plan that is in a subfolder of the main site (which amazingly....also has Civi installed! But it works fine here on a single site). I keep thinking I need a VPS or Cloud plan. Thoughts?

databell

  • I post occasionally
  • **
  • Posts: 32
  • Karma: -1
  • CiviCRM version: 4.5
  • CMS version: WordPress 4.0.1
  • MySQL version: 5.5.37-cll
  • PHP version: 5.3.25
Re: Issues with CiviCRM on WPMU: Can't create or edit posts or pages
December 05, 2014, 12:20:43 am
Found the solution. Turns out I had not installed Civi's database for the site. Once I did, the problem went away. Simple solution.

But it brings up another question in regards to WPMU. Will I need to create a database for each and every single site in the network? The client won't want that.

xavier

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4453
  • Karma: 161
    • Tech To The People
  • CiviCRM version: yes probably
  • CMS version: drupal
Re: Issues with CiviCRM on WPMU: Can't create or edit posts or pages
December 05, 2014, 12:38:35 am
you can use the same database for wordpress and civicrm. I suppose each site has already their own database? reuse that one and you don't have to create new ones.

They are pros and cons to have two separate databases, I personally favour having only one

X+
-Hackathon and data journalism about the European parliament 24-26 jan. Watch out the result

haystack

  • I post occasionally
  • **
  • Posts: 61
  • Karma: 2
  • CiviCRM version: 4.n
  • CMS version: WordPress 4.n
  • MySQL version: 5.n
  • PHP version: 5.n
Re: Issues with CiviCRM on WPMU: Can't create or edit posts or pages
December 05, 2014, 01:00:11 am
WordPress remaining functional during the install process is fixed (but yet to be merged) in:
https://github.com/civicrm/civicrm-wordpress/pull/64

In the case of WordPress multisite, it depends which kind of multisite you have. If you have subfolders, then you will need a separate Civi install per sub-site because the Civi backend will not be functional on sub-sites, only on the main site. If you're using subdomains, then Civi's backend should be functional on each site.

haystack

  • I post occasionally
  • **
  • Posts: 61
  • Karma: 2
  • CiviCRM version: 4.n
  • CMS version: WordPress 4.n
  • MySQL version: 5.n
  • PHP version: 5.n
Re: Issues with CiviCRM on WPMU: Can't create or edit posts or pages
December 05, 2014, 01:30:56 am
One more note regarding WPMU with subdomains:

If you want to point each subdomain to the same Civi instance, you'll have to do some amendment to your 'civicrm.settings.php' file per subdomain. This is because Civi defines a constant called `CIVICRM_UF_BASEURL` which contains the home URL and this will not match your subdomain in its default state - so you'll have to override it to match the subdomain. The `$_SERVER` array should contain all you need to set `CIVICRM_UF_BASEURL` appropriately depending on the domain being accessed.

(Disclaimer: I haven't tried this set up, so cannot guarantee that there won't be other side-effects)

databell

  • I post occasionally
  • **
  • Posts: 32
  • Karma: -1
  • CiviCRM version: 4.5
  • CMS version: WordPress 4.0.1
  • MySQL version: 5.5.37-cll
  • PHP version: 5.3.25
Re: Issues with CiviCRM on WPMU: Can't create or edit posts or pages
December 05, 2014, 04:53:38 pm
Thanks for the responses. That was what I was looking for

Just to clarify, all the 'sites' are on the same domain. So you'd have mysite.com/siteone, mysite.com/sitetwo and so on. Civi will be on it's own database while WP is on the other one. I just don't want to have X number of individual databases for each 'site' in this install.

With that in mind, I think haystack's most recent post is the correct one. Tweaking the civicrm.settings.php file, right?


haystack

  • I post occasionally
  • **
  • Posts: 61
  • Karma: 2
  • CiviCRM version: 4.n
  • CMS version: WordPress 4.n
  • MySQL version: 5.n
  • PHP version: 5.n
Re: Issues with CiviCRM on WPMU: Can't create or edit posts or pages
December 06, 2014, 01:55:57 am
Unfortunately - with your subfolder install - you're restricted to Civi being functional on the main site only. This is because Civi makes assumptions about the path to the WordPress admin pages. Search the Civi code for 'admin.php' to see the places where the assumptions are made. The result is that Civi never includes the slug of the sub-site in admin URLs, rendering the back end unusable. You'll see the Civi dashboard, but any further navigation will redirect to Civi on the main site.

At present, I don't think there's any tweaking of 'civicrm.settings.php' that will overcome this - it requires a whole raft of changes to Civi core. If you're interested (or bored) have a read here:
https://github.com/civicrm/civicrm-wordpress/pull/63#issuecomment-61738465

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Installing CiviCRM »
  • WordPress Installations (Moderators: Kurund Jalmi, Coleman Watts) »
  • Issues with CiviCRM on WPMU: Can't create or edit posts or pages

This forum was archived on 2017-11-26.