[#1593] issue? field type image

14 years 2 months ago #126123 by ndee
[#1593] issue? field type image was created by ndee
Hi guys,

if I want to show a image field only if it contains an image I can not figure out how to achieve this. Because there is at least the nophoto_n.png listed, even if the user did not touch the tab at all - but I don't want to show up tab or field if no data has been uploaded

Possible solution: add a paramater to field type, something like "show default picture: yes/no" and if no, do not display the field at all

optional: maybe one can specify another default image because the nophoto_n.png is related to avatar but we (maybe many others) use the field also for custom photos on tabs.

greets,
ndee

Post edited by: ndee, at: 2010/03/07 19:51

Post edited by: krileon, at: 2010/03/09 17:21

###################
SPEED UP HELP, read first: Help us help you
###################

Please Log in to join the conversation.

14 years 1 month ago #126264 by krileon
Replied by krileon on topic Re:issue? field type image
I suggest using a delimiter field in that case. Simply set the field to not show on profile; then display the image on profile with a delimiter field using substitutions such as [cb_myimagefield]. If no image is specified it won't display anything. You could even use IF/ELSE type scenarios with advanced substitutions. Please see tutorials in signature for further substitution usage information.


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.

14 years 1 month ago #126279 by ndee
Replied by ndee on topic Re:issue? field type image
Hi Kyle,

this is a really good idea I did not think of that possibility. I will revert my cb.core.php hack to have less work on next update :)

Thanks a lot!

Edit: But maybe in future versions there is param for that because the tn_nophoto_n.png does not fit to images which do not belong to avatar and may display something different.

Post edited by: ndee, at: 2010/03/08 22:13

###################
SPEED UP HELP, read first: Help us help you
###################

Please Log in to join the conversation.

14 years 1 month ago #126360 by krileon
Replied by krileon on topic Re:issue? field type image
Agreed, would be a good feature request to allow supplying your own default image or none at all. Have added a feature request for such a thing.

#1593


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.

14 years 1 month ago #127544 by caseyd
Replied by caseyd on topic Re:[#1593] issue? field type image
I understand the concept of substitutions, I just can't seem to figure out where to place the code, or what the substitution code should be exactly. Could anyone clarify this for me?

Please Log in to join the conversation.

14 years 1 month ago #127583 by krileon
Replied by krileon on topic Re:[#1593] issue? field type image
caseyd wrote:

I understand the concept of substitutions, I just can't seem to figure out where to place the code, or what the substitution code should be exactly. Could anyone clarify this for me?

You can place substitutions within Delimiter fields, Tab descriptions, Field descriptions. Basically nearly all locations of CB. Please see tutorials in my signature for further information on substitution usage.


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.551 seconds

Facebook Twitter LinkedIn