Jeditable in a Grid - How can it be done?


I have a grid form that displays a html field.

I am trying to implement Jeditable:

If I’m understating it correctly I need to do three things:
#1 - Put this stuff somewhere:
[INDENT]<script src=“” type=“text/javascript” charset=“utf-8”></script>
<script src=“jquery.jeditable.js” type=“text/javascript” charset=“utf-8”></script>
<script type=“text/javascript” charset=“utf-8”>[/INDENT]

#2 - Put this stuff somewhere:
[INDENT]$(function() {
$(".editable_textarea").editable(“”, {
indicator : “<img src=‘img/indicator.gif’>”,
type : ‘textarea’,
submitdata: { _method: “put” },
select : true,
submit : ‘OK’,
cancel : ‘cancel’,
cssclass : “editable”

#3 - Put this in the html filed I want the user to be able to edit:
[INDENT]<p class=“editable_textarea” id=“paragraph_1”>Put the editable content here</p>[/INDENT]

I think I’m doing number 3 right, but I can’t figure out how to get Scriptcase to put #1 and #2 in the <HEAD> </HEAD section.

I’ve tried onApplication, OnScriptinit, onHeader…???

I cant get it to work…

Any help you can provide is greatly appreciated.


You have to echo scripts on onappinit for example, but, what are you trying to do?

I’m trying to use Jeditable to edit on of the fields on the Grid, inline, similar to editing a field in phpMyAdmin.

When I echo the content in #1 and #2 above it seams to go before the HTML tag, not between <HEAD> and </HEAD>?

Got it… I was missing part of it… Thanks for your help…

Could be great if you share the results. Otherwise, Remember grids don’t do any database update. This means, if you use this plugin to do some inline editing, you will have to manage your database updates manually.

Remember too, there are an “editable grid” on SC, but it’s not called grid, it’s a mode of Form application.

I followed the example at:

It works great, but only for the first page. I have the grid form set to display 5 records at a time. The first page works great, but if I use the Scriptcase “GoTo” button, or the page selection arrows to go to a different page, the Jeditable JQuerry stopps working?

Any Idea why JQuerry/Javascript would only work on the first page?

It’s difficult without seeing the code.

Maybe the code is outside onRecord?
Can you share an export of the application ready to test?