similar to: custom js in rails project

Displaying 20 results from an estimated 1000 matches similar to: "custom js in rails project"

2011 Sep 01
7
couldn't find file 'jquery' rails 3.1 stable mountable engine
When I create a new engine in Rails 3.1 stable and then access the dummy app or the engine I get an error say that the app can''t find jquery. I''ve created the engine using rails plugin new coffee --mountable I''ve also created a basic controller in the engine and the dummy app. If I remove the javascript include tag, everything works. But with the tag there it just
2011 Nov 25
4
Sprockets File not Found Exception.
Hi Everyone, I was trying out some sample applications for Rails. I created some controllers and pages. But when i try to access one of them i get an exception on the webpage: --------------------------------------------------------------------- Sprockets::FileNotFound in Pages#home Showing c:/railscode/test_app/app/views/layouts/application.html.erb where line #6 raised: couldn''t
2012 Mar 01
1
help stylesheet_link_tag
I was reading the book "Agile Web Development with Rails 4th Edition". In Chapter 11, Iteration C2: Adding a Page Layout 1 <!DOCTYPE html> - <html> - <head> - <title>Pragprog Books Online Store</title> 5 <%= stylesheet_link_tag "scaffold" %> - <%= stylesheet_link_tag "depot", :media => "all" %> - <%=
2012 Feb 06
3
Can't complete the Getting Started tutorial due to ExecJS::RuntimeError in Home#index
I have just installed Rails 3.2.1 on my Xubuntu using the gem system and I try to make the tutorial http://guides.rubyonrails.org/getting_started.html and on section 4.3 Setting the Application Home Page I get the following error ExecJS::RuntimeError in Home#index Showing /home/xonx/rails/blog/app/views/layouts/application.html.erb where line #6 raised: (in
2014 Apr 26
0
jquery_ujs.js 404
I am getting this annoying error which relates to jquery_ujs.js not being served. Any clues? This is the site link: http://test.kopy.com.br/home/index GET http://test.kopy.com.br/assets/jquery_ujs.js?body=1 404 (Not Found) index:11 GET http://ads.panoramtech.net/loader.js?client=tac net::ERR_BLOCKED_BY_CLIENT rev.js:4 Error in event handler for (unknown): Cannot read property 'state' of
2011 Jul 19
3
What does "require tree" do in Rails 3.1?
In Rails 3.1.... This is my application.css: /* *= require_self *= require_tree . */ This is my application.js: //= require jquery //= require jquery_ujs //= require jquery-ui //= require_tree . What does the "require_tree ." do? -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To view this discussion on the web
2010 Jun 02
1
Ajax with JQuery
I have used Ajax link and live validation in index.rhtml Ajax link requires JavaScript "prototype" and live validation requires "jquery". i got "element.dispatchEvent is not a function" on the firebug console when i used "prototype" and "jquery" in same page index.rhtml after i removed javascript "prototype" library, i got "Ajax is
2011 Jul 07
2
Rails 3.1 + jQuery + jQuery UI = data is null
Trying to get jQuery UI to work with my rails 3.1 setup, but i keep getting errors that i cant see posted anywhere, this is driving my insane so please have a look => [application.js] // This is a manifest file that''ll be compiled into including all the files listed below. // Add new JavaScript/Coffee code in separate files in this directory and they''ll automatically // be
2009 Mar 26
1
Lightbox popup on ajax pages....
Hi, I''m using lightbox.js for displaying chromeless popup windows. I have a main page on which I have javascript_include_tag and stylesheet_link_tag to include lightbox. Calls to the lightbox popups from this main page work perfectly... But....calls to the lightbox popups from pages which are called by ajax(using link_to_remote) from the main page do not work... :( They work like
2011 Dec 05
9
jquery - word is not defined
Just starting out with a beginner book on jquery and the very first thing I am trying fails (has to be me) Rails 3.1 - other jquery things working including a poor example of drag & drop that is my ultimate target here but just simply trying to get every alternating row in a table to have a different css class So I''m using... app/assets/javascripts/people.js.coffee and put in...
2006 Jan 18
4
That ol'' AJAX select box update again : observe_field does nothing
Hi, I know this has been asked a million times before - but I still don''t really get it. CAn someone please tell me what''s up with the following; In a view I have (apologies for the formatting); <td> <select id="job.job_phase_id" name="job[job_phase_id]"><p><label for="job_job_phase_id">Job
2011 Sep 18
12
3.1 asset pipeline + Capistrano troubles
Hello, I''m having a bit of trouble with the asset pipeline and, I think, Capistrano. In my app layout I have: <%= stylesheet_link_tag "application", "bootstrap" %> And the relevant bits of the app dir structure are: app/assets/stylesheets/application.css.scss # Contains ''require_self'' and ''require_tree .'' as usual
2005 Jun 21
3
dynarch calendar problem when used with ajax
I''ve got a partial with a form using the dynarch calendar (calendar_field behavior). Working. Now I render this partial from the action specified in to a link_to_remote. Now when I click the calendar it''s not showed anymore. theese lines: <%= stylesheet_link_tag ''calendar-system.css'' %> <%= javascript_include_tag ''calendar'',
2006 Mar 18
3
Weird stylesheet_link_tag issue after moving servers
Dear experts, I am in the process of switching servers for my application. Before the move everything was working properly. After the move <%= stylesheet_link_tag ''/stylesheets/styles.css'' %> generates <link href="//stylesheets/styles.css" media="screen" rel="Stylesheet" type="text/css" />
2012 Jun 28
2
Best practice on Javascript and rails
Hi, I get constantly nervy whenever trying to implement any javascript / jquery in rails, basically because I''m not sure where to put things in the project! I know the people at rails have thought long and hard about how to best structure an app, so I''d like to learn the correct way. I''m using rails 3.2, ruby 1.9.3 ///////////// 1st situation - using a gem to include
2006 Apr 12
4
CSS and Javascript with partials and layouts
Hi, I''m developing an application that uses a layout called main on every page. Most of the individual pages are represented with a single partial template, but there are several pages that are composed of multiple partials. My main layout looks something like this: Code: <html> <head> <title><%= @title %></title> <%= stylesheet_link_tag
2010 Apr 09
2
dynamically linking to ajax.googleapis jquery
Hi I am using jquery and jqueryui in my application And in layout I use <%= javascript_include_tag "http://ajax.googleapis.com/ajax/libs/jquery/1.4.1/jquery.min.js"%> <%= javascript_include_tag "http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js" %> <%= stylesheet_link_tag
2007 Jan 19
4
Problem with link tags
Hell all, I have a layout were I add my stylesheets and javascript in the following manner: <%= stylesheet_link_tag "/form" %> <%= stylesheet_link_tag "/text" %> <%= javascript_include_tag :defaults %> But what happens is that in the actual web page the source is the following: <link href="/form.css?1168168516" media="screen"
2010 Oct 15
18
Newbie - Rails 3 lightbox?
Hello! I''m trying to create a simple image "popup" effect using Lightbox2, http://www.huddletogether.com/projects/lightbox2/. But I don''t get it to work. My code looks lite this: <span class="ad_image"> <a href="<%= ad.image.url(:thumb) %>" rel="lightbox"><img src="<%= ad.image.url(:thumb) %>"
2012 Nov 21
0
What to use //= require_tree or js,css incude tag in application.erb ?
Hi , We are using reqiure_tree in our application.js and application.css. As per i know require_tree include all js and css in application.js and application.css . We include application file of both .js and .css in our application.erb. Q . We include both .js and .css application file in application.erb . Is including in application.erb, did all .js and .css file are included in