search for: csrf_meta_tag

Displaying 20 results from an estimated 20 matches for "csrf_meta_tag".

Did you mean: csrf_meta_tags
2012 Aug 29
7
custom js in rails project
...ipt_include_tag ''app.js'' %> <%= javascript_include_tag ''jquery.foundation.navigation.js'' %> <%= javascript_include_tag ''modernizr.foundation.js'' %> <%= javascript_include_tag ''mijs.js'' %> <%= csrf_meta_tags %> </head> <body> <%= yield %> </body> </html> My scripts are in assets/javascripts. And the css works fine, but the js not. I google how to add js and css in rails, and I think I am doing it right.. any advice please?? thanks in advance! -- Posted via ht...
2011 Sep 01
7
couldn't find file 'jquery' rails 3.1 stable mountable engine
...ery'' (in /Webapps/coffee/test/dummy/app/assets/javascripts/application.js:7)): 3: <head> 4: <title>Dummy</title> 5: <%= stylesheet_link_tag "application" %> 6: <%= javascript_include_tag "application" %> 7: <%= csrf_meta_tags %> 8: </head> 9: <body> app/views/layouts/application.html.erb:6:in `_app_views_layouts_application_html_erb___187280571548804820_2155822020'' accessing the engine ---------------------------------------------------------- Sprockets::FileNotFound in Coffee/pages#in...
2011 Aug 10
3
javascript_include_tag error
<!DOCTYPE html> <html> <head> <title><%= @title %></title> <%= csrf_meta_tag %> <%= javascript_include_tag "http://ajax.googleapis.com/ajax/libs/jquery/1.6.2/jquery.min.js", "jquery.rails.js" %> <script type="text/javascript"> ...app/views/layouts/application.html.erb:7: syntax error, unexpected '','', exp...
2014 May 03
0
Putting form_authenticity_token (csrf token) in a cookie instead of in meta tags?
When you generate a default Rails app, it puts this in application.html.erb: <%= csrf_meta_tags %> It does this so the remote forms can be submitted--i.e., so JavaScript can submit a form. When jquery-rails is about to submit a form, it looks for the <meta> tags named "csrf-param" and "csrf-token" and from them it constructs a hidden "authenticity_token...
2012 Feb 06
3
Can't complete the Getting Started tutorial due to ExecJS::RuntimeError in Home#index
...app/assets/javascripts/home.js.coffee) Extracted source (around line #6): 3: <head> 4: <title>Blog</title> 5: <%= stylesheet_link_tag "application", :media => "all" %> 6: <%= javascript_include_tag "application" %> 7: <%= csrf_meta_tags %> 8: </head> 9: <body> Rails.root: /home/xonx/rails/blog I was doing everything exactly as said in the tutorial and don''t understand what the problem might be. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" g...
2013 Jan 09
4
CSRF resets my session in Firefox
Hello all, I''ve been trying to diagnose an issue with CSRF and Firefox specifically. I''ve got an ajax based form, using UJS (yes, I have csrf_meta_tag in my layout and I''ve tried adding the X-CSRF-Token header to the ajax beforeSend events without any luck)... The form just posts some data to an ajax method that creates, saves, and sets the session for a shopper as well as for a hit object, then returns some JSON. This works in Chrome an...
2011 Nov 25
4
Sprockets File not Found Exception.
...in c:/railscode/test_app/app/assets/javascripts/application.js:7) Extracted source (around line #6): 3: <head> 4: <title>TestApp</title> 5: <%= stylesheet_link_tag "application" %> 6: <%= javascript_include_tag "application" %> 7: <%= csrf_meta_tags %> 8: </head> 9: <body> Rails.root: c:/railscode/test_app ------------------------------------------------------------------------ I created some controllers using the command: $ rails generate controller Pages home contact create app/controllers/pages_controller.rb...
2012 Mar 01
1
help stylesheet_link_tag
...html> - <html> - <head> - <title>Pragprog Books Online Store</title> 5 <%= stylesheet_link_tag "scaffold" %> - <%= stylesheet_link_tag "depot", :media => "all" %> - <%= javascript_include_tag :defaults %> - <%= csrf_meta_tag %> - </head> "stylesheet_link_tag" and "javascript_include_tag" dosn''t work. My Rails version is 3.2.1. The book was written using Rails 3.0.5. How to modify stylesheet_link_tag parameters to fit Rails 3.2.1? My files hj@debian:~/depot$ ls app/assets/styles...
2014 Apr 26
0
jquery_ujs.js 404
...old_in_seconds = 0.5 end This is my application.html.erb <!DOCTYPE html> <html> <head> <title>Kopy</title> <%= stylesheet_link_tag "application", :media => "all" %> <%= javascript_include_tag 'application' %> <%= csrf_meta_tags %> </head> <body>sdfsdsds <%= yield %> </body> </html> This is my home.html.erb <!DOCTYPE html> <html> <head> <title>Admin Kopy</title> <%= csrf_meta_tags %> <link href="/assets/home.css?body=1" media="...
2011 Sep 07
4
jquery and ajax query in rails 3
hi people I don''t know much about ajax - jquery. And right now I need to use some functionality with them. In a form (sales model) I have the following code: <div> <%= f.label :product_id, "Product" %> <%= f.collection_select( :product_id, Product.all, :id, :name, options={} ) %> </div> <div> <%= f.label :price,
2010 Sep 04
0
CSRF protection not working with jquery ajax post request
Hallo, I want to test the csrf protection of my application but forgery protection is not working with jquery ajax request. I have used Unobtrusive Javascript with jquery I have removed the <%= csrf_meta_tag %> so that my application do not include authenticity token. In my view I have the following code $(function () { $(''#alert'').click(function () { $.ajax({ type: "POST", data: ({ lo: 67, pi: 22 }), url: ''/test/set'...
2013 Jun 12
0
debug(session) output help
..."description" content="<%= content_for?(:description) ? yield(:description) : "StudyAide" %>"> <%= stylesheet_link_tag "application", :media => "all" %> <%= javascript_include_tag "application" %> <%= csrf_meta_tags %> <%= yield(:head) %> </head> <body class="<%= controller_name %> <%= action_name %> gray"> <header class="navbar navbar-fixed-top"> <nav class="navbar-inner"> <div class="container"...
2014 Feb 23
0
ExecJS::RuntimeError in Say#hello
...head> <title>Blog</title> <%= stylesheet_link_tag "application", media: "all", "data-turbolinks-track" => true %> <%= javascript_include_tag "application", "data-turbolinks-track" => true %> <%= csrf_meta_tags %> </head> <body> Rails.root: D:/RailsInstaller/blog Application Trace <http://localhost:3000/say/hello#> | Framework Trace<http://localhost:3000/say/hello#> | Full Trace <http://localhost:3000/say/hello#> app/views/layouts/application.html.erb:6:in `_app_vi...
2011 May 25
1
trouble using jQuery in Rails 3.0.7
...er, I''m trying to follow the Getting Started tutorial which ahead a "Hello world" alert to all hyperlinks on the page, and nothing happens when I click a link. Here''s what''s in the <head> of my layout: <%= javascript_include_tag :defaults %> <%= csrf_meta_tag %> <script type="text/javascript" charset="utf-8"> $("a").click(function() { alert("Hello world!"); }); </script> Firebug is showing that that function is being called on page load, but when I click this...
2010 Oct 13
2
Routing Error
...ender :text =>"user created!" end end end end my application.html.erb is <!DOCTYPE html> <html> <head> <title>My web Site</title> <%= stylesheet_link_tag "site" %> <%= javascript_include_tag :defaults %> <%= csrf_meta_tag %> </head> <body> <h1>My Website</h1> <p> <%=link_to "Register",:action =>"register", :controller=>"user"%>| <%=link_to "Index",:action=>"index",:controller=>"site"%>| <%...
2012 Mar 29
25
Unable to deploy to Apache
Hi All, Can someone please help? I''ve been banging my head against for wall for 2 months; all of which has been spent trying to set up ROR. So I actually haven''t written 1 line of code :( Any help would be greatly appreciated :) I''m following the 4th edition of "Agile Web Development with Rails". So, I''m able to deploy the site via WEBrick.
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...
2011 Dec 01
7
ExecJS::RuntimeError in Home#index
...h file. (in C:/Sites/blog/app/assets/javascripts/home.js.coffee) Extracted source (around line #6): 3: <head> 4: <title>Blog</title> 5: <%= stylesheet_link_tag "application" %> 6: <%= javascript_include_tag "application" %> 7: <%= csrf_meta_tags %> 8: </head> 9: <body> The files application.js and home.js.coffee have no code, they are just the original templates. The line " ''C:\Program'' is not recognized as an internal or external command, operable program or batch file." suggest that the space...
2012 Jul 17
24
Static Pages from Railcast
Hi everyone, I need several pages to be static but also modify when requested. I try following the railcast from Ryan at http://railscasts.com/episodes/117-semi-static-pages?view=comments Here what I have done!! rails g scaffold Pages name:string permanentlink:string title:string author:string access_level:string is_published:boolean meta_description:string meta_keyword:string
2011 Jul 27
20
Rails, jquery and Ajax
How do I make an ajax call and then update a div with a partial? I''ve tried this but it''s not working. Comment is created but the partial is not loaded. //view <a href="#" id="testlink">Testlink</a> <div id="commentlist"> </div> //controller def new @comment = Comment.new @comment.save