# SuperInPlaceControl

**URL:** <https://www.ruby-forum.com/t/superinplacecontrol/154919>\
**Category:** Rails\
**Created:** [December 5, 2008, 6:51am UTC](https://www.ruby-forum.com/t/superinplacecontrol/154919 "2008-12-05T06:51:01Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Harold](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/h/8491ac/32.png) [@Harold](https://www.ruby-forum.com/u/Harold)\
**Post date:** [December 5, 2008, 6:51am UTC](https://www.ruby-forum.com/t/superinplacecontrol/154919/1 "2008-12-05T06:51:01Z")

</div>

In Rails 2.1, I am using the SuperInPlaceControl plugin to render an  
in\_place\_select on an instance of a model with a has\_many  
relationship. So far so good, except that when I click on OK to save  
the user’s selection, the ajax call is posted, the record is updated,  
but the label on the view never gets updated. In fact, it blanks out.

I am using render :text in the controller method, and Firebug reports  
the text being returned to the client after the ajax call.

Any idea why the label does not update? I would be happy with simply  
looking at some example demo, post, etc.

Thanks,  
-H

---

<div class="post-metadata">

**Author:** ![Harold](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/h/8491ac/32.png) [@Harold](https://www.ruby-forum.com/u/Harold)\
**Post date:** [December 5, 2008, 9:52pm UTC](https://www.ruby-forum.com/t/superinplacecontrol/154919/2 "2008-12-05T21:52:30Z")

</div>

Bump…

The fact that I get no response tells me that nobody is using  
SuperInPlaceControls. What’s out there for in place select editing on  
Rails 2.1? Any pointers or comments welcome.  
Thanks.

---

<div class="post-metadata">

**Author:** ![Harold](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/h/8491ac/32.png) [@Harold](https://www.ruby-forum.com/u/Harold)\
**Post date:** [December 5, 2008, 10:43pm UTC](https://www.ruby-forum.com/t/superinplacecontrol/154919/3 "2008-12-05T22:43:29Z")

</div>

On Fri, Dec 5, 2008 at 12:51 PM, Harold [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
wrote:

> The fact that I get no response tells me that nobody is using  
> SuperInPlaceControls. What’s out there for in place select editing on  
> Rails 2.1? Any pointers or comments welcome.

I think if you had a reproducible test case, it wouldn’t be that hard  
to get some help fixing the problem – it’s just JavaScript 🙂

> > In Rails 2.1, I am using theSuperInPlaceControlplugin to render an  
> > in\_place\_select on an instance of a model with a has\_many  
> > relationship. So far so good, except that when I click on OK to save  
> > the user’s selection, the ajax call is posted, the record is updated,  
> > but the label on the view never gets updated. In fact, it blanks out.

Sounds to me like it might be getting updated with an empty value…

## FWIW,

Hassan S. ------------------------ removed\_email\_address@domain.invalid

---

<div class="post-metadata">

**Author:** ![Harold](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/h/8491ac/32.png) [@Harold](https://www.ruby-forum.com/u/Harold)\
**Post date:** [December 6, 2008, 8:04pm UTC](https://www.ruby-forum.com/t/superinplacecontrol/154919/4 "2008-12-06T20:04:18Z")

</div>

You are absolutely right, it’s just JavaScript, and digging under the  
hood  
uncovered my error. I also modified the plugin slightly to accept a :url  
parameter in order to specify a controller, action, etc. Just more  
flexible.

Thanks,  
-H

On Fri, Dec 5, 2008 at 4:42 PM, Hassan S.  
\<removed\_email\_address@domain.invalid
