Skip to Content Skip to Menu

[SOLVED] Help with Creating a Query Field

10 years 2 weeks ago - 10 years 2 weeks ago #251466 by Smooth2SITF
Replied by Smooth2SITF on topic Help with Creating a Query Field
Ok great!

I got it to work... sorta.. but I ran into another problem.

Ok, here is what I did. I created a new tab (Officers Information) that's public view, but does not show on the public view of the profile. That was done to have certain member phone numbers on a officers list, but does not allow my entire database to be public.

I took my Contact Info field and changed the view to "Registered" so I can protect that info from Public View for all members.

I changed the Users setting in the Config to Show Profile.

I updated the fields in the List to the new fields made in Custom HTML

I checked the view, and yes, I can see the profiles now and it doesn't show the information I wanted to protect on it, so that's good however, if I check the list with the new fields, it doesn't show the data.

Here is my theory. Since the original field is in a Tab that is not publicly viewable on a profile (and I want to keep it that way, it wont show up under the new public tab setting) it will not show on the Custom HTML either, regardless if it is public or not.

Is there a way around this??

Make the field view on my list regardless of the original field's setting? Maybe like code something on the Custom HTML field to by-pass the original field's security settings?

I guess this derives from the security setting on the Tab instead of the individual fields.
Last edit: 10 years 2 weeks ago by Smooth2SITF. Reason: Added 1 more line

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48482
  • Thanks: 8283
  • Karma: 1443
10 years 2 weeks ago #251472 by krileon
Replied by krileon on topic Help with Creating a Query Field
In order for fields to be accessible through API (substitutions, getFields, etc..) but not visible on profile the fields need to be put on a tab that is in a not shown on profile position, but you need to ensure the fields themselves are set to display on profile (they won't due to the tabs position).


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 or Create an account to join the conversation.

10 years 2 weeks ago #251475 by Smooth2SITF
Replied by Smooth2SITF on topic Help with Creating a Query Field
I did that. I created a whole entire new tab that would be visible on a List but not on a profile.

I created the new fields based on what you had told me. The fields did work

The problem is, since the field the data comes from originally is not on a public tab, the new tab carries over the same security properties than the original.

Therefore, the field will not show on public view, even though the tab is public.

Is there a way around it?



Here is my delema: I have a List on my site that shows our organizations officers. I do want to show their phone numbers & link to email contact page. In order for the e-mail contact page to work, I had to make the profiles public as Nick had stated. Which brought me to the problem I have now. So, I created the new tab, and made the Tab public, but doesn't show on the profile. Well that works however, since the original data field is on a Tab that does not show on the profile, it causes the same data on the new field not to show up in my user list.

The reason I want to do this is, in case one of the officers updates their information, it changes it on the officers list page as well. I didn't want the entire membership's information public, but for the officers only, if they are on that Officers List, I wanted them only to show up.

Is there a work around to get around that? I have created the new tab, and the new fields and it works, other than the public view issue.

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48482
  • Thanks: 8283
  • Karma: 1443
10 years 1 week ago #251600 by krileon
Replied by krileon on topic Help with Creating a Query Field
Your tab should be public, published, and in a not shown on profile position. The fields on that tab can then be put into a column on your userlist and they'll display.

If you're substituting fields into a delimiter field that have no display on profile or a tab that's not accessible then it's not going to display anything unless you use raw values like [FIELD_NAME].

Aside from that I don't know what more to suggest aside from just putting the data you won't want publicly visible into a not shown on profile position, limit your userlist to officers only, then put whatever fields you want on it.


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 or Create an account to join the conversation.

10 years 1 week ago #251669 by Smooth2SITF
Replied by Smooth2SITF on topic Help with Creating a Query Field
krileon, thanks for that bit of help! The [FIELD_NAME] command works! I was able to make it transfer the data by using that one.

Next question, it didn't work too well for the e-mail. Instead of displaying a "Send Email" link to a web e-mail contact page, it shows the e-mail address itself. I would like for it to use the e-mail contact page format sending the e-mail VIA our site to their e-mail address.

Is there something I can add to the [FIELD_NAME] part of the CustomHTML field to make it do that?

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48482
  • Thanks: 8283
  • Karma: 1443
10 years 1 week ago #251691 by krileon
Replied by krileon on topic Help with Creating a Query Field
Please read the below tutorial carefully.

www.joomlapolis.com/support/tutorials/107-use-cases/18353-using-substitutions-throughout-cb

[FIELD_NAME] is raw output. It does not care about access permissions. It will display the raw value as seen in database. [cb:userfield field="FIELD_NAME" /] is formatted output. It does care about access permissions. It will display the formatted value as seen in profile view. If you need formatted value then you need to make sure the API can access the field. This means the tab needs to be enabled, published, and have a view access level the user can reach. Next the field it self needs to be set to display on profile.


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 or Create an account to join the conversation.

Moderators: beatnantkrileon
Powered by Kunena Forum