Using the theme options to change background

Written by  on November 9, 2016 

how do I add some options to a theme?
I would like to add support, in my thmes, for dinamically changing the page background.
I don’t even know how to start.

I think I can break down this issue in two questions:

  1. how do I add a “theme options page”
  2. how do I create a function that prints the link to an uploaded
    image, so I can hardcode the css in my header.php

thank you!