Jump to content

Page Icons


N1CK3RS0N

Recommended Posts

Hello,

 

I'm trying to include the $pageicon in my header file, so it can display the icon for the type of page your viewing. If your viewing clientarea, it displays the clientarea icon. If you view Knowledgebase, it displays the icon for the knowledgebase, etc.

 

The problem I'm having is I cannot edit the URLS of those icons, since they are in the php files themselves, and they are ioncube encoded. I saw someone else site that does it and it looked real nice and I wanted to add it to mine.

 

<img src="templates/{$template}/{$pageicon}" alt=""/>

 

Is what I'm currently using for it. The URL to an actual icon should be like this

 

<img border="0" alt="" src="templates/nickerson2.0/images/icons/clientarea.png"/>

 

But the way its coded it goes to this image.

 

<img alt="" src="templates/nickerson2.0/images/clientarea_big.gif"/>

 

How can I change the image locations in those files?

Link to comment
Share on other sites

The pages are encoded with ioncube. :/

 

I don't get why the current page images are coded as that. Those images don't even exist. They must have been from an old version and they forgot to change them when they updated the images to .png's and _big isn't even in the title.

Link to comment
Share on other sites

There's a couple o ways to do it, including (I believe) a regex replace in the header file.

 

However, i just found it easier to rename my icons to match the standard naming convention & overwrite the original files with my own for those cubed pages. Just be aware of overwriting that directory on upgrades.

Link to comment
Share on other sites

I would rename icons but that is a pain, and I'd have to make them .gif which is lower quality.

 

I could manually insert the breadcrumb into each template file then manually insert the icon, but thats a lot of work. Much easier to keep it in the header.

Link to comment
Share on other sites

FOR FUTURE REFERENCES.

 

Support advised me to use the code from the default templates to display the icons on the pages.

 

{if "templates/$template/images/icons/$filename.png"|file_exists}<img src="templates/{$template}/images/icons/{$filename}.png" align="right" alt="" />{/if}

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated