Menu

Warning: shell_exec() has been disabled...

Help
2008-08-16
2013-04-24
  • Frederic Muller

    Frederic Muller - 2008-08-16

    Hi!

    I'm on a shared hosting with shell_exec disabled, what are the way to remove the error message from the page header or to eventually modify the code to have the missing (?) functionality?

    Everything else seems to be working just fine.

    Thanks a lot.

    Fred

     
    • Frederic Muller

      Frederic Muller - 2008-08-18

      I replaced the code in navbar.fil with the one below (plain HTML links):
      <?php

      # Navigation bar interface.
      # To add a new page to the navbar, add the following bit to the page:
      # <!-- <!NAVTITLE [navbar link text]> -->

      print "<table><tr class=navbar>\n";
      print "<table><tr class=navbar>\n";
      print "<td><a href=index.php>Project List</td>\n";
      print "<td><a href=helpfwd.php>Documentation</td>\n";
      print "<td><a href=about.php>About</td>\n";
      print "<td><a href=admin.php>Administration</td>\n";
      print "<td><a href=chpw.php>Change Password</td>\n";
      print "<td><a href=login.php>Logout</td>\n";
      print "</tr></table>";

      and it works very well. Non-admin see the admin menu link but clicking on it send them back to the index.php page automatically.

      Hope that can help someone.

      Thanks

      fred

       
      • Keith Tyler

        Keith Tyler - 2008-08-18

        Hmm. It's rather annoying that your provider turns off shell exec, because I specifically wrote that bit to make it so adding navbar elements could be done simply by adding files to the directory that have a "NAVTITLE" meta element at the top (as you can see in the code).

        I wonder if there is another way to read the files in the directory without using the shell escape method? But then you'd have to look for the NAVTITLE marker by scanning every file through a PHP function instead of just using good old fgrep! As I said, that's a rather annoying restriction. Sorry they do that. I don't really support hardcoding the navbar in the distribution. Glad you worked around it.

         

Log in to post a comment.