Jump to content

Access to support ticket departments on homepage.tpl


Nullified

Recommended Posts

I have checked in {debug} and it seems no such variables exists within homepage.tpl that would allow me to list the support ticket departments on the homepage. Is it possible to get such data inserted? I am simply trying to add links to my support departments on the homepage.

Link to comment
Share on other sites

You just need to grab the list from the database. You can do that inside the template or by creating a hook. Here is an example of just adding it to the template:

 

{php}

$result = mysql_query("SELECT id, name FROM tblticketdepartments WHERE hidden = "");

$departments = array();

while ($data = mysql_fetch_array($result)) {

array_push($departments, $data);

}

$this->_tpl_vars['departments'] = $departments;

{/php}

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