posted 11 years ago
Delete the onclick from the inputText control and sensitize the ajax sub-element to 'event="click"'. That will allow you to fire an AJAX listener method in your backing bean which should copy the current value of "CustomerComponent.customer.customername" to a display property such as "CustomerComponent.oldCustomername" and set the "visible" property true. As part of the AJAX re-rendering processs, the the outputText component "test" will become visible and render the value of CustomerComponent.oldCustomername.
As a side note, backing beans are instances, not classes, so you really shouldn't start its name with an upper-case letter. A number of mechanisms (including the annotation processors plus many IDEs) make assumptions and take actions based on the assumed proper use of Java upper/lowercase conventions.
Education won't help those who are proudly and willfully ignorant. They'll literally rather die before changing.