Skip to content

Instantly share code, notes, and snippets.

@spsaucier
Created July 20, 2013 06:25
Show Gist options
  • Select an option

  • Save spsaucier/6044070 to your computer and use it in GitHub Desktop.

Select an option

Save spsaucier/6044070 to your computer and use it in GitHub Desktop.
Wordpress - Import Posts - Assign to Author
$('#authors > li').each(function(){
var textstring = $(this).find('strong').text().split(" (");
console.info(textstring[0]);
$(this).find('select[name^=user_map] option').filter(function() {
return $(this).text() == textstring[0];
}).prop('selected', true);
});
@anil3a
Copy link
Copy Markdown

anil3a commented May 15, 2017

Life Saver, Thousand Thanks...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment