Displaying 20 results from an estimated 1000 matches similar to: "Single page application authentication and authorization"
2013 Apr 09
3
Real-time events with WebSockets and fallbacks?
Does Rails have anything that supports real-time events and communication
with WebSockets and gracefully fallbacks to other techniques if WebSockets
are not supported?
I would like the possibility to pub/sub events and messages for live chats
and real time notifications.
--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To
2012 May 12
12
before_save messing up
#user.rb ------> Model
class User < ActiveRecord::Base
attr_accessible :email, :name, :password, :password_confirmation
has_secure_password
before_save :create_remember_token
.
.
.
.
.
.
.
private
def create_remember_token
self.remember_token = SecureRandom.urlsafe_base64
end
end
#sessions_controller.rb ------->
2011 Jul 30
22
Question about Helpers
Studying the RoR 3 Tutorial book by Michael Hartl
and on page 345 there''s the code inside the SessionsHelper:
_________________________________________________________
module SessionsHelper
def sign_in(user)
cookies.permanent.signed[:remember_token] = [user.id, user.sault]
self.current_user = user
end
end
__________________________________________________________
What is the purpose
2011 Jun 12
3
Problem with undefined variable current_user
Hi everyone,
I''m working through the tutorial at the following link and attempting to
customise/adapt the lessons for my own slightly different application.
Link:
Ruby on Rails Tutorial: Learn Rails by Example | Ruby on Rails 3
Tutorial book and screencasts | by Michael Hartl
<http://ruby.railstutorial.org/ruby-on-rails-tutorial-book>
I''m currently trying to work
2012 Jul 19
6
Rendering Partial
I am a bit confused when coming from layout and partials.
To start of I have a file called application.html.erb which has my
layout such has follow
<html>
<head>
<body>
<%= render ''layouts/footer'' %>
</body
</html>
This call a new file _footer.html.erb
This file his has follow
<footer class="footer">
<nav>
<%=
2010 Sep 03
1
Action Controller Error: undefined local variable or method `current_user'
Newbie learning Rails. I''m currently on Chp9 here:
http://railstutorial.org/chapters/sign-in-sign-out#top
At the end of the tutorial, rails is erroring (see below). being new
to Rails and after having checked the tutorial... How do you resolve
this kind of error. It''s saying current_user is not defined, and it is
supposed to be defined with/Sites/sample_app/app/helpers/
2005 Nov 10
2
rsync local copy saves ower:group remote copy sets to rsync.conf owner:group
Using sudo and rsync to perform migrations of source from test to prod
When the rsync 'source' 'target' are both on the local server the owner:group
is maintained from the source
When the copy is 'source' local 'target' remote the owner:group changes to
the value specified by uid:gid in the rsyncd.conf
I want the 'target' to always change to uid:gid
2011 Feb 24
1
concurrent users.
If I have:
class ApplicationController < ActionController::Base
protect_from_forgery
before_filter RubyCAS::Filter
before_filter :fetch_operator
include SessionsHelper
private
def fetch_operator
@operator ||= session[:cas_user] && Operator.find_by_uid(session[:cas_user])
log_out if @operator.nil?
end
end
@operator is available for all controllers of my
2008 Dec 11
2
restful_authentication errors
When I run
[code] script/generate authenticated user --include-activation [/
code]
it seems to work at first, but then it reports:
" The name ''SessionsHelper'' is either already used in your application
or reserved by Ruby on Rails. Please choose an alternative and run
this generator again "
I''ve heard that having both acts_as_authenticated and
2011 Feb 05
4
Questions about Chapter 9: Sign in, Sign out of RoR Tutorial | Learn Rails by Example
Hello
Finished reading chapter 9 and im a little bit confused.
1. In the tutorial, Modules are used instead of creating a Model and
working in a class inside a module , like in authenticating passwords.
Wouldn''t that be possible? Or is it unnecessary since we''re not
messing with a database in terms of storing data?
2. what is the difference between session[:remember_token] =
2010 Nov 08
1
dovecot + sieve
Hi,
In ower mail system we use postfix and dovecot v1.2.10 with sieve plugin and
i think is work fine but.....
i need to have access to variables values like in these test script
require ["enotify", "variables", "envelope"];
keep;
notify :importance "1" :message "TEST SIEVE ${from}: ${subject}"
"mailto:i_not_exist at
2012 Dec 05
1
In factor analysis in the psych package, how can I work out which factors the columns in $scores relate to? How do I know what each of the scores is scoring?
Hi
I have used fa() to perform a factor analysis of a psychological battery which is thought to have 11 factors. I can identify which factors the loadings relate to easily enough because I can see which items are loading onto each of the columns in the $loading output. However, how can I identify which items or loadings are being used to create each of the columns in the $scores output? I have
2003 Apr 15
1
dialplan problems cvs 04-15-03
Dialplan stopped working after I did cvs update for
zaptel-zapata-libpri-asterisk and 'make clean', 'make',
'make install' for the above components on 04-15-03.
All the config files are the same as before. Both PRI and SIP calls I am
making forward calls to 's' in the
default context. Fields 'from' and 'to' look normal. My attempts to fix it
by
2010 Sep 28
4
Mailman - searchable archive
Mailman works well for our mailing lists, but the archive is
unacceptable - the worst thing is lack of search function.
I got one tip for this:
1) emails converted to html format with mhonarc
2) search can be done with htdig
Opinions? Maybe there are better software solutions for this - I hope.
- Jussi
--
Jussi Hirvi * Green Spot
Topeliuksenkatu 15 C * 00250 Helsinki * Finland
Tel. +358 9
2008 Aug 21
3
Disk quotas for Sendmail
Hi,
CentOS 5.x, Sendmail 8.13.8.
I would like to start using disk quotas on my Sendmail server, and optimally
they should be configurable by user or group. How can this be done? (I tried
to google, but no success.)
- Jussi
--
Jussi Hirvi * Green Spot
Topeliuksenkatu 15 C * 00250 Helsinki * Finland
Tel. & fax +358 9 493 981 * Mobile +358 40 771 2098 (only sms)
jussi.hirvi at greenspot.fi *
2010 Jan 04
2
Sendmail error: auxpropfunc error invalid parameter supplied
I just noticed this error in my messages log after restarting sendmail.
The only change I have made is
1) manual fix in /usr/share/spamassassin/72_active.conf
2) sa-update (several times)
Now the mail is not running ok, my mail queue keeps growing.
Regards,
Jussi Hirvi
2008 Feb 22
3
Problem with cut
Hi All,
I might misunderstood how cut works. But following behaviour surprises
me.
vv <- seq(150, 346, by= 4)
cc <- cut(vv, 12)
cc[vv == 330]
Results [1] (330,346]
I would have expected 330 to fall into (313,330] category.
Can you please advice what do I do wrong?
Many Thanks,
Jussi Lehto
-------------- next part --------------
Visit our website at http://www.ubs.com
This message
2008 Aug 15
1
Hard disk, format, filesystem
Ok, I give up... I have to ask. This is CentOS 5.
I switched one of my raid1 disks, and I already thought I had succeeded. But
now it seems that something is very wrong with the first partition on the
new disk. Luckily my system is fully bootable with the other disk.
Here's some info. The new disk is sdb.
// I removed all partitions with parted, and created the first one again.
// parted
2005 May 31
2
A suggestion to improve ifelse behaviour with vector yes/no arguments
Dear All,
I luckily found the following feature (or problem) when tried to apply ifelse-function to an ordered data.
> test <- c(TRUE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE)
> ifelse(test, 0, 1:4)
[1] 0 0 0 4 1 2 3
>
It roots into the ifelse-syntax:
ans[!test & !nas] <- rep(no, length.out = length(ans))[!test & !nas]
Would it be possible to disable this feature in the
2007 Jan 19
2
Installing 4.4 - problem on 386
I tried installing with several options (noacpi noapm; noprobe; noprobe
skipddc noacpi noapm nodma). Always I get the same error.
BUT this is not in fac a CentOS problem at all, because I get the same error
always when I boot from hd (Fedora Core), IF there is a CD in the CD-ROM
drive. (I tried with CentOS 1/4, CentOS 2/4 and a HP printer software CD.)
It must be something with the CD drive!