fix for shell_exec and added pagination