CB substitutions - html format not displayed unless "show on profile" is Yes

1 month 2 weeks ago - 1 month 2 weeks ago #337649 by markfajgenbaum
Dear Support ,

For cb substitutions, it seems that I can call for the Raw Value of a field to be displayed regardless of whether the parameter "show on profile page" for the field in question is Yes or No, but I cannot do the same for the html format of the field - the html will not display as a cb substitution unless that field has the parameter "show on profile page" set to Yes. This is limiting.

e.g. I have a date field. I wish for the date to be displayed in a particular php format (e.g. MM-YYYY or whatever the case may be, which is duly set in the field's parameter setting). The only way for this to show up as MM-YYYY as a field substitution is to call the html of the field (not the raw field value). All good so far. Except, I can only get the html output to display IF the date field in question has the parameter “visible on profile” turned on. This is limiting, because some parameters you do not wish to show on the profile page. I am aware that you can place the date field in question in a “not shown in profile” tab position. But if I do this, the field can only be edited within that “hidden tab” and I wish the date field to be edited in another tab, to which it is more relevant. The upshot of all of this, is that allowing the html display of a cb_substitution to show irrepsective of the “displayed on profile page Y/N” parameter (similar to behaviour of raw value) would be very useful. Thank you for clarifying if this is doable.

Kind regards, Mark

Please Log in to join the conversation.

1 month 2 weeks ago - 1 month 2 weeks ago #337650 by markfajgenbaum
Hi support,

just an update: I ended up circumventing the issue, by putting the date field inside a tab that was in a hidden module position after all. But there will still be use cases where it would be helpful to hide a field from its standard profile display position (on the basis of where you might want it to appear in edit or registration), yet to call it in another position (e.g. another tab) in the profile display using cb_substitution.

I can see that the benefit of having the html substitution display respond to the publish-ability status of the original field, is that when the original field is empty, for example, the html display within a substitution can disappear (assuming empty fields are set to hidden in global parameters) etc; ie it responds to whether the field is even publishable. But it would be good to have a parameter within the cb_substition call, that will allow the html display to be overridden and always presented (much like the raw value), regardless of the publish ability status of the original field. ta, m

Please Log in to join the conversation.

1 month 2 weeks ago #337657 by krileon
Formatted substitutions always respect any display or access requirements of the field. The standard way to do this is to move the field to a not shown on profile tab position.

This may change a bit with CB 3.x as we might add a separate parameter to flag it has hidden, but still accessible. Ideally we'd like to provide a profile layout builder (similar to page builders) and these display parameters could just go away as display would be subject to whatever is setup in the layout, but that's just a "want to have" and may not make it into CB 3.x


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.191 seconds

Facebook Twitter LinkedIn