search for: my_th

Displaying 3 results from an estimated 3 matches for "my_th".

Did you mean: my_h
2010 May 19
0
render html partial from atom builder
...o render the atom, called index.atom.builder. Inside this builder template, I''d like to render one of my existing html partials, to put in the atom:content element, perfectly normal atom thing to do. xml.content :type => "text/html" do xml.text! render(:partial => "my_thing") end The problem is that the template for my_thing is my_thing.html.erb. And since we''re somehow in an xml ''context'', the render call doesn''t find it, it complains that no template could be found. If I change it to render(:partial => "my_thing...
2010 Aug 30
9
Validates numericality issue
Hello everyone I have a problem in my app with the validation on numericality. The field should be all numbers, and if an user types for example "12345abc" into the field an error is raised and the data is not saved. But in the field where the error was raised it now says "12345", I want this field to be blank instead. What is the best way to go about doing this? Thanks in
2009 Mar 08
3
Thread creation in Wine
...d actually there's no difference (on my Intel dual core). Anyone does know what is the benefit from switching from one to other option? Attaching some stupid code used by MT testing: Code: #include <iostream> #include <cmath> #include <pthread.h> extern "C" void *my_th(void *param) { const unsigned int CNT=1024; double mysum=0.0; for(unsigned int j = 0; j< CNT; j++) for(unsigned int k=0; k < CNT; k++) for(unsigned int i=0; i<CNT; i++) mysum += i; std::cout << "mysum: " << mysum << std::endl; return 0; } int...