Icy Phoenix

     
 


Post new topic  Reply to topic 
Page 1 of 1
 
 
Reply with quote Download Post
Post CUSTOMIZATION - Nav-Quick-Links Menu - Modifying - Removing - Adding Links. 
 
Open: /templates/default/nav_quick_links.tpl

To remove the links, use the example below for the Calendar and the ChatBox.

Find and Remove: (This is the Calendar)

Code: [Download] [Hide] [Select]
                <tr>
                    <td align="left" width="8">{IMG_NAV_MENU_SEP}</td>
                    <td class="genmed" align="left"><a href="{U_CALENDAR}">{L_CALENDAR}</a></td>
                </tr>


Find and Remove: (This is the Chat)

Code: [Download] [Hide] [Select]
                <tr>
                    <td align="left" width="8">{IMG_NAV_MENU_SEP}</td>
                    <td class="genmed" align="left"><a href="{U_AJAX_SHOUTBOX}">{L_AJAX_SHOUTBOX}</a></td>
                </tr>


Note: You start removal at the <tr>, and finish removal at the </tr> for each block / link that you want to remove.


To Add Links:

You will need to reverse the above, with the replacement of the appropriate Variables for the URL and language. If Icy Phoenix variables are not available for your application, then Hard-Code them. You may wish to do this anyway using this example and ensuring that the actual href="path" is correct for the location of your application:

Code: [Download] [Hide] [Select]
                <tr>
                    <td align="left" width="8">{IMG_NAV_MENU_SEP}</td>
                    <td class="genmed" align="left"><a href="your-application-path">My Application</a></td>
                </tr>


Permission Strings:

The permission Strings Used in the Menu Links Are:

Code: [Download] [Hide] [Select]

<!-- IF S_ADMIN -->

<!-- ENDIF -->


<!-- IF S_LOGGED_IN -->

<!-- ENDIF -->
 


And while the Menu's and the Links can be grouped for permission, the example is only for one link. Take Careful Note of the placement of the Strings.

ONLY Admin can see this Link:

Code: [Download] [Hide] [Select]
<!-- IF S_ADMIN -->
                <tr>
                    <td align="left" width="8">{IMG_NAV_MENU_SEP}</td>
                    <td class="genmed" align="left"><a href="{U_AJAX_SHOUTBOX}">{L_AJAX_SHOUTBOX}</a></td>
                </tr>
<!-- ENDIF -->


ONLY Those who are logged in can see this Link:

Code: [Download] [Hide] [Select]
<!-- IF S_LOGGED_IN -->
                <tr>
                    <td align="left" width="8">{IMG_NAV_MENU_SEP}</td>
                    <td class="genmed" align="left"><a href="{U_AJAX_SHOUTBOX}">{L_AJAX_SHOUTBOX}</a></td>
                </tr>
<!-- ENDIF -->


 How to Add Permission Strings to a Sub-Menu:

In the example below is a Sub-Menu that is available only to Admin. This Sub-Menu could be any other Sub-Menu with permission for whoever you like. The only purpose of it here is to show where the Permission Strings should be added to hide the whole Sub-Menu and not just a part of it containing the links. Some language VARS are NOT used in this example on purpose, or they don't exist.
Code: [Download] [Hide] [Select]

        <!-- IF S_ADMIN -->
<tr>
    <th style="cursor: pointer;" align="left" onclick="ShowHide('admin_links', 'admin_links2', 'admin_links');">
        <img src="{IMG_NAV_MENU_GROUP}" alt="Admin" title="Admin" />&nbsp;
        <a href="#" onclick="return false;" title="Admin" class="nav-menu-link"><b>Admin</b></a>
    </th>
</tr>
<tr>
    <td class="row5">
        <div id="admin_links2" class="nav-menu">
            <table class="forumline-no2" width="100%" cellspacing="0" cellpadding="2" border="0">
                <tr>
                    <td align="left" width="8">{IMG_NAV_MENU_SEP}</td>
                    <td class="genmed" align="left">{U_ACP}</td>
                </tr>
                <tr>
                    <td align="left" width="8">{IMG_NAV_MENU_SEP}</td>
                    <td class="genmed" align="left"><a href="{U_CMS}">{L_CMS}</a></td>
                </tr>
            </table>
        </div>
        <div id="admin_links" class="js-sh-box">
            <script type="text/javascript">
            <!--
            tmp = 'admin_links';
            if(GetCookie(tmp) == '2')
            {
                ShowHide('admin_links', 'admin_links2', 'admin_links');
            }
            //-->
            </script>
        </div>
    </td>
</tr>
        <!-- ENDIF -->


Note: You should test your changes as Admin - User and Guest - before you commit them to your "Live" forum.
 
 
Edited by Guest, Wed 09 Sep, 2009 01:06: Upgraded to IP v1.3.*
 
Back to topPage bottom
Icy Phoenix is an open source project, you can show your appreciation and support future development by donating to the project.

Support us
 
Post new topic  Reply to topic  Page 1 of 1
 


Display posts from previous:    

HideWas this topic useful?

Link this topic
URL
BBCode
HTML




 
Permissions List
You cannot post new topics
You cannot reply to topics
You cannot edit your posts
You cannot delete your posts
You cannot vote in polls
You cannot attach files
You can download files
You cannot post calendar events