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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T04:44:21+00:00 2026-05-20T04:44:21+00:00

My question is about thinking through Rails app. I have a rich ajax-application which

  • 0

My question is about thinking through Rails app.

I have a rich ajax-application which uses google maps api, jquery, jquery ui and a lot of jquery plugins such as history, browser, hotkeys and scrollto.
Now it has a PHP backend, but I want to rewrite it in the Rails on Rails.

Would it be normal to remove all of the Rails javascripts (e.g. javascript_include_tag) from the code and use only my?

  • 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-05-20T04:44:22+00:00Added an answer on May 20, 2026 at 4:44 am

    You could do it if you felt like it. The main (only?) reason to use javascript_include_tag is to make sure that when JS scripts hosted on your server change, your users’ browsers download the new script instead of using their cached copy of the script, which they’ll have if they’ve ever visited your site before.

    Basically, if the file ‘public/javascripts/myscript.js’ exists, then

    <%= javascript_include_tag 'myscript.js' %>
    

    evanluates to

    <script type="text/javascript" src="/javascripts/myscript.js?CHECKSUM"></script>
    

    where CHECKSUM is either the last modification date of the file or a checksum of its contents (I’m not sure which – suffice it to say that the value will change whenever the file changes, tricking browsers into downloading the new script).

    If the javascript file in question isn’t on your server (say you’re pulling jQuery from Google APIs), then Rails won’t know how to generate the checksum, and the result will come out looking like a regular <script> tag (without the ?CHECKSUM bit).

    So there’s no reason to use javascript_include_tag on scripts you’re not hosting yourself. But if you have your own custom script files – and especially if these will be changed with even moderate frequency – then you should probably look into using it; it’s a convenient way to make sure everyone is seeing the true current version of the site.

    Hope this helps!

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

Sidebar

Related Questions

This recent question about sorting randomly using C# got me thinking about the way
While thinking about this question and conversing with the participants, the idea came up
Can I specify interfaces when I declare a member? After thinking about this question
I've been thinking about this object oriented design question for a while now and
So I was thinking about creating a dynamic sql question, meaning that i want
Several questions about functional programming languages have got me thinking about whether XSLT is
I've been thinking about software estimation lately, and I have a bunch of questions
Ok, have a bunch of questions that I have been thinking about the past
I'm thinking about starting a new project using EF 4 and going through some
I am thinking about some issues which may match the term software integration best.

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.