Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9087471
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T21:42:11+00:00 2026-06-16T21:42:11+00:00

i’m using parse.com for the first time and searching for the way to get

  • 0

i’m using parse.com for the first time and searching for the way to get json response using javascript api. actually, i’m using handlebars as template engine and trying to get json response form parse.com so i can easily pass it to handlebars template. currently, i’m getting object response which needs to do like result.get(“title”). i searched the parse.com javascript guide and documentation but couldn’t find the way to do this. i’m want to get all the feeds records from parse.com class as json. is there any way to do this any soution??

here’s handlebars template script::

<script id="post-template" type="text/x-handlebars-template">
    {{#each feeds}}
        <div class="post" style="padding-top: 5px; width: 307px; margin: 0 auto;" >
            <div style="background: rgba(255,255,255, 0.5); text-align: left;">
                <img src="{{post-img}}" alt="image"/>
                <p>{{post-mes}}</p>
                <p style="position: relative;">
                    <img src="{{post-by-img}}" alt="image" /><label>  By @{{post-by}}</label>
                    <label class="ago" style="vertical-align: top; position: absolute; right: 10px; top: 18px; height: 20px;">{{post-dt}}</label>
                </p>
            </div>
            <div>
                <a href="javascript: alert('Like')" class="button like" >Like</a>
                <a href="javascript: alert('Comment')" class="button comment" >Comment</a>
                <a href="javascript: alert('Share')" class="button share" >Share</a>
            </div>
        </div>
        {{/each}}
    </script>

sample json i’m using to test template::

feeds:[
    {
    'post-img': 'assets/images/photo1.png',
    'post-mes': 'Before the party, with @Marie',
    'post-by':  'Naza',
    'post-by-img':'assets/images/by.jpg',
    'post-dt':  '5 min'
    },
    {
    'post-img': 'assets/images/photo1.png',
    'post-mes': 'Before the party, with @Marie',
    'post-by':  'Naza',
    'post-by-img':'assets/images/by.jpg',
    'post-dt':  '10 min'
    },
    {
    'post-img': 'assets/images/photo1.png',
    'post-mes': 'Before the party, with @Marie',
    'post-by':  'Naza',
    'post-by-img':'assets/images/by.jpg',
    'post-dt':  '15 min'
    }
]

and parse.com script::

var feedsObject = Parse.Object.extend("feeds");
var query = new Parse.Query(feedsObject);

        query.find({ ... });

i like to get it as following::

query.find({
    success: function(feeds){
        //load home page template
        var source = $('#post-template').html();
        var template = Handlebars.compile(source);
        var html = template(feeds);  // here's example with some details [link](http://screencast.com/t/XvPFuafRuIW)
        $('#home .content').append(html);

    },
    error: function(object, error){
        console.log(error);
    }
});

thanks in advance!!!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T21:42:12+00:00Added an answer on June 16, 2026 at 9:42 pm

    I’ve never used Parse.com (in fact, didnt know it existed). But in the example here, it returns an array of Parse.Object instances.

    Parse.Object has a function toJSON(). This should do it.

    So in your case:

    query.find({
        success: function(feeds){
            var jsonArray = [];
    
            for(var i = 0; i < feeds.length; i++) {
               jsonArray.push(feeds[i].toJSON());
            } 
    
            //load home page template
            var source = $('#post-template').html();
            var template = Handlebars.compile(source);
            var html = template(jsonArray);  // here's example with some details [link](http://screencast.com/t/XvPFuafRuIW)
            $('#home .content').append(html);
    
        },
        error: function(object, error){
            console.log(error);
        }
    });
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am using JSon response to parse title,date content and thumbnail images and place
I am using jsonparser to parse data and images obtained from json response. When
I'm making a simple page using Google Maps API 3. My first. One marker
I am confused How to use looping for Json response Array in another Array.
I am using the SimpleRSS gem to parse a WordPress RSS feed. The only
I am trying to render a haml file in a javascript response like so:
We're building an app, our first using Rails 3, and we're having to build
I'm trying to convert HTML to plain text. I get many &\#8217; &\#8220; etc.
I am reading a book about Javascript and jQuery and using one of the
I'm new to using the Perl treebuilder module for HTML parsing and can't figure

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.