Action

Gender Change - Male to Female

Posted by slyfox, Last update over 4 years ago

Change gender from Male to Female. Mr. to Ms. etc..

Steps

  • script

    // Gender Change using word boundary tokens
    draft.content = draft.content.replace(/Mr.\s/g, 'Ms. ');
    draft.content = draft.content.replace(/\bHe\b/g, 'She');
    draft.content = draft.content.replace(/\bhe\b/g, 'she');
    draft.content = draft.content.replace(/\bHis\b/g, 'Her');
    draft.content = draft.content.replace(/\bhis\b/g, 'her');
    draft.content = draft.content.replace(/\bhim\b/g, 'her');
    draft.content = draft.content.replace(/himself/g, 'herself');
    
    // Update content
    draft.update();

Options

  • After Success Default
    Notification Info
    Log Level Info
Items available in the Drafts Directory are uploaded by community members. Use appropriate caution reviewing downloaded items before use.