Hey guys,
I have the following code in an action:
@user = @current_user
@user.votes[1430]='up'
@user.update_attributes(params[:user])
Votes is a string type, there is no default value - I just want to set it for the first time when this action occurs.
Unfortunately I get this error:
NoMethodError
You have a nil object when you didn't expect…
Hey everyone,
I'm trying to style my select box, I assume I need some type of javascript method.
I'm using rails - and sticking with prototype/scriptactulous.
Does anyone know of any solutions?
I have the following relation in my rails app:
genre
- has many - authors
authors - belong to genre and has many books
books - belongs to authors and belongs to users
(users can add books to the db)
in my controller I have:
@books=current_user.books(:include => [:author => :genre], :order => 'books.created_at DESC')---
--
In my…
In this Issue:
Michael Washington,
Manas Patnaik,
Jeff Blankenburg,
Doug Mair,
Jon Galloway,
Richard Bartholomew,
Peter Bromberg,
Joel Reyes,
Zeben Chen,
Navneet Gupta, and
Cathy Sullivan.
…
Google I/O 2012 - Advancing Accessibility for the Web
Rachel Shearer, Dominic Mazzoni, Charles Chen This session will help you learn through code samples and real world examples how to design and test your web apps for complete accessibility coverage. We will review APIs such as the Text-to-speech (TTS) API, tools like ChromeVox and…
As we wrap up this week recapping all the great things that happened at Oracle OpenWorld, we thought we'd share with our community the faces behind this blog and the Oracle WebCenter Product Marketing team! With the majority of the team working remotely, OpenWorld is the one time we are all together for an entire week.
L to R:…
<b>SF Gate:</b> "Police raided Gizmodo editor Jason Chen's home in Fremont, Calif. last week, seizing computers and other gadgets, as detectives probe how the gadget blog obtained an Apple iPhone prototype, which the blog first published photos and videos of last Monday."
<b>MacNewsWorld:</b> "Will Gizmodo's Jason Chen land in the cooler for his part in leaking Apple's next-gen iPhone to the world? Or did Silicon Valley's High Tech Task Force violate legal protections established to shield journalists when they raided the editor's home?"
Adding and removing nodes in SQL Server Clusters is not so difficult, and instructions on how to do so abound on the internet. However, mismanagement when adding/removing nodes can quickly become a 'gotcha' that wastes time. Bo Chen offers insight into some of those scenarios that are not normally covered in the standard online…
Adding and removing nodes in SQL Server Clusters is not so difficult, and instructions on how to do so abound on the internet. However, mismanagement when adding/removing nodes can quickly become a 'gotcha' that wastes time. Bo Chen offers insight into some of those scenarios that are not normally covered in the standard online…
I am trying to build a reStructuredText to MS Word document tool-chain, so I will be able to save only the rst sources in version control.
So far I --
Have rst2odt.py to convert reStructuredText to OpenOffice.org Writer format.
Next I want to use the most recent OpenOffice.org (currently 3.1) that do a pretty decent work of…
Can anyone point me to a cognos API document and some example code? The best for me is that the API can be access thru python. But examples in other languages are good also.
Is there any recommended java application profiling tutorial? I am now using jProfiler and eclipse TPTP with my profiling. However, although equipped with wonderful weapons, as a newbie in java profiling, I am still missing the general theory and skill in pinpointing the bottleneck. So would you please provide me with some…
Hi,
I have one swf and a program to load this swf. The swf is put in a server. I encounter a weird problem that if I put this swf in serverA, each time my program will issue a http request to that webserver(with 304 response).
But when I move the swf from serverA to serverB, some weird things happen, the progrom will…
I love reStructuredText, however the tools that support it are scattered all over the Internet. The official tool list is incomplete and/or outdated, and can be updated only via commit privileges. For some time there was a comprehensive list at the Wikipedia reStructuredText page, but this apparently "may not meet the…
What I want to do is passing a map to the method in Controller using @RequestParam, but it seems not working. While this is working in Struts 2.
Below is what I am trying:
In JSP using JQuery:
var order = {};
order['seq'] = "ASC";
var criteria = {};
criteria['label'] = "Directory";
$.post(context +…
I am currently working on a project with both java and C# codes within. Java takes the major role in this project. However, C# still takes a small part in it.
I am using Ant to build the projects, and would very much like to use it to build C# too. I have learned that it's possible to build C# under Ant with the…
Is it possible to Marshal a generic return type as non-generic for COM interop?
Let's say I have the following class:
[ComVisible(true)]
public class Foo
{
public IEnumerable GetStr() // Generic return type
{
yield break;
}
}
I know that IEnumerable implements IEnumerable.
Can I force…
it seems that my code adds 6 bytes to the result file after encrypt decrypt is called..
i tries it on a mkv file..
please help
here is my code
class TripleDESCryptoService : IEncryptor, IDecryptor
{
public void Encrypt(string inputFileName, string outputFileName, string key)
{
…
I have a validator in my page:
<asp:RequiredFieldValidator ID="rfv1" runat="server" ControlToValidate="IdentifySEDSED1TxtDate" ErrorMessage="Significant Event Date 1 is missing" ValidType="SEDate">*</asp:RequiredFieldValidator>
I found that in Page_Load: (below is a screen shot…
Unix configuration files come in all shapes and forms. I know that Webmin has a Perl API that makes it easy to parse and modify most common configuration pro grammatically, while preserving changes that might have been made by hand.
Are there any other libraries that has similar…
I am currently using Eclipse Version: 3.5.1. It works perfectly in normal conditions, even with the SVN plugin, the faulty component that I am about to talk about now.
The thing is that whenever I am conducting a merge, eclipse shuts down. It just crashes without even leaving an…