-
Notifications
You must be signed in to change notification settings - Fork 0
/
mod_jmnewsticker.php
29 lines (24 loc) · 1009 Bytes
/
mod_jmnewsticker.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
<?php
/**
* @module JM News Ticker
* @copyright Copyright (C) 2016 John McCabe
* @license GPL 3
*
*/
defined ( '_JEXEC' ) or die ( 'Restricted access' );
error_reporting ( E_ERROR );
define ( "DS", DIRECTORY_SEPARATOR );
require_once __DIR__ . '/helper.php';
/* Handle the JQuery and Javascript stuff */
$document = &JFactory::getDocument ();
$loadJ = $params->get ( 'loadJ', true );
if ($loadJ) {
$document->addScript ( JURI::root () . 'modules/mod_jmnewsticker/js/jquery.js' );
}
$document->addScript ( JURI::root () . 'modules/mod_jmnewsticker/js/jquery.nc.js' );
$document->addScript ( JURI::root () . 'modules/mod_jmnewsticker/js/jquery.ticker.js' );
$document->addStylesheet ( JURI::root () . 'modules/mod_jmnewsticker/css/style.css' );
/* Get the data we're going to show from the helper */
$rows = mod_jmnewstickerHelper::getList ( $params );
/* Need to pull in the selected layout file */
require JModuleHelper::getLayoutPath ( 'mod_jmnewsticker', $params->get ( 'layout', 'default' ) );