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 9102125
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T01:18:13+00:00 2026-06-17T01:18:13+00:00

I have an AngularJS app that I’m trying to get working with a Rails

  • 0

I have an AngularJS app that I’m trying to get working with a Rails rest api. I am to the point where all the javascript seems to be loading without errors, but some templates don’t seem to be included properly when I use ng-include. Here is an example:

<div ng-include="'<%= asset_path('header.tpl.html') %>'"></div>

When this section loads, I never see any attempt to load the specified template in the browser console. Any suggestions as to why the template isn’t getting requested?

  • 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-17T01:18:15+00:00Added an answer on June 17, 2026 at 1:18 am

    You have conflicting single quotes.

    If you need to dynamically change what will be in the ng-include, try setting the value programmatically and then just pass that variable to the ng-include.

    <div ng-include="templatePath"></div>
    
    <script>$scope.templatePath = "header.tpl.html";</script>
    

    Later in the code you can change the value of $scope.templatePath to whatever other file you need.

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

Sidebar

Related Questions

I'm building a HTML-app with the AngularJS framework. I have some legacy JavaScript actions
I have an AngularJS app that returns a list of json objects and I
I have this Rails app that serves an index.html.erb by a UsersController. In the
I am working on single-page AngularJS application that doesn't have any backend but use
I am working on a web app using AngularJS with which I am quite
EDIT: This only happens with IE (tested on IE10) I have a app that
I have the AngularJS seed project and I've added $locationProvider.html5Mode(true).hashPrefix('!'); to the app.js file.
I currently have a dotcloud app that uses django to serve everything. It works
I have an angularjs web app which has a view with the following basic
In angularjs you have the tag ng-src which has the purpose that you won't

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.