Jump to content
MakeWebGames

Recommended Posts

Posted

open up admin_module_manager/content.php

look for

TableHeader("Modules");

and just before it add

 

// START SECTION FOR DE-ACTIVATED MODULES //

TableHeader("Current Locked Modules");
echo "<table class='plainTable'>";
echo "<tr class='titleLine'>";
echo "<td>" . Translate('Name') . "</td>";
echo "<td>" . Translate('Status') . "</td>";
echo "<td>" . Translate('Action') . "</td>";
echo "</tr>";

$row = 0;
foreach ($allModules as $l)
{
   if ($row % 2 == 0)
       echo "<tr class='evenLine' valign='top'>";
   else
       echo "<tr class='oddLine' valign='top'>";
   if (file_exists("$baseDir/modules/$l/module.lock"))
   {
       echo "<td width='50%' style='color: green; font-weight: bold;'>$l</td>";
	echo "<td width='40%' style='color: red; font-weight: bold;'>Locked</td>";
       echo "<td width='40%'><a href='index.php?p=admin_module_manager&unlock=" . urlencode($l) . "' style='color: green; font-weight: bold;'>Un-Lock</a></td>";
   }
   echo "</tr>";
   $row ++;
}
echo "</table>";
TableFooter();
// END SECTION FOR DE-ACTIVATED MODULES //

 

All Locked modules will now be visible as quick find

Posted
// START SECTION FOR DE-ACTIVATED MODULES //

TableHeader('Current Locked Modules');
echo '<table class="plainTable">';
echo '	<tr class="titleLine">';
echo '		<td width="40%">' . Translate('Name') . '</td>';
echo '		<td width="30%">' . Translate('Status') . '</td>';
echo '		<td width="30%">' . Translate('Action') . '</td>';
echo '	</tr>';

$style = 'color: green; font-weight: bold;';
$row = 0;
foreach ($allModules as $module)	{

if(file_exists($baseDir.'/modules/'.$module.'/module.lock'))	{

	echo '	<tr class="'.(($row % 2 == 0) ? 'evenLine' : 'oddLine').'" valign="top">';
	echo '		<td '.$style.'>'.$module.'</td>';
	echo '		<td '.$style.'>Locked</td>';
	echo '		<td><a href="index.php?p=admin_module_manager&unlock='.urlencode($module).'" '.$style.'>Un-Lock</a></td>';
	echo '	</tr>';

	++$row;

}

}
echo '</table>';
TableFooter();

// END SECTION FOR DE-ACTIVATED MODULES //

 

There you go. To fix your row odd/even colors :)

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.

×
×
  • Create New...