jQuery("#user_email").focusout(function() {
var addressinput = jQuery(this).val();
console.log(addressinput);
var res = addressinput.split("@");
var username = res[0];
console.log(username);
jQuery('#user_login').attr('value', username);
});
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter