On Sunday, June 12, 2011 9:08:10 AM UTC-4, blackthorne wrote: 
>
> My point remains on that even if that is working correctly you are 
> defining the id for a table so you are not free to replace that 
> component for something else not being a table.

 
Can't you just use the jQuery replaceWith() method: 
http://api.jquery.com/replaceWith/
 
In your code, instead of $(this).html(result), maybe use 
$(this).replaceWith(new_html_element_containing_result).
 
 

> So I added the 
> container for jqgrid and also the load widgets like this: 
>     def load_url(src,_divid=None): 
>         """ 
>         loads the contenct of the url via ajax 
>         and traps forms 
>         """ 
>         if not _divid: 
>             return LOAD(url=src) 
>         else: 
>             return DIV(LOAD(url=src),_id=_divid) 
>
>     @staticmethod 
>     def load_action(action, controller='', ajax=True,_divid=None): 
>         """ 
>         loads the content of URL(request.application, controller, 
> action) via ajax 
>         and traps forms 
>         """ 
>         if not _divid: 
>             return LOAD(controller, action, ajax=ajax) 
>         return DIV(LOAD(controller, action, ajax=ajax),_id=_divid)

 
In the above functions (which you may not need anyway), instead of named 
arguments for controller, action, etc., maybe you can just use *args and 
**kwargs and pass them through to LOAD in order to enable all of the LOAD 
arguments.
 
Anthony
 

Reply via email to