147a148,152 > // Workaround for command paths with spaces > $cwd = getcwd(); > $aspell = pathinfo(substr($aspell_prog, 1, -1)); // Remove quotes and get path info > chdir($aspell['dirname']); // Change to aspell dir > 149,150c154,158 < $cmd = "$aspell_prog $aspell_opts < $tempfile 2>&1"; < if( $aspellret = shell_exec( $cmd )) { --- > $cmd = $aspell['basename'] . " $aspell_opts < \"$tempfile\" 2>&1"; > $aspellret = shell_exec( $cmd ); > chdir($cwd); // Change back to orig dir > > if( $aspellret) {