There are so many different editors on the market that it is impossible to say exactly what you are doing wrong without knowing what software you are using to build your site.
AS a general rule most editors have two different modes - one to enter text and another to enter code. If you paste code while using the text editing function the editor will put the code in a a quotation rather than as working code.
Many editors will give you an option to insert a code snippet if you put the cursor in the correct place and right click. If not you will need to use the on line help that comes with the editor.
this was posted a while back, but in case you haven't found an answer, this might help. Just judging by what I have seen, most editors are going to allow content to be put on a web page/blog in either of 2 ways. Using the wizard editor available from bravenet, there is the option of a 'Code Editor' view, or 'Visual Editor' view. The former being where you would enter HTML, or scripts for images, such as a banner, java script, and so forth. Linking a text line to a url can be done in most editors from the visual, or also known as What you see/What you get. By highlighting the text you want to be a clickable link, and in the tools at top of editor window, will be a 'Link' option. Clicking it will open a dialogue box for the url to be pasted/typed into. It will usually have the http in the space so make sure your not putting that twice when pasting in a url.