[Kss-devel] Problems changing form fields in Firefox

Rob Campbell kg6hum at gmail.com
Wed Mar 21 21:35:11 CET 2007


On 3/21/07, Balazs Ree <ree at ree.hu> wrote:
>
> It's difficult to tell if we don't know exactly what you are doing. Is it
> possible to see an example?
>
> I'd be further interested in your OS and exact browser version, and if
> the same error can be reproduced in other browsers. (We can help you
> checking that if we can install your example ourselves.)
>
> --
> Balazs Ree

Ok, here is the server side script that I am using.

# import Through-The-Web(TTW) API
from kss.core.ttwapi import startKSSCommands
from kss.core.ttwapi import getKSSCommandSet
from kss.core.ttwapi import renderKSSCommands

# start a view for commands
startKSSCommands(context, context.REQUEST)

# add a command
core = getKSSCommandSet('core')

callsign = form['Callsign']
core.setAttribute('input#fullname', 'value', 'Bob')
core.setAttribute('input#email', 'value', 'bob at example.net')

content = '<h1>%s</h1>' % (callsign,)
core.replaceInnerHTML('#portal-siteactions', content)

# render the commands
return renderKSSCommands()

And in the kss file I have this.

div#archetypes-fieldname-Callsign input:blur {
  action-server: response1;
  response1-form: currentForm();
}

I can tell that it's running response1 since portal-siteactions is
being replaced.  I can also see in Firebug that the HTML for the page
is being changed.  I just don't see the change happening on the page,
most of the time.  It does work from time to time, but the same code
doesn't work again later.

The browser I am using is Firefox 2.0 on both Windows and Linux.  I
don't have access to any other browsers right now, but I can try it in
IE tonight.  I might also download Opera to try it tonight.

-- 
Rob Campbell
KG6HUM


More information about the Kss-devel mailing list