> -----Original Message-----
> From: Frank W. Zammetti [mailto:[EMAIL PROTECTED]
> Sent: 06 January 2006 18:03
> To: Struts Users Mailing List
> Cc: 'Struts Users Mailing List'
> Subject: RE: [OT] JavaWebParts and Struts / Ajax integration
> 
> 
> On Fri, January 6, 2006 12:41 pm, Pilgrim, Peter said:
> > I am back from vacation, and I solved the issue with 
> taglibs. I had to
> > downgrade the taglib DTD version from 1.2 to 1.1 for some reason,
> > and the application deployed to WebLogic 8.1
> 
> Hmm, weird.  Ok, well, it's a solution :)
> 

Me too. I developing on the old Service Pack 1 of WLS. Production has 
the latest SP4 and SP5 better. May be it was me, Eclipse, My Eclipse,
and combination of all. Either way I rewrite tag library definitions
in web.xml and my JSP by hand, just to make sure I wasn't going crazy!

> > I have a couple of questons. I am getting a 404 because the 
> target URL
> > in the Ajax JavaScript is wrong. How do I set the right 
> target and make
> > it context relative? E.g. the web context is `asds'
> 
> Looking at the access log, I'm not clear as to what's 
> wrong... is it the
> /secured/ portion that you don't expect to see?  If the 
> context is asds,
> then I would expect to see /asds/typeAheadSuggestions, is that your
> expectation as well?  I don't want to put forth any answer 
> until I hear
> your answer to that, just so I know we're trying to get to 
> the same place
> :)

Actually I forgot to saw that the JSP page itself is 
`/asds/secured/showContactDetails.jsp'
where `/asds' is the context root. 

> 
> Actually, I guess I will take a stab at it first... try 
> putting a leading
> slash before the target URL?
> 

I thought of that before heading home, but I wanted to wait for response,
because what I would really need is access the `contextRoot' as
a variable. I could write something like this

<target>%contextPath%/typeAheadSuggestions</target>

But I will give it shot now and see what happens ....

                <requestHandler type="std:QueryString" method="get">
                    <target>/typeAheadSuggestions</target>
                    
<parameter>enteredText=search.contact.contactName</parameter>
                </requestHandler>

... ( No it does not work) Sorry 

127.0.0.1 - auth1 [06/Jan/2006:18:21:41 +0000] "GET 
/typeAheadSuggestions?enteredText=x&assureUnique=1 HTTP/1.1" 404 1214 
127.0.0.1 - auth1 [06/Jan/2006:18:21:44 +0000] "GET 
/typeAheadSuggestions?enteredText=xa&assureUnique=2 HTTP/1.1" 404 1214 

The ajax submission is now missing the context path completely.
Can you cut a release of the javawebparts to fix the bug or tell me where
I can patch it please.

> > Assuming I get this working for one control. How do expand 
> this example so
> > that
> > it support multiple fields submit to the same suggestion servlet?
> 
> You should just need to create an entry for the other fields 
> in the config
> file and throw an <ajax:event> tag after them... just point 
> them all at
> the same target URL, it should work fine.  Should be as easy 
> as copying
> the config that is there now and changing the element's ajaxRef.
> 

How do you discern in the Servlet what field is being query?

I had a look at the source of the page, there is a JavaScript
variable called `debugAjax'. Is there anywhere to switch on or off
via the javawebparts custom tags? I looked at <ajax:enable/>, but
the tag description says it an empty tag. You might want to allow
this feature.

> > Thanks in advance
> 

This is where I pause for the weekend in London.  *PAUSE*


--
Peter Pilgrim :: J2EE Software Development
Operations/IT - Credit Suisse First Boston, 
Floor 15, 5 Canada Square, London E14 4QJ, United Kingdom
Tel: +44-(0)207-883-4497

==============================================================================
Please access the attached hyperlink for an important electronic communications 
disclaimer: 

http://www.csfb.com/legal_terms/disclaimer_external_email.shtml

==============================================================================


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to