change $top to $settings