Http://www.domainname.com vs domainname.com

Greetings all,

my knowledge is too little to use correct words for this but

when i make a website that loads xml it all works well when the user visit it via
http://www.domainname.com

now a lot of users seems to visit the sites through “domainname.com
thus without http://www.

but through this way the xml doesn’t get loaded.

is there anyway to prevent this? I don’t know even how to google this issue.
so any help is much much appreciated.

Thank you