Anyone want to tell me why this portion of my code wont work. After it asks for the string, it doenst let you enter it goes straight into "you entered"

Here is all of my code. Ive commented the problem.

Code:
#ifndef GUARD_Character_Info
#define GUARD_Character_Info
#include <iostream>
#include <fstream>

using namespace std;

class Character_Info
{   
    private:
    char player_name[20];  //players name
    
    public:
    void name() //get players name 
    {    
        cout <<"Enter your players name."<<endl; //problem lies in this section
        cin.getline(player_name, 20);
        cout<<"You have entered"<<player_name<<endl;
    }
    void infOut()
    {
        ofstream charout;
            
        charout.open("CHARACFILE.log", ios::app | ios::binary);
        charout.write( (char*)this, sizeof(*this));
    }
};
#endif

or maybe theres a problem here with the function call.
Code:
#ifndef GUARD_Intro
#define GUARD_Intro
#include <iostream>
#include "Character_Info.h"



using namespace std;

class Intro: public Character_Info
{   
    private:
    int ch; //users choice on switch
    public:
    void Display_Intro() // display and get name
    {

        cout <<" You have just entered the world of Lost Dungeons"<<endl;
        cout <<" You will be taken on a long journey of trouble and danger."<<endl;
        cout <<" If you are up to the task then select your choice (1 or 2):"<<endl;
        
        cin >> ch;
        
        switch (ch)
        {
                case 1:
                Character_Info::name(); //this is where i call the function with the problem.
                infOut();
                break;
                case 2:
                cout <<"Quitting program";
                break;
                default:
                cout <<"ERROR";
                
        }
    }
};
#endif
ANY HELP IS APPRECIATED