I have ArcGIS server and ArcGIS Viewer for Flex installed up and running. I use ArcMap 10.2 to publish my shapefiles. There is a lot of users who is using my maps. How can I provide login for them in the web page for map? Should I use it as a widget or there is another way?
Are you saying you want to password-protect the map so that only people who have a login can access it? If so, you will need to turn on map service security on ArcGIS Server, create users in ArcGIS Server's user store, and then use the ArcGIS token capability in your viewer to provide access to the map. It's not trivial, but not brain surgery, somewhere in between.