php and html
Posted: Mon Jan 28, 2008 10:23 am
Hello guys! i really don't know if this topic was discussed before but i haven't got any rsult from the search.I'm tring to build a control panel which will be use by differents persons gategorised by thier group id in the database.ok.In the panel i created all the tool links necessary to manage the site.But then i entend t hide some links that some people with low privilige shouldn't see.
here is my codes
i named the div tag by id but nothing is happenning for people of group id 2.If there is a better idea please let me know or help me make this work please. thanks
here is my codes
Code: Select all
<?php
if ($_SESSION['MM_UserGroup']==2) {
echo "<script language='javascript'>";
echo "document.getElementById('createarticle').style.display='none'; ";
echo "document.getElementById('articlesindex').style.visibility='hidden'; ";
echo "document.getElementById('valider').style.visibility='hidden'; ";
echo "document.getElementById('corbeille').style.visibility='hidden'; ";
echo "document.getElementById('configglobale').style.visibility='hidden'; ";
echo "</script>";
}
?>