Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » ServerTools (WTP) » JSP/JSF autocomplete
JSP/JSF autocomplete [message #502675] Wed, 09 December 2009 11:25 Go to next message
MJ is currently offline MJFriend
Messages: 8
Registered: December 2009
Junior Member
Hi All,
I'm just starting out looking at java faces and trying to work through the brief tutorial in the eclipse documentation

("WTP Tutorials - JavaServer Faces Tools Tutorial" in http://help.eclipse.org/galileo/index.jsp)

However when I try to use autocomplete, nothing happens. If I place the cursor between the brackets listed below and hit ctrl-space, there's no autocomplete box coming up, where I would have expected it to show at least the backing bean I created as part of the tutorial.

<?xml version="1.0" encoding="ISO-8859-1" ?>
<jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html" version="2.0">
    <jsp:directive.page language="java"
        contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1" />
    <jsp:text>
        <![CDATA[ <?xml version="1.0" encoding="ISO-8859-1" ?> ]]>
    </jsp:text>
    <jsp:text>
        <![CDATA[ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> ]]>
    </jsp:text>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<title>Insert title here</title>
</head>
<body>
<f:view>

<h:form>
		<h:panelGrid border="1" columns="2">
			<h:outputText value="name"></h:outputText>
			<h:inputText value="#{loginBean.name}"></h:inputText>
			<h:outputText value="password"></h:outputText>
			[B]<h:inputSecret value="#{}"></h:inputSecret>[/B] 
		</h:panelGrid>
		<h:commandButton value="Login" action="login"></h:commandButton>
	</h:form></f:view>
</body>
</html>
</jsp:root>


The faces xml config is

<?xml version="1.0" encoding="UTF-8"?>

<faces-config
    xmlns="http://java.sun.com/xml/ns/javaee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-facesconfig_1_2.xsd"
    version="1.2">
	<application>
		<view-handler>com.sun.facelets.FaceletViewHandler</view-handler>
	</application>
	<managed-bean>
		<managed-bean-name>loginBean</managed-bean-name>
		<managed-bean-class>com.tutorial.LoginBean</managed-bean-class>
		<managed-bean-scope>session</managed-bean-scope>
	</managed-bean>

</faces-config>



Also, for the faces library (project properties->project facets->java server faces), I'm presently using the weblogic shared library. I also tried downloading "JSF 1.2 (sun RI)", but that doesn't seem to make much difference and I don't know how to properly add JSTL to match since the tutorial was incomplete.

Lastly, I also have the compilation warning "cannot find fully qualified class: com.sun.facelets.FaceletViewHandler"


Any ideas??
Re: JSP/JSF autocomplete [message #503608 is a reply to message #502675] Mon, 14 December 2009 23:15 Go to previous message
MJ is currently offline MJFriend
Messages: 8
Registered: December 2009
Junior Member
And the answer...

- remove 'facelet' from the project facets
- remove com.sun.facelets.FaceletViewHandler from the faces-config.xml

and autocomplete works just fine.
Previous Topic:Re: Incomplete EAR creation/deloyment
Next Topic:JSP files not syntax highlighting
Goto Forum:
  


Current Time: Tue Mar 19 09:30:36 GMT 2024

Powered by FUDForum. Page generated in 0.02398 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top