> The -p option wiped out my history replacing it with links to fb etc,
Are you sure that it didn't simply create a new profile, and what you
now see is this new, fresh, empty, profile? The new profile is supposed
to be empty, this is why you created it.
Most likely the newly created profile became set as the default profile
and therefore now this new profile is what you now see.
The old profile should still be present and untouched. Type into the
address bar the following, but don't mess things up with the functions
there (here you could actually destroy your old profile!), simply read
what will be shown on the screen:
about:profiles
You should find listed there the available profiles, the new one and
also the old one. Now remember the name of the profiles as shown in the
title of the table entries, the name will be given behind the
"Profile:", for instance saying "Profile: PROFILE_NAME".
Close all Firefox instances and only afterwards start it again, but this
time explicitly saying which profile you want to use. Type (of course
replacing PROFILE_NAME with a real name of a profile as you remember it
from the about:profiles page):
firefox -p PROFILE_NAME -no-remote
One of the profiles should be the newly created on (free of any
configuration clutter, therefore it should work for your desired
activity), the other one should contain your old profile as you knew it
by now (containing your personal configurations, incl. bookmarks,
add-ons, etc.).
Recommended reading:
https://developer.mozilla.org/en-US/docs/Mozilla/Firefox/Multiple_profiles
Best wishes, Marco.