I formatted /sdcard and my phone won't boot I have a Samsung Galaxy Star Duos GT-S5282. I installed ClockworkMod Recovery 5 and I was messing with it. I went to "mounts and storage" then chose format /sdcard and then rebooted the system.

It is stuck on the logo and restarting and isn't loading. How can I fix it?
I'm afraid you delete the whole system on your device, so that there is currently no rom to boot.
What you can do now is to flash a rom. If you have an external SD card slot, then push your rom files and g-apps onto it and insert the card and flash via recovery.
If your device does not have an external SD card slot or you do not have one, you have to flash the rom via adb. Here's a link to that: xda-Wiki
I hope I understood you correctly and that it helps