Support has been upgraded!
The Support Forum is closed. Not to worry! Providing the top quality support you expect and we're known for will continue! We're not ending support, just changing where you submit requests. This will provide you with the best experience possible.
Premium Support
Have you purchased an addon for Connections such as one of our premium templates or extensions with a valid license and you need help?
Please open a Support Ticket in your user account.
Free Support
Are you using the free Connections plugin? Don't worry, you are still very important to us! We are still providing you with the same high quality support that we're known for.
Please open a new support topic in the WordPress support forums for Connections.
Tagged: 8.6.2
- This topic has 5 replies, 2 voices, and was last updated 5 years, 11 months ago by
Jennifer.
-
AuthorPosts
-
04/04/2017 at 1:50 am #418838
Jennifer
ParticipantHi Steve,
Several questions that I’ve accumulated over the last week re: modifying the Add Entry page, at your convenience.
First, I’ve been trying to modify a code snippet for a similar solution you suggested for someone wanting to remove a radio label. I want to display Individuals and Families, but not organizations. I’ve tried several variations of the following:
function ottomek_link_entry_types( $atts ) { $atts['entry_type'] = array( __( 'Individual', 'connections' ) => 'individual' ); $atts['default']['type'] = 'individual'; $atts['default']['visibility'] = 'public'; return $atts; $atts['entry_type'] = array( __( 'Family', 'connections' ) => 'family' ); $atts['default']['type'] = 'family'; $atts['default']['visibility'] = 'public'; return $atts; } add_filter( 'cn_admin_metabox_publish_atts', 'ottomek_link_entry_types', 11 );
Is it possible to alter that code for this goal?
Second: I am also trying to hide the Organization and Department text fields on the Add Entry page. I have tried the following CSS without success (I am putting it on the tile-plus custom stylesheet).
#cn-metabox-section-organization {display: none !important;} #cn-metabox-section-department {display: none !important;}
Third: Is it possible to hide the “Select Relations” dropdown box via snippet or CSS? I have not been able to find the right CSS.
Fourth: Is it possible to expand the height of the categories box on the Add Entry page?
Fifth and Final: Can the “Add Entry” button be modified to say “Save Entry?” I tried this via Say What but it modifies the Add Entry page title and menu item. Believe it or not, a few of the non-tech savvy users have confused that button with the Add Email or other Add buttons, and for some reason believe that a box should pop up when that is pressed. Doesn’t make much sense to me, but requested by the end-user so wanted to ask.
Sorry for the length, just wanted to consolidate a bunch of admin questions into one thread. Thank you so much.
04/04/2017 at 11:27 am #418881Steven Zahm
Keymaster@ Jennifer
re: First
Close… this should do it (untested):
function cn_entry_types( $atts ) { $atts['entry_type'] = array( __( 'Individual', 'connections' ) => 'individual' , __( 'Family', 'connections' ) => 'family' ), ); return $atts; } add_filter( 'cn_metabox_publish_atts', 'cn_entry_types', 11 );
re: Second
Putting it in the template’s CSS will not have any affect on the admin pages. The template’s CSS is loaded only on the site’s frontend. There is no easy way to hide these fields in the admin, sorry.
You could try CSS using this plugin:
https://wordpress.org/plugins/add-admin-css/
re: Third
Like the org/dept admin fields, there is no easy way to hide the relations field.
re: Fourth
Yes, use this plugin.
https://wordpress.org/plugins/post-category-height-edit/
It works with Connections too. Still works fine even though it has not been updated in years. Really, an update would only be needed if WP radically changed their admin.
re: Fifth
Sorry, no you would have to edit the PHP code to make it distinct text from the other places that string is used.
Hope my answers have helped.
04/04/2017 at 3:13 pm #418900Jennifer
ParticipantThank you so much!!! That’s very very helpful.
The Add Admin CSS plugin works great — I really appreciate the tip. I was able to hide the org/dept fields.
The CSS class on the Select Relation box seems to change every time (div#cn_family_member_1220374488759__relation__chosen); if it isn’t possible to hide via CSS, is this something you can hide via customization? Also, same with the Add Entry button string?
If so, can you please add those to the quote list I emailed you? Or, I can resend a master list if that’s easier.
You are the best.
Jennifer
04/04/2017 at 3:27 pm #418901Jennifer
ParticipantOh, sorry… one more comment. Forgot to say that the Post Category Height plugin is a good workaround for now, but the setting isn’t retained at a user level and seems to reset if I switch browsers. If this is something that can be achieved by further customization by you, I would be interested in adding that to the aforementioned list as well.
04/05/2017 at 1:00 pm #419027Steven Zahm
Keymaster@ Jennifer
re: The CSS class on the Select Relation box seems to change every time (div#cn_family_member_1220374488759__relation__chosen); if it isn’t possible to hide via CSS, is this something you can hide via customization?
Yes, that is dynamic, controlled by the library the “enhances” the select drop down. You should be able to hide it with this:
ul#cn-relations div[id$='__relation__chosen'] { display: none; }
re: same with the Add Entry button string?
This could be customized by deregistering the “core” publish metabox and registering a custom one with the text you want. The biggest downside I see to this is if I add remove or otherwise make changes to the publish metabox that is required for Connections to function you would not get those changes because your instance would be using the custom publish metabox. I would expect occurrences like that would be very rare and well, the custom one could be updated. I’ll add this to the quote … working on it.
Forgot to say that the Post Category Height plugin is a good workaround for now, but the setting isn’t retained at a user level and seems to reset if I switch browsers.
This is cookie based, if I remember correctly. So, it should be based per browser, not per user. So it would change between browsers, but should be retained by the browser for a year, unless cookies are cleared.
I suppose some type of custom solution could be developed making it global and/or per user based. I’ll add that to the quote too.
04/06/2017 at 3:56 pm #419200Jennifer
ParticipantThe CSS you provided for the Select Relation box works like a charm. Thank you thank you!!!
Understood re: Add Entry button — I wouldn’t want to make any changes that will alter the site’s ability to be fully updated, so I’m not sure I would want to pursue that.
The main reason I want a cost-breakdown (aside from my wallet :P) is because I hope to have a long business relationship with you, and there will be other changes that the end user requests (it’s already happening) so I will need to choose what to prioritize first. I know it’s a pain to break everything down so I really appreciate your time on this. Talk soon.
-
AuthorPosts
You cannot reply to this support topic. Please open your own support topic.