Quote:
Originally Posted by mtha
Installed and it works for vb4, with minor modification
replace plugin Aktuellste Versionen anzeigen
with
PHP Code:
if ($_REQUEST['do'] == 'product') { $html = @ob_get_contents(); while (@ob_end_clean()); if (!empty($html)) { global $products, $bgcounter, $stylevar;
@ob_start();
$search = array( "<form action=\"plugin.php?do=productexport\" method=\"post\" target=\"download\" name=\"cpform\" id=\"cpform\">", "<td class=\"tcat\" align=\"center\" colspan=\"4\"><b>$vbphrase[installed_products]</b></td>", "<td class=\"thead\">$vbphrase[version]</td>", "<strong>vBulletin</strong></td>\n\t<td class=\"alt1\" align=\"".vB_Template_Runtime::fetchStyleVar('left') ."\">" . $vbulletin->options['templateversion'] );
$replace = array( "<p align=\"center\"><a href=\"plugin.php?do=productadd\">[$vbphrase[add_import_product]]</a> - <a href=\"misc.php?do=updateversions\">[$vbphrase[check_all_products]]</a></p>\n<form action=\"plugin.php?do=productexport\" method=\"post\" target=\"download\" name=\"cpform\" id=\"cpform\">", "<td class=\"tcat\" align=\"center\" colspan=\"5\"><b>$vbphrase[installed_products]</b></td>", "<td class=\"thead\">$vbphrase[version]</td>\n\t<td class=\"thead\">$vbphrase[latest_version]</td>", "<strong>vBulletin</strong></td>\n\t<td class=\"alt1\" align=\"".vB_Template_Runtime::fetchStyleVar('left') ."\">" . $vbulletin->options['templateversion'] . "</td>\n\t<td class=\"alt1\" align=\"".vB_Template_Runtime::fetchStyleVar('left') ."\">$vbphrase[latest_version_available_x]</td>" ); $vbulletin->db->data_seek($products, 0); $bgcounter = 1; while ($product = $vbulletin->db->fetch_array($products)) { $bgclass= fetch_row_bgclass(); $title = htmlspecialchars_uni($product['title']); if (!$product['active']) { $title = "<strike>$title</strike>"; } if ($product['url']) { $title = '<a href="' . htmlspecialchars_uni($product['url']) . "\" target=\"_blank\">$title</a>"; } $product['version'] = htmlspecialchars_uni($product['version']); if (is_newer_version($product['latestversion'], $product['version'])) { $search[] = "$title</td>\n\t<td class=\"$bgclass\" align=\"".vB_Template_Runtime::fetchStyleVar('left') ."\">$product[version]"; $replace[] = "<strong>$title</title></td>\n\t<td class=\"$bgclass\" align=\"".vB_Template_Runtime::fetchStyleVar('left') ."\"><span style=\"color: #AA0000\"><strong>$product[version]</strong></span></td>\n\t<td class=\"$bgclass\" align=\"".vB_Template_Runtime::fetchStyleVar('left') ."\"><span style=\"color: #AA0000\"><strong>$product[latestversion]</strong></span></td>"; } else { $search[] = "$title</td>\n\t<td class=\"$bgclass\" align=\"".vB_Template_Runtime::fetchStyleVar('left') ."\">$product[version]"; $replace[] = "$title</td>\n\t<td class=\"$bgclass\" align=\"".vB_Template_Runtime::fetchStyleVar('left') ."\">$product[version]</td>\n\t<td class=\"$bgclass\" align=\"".vB_Template_Runtime::fetchStyleVar('left') ."\">$product[latestversion]</td>"; } } echo(str_replace($search, $replace, $html)); } }
|
Thanks, however it would be nice to see an official update from the author too. I use this all the time to easily find when there is an updated mod.