Kunena 6.3.0 released

The Kunena team has announce the arrival of Kunena 6.3.0 [K 6.3.0] in stable which is now available for download as a native Joomla extension for J! 4.4.x/5.0.x/5.1.x. This version addresses most of the issues that were discovered in K 6.2 and issues discovered during the last development stages of K 6.3

Question [SOLVED] How to add security to the Birthdate for guests?

More
12 years 10 months ago - 12 years 10 months ago #1 by Cordel
This is sort of a hack, things are in the right place but there are two calls added to load Kunena config from the database so it probably could be cleaner. Other than that it works in both Vanilla Kunena and Kunena with CB tested.

I have a typical site, using the latest CB 1.4.0, Joomla 1.6.3, uddeIM 2.3, and Kunena 1.6.4 at this time.
I have setup field integration between CB and Kunena. I'm not sure exactly where the security should really lay but I'm choosing to place the security in Kunena as it seems the logical place to me. I'd also be happy to share the patch with whom ever wants it.

What I have not been able to find though to implement the birthday not being visible to guests on the profile table next to the post is a feasible function or condition to use in administrator/components/com_kunena/libraries/user.php
Code:
case 'birthdate' : if (($this->birthdate) && ($session->guest == 0)) { jimport('joomla.utilities.date'); $date = new JDate ( $this->birthdate, 0 ); if ($date->toFormat('%Y')<1902) break; return '<span class="kicon-profile kicon-profile-birthdate" title="' . JText::_ ( 'COM_KUNENA_MYPROFILE_BIRTHDATE' ) . ': ' . CKunenaTimeformat::showDate ( $this->birthdate, 'date', 'utc', 0 ) . '"></span>'; } break;
I added $session->guest in this trial and have also tried using $this->userid as a condition and in several variations of each. I would think there would be a function some where that would return is registered or the like but have not found it as of yet.

I also modified Blue Eagle theme to show the social icons in this same area and would apply the same security in this same file. Ideally this would key off of parameter in com_kunena "Allow Guests to see User Profiles" but I have not yet been able to figure out how to use this.

Any pointers or advice would be helpful.

This message contains confidential information

Database collation check: The collation of your table fields are correct

Legacy mode: Disabled | Joomla! SEF: Disabled | Joomla! SEF rewrite: Disabled | FTP layer: Disabled |

This message contains confidential information
htaccess: Missing | PHP environment: Max execution time: 30 seconds | Max execution memory: 128M | Max file upload: 5M

This message contains confidential information

Joomla default template details : yougrids | author: Youjoomla LLC | version: 1.0 | creationdate: 10-01-2010

Kunena default template details : Blue SEK (default) | author: Kunena.org | version: 1.6.4 | creationdate: 2011-05-07

Kunena version detailled: Installed version: 1.6.4 | Build: 4832 | Version name: Kerkrade | Kunena detailled configuration:

Warning: Spoiler!

Third-party components: CommunityBuilder: The file doesn't exist comprofilej.xml ! | UddeIm: The file doesn't exist uddeim.j15.xml !

Third-party SEF components: None

Plugins: System - Mootools Upgrade: Disabled | System - Mootools12: Disabled | Kunena Search 1.6.4 | Kunena Discuss 1.6.4

Modules: Kunena Latest 1.6.4 | Kunena Stats 1.6.4 | Kunena Login 1.6.4 | Kunena Search 1.6.4

Last edit: 12 years 10 months ago by Cordel. Reason: Edit to mark solved and put info on top.

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

More
12 years 10 months ago #2 by Cordel
Guess I need to repost this and omit details, and be more specific to keep from being unnecessarily moved. :angry:
So here I'll try again. :whistle: and reword it so it's understood why it's here.

In Kunena, when a user fills out his Birthdate, it shows on the summery profile next to, or on top of his post depending on your configuration. I need this to not show for guest users and it makes no difference if you are using a vanilla Kunena or integration. This includes when not to show profile to guests is set in a vanilla installation whit no integration.

What I need help with:
I need to find a function or condition that I can add to administrator/components/com_kunena/libraries/user.php to omit the icon and tooltip for Birthday from the summery profile that is next to the users post.

Here is the section of code I'm looking at and example of what I tried:
administrator/components/com_kunena/libraries/user.php
Code:
case 'birthdate' : //if ($this->birthdate && (! $this->userid)) { //Added member condition so not public if (($this->birthdate) && ($session->guest == 0)) { jimport('joomla.utilities.date'); $date = new JDate ( $this->birthdate, 0 ); if ($date->toFormat('%Y')<1902) break; return '<span class="kicon-profile kicon-profile-birthdate" title="' . JText::_ ( 'COM_KUNENA_MYPROFILE_BIRTHDATE' ) . ': ' . CKunenaTimeformat::showDate ( $this->birthdate, 'date', 'utc', 0 ) . '"></span>'; } break;
Obviously I'm not fully understanding something and I'm learning. Any pointers would be appreciated!

