Execute php after post save/update

I have created a php script (generate.php) which is querying posts on set criteria and then writing result in custom xml file. I would like to execute the generate.php everytime the post Save/Update button is pressed. Do you have any clue on how to do this? May be with cron jobs every X minutes would be better?

Saving multiple fields (dropdown and text) in custom metabox

I have seen this question asked a bunch but nothing seems to work. I have a simple metabox within a CPT that needs to save two values. It needs to save a dropdown of pages and a url text field. I can get the text field to save and display but not the drop down. My class is being called on initialization. I think it has something to do with the $dropdown_args variable but I’m not too sure. I can see it saving in my database but it just doesn’t display the selection after saving. The description metabox saves and displays fine, it’s the landing page one that needs help. I have posted all my code and any help will be greatly appreciated.