hey – just upgraded to the new version of php-exec plugin and put some php code into a text widget for my blog. I have a loop that seems to be causing some problems that I didn’t have in the older version of the plugin. Here is the code:
<?php
while ($i < 10) {
$randnum = rand(1, $x) -1;
if (!in_array($randnum, $numarray)) {
$numarray[$i] = $randnum;
$i++;
}
}
?>
The code works fine when you look at the website, but now when i click on the widgets option in the admin panel it freezes up.
The only way I can view my widgets again is to disable the php-exec plugin, go back to widgets and remove the loop.
Any ideas as to what is causing the widget panel to freeze with loops?