How to change alfresco landing page

Do you wanna change the landing page for your alfresco i tested this on 4.0 and 5.0 and this work in this way, you have just to modify the file in this directory

/opt/alfresco-5.0.b/tomcat/webapps/share/site-index.jsp

and modify the row where you read

// redirect to site or user dashboard as appropriate

below an example of site-index.jsp to use as landing page the repository page


<%@ page import="org.alfresco.web.site.*" %>
<%@ page import="org.springframework.extensions.surf.*" %>
<%@ page import="org.springframework.extensions.surf.site.*" %>
<%@ page import="org.springframework.extensions.surf.util.*" %>
<%@ page import="java.util.*" %>
<% // retrieve user name from the session String userid = (String)session.getAttribute(SlingshotUserFactory.SESSION_ATTRIBUTE_KEY_USER_ID); // test user dashboard page exists? RequestContext context = (RequestContext)request.getAttribute(RequestContext.ATTR_REQUEST_CONTEXT); if (!context.getObjectService().hasPage("user/" + userid + "/dashboard")) { // no user dashboard page found! create initial dashboard for this user... Map tokens = new HashMap();
tokens.put("userid", userid);
FrameworkUtil.getServiceRegistry().getPresetsManager().constructPreset("user-dashboard", tokens);
}

// redirect to site or user dashboard as appropriate
String siteName = request.getParameter("site");
if (siteName == null || siteName.length() == 0)
{
// forward to user specific dashboard page
// response.sendRedirect(request.getContextPath() + "/page/user/" + URLEncoder.encode(userid) + "/dashboard");
response.sendRedirect(request.getContextPath() + "/page/repository");
}
else
{
// forward to site specific dashboard page
//response.sendRedirect(request.getContextPath() + "/page/site/" + URLEncoder.encode(siteName) + "/dashboard");
response.sendRedirect(request.getContextPath() + "/page/repository");
}
%>