Displaying 18 results from an estimated 18 matches for "alternativefocusmedia".
2006 Sep 06
7
Error on Windows and FreeBSD
First off Windows, because actually what I appear to be getting is a
Rails error which only occurs when I use Mongrel, using Webrick I do not
get this error.
I start Mongrel using:
mongrel_rails start
I have mongrel, win32-services and mongrel-service gems installed even
through Im not using mongrel as a service at the moment.
The whole application works apart from one action. The error I get
2006 May 31
2
Rails AJAX helpers or DIY
I''ve used script.aculo.us before (pre-Rails) to do JS effects like
having a menu link that when clicked shows a sub menu, that kind of
thing.
Now I want to do something very similar but in Rails. Basically I have a
list of summaries displayed in a view. I want to have a link that when
pressed shows the detail.
To do this I would normally have each summary in a DIV, the ID of each
2006 May 16
5
Transactions in RoR
Hi,
Does anyone knows how to manage transactions in RoR.
Thanx
2006 May 16
10
Date verus Time class
I''m using the date_select and datetime_select helpers in my view, and
they return Date classes from the params hash.
But how do I work with Date classes, they don''t print human readable
dates or times, Time classes work well I can use strftime("%H:%M") to
print to the screen.
Is it possible to convert a Date to a Time, Ive been tinkering in irb
but have got
2006 Apr 04
11
Date/Time format and syntax
Hi,
Just wondering how I get both the current date and time to display here
(so far I can only get the date OR the time):
@tblregisteredphone.txtregisterdatetime = Date.today
Also, how can I change the format of the date and time from:
Tue Apr 04 00:00:00 GMT Daylight Time 2006
to
2006-04-04 12:04:00
??
I''m sure it''s very simple, I just don''t know how
2006 Mar 25
1
Re: Rails Digest, Vol 18, Issue 656
...art --------------
> An HTML attachment was scrubbed...
> URL:
> http://wrath.rubyonrails.org/pipermail/rails/attachments/20060325/a8b404d0/attachment-0001.html
>
> ------------------------------
>
> Message: 4
> Date: Sat, 25 Mar 2006 15:11:38 +0100
> From: Kris <kris@alternativefocusmedia.com>
> Subject: [Rails] dynamic set_table_name for achives
> To: rails@lists.rubyonrails.org
> Message-ID: <76accf48af492804dfdd115e8bad7421@ruby-forum.com>
> Content-Type: text/plain; charset=utf-8
>
> How can I pass something to set_table_name so that I can switch table...
2006 Jun 22
1
Can Rails be used without gems?
I have ruby installed on linux, but not gems.
I wish to run a Rails application so I generated a Rails app on another
(win32) machine and placed the Rails framework in ./vendor/rails so that
it used that instead of rails gem.
I then transfered this over to the linux machine. When I run ruby
script/server I get an error:
=> Booting WEBrick...
2006 May 31
3
Should partials have access to the same var''s as the view?
I have a view, part of it I put in to a partial - a copy paste - but now
I get an error saying that there is an "undefined local variable or
method" in the partial code...
Do I need to pass my var to the partial, I would have though not?
Cheers AFM
--
Posted via http://www.ruby-forum.com/.
2006 Apr 18
1
:through example
I''m trying to use :through to ''link'' to models, but the << assignment
does not appear to work as I have it. Any help would be great :)
User model:
has_many :assignments
has_many :jobs, :through => :assignments
Jobs model:
has_many :assignments
has_many :users, :through => :assignments
Assignments:
belongs_to :job
belongs_to :user
This is
2006 Apr 21
1
render_component includes layout
I have dynamically generated list of links that I wish to include in
different views, I''m using render_component to do this but it is also
including the layout.
How do I turn layout off on a per action basis?
Many thanks, K.
--
Posted via http://www.ruby-forum.com/.
2006 Mar 22
0
Time table models and querying approach
I doing an app to allow people to search bus time tables by bus stop and
time.
My models are:
Providers -> Services -> Runs -> Stops <- Stations
Key:
"->" denotes a one to many
Providers = Bus companies
Services = the bus number
Runs = Columns on a bus time table
Stops = Cells on a bus time table, basically a time
Stations = Rows on a bus time table
StationA 10:00
2006 Mar 28
1
Passing the input name to "text_field_with_auto_complete"
I have a view with two auto complete input boxes. How do I give the
input a name like I can for "text_input" helper?
I''ve looked at the docs
(http://api.rubyonrails.com/classes/ActionView/Helpers/JavaScriptMacrosHelper.html#M000462)
but cant make sense of it...
<p><label for="search_start_station">From</label><br/>
<%=
2006 Mar 29
1
Query a timetable (cute solution?)
I am developing app which needs to query a timetable. The user specifies
where they want to go from (start_station) and to (end_station) and the
time (start_time) they wish to leave.
My models are as follows:
Provdier -> Service -> Run -> Stop <- Station
-> = has many
Provider = Bus Company
Service = eg. Number 10 bus
Run = Column on timetable
Stop = Cell on timetable
Station =
2006 Mar 29
2
distance_of_time_in_words and Time classes
There is <%= distance_of_time_in_words(Time.now, @a_time) %> before
xzy.<BR />
<!-- ^ this gives 2279 days -->
This does not work because when @a_time is stored, even though it is a
Time field and the class is Time, it includes a date. The Date isn''t
even that days date its the year 2000, hence the 2279 days ago.
So how do I set the date part of @a_time (a Time
2007 Mar 07
1
Two Mongrel''s Two Rails Applications
Hi, I have Mongrel up and running for one application (port 3000), but
when I start another Mongrel for a second application (port 4000) I can
access both sites locally (using curl) but not remotly via a browser.
If I stop the first applications Mongrel and start the second the second
one works. In other words I can only run one application at once...
I have both on different ports, it makes
2006 Mar 25
4
dynamic set_table_name for achives
How can I pass something to set_table_name so that I can switch tables
on the fly for accessing archive data?
If I could access sessions inside a model I would do something like:
if @session[:current_period]
set_table_name "statistics_" + @session[:archive_year]
else
set_table_name "statistics_" + Date.now.year
end
But since I cannot access the session from within a
2006 Jul 04
2
Display a calendar helper
Before I starting writing a helper to display a calendar I wondered if
anyone was aware of a calendar helper, basically something that is
displayed inline (not a pop-up window) that can replace a date_select.
The way I am thinking of doing it is to have a partial which is passed a
Time class, the month is extracted from the date and a grid displayed
for that month. Which should not be to
2006 Mar 21
5
Getting a time select input
I''m having trouble workign out which ActionView DateHelpers to display a
time input for an ActiveRecord field of type :time.
I just want an hours input and a minuites input. I can get these with
time_select helper using :field_name and :prefix but it gives both hours
and miniutes the same name.
<%= select_time(Time.now, :prefix => "search", :field_name =>