I'm using Joomla 1.6.3, Kunena 1.6.4
More details about this at this link:
www.kunena.org/forum/12-community-builde...birthdate-for-guests

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

More
12 years 10 months ago #3 by sozzled
*** Topics merged ***

The answer to this question requires an understanding of both Kunena and Community Builder. Please don't start several topics on the same subject; let's keep the discussion focused in the one area.

I don't, personally, know the answer. I hope that someone else, who may know the answer (and who has an interest in both Kunena and Community Builder) will see your topic and will respond. :)

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

More
12 years 10 months ago #4 by Cordel
No actually this problem lays in vanilla Kunena as well! as explained above if you would read!
Otherwise I would not repost as I have to moderate as well and know the issues with users... hence I have no patience for BS.
At least I read before flaming!!!!!!!!!!!!!!1

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

More
12 years 10 months ago #5 by sozzled
So we are actually discussing how to make changes to "vanilla-flavoured" Kunena, eliminating any integration issues with Community Builder? Have I correctly interpreted your question now?

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

More
12 years 10 months ago #6 by Cordel
Guess I need to repost this and omit details, and be more specific to keep from being unnecessarily moved. :angry:
This is a problem with Kunena where it exposes the Birthdate in the profile summery next to the forum post and I need it not to.

This happens with no integration! So stop moving the POST to CB section!

In Kunena, when a user fills out his Birthdate, it shows on the summery profile next to, or on top of his post depending on your configuration. I need this to not show for guest users and it makes no difference if you are using a vanilla Kunena or integration. This includes when not to show profile to guests is set in a vanilla installation whit no integration.

What I need help with:
I need to find a function or condition that I can add to administrator/components/com_kunena/libraries/user.php to omit the icon and tooltip for Birthday from the summery profile that is next to the users post.

Here is the section of code I'm looking at and example of what I tried:
administrator/components/com_kunena/libraries/user.php
Code:
case 'birthdate' : //if ($this->birthdate && (! $this->userid)) { //Added member condition so not public if (($this->birthdate) && ($session->guest == 0)) { jimport('joomla.utilities.date'); $date = new JDate ( $this->birthdate, 0 ); if ($date->toFormat('%Y')<1902) break; return '<span class="kicon-profile kicon-profile-birthdate" title="' . JText::_ ( 'COM_KUNENA_MYPROFILE_BIRTHDATE' ) . ': ' . CKunenaTimeformat::showDate ( $this->birthdate, 'date', 'utc', 0 ) . '"></span>'; } break;
Obviously I'm not fully understanding something and I'm learning. Any pointers would be appreciated!

I'm using Joomla 1.6.3, Kunena 1.6.4
More details about this at this link:
www.kunena.org/forum/12-community-builde...birthdate-for-guests

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

More
12 years 10 months ago - 12 years 10 months ago #7 by Cordel
YES THAT IS CORRECT!
Thank You.
Feel free to either delete these or what ever you like.
Last edit: 12 years 10 months ago by Cordel.

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

More
12 years 10 months ago - 12 years 10 months ago #8 by sozzled
You only had to ask nicely. Let's keep things together and not fragment the discussion, shall we?

I can probably answer the question, without delving into the specifics of Community Builder, as far as Kunena is concerned. When we start talking about Community Builder we're narrowing the focus. Give us a chance to find the answer for you and reply with the information.

This is a community-driven, self-help forum where we encourage everyone to help one another. Please try to remain calm and be patient why we look for ways that will help you effectively. OK?
Last edit: 12 years 10 months ago by sozzled.

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

More
12 years 10 months ago #9 by migus
Hi Cordel,
I have a custom solution for this issue in:
...home.../components/com_kunena/template/default(or yours)/view/profile.vertical.php
simply use if ( $this->my->id ) statement:
Code:
<li class="kpost-smallicons"> <?php echo $this->profile->profileIcon('website'); ?> <?php echo $this->profile->profileIcon('gender'); ?> <?php if ( $this->my->id ) : ?> <?php echo $this->profile->profileIcon('birthdate'); ?> <?php echo $this->profile->profileIcon('location'); ?> <?php echo $this->profile->profileIcon('private'); ?> <?php echo $this->profile->profileIcon('email'); ?> <?php endif ?> </li>
Good luck :cheer:

Altai Mountains - is a fairy tale!

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

More
12 years 10 months ago #10 by Cordel
Thank you and I understand the concept as I manage many forums and moderate 32 my self.
I'm sure you get plenty users that don't get the subject right or even care to try so I get that. Hence why I reworded the issue to point out what I hoped to be obvious enough.

So in short, I'm looking for an appropriate function within Kunena to validate whether or not the person is registered and logged in. For this portion of code in administrator/components/com_kunena/libraries/user.php and a native function to either Joomla framework, or Kunena ( maybe I should have phrased it this way ). ;)


We have over 300 sites that I contract to that use Kunena and I'm getting more and more questions to this particular issue. If it were just showing Month and Day they probably would overlook it but it shows the year and I am getting growing concerns of ID Theft :( Yet they like to use it.

Thank you

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

Time to create page: 0.609 seconds