Correction to "link" attribute type - links were not actually created.

Also changed it to proper "cake" way.
pull/61/head
deresz 2012-07-04 15:51:19 +02:00
parent 50e3566f3a
commit dbf7fafea8
2 changed files with 5 additions and 2 deletions

View File

@ -25,8 +25,9 @@
if('attachment' == $attribute['Attribute']['type'] ||
'malware-sample' == $attribute['Attribute']['type']) {
echo $this->Html->link($sig_display, array('controller' => 'attributes', 'action' => 'download', $attribute['Attribute']['id']));
} elseif('link' == $attribute['Attribute']['type']) {
?><A HREF="<?php echo $attribute['Attribute']['value']?>"><?php echo $attribute['Attribute']['value']?></A><?php
} elseif ('link' == $attribute['Attribute']['type']) {
echo $this->Html->link($sig_display, $sig_display);
} else {
echo $sig_display;
}

View File

@ -119,6 +119,8 @@
if (isset($filename_hash[1])) echo ' | '.$filename_hash[1];
} elseif ('vulnerability' == $attribute['type']) {
echo $this->Html->link($sig_display, 'http://www.google.com/search?q='.$sig_display, array('target'=> '_blank'));
} elseif ('link' == $attribute['type']) {
echo $this->Html->link($sig_display, $sig_display);
} else {
echo $sig_display;
}