Calling a fragment with this method
public void showFragment(Fragment fragment){ getSupportFragmentManager() .beginTransaction() .addToBackStack(null) .replace(R.id.layout1, fragment) .commit(); } As a result, I get the imposition of a fragment on a fragment, but not a replacement

