I want to have a feature which causes the following to happen everytime any page in a site loads.
I need to have a web part or user control which adds information about the current user to the page. This information doesn't need to be displayed to the user, it just needs to be available for javascript to read it. It can be either in meta tags or as a script block.
The feature uses a custom action to reference a javascript file which uses the information set above.
The issues I'm running into are:
How can I ensure this user control is on every page? I can manually add the web part to the master page but what about pages using other master pages? It also seems that it is best practice to avoid modifying master pages if possible.
Timing issues - I'll need to make sure that the information is available on the page before the javascript is added.
I'm still new to SharePoint so any suggestions are highly appreciated.