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

  • SEARCH
  • Home
  • 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 8816691
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T04:40:37+00:00 2026-06-14T04:40:37+00:00

I have a Ruby on Rails 3 news app. It takes a title, some

  • 0

I have a Ruby on Rails 3 news app. It takes a title, some content and an image attachment (using the paperclip gem). I’m using the RABL gem to provided a Sencha Architect project with a JSON feed.

The problem is Sencha Architect can’t read the JSON url. When I try to load the data into the store I get a very unhelpful message saying ‘Unable to load data using the supplied configuration’ and a link to open the url in the browser (which opens just fine). Does Sencha Architect have a log somewhere that provides more information about this error?

Here are the RABL files:

# show.rabl
object @article
attributes :title, :body
node(:mobile_url) { |article| article.image.url(:mobile, false) }
node(:tablet_url) { |article| article.image.url(:tablet, false) }
node(:original_url) { |article| article.image.url(:original, false) }

# index.rabl
collection @articles
extends "articles/show"

RABL does not provide a content type by default so I have this in the articles controller:

before_filter :default_format_json

def default_format_json
  if(request.headers["HTTP_ACCEPT"].nil? && params[:format].nil?)
    request.format = "json"
  end
end

This is the code generated by Architect to show the configuration options I have used:

# Stories store
Ext.define('MyApp.store.Stories', {
    extend: 'Ext.data.Store',

    requires: [
        'MyApp.model.Story'
    ],

    config: {
        autoLoad: true,
        model: 'MyApp.model.Story',
        storeId: 'Stories',
        proxy: {
            type: 'jsonp',
            url: 'https://feedr.org.uk/articles.json',
            reader: {
                type: 'json',
                rootProperty: 'article'
            }
        }
    }
});

# Story model
Ext.define('MyApp.model.Story', {
    extend: 'Ext.data.Model',

    config: {
        fields: [
            {
                name: 'title'
            },
            {
                name: 'body'
            },
            {
                name: 'mobile_url'
            },
            {
                name: 'tablet_url'
            }
        ]
    }
});

How can I get Sencha Architect to read my JSON data? Any help you can provide is much appreciated.

  • 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-14T04:40:38+00:00Added an answer on June 14, 2026 at 4:40 am

    Ok, it turns out there is nothing wrong with the Sencha configuration, the problem was with my rails app. I’m using the RABL gem to generate a Json response. RABL needs to be configured to generate a JsonP response in the form of an initializer like so:

    # config/initializers/rabl_init.rb
    Rabl.configure do |config|
      config.include_json_root = false
      config.include_xml_root  = false
      config.enable_json_callbacks = true
    end
    

    The important option is enable_json_callbacks = true. It causes RABL to serve the response as JsonP which my Sencha app could understand.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a Ruby on Rails 3.2 app using bundler and capistrano for deployment.
I have a ruby on rails web app, and in some views i have
I have a Ruby/Rails app, which is standard Rails CRUD, with some jQuery and
We have a Ruby on Rails application. We're using Ruby's aasm gem to manage
I have a ruby on rails app running a server and sometimes it needs
I have a Ruby on Rails app running on my server, and I can't
I have a Ruby on Rails app that I've recently deployed to a remote
I have a Ruby on Rails page that loads another page using jquery. I
I have ruby on rails website,in which I want to perform some task at
I have a ruby on rails app that has a signup page. Different pages

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.