add some code about media request