Added link generation method with support for development and production modes.