The SP2504C exists both in Pata and Sata so you have to check which interface your computer accepts.
Depending on your OS and Bios, you may have some limits at 128GiB (137GB).
A few known incompatibilities exist as well.
But generally speaking, there is strictly no need to replace a Hdd by the same model; this is a good opportunity to look for a faster model than the SP2504C.
Smart is rather reliable (but not completely) so if it tells your disk is dying, do not use the disk, and find quickly a backup method. Borrow a disk, backup on another computer (from another person if needed).
If this is our OS disk and you don't have an installation CD, it's about time to find one or burn one. Same for the drivers.