I changed your regex to ("^(?:http://)?([^/]+)(?://?.*/?)/(.*)$");
so it recognizes :// instead of :/ .
How can we add www. to the regex?
I changed your regex to ("^(?:http:// )?([^/]+)(? ://?.*/ ?)/(.*) $");
so it recognizes :// instead of :/ .
How can we add www. to the regex?