Difference between revisions of "Notifications API"

(Created page with "==Overview== The built in notification system, first ever in Joomla allows your app to keep the user (or group of users) informed about various different events in your compo...")
 
(Overview)
Line 1: Line 1:
 
==Overview==
 
==Overview==
The built in notification system, first ever in Joomla allows your app to keep the user (or group of users) informed about various different events in your component. Think of notifications as important alerts that user would be interested to read and keep track of it.<br/>
+
The built in notification system, first ever in Joomla, allows your app to keep the user (or group of users) informed about various different events. Think of notifications as important alerts that user would be interested to read and keep track of it.<br/>
 
Notifications can be generated everywhere. In your component or plugins and later displayed inside JomSocial notification system.<br/>
 
Notifications can be generated everywhere. In your component or plugins and later displayed inside JomSocial notification system.<br/>
This tutorial will show you how, but since we do not have an idea of any third-party component we could use :) the examples will be done on a community plugin which will be triggered at [[onAfterProfileUpdate]] event<br/>
+
This tutorial will show you how, but since we do not have idea of any third-party component we could use :) the examples will be done on a community plugin which will be triggered at [[onAfterProfileUpdate]] event<br/>
If you don't know how to create plugin which will be triggered on this even, we suggest you to check [[Plugin_Tutorials#Community_Plugin|this guide]]
+
If you don't know how to create plugin which will be triggered on this event, we suggest you to check [[Plugin_Tutorials#Community_Plugin|this guide]]<br/>
 +
 
 +
===Implementing it in your component anyway===
 +
As stated in overview of this tutorial, we will generate notifications using community plugin.<br/>
 +
You will most likely want to generate it inside your component.  or your plugin. The following tutorial will work for it. You only need to determine at what point in your code the notification will be created and load the JomSocial Core Libraries file.
 +
<syntaxhighlight lang="php">
 +
require_once JPATH_ROOT .'/components/com_community/libraries/core.php';
 +
</syntaxhighlight>
 +
<br />

Revision as of 13:46, 1 October 2013

Overview

The built in notification system, first ever in Joomla, allows your app to keep the user (or group of users) informed about various different events. Think of notifications as important alerts that user would be interested to read and keep track of it.
Notifications can be generated everywhere. In your component or plugins and later displayed inside JomSocial notification system.
This tutorial will show you how, but since we do not have idea of any third-party component we could use :) the examples will be done on a community plugin which will be triggered at onAfterProfileUpdate event
If you don't know how to create plugin which will be triggered on this event, we suggest you to check this guide

Implementing it in your component anyway

As stated in overview of this tutorial, we will generate notifications using community plugin.
You will most likely want to generate it inside your component. or your plugin. The following tutorial will work for it. You only need to determine at what point in your code the notification will be created and load the JomSocial Core Libraries file.

require_once JPATH_ROOT .'/components/com_community/libraries/core.php';