search for: libdoc

Displaying 20 results from an estimated 66 matches for "libdoc".

Did you mean: libdo
2006 Jul 06
3
URI.escape() broken or misdocumented in Ruby 1.8.4
...) is supposed to be able to take a second parameter listing unsafe characters in the URI. This may be a regexp or string. If a string, it''s supposed to represent a character set listing all unsafe characters. An example given in the core documentation at: http://www.ruby-doc.org/stdlib/libdoc/uri/rdoc/classes/URI/Escape.html#M008992 ...is: p URI.escape("@?@!", "!?") # => "@%3F@%21" Unfortunately this doesn''t work. It seems that the string does not represent a character set to match any more, but a literal string to find - thus the follo...
2013 May 07
2
Net::HTTP
I''m looking at the documentation: http://ruby-doc.org/stdlib-2.0/libdoc/net/http/rdoc/Net/HTTP.html And I notice two uses of Net::HTTP. Both are using GET requests. But what''s the difference? When to use which? Net::HTTP.start(uri.host, uri.port) do |http| request = Net::HTTP::Get.new uri response = http.request request # Net::HTTPResponse object end...
2009 Jan 28
6
Creating an object from a pp string?
When I use pp on an object in rails, it prints out a nice string representation of the object. I am trying to pass objects from one server to another and I am wondering if I can just pass this string and create an object on the other server. Any libraries/functions out there that can do this? Or any other way to do this (not necessarily using pp). Thanks! -- Posted via
2010 Mar 18
3
Sending mail using action mailer
Hi everyone, I am new to ruby and i just wanna send an email using ruby action mailer. i have been trying it for about a day. Not achieved. so many replies came in from google but many were beating the bushes .. can any one send me a correct procedure.. regards ds -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups
2012 Oct 20
5
Is it possible to store the log file by day?
I hope to store the log file by day , because the log file will be so large with the time goes by.Is it possible to do this ? -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to
2011 Jun 17
7
Encoding
What''s a good solution for fixing character encoding problems for compatibility between ascii and utf-8? The database is postgres and is encoded in utf-8. Once in awhile there will be a compatibility error from strings from a webform. Is there a command to fix this besides using a_string.force_encoding(''utf-8'')? Even this doesn''t seem to always work either.
2006 Jun 07
2
Making an HTTP request to an external machine
During one of my controller actions I want to call an external machine before I do anything. It''s not a real web service, more like a REST-style thing where I''ll just be tweaking a servlet running on another machine and sending it some data. Does Rails give me anything to work with for doing that? I read the web service stuff but it''s overkill for what I need. I
2006 May 18
2
Utility to translate HTML character entities into text?
Anyone know of a Ruby utility that will translate HTML character entities into text? Thanks, Wes -- Posted via http://www.ruby-forum.com/.
2006 Mar 05
2
Sending http post requests
I''m trying to send http post request in the controller to a web address. In my application I''m using ajax to communicate with the controller, and then use the controller to pass the message on to a remote server, something you can''t do using ajax because of browser security problems. Just wondering what the syntax for a http post is in rails. Thanks Alex -- Posted
2006 Mar 07
2
grep page source
hi all, any one know how to grep page source by rails? i.e. i wanna grep html source from http://www.ruby-forum.com/ by ruby code. regards -- Posted via http://www.ruby-forum.com/.
2005 Dec 15
2
.rhtml in the model rather than the controller
Hi, I''m developing a mini-programming language for research surveys. [code] question S1 { label: The first few questions are just to help us categorize you. label: Do you or does any member in your household work for... (MARK ONE ONLY FOR EACH.) grid { col { 1 Yes 2 No } row { 1 An advertising agency 2 A public relations company 3 A marketing research firm or
2005 Dec 29
3
What does ''h'' do?
I''m sure a real newbie question, but try searching for ''h'' in any search engine and you don''t get far. I am wondering what the h does in Ruby as in the code below: <%= h(truncate(product.description, 80)) %> -- Posted via http://www.ruby-forum.com/.
2008 May 05
2
Geocoding and XMLRPC
Hello people, I''m implementing a geocoding feature in my web app, a classic feature, for showing registered user by location. For this purpose, I''ve inspired myself from the following tutorial : http://earthcode.com/blog/2006/04/rails_geocoding_and_google_map.html However, I''m getting this error from Rails : uninitialized constant SandboxController::XMLRPC Being a
2006 Sep 13
1
Net::HTTPResponse
...ss.new success.expects(:body).returns("this is the body") .... Which is a little bit frustrating - it''s to avoid having to do this type of code I''m using Mocha in the first place ! Any ideas ? Thanks for this great library btw!, Anselm [1] http://ruby-doc.org/stdlib/libdoc/net/http/rdoc/classes/Net/HTTP.html -- ------------------------------ Netuxo Ltd a workers'' co-operative providing low-cost IT solutions for peace, environmental and social justice groups and the radical NGO sector Registered as a company in England and Wales. No 4798478 Registered offi...
2006 Sep 20
2
Defining function in template files?
...the line in apt.pp holding: content => template("$conffile.erb") I can run this code as a stand-alone ruby program and it works. Am I doing something wrong or is this not supported? Also, is there any good documentation on ERB beyond what is here: http://www.ruby-doc.org/stdlib/libdoc/erb/rdoc/ ? Thanks, -Brett.
2006 Jun 06
4
PHP FTP functions equivalents?
Two questions from a PHP guy thinking of moving to Rails: 1. Does Rails have equivalents for PHP''s FTP functions (www.php.net/ftp)? 2. What about image editing functions similar to PHP''s GD2 functions? (I would basically want to be able to crop, rotate, draw lines, add text...) I searched online for the above but I got somewhat conflicting info about image editing and
2006 Aug 08
3
How can i read a properties file in RoR
Hi, Iam a nubie, i wanna know how can i load/read a .properties file in to my rails application. For example i have a property file where i have defined the spanish equivalants of some english words as follows user Name:nombre del usuario user Code :c?digo del usuario likewise. now , where should i store this properties file in the directory structure and how can i read these in to my
2006 Sep 08
1
A quick guide to Mocha
Hello :) Having just gone through the (admittedly simple) API of Mocha to learn how it works, I wrote a quick guide (190 lines) to help others get up to speed. I''ve attached it as RDOC and as HTML. It is a first draft - please help me improve by giving feedback ! Contents : Overview - Quick overview of Mocha Unit testing, mock object and stubs - Very quick introduction to mock
2006 Mar 26
3
Charts and Java servers
Hi, As a long time Java/J2EE exponent I wanted to give Rails a fair crack of the whip and after we evaluated it for several weeks I have to say I like it. The installation process for the base system/framework is straightforward on the two platforms we''ve tried (Windows and Mac OS X). However, the charting components available, relying on ImageMagick or GraphicsMagick seem less clear
2006 Jun 30
6
RSS::Parser Documentation
...sses I am getting back. For example, the class has a "channel" which I can tell has a "title" attribute (because it works when I query it :) but I would really like a list of every attribute that is supported! I found documentation for it here: http://www.ruby-doc.org/stdlib/libdoc/rss/rdoc/ But unless I am missing it, taking the example I used before and looking at the doc for RSS::Rss::Channel: http://www.ruby-doc.org/stdlib/libdoc/rss/rdoc/classes/RSS/Rss/Channel.html It doesnt tell me the basics like what attributes and methods it has. Am I missing something? What is...