![]() |
Real Names Listed Under Usernames in Calendar Posts
Someone kindly helped me to figure out how to list my member's real names directly under their usernames in posts. However, this does not work with calendar posts and I'm wondering how I can change that. Here is how I got the names to show up under their usernames.
In the postbit template find: PHP Code:
PHP Code:
Can anyone help me figure out how to make this work for the calendar posts?:confused:I would think it would be simple, but I just don't know what I need to edit. |
Have you looked at the calendar templates?
|
I've looked at them, but I'm kind of new to this and I'm not sure which one I should edit. Would I just find this same line of code...maybe do a search for it...and that would be the correct template to change?
|
Let me look and see if I can find anything.
--------------- Added [DATE]1206996689[/DATE] at [TIME]1206996689[/TIME] --------------- Try looking for username in the search templates. There are a few calender ones that have that. I'm not sure which one you are wanting. |
Thanks! I'll do that. I really appreciate your help. I have a big re-launch on Thursday and a meeting with our 250 members to demo the site and I'm freaking out about all the details right now, some of which are major!
|
Just relax and remember, the world doesn't end it things aren't up to snuff. ;)
|
Thanks! It is just very nerve-wracking because I just discovered that even though I put all my members into the usergroup for paid subscriptions, they will apparently not be treated the same way as a paid member because they are not listed as "subscribed members". I guess their membership won't expire. This is a major issue and I have no clue what to do about it. I've posted in here about it.
|
When it comes to subscriptions, I am at a loss as I have never used that.
|
I think we came up with a plan! Whew! I posted it in that thread I linked to in case someone else needs to know.
I still haven't figured out the other problem with the real names not showing up under usernames in the calendar posts, but hopefully I'll figure it out. After my other problem, this seems very minor! |
You'll get it. You're on a roll now. ;)
|
1 Attachment(s)
ok, I am not 100% sure if this is what you're looking for... it may not be the best solution either.
Unfortunately I don't think the custom profile fields is available in the calendar_showeventsbit template, which is the template I think you are looking for. Therefor you need a plugin to get that information, a call to the function fetch_userinfo would work. This will add one sql query for each user though. Which doesn't feel like the best solution honestly. Maybe someone else has a better idea. I have attached a simple plugin to this message, its for the hook calendar_getday_event. Import that plugin and edit the template calendar_showeventsbit Find Code:
<td align="$stylevar[left]"><if condition="$show['postedby']"><a class="bigusername" href="member.php?$session[sessionurl]u=$eventinfo[userid]">$eventinfo[musername]</a><else /> </if></td> Code:
<td align="$stylevar[left]"><if condition="$show['postedby']"><a class="bigusername" href="member.php?$session[sessionurl]u=$eventinfo[userid]">$eventinfo[musername]</a><div class="smallfont">$eventbituser[fieldx] $eventbituser[fieldx]</div><else /> </if></td> Hopefully it was something like this you where looking for :) /SK |
Thanks so much! I am a newbie who is jumping in with both feet, so I have to say I am not totally sure if I did this right. It didn't seem to change anything. I imported the plugin and then I edited the calendar_showeventsbit template, as you said. But, nothing seems to have changed. Did I miss a step?
Thanks again for helping!:) Seeing real names on all posts is a very important issue to the leaders of my group. Hope I can get this figured out! |
That should have done it, I tested this and it works for me.
You can test and add some random text before $eventbituser[fieldx] If that text shows up then it is the correct template and probably something wrong with the plugin. /SK |
I tested it and apparently I do have the right template, but those fields are still not showing up. I also did some checking to make sure I did everything right with the plug-in (since I'm new at this) and it looks like all you do is upload it, correct? Everything looks right to my untrained eye.;) Any thoughts?
By the way, do you think this will slow things down? Is that what you were concerned about with it querying the database for all the users? (Again, I'm still learning). I am having a major issue with my site being slow right now, so I am scared of anything slowing it down further. But, I guess I could always take it out if it caused problems. Thanks again for your help! |
The plugin should be imported via the admincp (Plugins & Products -> Download / Upload Plugins -> Import Plugin Definitions XML File)
Make sure its activated. It should be by default though. Not sure otherwise, not much that can goes wrong... You did remember to change the X to correct fieldnumber I hope. As I mention before this will add a query for each user when showing a calender event so it won't make things quicker... But as you said, if there would be a problem just deactivate the plugin in the plugin manager. /SK |
Hmmmm...I cannot seem to figure out what in the world I am not doing right! :confused: Could it be a version thing? I'm running 3.6.8 PL2. Here is the code I pasted in (with a snippet of some of the code before and after). I don't know that it will really help for you to see it, because I pasted it in right where you said to, to my knowledge. But, maybe you'll catch something I missed.
PHP Code:
|
That seems correct to me.
I guess the plugin doesn't run correctly. Do you have other plugins? Do they run? I realize that this a bit desperate, but just to be sure that the plugin/hook system isn't turned off. Otherwise go to the plugin and edit it. Add this after the current line. PHP Code:
/SK |
You know what...
After all this, my husband and I were trouble-shooting the site last night about the slowness issue and we found that the other code I had added to display the real names below the posts was slowing things down quite a bit! I think the host is not exactly lightning fast, but I'm kind of stuck with them right now. Sooooo....I think I'm going to save all this for later. Maybe we can switch hosts at some point. I'm hoping the leaders of my organization don't notice that there are no longer names under the posts.;) This was quite important to them. But, for now, it's just not going to work, since pages were sometimes taking up to 35 seconds to load! THANK-YOU for all your help, though! It is so nice when people take the time to help newbies like me.:D |
All times are GMT. The time now is 06:28 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|