inherit
256569
0
Oct 23, 2018 20:18:45 GMT -8
Emory P. Sterling
21
October 2018
emorysterling
|
Post by Emory P. Sterling on Oct 6, 2018 14:06:17 GMT -8
Hello. I have installed and are using the award system plugin and it's working beautifully! I love it. So here is what I would like to do. I have created a custom page called "Dashboard" on my forum that contains widgets like the members profile, personal messages, notifications, recent posts and and so on. It's for each specific user, their information and their activity. What I want to do is add the awards that have been given to that specific user on their dashboard within a html widget container. Screenshot below: Is this possible? I have attempted this to no avail. Granted I don't know much about coding. I managed to learn enough to manipulate a lot but this one has me stumped. I understand that this isn't the place to ask for coding help regarding plugins but I don't plan to modify the plug in; just bounce over the awards to a widget. Thanks for any help or advice!
|
|
inherit
140147
0
Apr 30, 2024 0:07:08 GMT -8
Nscalerr 🐺
Throw me to the wolves and I'll return leading the pack!
3,007
May 2009
nscalerr
|
Post by Nscalerr 🐺 on Oct 6, 2018 18:42:25 GMT -8
Hi Emory P. SterlingAfter doing some testing of my own, it looks like the Awards plugin is only designed to show up in the profile and mini profile. If you make a request in the Support thread for the plugin, the creator may be able to come up with a custom version that has this function.
|
|
inherit
256569
0
Oct 23, 2018 20:18:45 GMT -8
Emory P. Sterling
21
October 2018
emorysterling
|
Post by Emory P. Sterling on Oct 6, 2018 20:54:03 GMT -8
Hi Emory P. Sterling After doing some testing of my own, it looks like the Awards plugin is only designed to show up in the profile and mini profile. If you make a request in the Support thread for the plugin, the creator may be able to come up with a custom version that has this function. Thanks! I shall. Also. I have one more question. I'm trying to create a text link to the current users profile with no luck. What I have done is used the Sidebar Redux to create a 'mini profile' on the homepage. I have my username at the top. Avatar below that. Links to various parts of my forum under that. I want to be able to include a text link called "Profile" for the user to click that will take them to their own profile. My idea is I want to do away with the standard navigation bar and use it in the side bar. I have used a code before that allowed me to do this, but I'm making a custom one where; instead of text, I'm using images. I have it all working except for the profile link. By default, it wants to take me to user/1 instead of the actual user that would be clicking the link themselves. I've tried using /user/$[current_user.id} but it fails. I'm not sure if I explained this good enough. lol. Pretty much I want every user to be able to use the sidebar redux navigation menu I created and be able to click the profile link and it will take them to their own profile. As you can see, I've made some progress since the first screen shot above.
|
|
inherit
140147
0
Apr 30, 2024 0:07:08 GMT -8
Nscalerr 🐺
Throw me to the wolves and I'll return leading the pack!
3,007
May 2009
nscalerr
|
Post by Nscalerr 🐺 on Oct 6, 2018 22:10:21 GMT -8
This bit of code will send a user that clicks on the link to their own profile.
<a href="$[current_user.href]"><img src="LINK TO IMAGE HERE" alt=""></a>
Any chance of a link to your forum ??
|
|
inherit
Official Code Helper
65613
0
1
Apr 15, 2024 17:01:41 GMT -8
Chris
"'Oops' is the sound we make when we improve"
8,864
December 2005
horace
|
Post by Chris on Oct 8, 2018 4:00:48 GMT -8
I've tried using /user/$[current_user.id} but it fails. ... Pretty much I want every user to be able to use the sidebar redux navigation menu I created and be able to click the profile link and it will take them to their own profile. Is there anyway to use proboards $[template variables] within the sidebar? e.i. $[current_user.avatar_medium] it doesn't seem like it works. I was hoping there would be a way that it could? It's not possible to use layout template variables within a plugin as they only exist within the layout templates themselves. You'd need to make a hidden <div> element in your Forum Wrapper template and move that into the sidebar using Javascript if you wanted to generate something using layout template variables. You could also try the following method <a href="user" onclick="this.href+=pb.data('user').id" rel="norewrite">LINK CONTENT</a> with the caveat that some browsers both now and perhaps in the future would view that as misleading since the user does not have the ability to see the final landing page on link hover (so could conceivably disallow now or in the future).
|
|
inherit
256569
0
Oct 23, 2018 20:18:45 GMT -8
Emory P. Sterling
21
October 2018
emorysterling
|
Post by Emory P. Sterling on Oct 8, 2018 19:15:10 GMT -8
Thanks guys for the help! Unfortunately it didn't work. I'm assuming it was disallowed. That's okay though. I can work around that.
|
|
inherit
2671
0
May 14, 2013 14:40:03 GMT -8
Peter
🐺
10,615
February 2002
peter3
|
Post by Peter on Oct 9, 2018 1:30:52 GMT -8
You can get the awards showing up on custom pages with a little bit of trickery.
<script>
pb.data("route").name = "page_user"; location.hash = "/user/" + pb.data("user").id;
</script>
<div class="container"> <div class="user_awards"></div> </div>
Place it inside the widget and that will fool the plugin in thinking it's a profile page.
|
|
inherit
140147
0
Apr 30, 2024 0:07:08 GMT -8
Nscalerr 🐺
Throw me to the wolves and I'll return leading the pack!
3,007
May 2009
nscalerr
|
Post by Nscalerr 🐺 on Oct 9, 2018 1:54:16 GMT -8
|
|
inherit
140147
0
Apr 30, 2024 0:07:08 GMT -8
Nscalerr 🐺
Throw me to the wolves and I'll return leading the pack!
3,007
May 2009
nscalerr
|
Post by Nscalerr 🐺 on Oct 9, 2018 2:09:08 GMT -8
I think I have this bit working too Chris and Emory P. Sterling looks like it just needed to be user/ <a href="user/" onclick="this.href+=pb.data('user').id" rel="norewrite">Profile</a>
|
|
inherit
256569
0
Oct 23, 2018 20:18:45 GMT -8
Emory P. Sterling
21
October 2018
emorysterling
|
Post by Emory P. Sterling on Oct 9, 2018 7:55:12 GMT -8
You can get the awards showing up on custom pages with a little bit of trickery. <script>
pb.data("route").name = "page_user"; location.hash = "/user/" + pb.data("user").id;
</script>
<div class="container"> <div class="user_awards"></div> </div> Place it inside the widget and that will fool the plugin in thinking it's a profile page. YES YES YES YES!!! Thanks! THAT'S AWESOME! You have made my entire week! I can't tell you how happy I am. I appreciate it!
|
|
inherit
256569
0
Oct 23, 2018 20:18:45 GMT -8
Emory P. Sterling
21
October 2018
emorysterling
|
Post by Emory P. Sterling on Oct 9, 2018 8:03:12 GMT -8
I think I have this bit working too Chris and Emory P. Sterling looks like it just needed to be user/ <a href="user/" onclick="this.href+=pb.data('user').id" rel="norewrite">Profile</a> I appreciate your help with this! So I tried this out and it sort of worked. It does take me to the correct user but I get an error when it displays. It may be getting stopped.
|
|
inherit
140147
0
Apr 30, 2024 0:07:08 GMT -8
Nscalerr 🐺
Throw me to the wolves and I'll return leading the pack!
3,007
May 2009
nscalerr
|
Post by Nscalerr 🐺 on Oct 9, 2018 21:05:02 GMT -8
Are you logged in when you tried this ?? Btw I have just joined your forum, (with the nick SkyFire & I like writing) and it worked ok for me.
|
|
inherit
256569
0
Oct 23, 2018 20:18:45 GMT -8
Emory P. Sterling
21
October 2018
emorysterling
|
Post by Emory P. Sterling on Oct 9, 2018 21:08:07 GMT -8
Yes I was. Glad you joined up! Sorry for the forum mess. I really need to speak to the maid.
|
|
inherit
140147
0
Apr 30, 2024 0:07:08 GMT -8
Nscalerr 🐺
Throw me to the wolves and I'll return leading the pack!
3,007
May 2009
nscalerr
|
Post by Nscalerr 🐺 on Oct 9, 2018 21:20:43 GMT -8
Just did some more testing on my forum and found that if you were already in your profile it would generate an error, but by changing it to the following it now works, (I am thinking this will solve the other problem too).
<a href="/user/" onclick="this.href+pb.data('user').id" rel="norewrite">Profile</a><br />
|
|
inherit
256569
0
Oct 23, 2018 20:18:45 GMT -8
Emory P. Sterling
21
October 2018
emorysterling
|
Post by Emory P. Sterling on Oct 9, 2018 21:21:10 GMT -8
So you clicked profile and it went to your profile?
|
|