Helpdesk for my helpdesk software
Moderator: mkoch227
jones
Posts: 75 Joined: Sat Jul 20, 2013 6:41 pm
Post
by jones » Thu Oct 30, 2014 8:05 am
Hello
,
How do I change the sizes of the fields in print.php?
When I print a ticket from Hesk, see the not so pretty.
Try and see a photo here:
https://www.dropbox.com/s/9rhj6e3emek9h ... v.jpg?dl=0
I would like that there are only 3 fields on each line, can I change it so "custom" fields do not fill 6 fields on one line
Is it possible that i can insert "custom" fields somewhere else in print.php?
mkoch227
Posts: 666 Joined: Wed Jul 04, 2012 3:37 pm
Post
by mkoch227 » Thu Oct 30, 2014 12:55 pm
The column issue is actually a bug in NuMods, as HESK (I believe) just prints each item on one line. In print.php, find:
On lines 219-221. Change it so it reads
So the row count actually updates. If you want to move where the custom fields appear, move lines 205-221 wherever you want them to appear.
Mike, Lead Developer of
HESK: A surprisingly simple, user-friendly and FREE help desk software with integrated knowledgebase.
jones
Posts: 75 Joined: Sat Jul 20, 2013 6:41 pm
Post
by jones » Thu Oct 30, 2014 1:39 pm
Hi Mike,
Thanks
After and have changed it in print.php, Works also print font size in NuMods.
As you yourself can change in Settings> Help Desk
So that you just have changed. Before version 1.6
Jones
jones
Posts: 75 Joined: Sat Jul 20, 2013 6:41 pm
Post
by jones » Tue Nov 04, 2014 12:52 pm
Hello,
How do I insert custom fields in print.php?
I would like the various "custom" fields set in various locations in print.php
Jones
jones
Posts: 75 Joined: Sat Jul 20, 2013 6:41 pm
Post
by jones » Tue Nov 04, 2014 3:46 pm
Hello,
How do I insert "website title" from Hesk into print.php?
Jones
jones
Posts: 75 Joined: Sat Jul 20, 2013 6:41 pm
Post
by jones » Fri Nov 07, 2014 10:17 am
Hi Klemen,
Can you help me with the above ??
Jones
Klemen
Site Admin
Posts: 10147 Joined: Fri Feb 11, 2005 4:04 pm
Post
by Klemen » Fri Nov 07, 2014 12:41 pm
You can use the $hesk_settings['site_title'] variable, as found in the hesk_settings.inc.php file.
If within PHP:
Code: Select all
echo $hesk_settings['site_title'];
If within pure HTML:
Code: Select all
<?php echo $hesk_settings['site_title']; ?>
But please note, that teaching PHP is not something this forum is for. You should consider searching Google for PHP tutorial and learning a bit there
jones
Posts: 75 Joined: Sat Jul 20, 2013 6:41 pm
Post
by jones » Fri Nov 07, 2014 12:49 pm
Hi Klemen,
Thanks, will not learn anything about php
I just want to know what your code is called for custom fields
So I can modify and insert them elsewhere in print.php
Jones
Klemen
Site Admin
Posts: 10147 Joined: Fri Feb 11, 2005 4:04 pm
Post
by Klemen » Fri Nov 07, 2014 2:40 pm
Hmm, give a man a fish...
I have a better idea
- why don't you see how the settings file is setup, read a bit on Google on PHP arrays and how to print an array element and see if you can get it to work. If not you can still come back, show what you tried and we can guide you to the solution.
jones
Posts: 75 Joined: Sat Jul 20, 2013 6:41 pm
Post
by jones » Fri Nov 07, 2014 4:12 pm
Hi Klemen!
That's not helping anything.
Because I can not see in settings.php what you have called the custom field no. 2
I would like to insert the custom fields differently in print.php
As I can set up under (Settings> Custom Fields).
But I can not find any places what they are called?
Because if I want to insert all the custom fields in the same table, I use this code:
<? php echo $hesk_settings ['custom_fields']; ?>
But if I only want to add the custom fields no. 2 (Custom2) and 4 (Custom4)
I have tried with this code:
<? php echo $hesk_settings ['custom_fields2']; ?>
<? php echo $hesk_settings ['custom_fields4']; ?>
And this code:
<? php echo $hesk_settings ['Custom2']; ?>
<? php echo $hesk_settings ['Custom4']; ?>
But no luck.
Klemen
Site Admin
Posts: 10147 Joined: Fri Feb 11, 2005 4:04 pm
Post
by Klemen » Sat Nov 08, 2014 8:51 am
How is ticket name inserted into the print.php?
jones
Posts: 75 Joined: Sat Jul 20, 2013 6:41 pm
Post
by jones » Sat Nov 08, 2014 12:16 pm
Hi Klemen,
Is it that you mean:
echo '
<td bgcolor="#EEE"><b>' . $hesklang['name'] . ':</b></td>
<td bgcolor="#DDD">' . $ticket['name'] . '</td>
';
echo '</tr>';
Klemen
Site Admin
Posts: 10147 Joined: Fri Feb 11, 2005 4:04 pm
Post
by Klemen » Sat Nov 08, 2014 4:34 pm
Yes.
So, if "name " is printed out with $ticket[' name '] , then "custom1 " will be printed out like...
jones
Posts: 75 Joined: Sat Jul 20, 2013 6:41 pm
Post
by jones » Fri Nov 14, 2014 6:57 pm
Hi
How do I insert sequential number in print.php?
Jones