View previous topic :: View next topic |
Author |
Message |
doodleman99
Joined: 02 Sep 2008 Posts: 38
|
Posted: Wed Apr 20, 2016 6:04 am Post subject: So simple, but i can't work it out |
|
|
I have created a view for each folder/server that shows a very simple list of Bad tests and their reply.
If i goto the properties of the view to create reports for this, the report type HTML is great, but i'd like to clean it up a little, so i use the HTML(Custom) and that uses buttons and i lose test names and each test is horizontal.
How can i add/edit my own HTML report types?
thanks,
JV
Last edited by doodleman99 on Wed Apr 20, 2016 6:40 am; edited 2 times in total |
|
Back to top |
|
![](templates/subSilver/images/spacer.gif) |
KS-Soft
Joined: 03 Apr 2002 Posts: 12795 Location: USA
|
|
Back to top |
|
![](templates/subSilver/images/spacer.gif) |
doodleman99
Joined: 02 Sep 2008 Posts: 38
|
Posted: Wed Apr 20, 2016 6:39 am Post subject: |
|
|
It's not the profiles that i need to edit though. because even if i create a new profile, i'm still restricted to use one of the predefined "Report Types".
This is the before and after of what im trying to achieve http://imgur.com/a/1h4bK
the code is editable for the CustomHTML but that has buttons and is a little too complicated for what i need
To clarify, if i generate the HTML report, i am able to edit that to look exactly how i like, where is the template stored with all the variable that the htm report is being generated from? and how can i add to those? |
|
Back to top |
|
![](templates/subSilver/images/spacer.gif) |
KS-Soft
Joined: 03 Apr 2002 Posts: 12795 Location: USA
|
Posted: Wed Apr 20, 2016 8:09 am Post subject: |
|
|
When you are using Custom HTML report, you can modify code as you wish using the same Report Manager - there is big "Setup report template" button, click it and modify template.
Regards
Alex |
|
Back to top |
|
![](templates/subSilver/images/spacer.gif) |
doodleman99
Joined: 02 Sep 2008 Posts: 38
|
Posted: Wed Apr 20, 2016 10:12 am Post subject: |
|
|
KS-Soft wrote: | When you are using Custom HTML report, you can modify code as you wish using the same Report Manager - there is big "Setup report template" button, click it and modify template.
Regards
Alex |
yeah i didn't think that would work but i gave it a go anyway.
i deleted all the code in the header section and replaced it with the following
http://imgur.com/e6nxWGI
Code: | <html><head>
<meta name="GENERATOR" content="Advanced Host Monitor">
<title>%Folder% report</title>
<STYLE TYPE="text/css"><!-- a:hover { color: "#00FFFF"; } --> </STYLE>
</head>
<body bgcolor="#000000" text="#E9E9E9" link="#00FFFF" vlink="#00FFFF" alink="#00FFFF">
<p align="left"><u><strong><big><big>%Folder% Report</big></big></strong></u><br>
<div align="left"><left>
<table border="0" bordercolor="#000000" width="100%">
<tr>
<td bgcolor="#4D4D4D" nowrap align="left"><strong><font color=#C0C0C0>Test name</font></strong></td>
<td bgcolor="#4D4D4D" nowrap align="center"><strong><font color=#C0C0C0>Reply</font></strong></td>
</tr>
<tr>
<td bgcolor="#000000" nowrap valign="top" align="left"> <font color=#FF2B2B>%TestName%</font> </td>
<td bgcolor="#000000" nowrap valign="top" align="center"> <font color=#FF2B2B>%Reply%</font> </td>
</tr>
<tr>
<td bgcolor="#000000" nowrap valign="top" align="left"> <font color=#FF2B2B>%TestName%</font> </td>
<td bgcolor="#000000" nowrap valign="top" align="center"> <font color=#FF2B2B>%Reply%</font> </td>
</tr>
</table>
</center></div>
</body></html>
|
i'm guessing i have the syntax wrong. i cant find the test name variable in http://www.ks-soft.net/hostmon.eng/mframe.htm#profiles.htm#Reports
If there was a big "Setup report template" button for the regular HTML template i'd be dancing.
thanks |
|
Back to top |
|
![](templates/subSilver/images/spacer.gif) |
KS-Soft
Joined: 03 Apr 2002 Posts: 12795 Location: USA
|
Posted: Wed Apr 20, 2016 10:50 am Post subject: |
|
|
You cannot use %TestName% in the header because it does not make any sense. Test related variables should be used in Test items section.
Please check the manual and look at the samples before "deleted all the code"
Quote: |
Header
Specify header of the report, this template will be used once for the report.
Folder title
Provide HTML code that will be used to display Folders. Here you may use Folder Specific macro variables (in addition to regular, user defined and date variables).
If you do not want to display folders in the report, leave "Folder title" field empty.
Test items
Provide HTML code for each test status. Here you may use test related macro variables (in addition to regular, user defined and date variables).
Folder summary
Provide HTML code that will be used to display summary information about each Folder. Here you may use Folder Specific macro variables (in addition to regular, user defined and date variables).
If you do not want to display any summary information, keep "Folder summary" field empty.
Gap between folders
Provide HTML code that will be inserted between last test item (from current folder) and next folder. In other words this code will be used before each folder item except 1st one.
Footer
Specify footer of the report, this template will be used once for the report.
|
|
|
Back to top |
|
![](templates/subSilver/images/spacer.gif) |
KS-Soft Europe
Joined: 16 May 2006 Posts: 2832
|
Posted: Wed Apr 20, 2016 10:51 am Post subject: |
|
|
These variables will be resolved in "Test items" section.
Just remove items-related HTML code from header and paste HTML code for one test items into "Test items section", then right mouse click on test items type (e.g. "with 'Good' status) and select "Use selected template for all statuses" to use same HTML code for all test statuses. |
|
Back to top |
|
![](templates/subSilver/images/spacer.gif) |
doodleman99
Joined: 02 Sep 2008 Posts: 38
|
Posted: Wed Apr 20, 2016 11:18 am Post subject: |
|
|
KS-Soft Europe wrote: | These variables will be resolved in "Test items" section.
Just remove items-related HTML code from header and paste HTML code for one test items into "Test items section", then right mouse click on test items type (e.g. "with 'Good' status) and select "Use selected template for all statuses" to use same HTML code for all test statuses. |
ok so i have messed about for a while now and changed the test items section to
http://imgur.com/y7fWFOe
Code: | <p> <font color=#FF2B2B>%TestName% %Reply%</font></p> |
where/what do i need to do to get my headings back?
if i had the plain html template that the standard HTML is created from i could have done this in 5 mins lol
i tried putting the following into the folder title tab but it doesnt work
Code: |
<tr>
<td bgcolor="#4D4D4D" nowrap align="left"><strong><font color=#C0C0C0>Test name</font></strong></td>
<td bgcolor="#4D4D4D" nowrap align="center"><strong><font color=#C0C0C0>Reply</font></strong></td>
</tr>
|
i know i'm being stupid and i apologize - as i said, with the flat HTML that is created i am able to modify that all day long to do whatever i want. this has thrown me because i have to start from fresh instead of modifying what's there (Because the example in the HTML Custom is nothing like the layout of the HTML normal
#Painful |
|
Back to top |
|
![](templates/subSilver/images/spacer.gif) |
KS-Soft
Joined: 03 Apr 2002 Posts: 12795 Location: USA
|
Posted: Wed Apr 20, 2016 12:57 pm Post subject: |
|
|
Quote: | where/what do i need to do to get my headings back? |
I have no idea what exactly heading do you want but if you are using so simple test items (just %TestName% %Reply%) than I think you don't need any special header.
Probably you want this?
Code: | <html><head><title>HostMonitor report</title></head>
Generated on %Date% at %Time%</font><br> |
Quote: | i tried putting the following into the folder title tab but it doesnt work |
Your "test items" template do not use any table-related tags. Why you are using such tags for "folder title"?
If you want to create table, then use table elements everywhere.
E.g.
- create table using <table> in "Header"
- use <tr><td> and </td></tr> elements for "test items"
- add </table> in "Footer" section
or
- create table using <table> in "Folder title" section
- use <tr><td> elements for "test items"
- add </table> in "Folder summary" section
I just don't know what exactly do you need.
Quote: | if i had the plain html template that the standard HTML is created from i could have done this in 5 mins lol |
Standard HTML is not created from template but there are various examples. You just need to spend some time to read and undersstand how it works...
If you need something close to "standard" HTML report, check this template
http://www.ks-soft.net/cgi-bin/phpBB/viewtopic.php?t=2278
Regards
Alex |
|
Back to top |
|
![](templates/subSilver/images/spacer.gif) |
doodleman99
Joined: 02 Sep 2008 Posts: 38
|
Posted: Thu Apr 21, 2016 2:56 am Post subject: |
|
|
KS-Soft wrote: | Quote: | where/what do i need to do to get my headings back? |
I have no idea what exactly heading do you want but if you are using so simple test items (just %TestName% %Reply%) than I think you don't need any special header.
Probably you want this?
Code: | <html><head><title>HostMonitor report</title></head>
Generated on %Date% at %Time%</font><br> |
Quote: | i tried putting the following into the folder title tab but it doesnt work |
Your "test items" template do not use any table-related tags. Why you are using such tags for "folder title"?
If you want to create table, then use table elements everywhere.
E.g.
- create table using <table> in "Header"
- use <tr><td> and </td></tr> elements for "test items"
- add </table> in "Footer" section
or
- create table using <table> in "Folder title" section
- use <tr><td> elements for "test items"
- add </table> in "Folder summary" section
I just don't know what exactly do you need.
Quote: | if i had the plain html template that the standard HTML is created from i could have done this in 5 mins lol |
Standard HTML is not created from template but there are various examples. You just need to spend some time to read and undersstand how it works...
If you need something close to "standard" HTML report, check this template
http://www.ks-soft.net/cgi-bin/phpBB/viewtopic.php?t=2278
Regards
Alex |
Many thanks Alex,
Thats exactly what i was looking for.
Appreciate your time! |
|
Back to top |
|
![](templates/subSilver/images/spacer.gif) |
KS-Soft
Joined: 03 Apr 2002 Posts: 12795 Location: USA
|
Posted: Thu Apr 21, 2016 7:15 am Post subject: |
|
|
You are welcome
Regards
Alex |
|
Back to top |
|
![](templates/subSilver/images/spacer.gif) |
|