sample Rails Application that includes email support page with captcha - ruby-on-rails

What's the quickest / easiest starting point for a simple Rails application that has a main page, and an email "contact us" page, with captcha support? Is there a popular base Rails app that I could download that would already have this functionality as a starting point?
(e.g. for just a basic informational type web site, but with the abily for the user to send support requests back to support, but via a web page with captcha)
thanks

IMHO you shouldn't use Rails, nor any other Framework for a task like that. For a simple contact form you could put a standalone php page plus some static html pages on your server and you're done.
If you doesn't know Rails yet (or any other web framework written in any language) it would be a pain to setup a such structure only to display a contact form. Is like to take a gun to kill a fly.
BTW to come to your question, I don't know any project which do what you're asking for, maybe you want to try to do that by yourself, it's pretty simple, what you need is ActionMailer and a captcha plugin
Just my two cents.

Related

Creating a marketing front for Rails app

I started to get comfortable with Rails and programming in general. I'm working on a Rails app with basic authorization and authentication. I wish to have a CMS for the landing page, while the core functionality of the website would be in Rails. I've seen that it's very useful to separate the marketing assets from the core app for iterating on the messaging and other content.
My plan is for the landing page to have 3 fields for the signup- Username, email and password, for new users to fill in, which should then be stored in the database and used by the Rails app behind the landing page. I'm thinking of using Wordpress to do so, simply because that's the only CMS I'm comfortable with.
I was wondering how I should go about this? Is this recommended, and if so, would the necessary way to go about it be a Wordpress plugin? (I couldn't narrow it down to a good Rails plugin, so any suggestions would be greatly appreciated) . Are there any alternatives to plugins? Thanks in advance!
Why not using devise gem? Everyone uses that. Its well tested and has tons of useful features. And if its a small app, your own created authentication system might be enough.
And for CMS I would like Wordpress for SEO purposes, and Rails Frog for ease of use
You could use Refinery CMS with or without the Rest API:
http://www.refinerycms.com/
http://www.refinerycms.com/guides/with-an-existing-rails-app
https://github.com/refinerycms-contrib/refinerycms-api

Extend Rails app with standard content pages

I developed an App with Rails 3.2
We realized that we may end up having many 'standard' content pages, mainly text documenting the application itself. Nothing the application users will be playing with.
Is there an extension (plugin, gem) I could use to add page to my app like we would normally do on a standard CMS?
I want to be able to delegate the addition/nodfication of content to the admin rather than coding it in HTML.
We had a similar problem with our knowledge base, and chose to use nanoc for it.
This gives us something similar to developer.github.com in term of end-user. And the code is written in markdown (developer.github.com is open source).
This way, all our documentation is written in markdown in static files.
Support people can write them without having to know about programming. With the GitHub Mac App, they can very easily push and pull from a repository.

Ruby on rails making an app for smartphone

I want to build an app that use in the backend Ruby on Rails. However my problem comes in the lack of information i found on it. My goals is not just to create a website but an application that interacts with it, like my android facebook app when pressing menu I get button like logout and so on.
I am wondering if their exists tutorial on how to build an application but using rails or should i scrap my entire website and do it in php. I am looking for guide and tutorial. Thanks in advance
You can build an app on any platform and make it interact with your Rails-based server using HTTP requests (like AJAX).
You can send information back and forth using JSON or XML; you would probably need to make a new set of actions for the app to use.
There is no reason to use PHP. ever.
A little unclear from your original question, but if you are looking to create a mobile app using Ruby (and a structure similar to Ruby on Rails) then you may be interested in Rhomobile. It is a cross-platform mobile application framework that uses Ruby for its backend code, and follows a structure similar to (older) Ruby on Rails versions.
From what I understand of your problem, you want to use the robustness of Ruby to develop a native app (not just another app that mirrors a website).
The best thing I know of for this is RubyMotion. The bummer is the cost ($200). But then you would get to accomplish your task.

Rails form in external site with ajax

Basically I'm wondering if it's possible to have a form on a site outside of mail Rails app to POST to a form in my Rails app. For example (not what I'm going to be doing) a contact form on a Wordpress site, when submitted would POST the values to my Rails app. What would my steps be to make that possible? Or any references that are already out there?
OR if it's possible to load a form from my Rails to an outside site using Ajax or something. Eh that's probably a long shot but don't know what would be more secure and slim on code.
Thanks so much!
If you do it with AJAX you may have to handle XSS issues. Maybe you need to write an easy API for your application that could be consumed from that other application. That's not difficult from Rails and you can get help from some good controller abstractions like inherited_resources.
At some point that external application will send a form to itself using AJAX and will handle it and send it to your rails application using JSON or XML... or whatever format you want.
Yes, you can do it. Be aware that you'll have issues with the form authenticity token, so it might be easier to turn the token off.

CMS type app for creating HTML emails?

For a new SaaS app that I'm working on, I want the end user to be able to create "promotions" which they can send to their customers; they will be able to do this via direct (snail) mail, e-mail, or SMS text message.
Typically these promotions will be HTML email messages with lots of pretty graphics and whatnot. I don't expect my users to know much, if any, HTML at all (ideally they would have someone to create these promos, but I can't guarantee it as I'm targeting small businesses and organizations who might not have on-site IT staff). My application would save these promotions and allow them to be modified. To make it easier on the end user I am debating using a templating system of some kind, for example Textile, so they don't need to know HTML but can create nice looking promotions.
Now, this is basically what amounts to a CMS but not as encompassing or feature-rich. Would I be better off to use a CMS of some sort and tweak it to suit my needs, or could I get away with writing my own since it's a less-functional CMS at it's heart? My application is going to be written using Ruby on Rails, but I'm not really familiar with any good quality CMS systems for that framework (and a lot of Rails applications seem to dislike playing with other apps). What I would have to do is save the template and then let the user select it later (along with the list of people they want to send it to), and tell ActionMailer to render the chosen template as the body of the message, while providing the first/last name of the customer(s) that will receive it. This doesn't sound that difficult to create, but if I can save development time by using or modifying an existing solution I would prefer to go that route.
The Radiant CMS has something like you're describing. It's released under the MIT license, so you can use their code as long as you keep the copyright notice.
Rails Email Preview (rails engine) has Comfortable Mexican Sofa CMS integration:
More information on github and wiki
Take a look here: http://www.campaignmonitor.com/ (it can be integrated into your app).

Resources