Welcome to the MetaMod and Chameleon Support Forums.

Before posting, please check out the FAQs.

helpme

 

Need extra help with your Joomla site? Consider paid Joomla support by the developer of Chameleon and MetaMod.

 

Uddeim link that shows new PMs?

Uddeim link that shows new PMs?

I don't know if this is possible, or if it is possible with your mod or not, but I am hoping so.  If it is, I will bake you all cookies and love you long time.

With that said, I am using Uddeim PMS.  I would like it to display "Private Messages" as a menu link if you have no unread PMs (easy enough), but have it display, say "Private Messages (1 New)" or something like that.

Is this possible? Please please smile

I am using Joomla 1.5.24, and the newest Metamod (I just downloaded it!).  In case you aren't familiar with Uddeim, it is at http://www.slabihoud.de/software/id4001.htm

Edited By: Paladin Brewer
21-Nov-11 04:26:22

Paladin Brewer
Beginner Modder
ranks
useravatar
Offline
13 Posts
Administrator has disabled public posting

Re: Uddeim link that shows new PMs?

Oh, you're so going to love this.

Instead of MetaMod, use Chameleon. Even the Lite (free) version will work. (Note: Joomla 1.5 only - see http://www.metamodpro.com/forums/topic?id=1387#p6275 for a Joomla 2.5+ version)

Install it.
Create a new rule and give it a title.
Find the box in the right column in the "SUCCEED Actions" section, called "Run PHP"
Copy and paste in the following PHP code.
Make sure you find the menu id (Itemid) of the menu that you want to change the name of, and edit the first line of the PHP code to use that id number.
Save the rule.
Enjoy.

Code:

$menuid = XXX; // replace XXX with the id of the menu item to change


$udduserid = $user->id;
$uddsql="SELECT count(a.id) FROM #_" . "_uddeim AS a WHERE `a`.`delayed`=0 AND a.totrash=0 AND a.toread=0 AND a.toid=".(int)$udduserid;

$db->setQuery($uddsql);
$uddresult=(int)$db->loadResult();
$message = "Private Messages";
if ($uddresult > 0) $message .= " ($uddresult new)";
$menu =& JSite::getMenu();
$menu->_items[$menuid]->name = $message;

Freshly baked cookies are great but might not be so fresh by the time they get to New Zealand. Purchasing the full version of Chameleon would be a great second option smile

Best regards,
Stephen

Stephen Brandon
MetaMod / Chameleon developer
If you use MetaMod or Chameleon, please post a rating and a review at the Joomla! Extensions Directory: Chameleon | MetaMod

metamodguy
useravatar
Offline
3329 Posts
User info in posts
Administrator has disabled public posting

Re: Uddeim link that shows new PMs?

Oh man that worked with no problem, I could kiss you. I thought this would not be possible and I was going to cry sad I would so love to buy it if I wasn't unemployed :0 But I've seen people asking this same question in my searches, so I will advertise for you, best I can do smile

Paladin Brewer
Beginner Modder
ranks
useravatar
Offline
13 Posts
Administrator has disabled public posting

Re: Uddeim link that shows new PMs?

hey by all means spread the word - thanks!

And...

"If you use Chameleon, please post a rating and a review at the Joomla! Extensions Directory"

Stephen Brandon
MetaMod / Chameleon developer
If you use MetaMod or Chameleon, please post a rating and a review at the Joomla! Extensions Directory: Chameleon | MetaMod

metamodguy
useravatar
Offline
3329 Posts
User info in posts
Administrator has disabled public posting

Board Info

Board Stats:
 
Total Topics:
1683
Total Polls:
6
Total Posts:
5940
Posts this week:
11
User Info:
 
Total Users:
5142
Newest User:
zaki98040
Members Online:
0
Guests Online:
141

Online: 
There are no members online

Forum Legend:

 Topic
 New
 Locked
 Sticky
 Active
 New/Active
 New/Locked
 New Sticky
 Locked/Active
 Active/Sticky
 Sticky/Locked
 Sticky/Active/Locked