I was intending to upload video to my site to sell rights managed. I have been told to do that I need to pay royalties to use .264.
Is this correct, how do I go about it and at what cost.
"Selling right managed" might still require H.264 licensing: the linked article H.264 goes royalty-free ... forever
is only about the case where "those videos are free to the end user."
By the way, Flash uses H.264 encoding for video, so there might still be a licensing issue of you go that way. Much as I hope Flash will go away, especially now that it is no longer supported in Android, never has been on iOS, and Firefox has let H.264 back into its HTML5 video support, there _might_ sadly be a case for considering Flash: it might provide tools that help with the sales and access control side of things that HTML5 video does not.
If you enjoy reading legalize, you can go into to lion's den of the licensing authority, MPEGLA, and read the SUMMARY OF AVC/H.264 LICENSE TERMS
You seem to be in case (b)(1), meaning the lesser of 2% or $0.02 per sale.