Solved

bootstrap-ajax json.html response format

Posted on 2012-12-31
2
786 Views
Last Modified: 2012-12-31
I'm reading eldarion's bootstrap-ajax, and it talks about the json html return to get back that feeds the ajax response:

https://github.com/eldarion/bootstrap-ajax


does anyone have an example of the format for the json.html?  I'm a bit confused on what it's supposed to look like.

Thanks.
0
Comment
Question by:Evan Cutler
2 Comments
 
LVL 82

Accepted Solution

by:
leakim971 earned 500 total points
ID: 38733929
just : { "html":"yourhtml" }
example for adding a new task here : http://uk013.o1.gondor.io/ 
{
    "html": "<tr class=\"\">\n    <td>\n        <div class=\"btn-toolbar\">\n            <div class=\"btn-group\">\n                \n                    <a href=\"/tasks/5699/done/\" class=\"btn ajax\" data-method=\"post\" data-refresh=\"#done-count\" data-replace-closest=\"tr\"><i class=\"icon-ok\"></i></a>\n                \n                <a href=\"/tasks/5699/delete/\" class=\"btn ajax\" data-method=\"post\" data-replace-closest=\"tr\" data-refresh=\"#done-count\"><i class=\"icon-trash\"></i></a>\n            </div>\n        </div>\n    </td>\n    <td>\n        <div class=\"task-label\">\n            test\n        </div>\n    </td>\n</tr>"
}

Open in new window

0
 
LVL 9

Author Closing Comment

by:Evan Cutler
ID: 38733967
Thanks much.
A picture is worth a 1000 words
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

JavaScript can be used in a browser to change parts of a webpage dynamically. It begins with the following pattern: If condition W is true, do thing X to target Y after event Z. Below are some tips and tricks to help you get started with JavaScript …
This article explains how to prepare an HTML email signature template file containing dynamic placeholders for users' Azure AD data. Furthermore, it explains how to use this file to remotely set up a department-wide email signature policy in Office …
In this tutorial viewers will learn how add a full-size background image to a webpage using CSS3. Create a new HTML document with an internal stylesheet.: In CSS, define the html element to have a background image. Use a high resolution image.: In t…
HTML5 has deprecated a few of the older ways of showing media as well as offering up a new way to create games and animations. Audio, video, and canvas are just a few of the adjustments made between XHTML and HTML5. As we learned in our last micr…

943 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

6 Experts available now in Live!

Get 1:1 Help Now