Phone sometimes can't detect any WIFI networks I have a fully rooted Lenovo A328, and at random times, it would just totally not detect wifi. Even if I place the phone right in front of my wifi router, it still doesn't detect it. In the WLAN settings, it gets stuck at the 'Searching for WLAN networks'.

And I also can't seem to turn the WLAN setting off. Heck, the settings would sometimes suddenly freeze also. The only temporary fix I've found for this is restarting the phone, but then, the problem would usually return after a few minutes or so, prompting me to restart it again and again.

Is there a reason for why this is happening? And is there a permanent fix for this?
This is an issue happening because of problem in the wifi module of the ROM you have flashed. 

Try to get a fresh ROM and also don't forget to read the bug reports of it.

If you see many download links, download the stable instead of nightly / experimental.

Flash it. Or else, go back to stock ROM