Remove unused custom metaboxes from Book info custom post type


#1

If we do not use the custom metaboxes of comments and discussions, maybe we should take it off.


#2

This does not appear for me, so I’m a bit puzzled. The Book Information post type is registered without support for comments, so this shouldn’t be showing up.


#3

Not even if you go to screen options and you show it?


#4

I see is registered without support, but i don´t understand too why the option is available in screen options. If i try to add comments, of course do not works, but the metabox still there.


#5

It doesn’t appear in Screen Options for me.


#6

Really? I do have one installation for development and other just for testing purposes with just the original Presbooks and 3 more plugins. Nothing else. And we have see that in both installations.

Now i´m reviewing the final installations were we will offer the books and we do not have such boxes. Weird.

I will do more research. and i will let you know


#7

I use plesk for the sites and I have 2 containers. One for production and other for development. The one about development ((NameOfTheSite.lvps84-39-103-248.mammuts-servidor.es/) have several installations for testing. Some of them new and fresh. And they have the metaboxes available. We are in the middle of the installation of the dependencies. Could be we did something wrong installing the dependencies?
We don´t have something else different…


#8

Do you have any other plugins installed?


#9

I just set up a fresh install with just the Pressbooks plugin and I can’t reproduce this issue. I expect it’s a conflict with another plugin.


#10

System Information

Book Info

Book ID: 8
Book URL: http://pressbooks.lvps84-39-103-248.mammuts-servidor.es/metadata/
Book Privacy: Public

Browser

Platform: Apple
Browser Name: Firefox
Browser Version: 53.0
User Agent String: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:53.0) Gecko/20100101 Firefox/53.0

WordPress Configuration

Network URL: http://pressbooks.lvps84-39-103-248.mammuts-servidor.es/
Network Type: Subdirectory
Version: 4.7.4
Language: en_US
WP_ENV: Not set
WP_DEBUG: Enabled
Memory Limit: 64M

Pressbooks Configuration

Version: 3.9.8.2
Book Theme: Luther
Book Theme Version: 1.7.0
Root Theme: Pressbooks Publisher
Root Theme Version: 3.0.1

Pressbooks Dependencies

Epubcheck: Not Installed
Kindlegen: Not Installed
xmllint: Installed
PrinceXML: Not Installed
Saxon-HE: Not Installed

Must-Use Plugins

Network Active Plugins

Pressbooks: 3.9.8.2
Pressbooks mPDF: 1.6.2.3

Book Active Plugins

Pressbooks mPDF: 1.6.2.3

Inactive Plugins

Akismet Anti-Spam: 3.3
Hello Dolly: 1.6
Pressbooks Textbook: 3.0.2.1
Wordfence Security: 6.3.7

Server Configuration

PHP Version: 7.0.18
MySQL Version: 5.5.53
Webserver Info: Apache

PHP Configuration

Safe Mode: Disabled
Memory Limit: 256M
Upload Max Size: 2M
Post Max Size: 8M
Upload Max Filesize: 2M
Time Limit: 30
Max Input Vars: 1000
URL-aware fopen: On (1)
Display Errors: On (1)

PHP Extensions

cURL: Supported
cURL Version: 7.35.0
imagick: Installed
xsl: Installed


#11

Hacky, but can you try changing this line from:

'supports' => array( '' ),

to:

'supports' => false,

(See https://codex.wordpress.org/Function_Reference/register_post_type#supports)


#12

Do not works the change.

And is strange, because in my production sites, those metaboxes do not exist. I just can see it in my testing and development sites…


#13

This was a bug. @dac.chartrand fixed it: https://github.com/pressbooks/pressbooks/pull/1014