You first go to an FFL dealer, or call one, and found out if they will (and what they charge to) accept delivery of the gun and do the paperwork to transfer it to you.
Then you order the gun online and have it delivered to that FFL dealer, go have your background check done there, pay the handling fee to the FFL, and get the gun.