It seems you installed your site in the wordpress folder
e.g. instead of straight into the root.
That is why http://mydomain.com will generate a 404-error and http://mydomain.com/wordpress won’t.
If you are just starting out:
- FIRST: In Dashboard > Settings > General Setting > change the ‘wordpress address url’ and ‘Site Address url’to the CORRECT path: http://myExample.com’ and save all changes.
- check out:
http://codex.wordpress.org/Moving_WordPress
go to heading
On Your Existing Server