What nikon lens to buy?

I have a d3100 at the moment and i'm using the 18-55 lens that came with it.
I'm looking for a prime lens as I want higher quality images
I won't be upgrading my camera body for a while yet so I want to get a good lens as when I do upgrade my body next year or the year after, i will stay with nikon.
I had my mind set on getting the 50mm 1.4 af-s but now i'm looking at the 35mm ones?
I'm don't really take many portraits or close ups and I read that the 50mm 1.4 was best for portraits and shooting in low light?
I take photos similar to this rather than ones like this

Even though your camera is a cropped camera, I still like the 50mm prime over the 35mm. True, you will have to backup a bit when using the 50mm, but it will have less perspective distortion than the 35mm lens.
Another option is the Sigma 17-50mm f/2.8 zoom. While I normally like to stay with Nikon or Tokina, this lens is a great lens, and may be best lens Sigma has ever made. DxOMark testing and other reviews has shown that this lens is better than the Nikon 17-55mm f/2.8 at half the price. And interestingly enough, the Canon version of the Sigma 17-55mm f/2.8 is also better than the Canon 17-55mm f/2.8.
So don't discount the Sigma 17-50 f/2.8, just because it is not a Nikon brand lens.
The only issue I know of is that Sigma may have some QC issues from lens to lens. For this reason, it might be wise to buy such a lens from a local camera shop so that you know you are getting a good copy.

Truth of the matter is, if you can't get high quality images with the 18-55mm lens, you won't either even with a more expensive prime lens. For both links you supplied, the 18-55mm lens can be used to get those just the way they are.
Getting a new lens means extending your versatility. The new lens does not replace the old one. It adds to the functionality of the whole set of cameras (yes, with an "s") and lenses (again, plural). If you really insist on shooting prime right now to learn more about photography, the 35mm f/1.8 would be better than the 50mm f/1.4. 35mm would be normal/standard to your camera meaning it will have the same angle of view as your eyes. This makes composition easier. This also means you will have to move around a lot to get the right frame the way real photographers do it.

The 50mm 1.4 will be better for shooting in low light and is a better length for portraits, but is pretty much useless for anything else.
The 35mm is a much better 'normal' length, but even it is a tad on the narrow side (52mm full frame equivalent).No, it doesn't look any different than a 50mm does on a full frame camera as far as perspective goes.
- I want to buy a Nikon D90. Do I buy from Best Buy or Crutchfield?
- Should I save up to buy the Nikon 50mm f/1.4 or buy 50mm f/1.8 lens?
- When you first buy a new nikon d810 body what are the best absolutely sharpe lens to buy?
- I'm planning to buy 70-300 AF Nikkor lens, is it still a good buy than buying 70-300 AF S?
- I have Nikon D5100. I like to buy lens 18-200mm. Nikon lens is very costly?