1.) Clicking on a email link in a webpage should create a new email with kmail.
Start firefox and type the following in the url bar: about:config
A big table with configuration options will appear in the main browser window.
Look for the item network.protocol-handler.external.mailto and make sure its value is set to true. The value is the right most piece of text in the row for that item. Right-click on that line and select "toggle" in the pop-up menu to toggle if necessary.
Now, do a right-click again and select New -> String. A window will appear, asking you to set the name of the new config item, set it to network.protocol-handler.app.mailto and and click OK to confirm. A second window will appear to ask for the value of the config item. Type kmail into its text field and confirm again.
Now, if you click on an email link on a webpage (in the status bar, that is the bar at the lower end of the firefox window, you will see something like mailto:[email protected]) kmail should fire up with a new email to that address.
2.) Clicking on a weblink in kmail (and other kde apps) should open and load the link into firefox.
This can be configured by changing one kde setting. Depending on the kde version you have there may be different ways to get to that kde settings window we need.
For kde 3.4.2, click on the System button in the control panel, it is the one right next to the blue K button in the control panel.
A pop-up menu appears, select Settings. A new konqueror window will appear showing the contents of the settings:/ directory. Select KDE components -> Component Selection. This will open the kde control center module we need, appearing in a new window.
There is a list at the left site of that window, select Web browser and click on the lower button in the main section of the window, named in following browser. The text input field below the button will become active, type mozilla-firefox and click the OK button to confirm the setting.
From now on, links in emails etc. should be opened in firefox.