Hello There, Guest! › Register

MySubscriptions 2.2 released.
Looking for a custom plugin for your site? Ask here for a quote.

Adding links
#1

Is there a way to add links into the left menu area of newpoints.php?
#2

Yes, take a look at the /newpoints.php file, I believe that's where links are added. (can't remember right now)

Let me know if you can find it.
To download our paid plugins and receive support you must be a paid subscriber. Click here for more information.
#3

(05-10-2011, 03:57 AM)Pirata Nervo Wrote: Yes, take a look at the /newpoints.php file, I believe that's where links are added. (can't remember right now)

Let me know if you can find it.
How do I add it?
I think this is the code?
PHP Code:
// default menu options
$menu[0] = '<a href="'.$mybb->settings['bburl'].'/newpoints.php">'.$lang->newpoints_home.'</a>';
if (
$mybb->settings['newpoints_main_statsvisible'] == 1)
    
$menu[1] = '<a href="'.$mybb->settings['bburl'].'/newpoints.php?action=stats">'.$lang->newpoints_statistics.'</a>';
if (
$mybb->settings['newpoints_main_donationsenabled'] == 1)
    
$menu[2] = '<a href="'.$mybb->settings['bburl'].'/newpoints.php?action=donate">'.$lang->newpoints_donate.'</a>';
    
if (
$mybb->input['action'] == '')
{
    
$menu[0] = "&raquo; ".$menu[0];
}
elseif (
$mybb->input['action'] == 'stats')
{
    
$menu[1] = "&raquo; ".$menu[1];
}
elseif (
$mybb->input['action'] == 'donate')
{
    
$menu[2] = "&raquo; ".$menu[2];



#4

At the bottom of that code add:
PHP Code:
$menu[3] = '<a href="'.$mybb->settings['bburl'].'/newpoints.php?action=MYPAGE">This is my new page</a>'
To download our paid plugins and receive support you must be a paid subscriber. Click here for more information.
#5

I got this error
Parse error: syntax error, unexpected T_IF in /home/gfxcafen/public_html/mcmines.com/inc/plugins/newpoints.php on line 57
Here is the code with MY edits.
PHP Code:
$menu = array();
// default menu options
$menu[0] = '<a href="'.$mybb->settings['bburl'].'/newpoints.php">'.$lang->newpoints_home.'</a>';
if (
$mybb->settings['newpoints_main_statsvisible'] == 1)
    
$menu[1] = '<a href="'.$mybb->settings['bburl'].'/newpoints.php?action=stats">'.$lang->newpoints_statistics.'</a>';
if (
$mybb->settings['newpoints_main_donationsenabled'] == 1)
    
$menu[2] = '<a href="'.$mybb->settings['bburl'].'/newpoints.php?action=donate">'.$lang->newpoints_donate.'</a>';
    
$menu[3] = '<a href="'.$mybb->settings['bburl'].'/buy.php">Buy Diamonds</a>'
    
if ($mybb->input['action'] == '')
{
    
$menu[0] = "&raquo; ".$menu[0];
}
elseif (
$mybb->input['action'] == 'stats')
{
    
$menu[1] = "&raquo; ".$menu[1];
}
elseif (
$mybb->input['action'] == 'donate')
{
    
$menu[2] = "&raquo; ".$menu[2];

#6

You forgot the last ;
To download our paid plugins and receive support you must be a paid subscriber. Click here for more information.




Users browsing this thread: 1 Guest(s)