similar to: Submitting data to two tables

Displaying 20 results from an estimated 20000 matches similar to: "Submitting data to two tables"

2006 Mar 04
4
Submitting data to two different tables with two different models
I''m very new to Rails. I''ve been reading Agile Web Dev for a while and read up on ruby, but I''m still learning. I designed a website for someone for an engineering shop. New projects had to be added manually. Well, I figured this would be a great canidate for railifying! I have the form working perfectly, you can add your data and get it in a table, and listing
2006 Aug 11
1
Absolute path to public/images in rake task?
Hi all I''m trying to create a rake task for the first time, so please be a bit patient with me. ;-) I''m coding a photo gallery. Every photo gallery''s photos are in its own folder, and after an update I''d like to be able to synchronize the photo files with the database (because every photo has its own Photo class object). I''ve got so far: # File
2005 Sep 14
4
How to drag/drop visitable anchors ?
Hi ! I have the following: <li id="photo_<%= @photo.id %>" class="photo"> <%= link_to(image_tag(url_for_file_column(:photo, :picture)), {:action => ''photo'', :id => @photo}, {:title => @photo.description}) %> </li> <script type="text/javascript" language="JavaScript"><!--
2008 Jun 20
4
Handling content pages (CMS-like)
Hello list, I wonder how you guys handle content pages? Often described as "static" pages. However, I don''t like to call them "static" because these pages often do use some minor dynamic content. This is what I like to think of as the "website" part of the web application. Content that does not have complex logic behind it. I had to handle it in the
2013 Apr 05
1
Internet connection
Tried several ways to connect to Internet. Perhaps R help could point me in the right direction to make this connection work. setInternet2(use = TRUE) > download.file(" + http://image.shutterstock.com/display_pic_with_logo/322090/322090,1307359665,10/stock-photo-car-silhouette-for-race-sports-design-vector-version-also-available-in-gallery-78667174.jpg + ", +
2007 Aug 15
0
Rails error on generated app
I created a very simple app with a database table for image file names and tags to be associated with the image. When I generate the scaffolded app it has an error in it. There is an uninitialized constant of the same name as the model class but singular instead of plural. I.E. Model class Photos < ActiveRecord::Base and in the completely generated app I get an error when creating a row in
2006 Jun 22
1
Sharing primary key between two tables?
Hello, I have an ActiveRecord question. I have two tables, "customers" and "users". Those two tables really should share their primary key, in order to have a "real" 1:1 relationship. (I don''t mean to start a database-resign religious war, but I must say that I do feel very uneasy about using ActiveRecord''s "normal" way, which is to
2006 Jun 16
4
Depot App: Upload Images
Hello, I''m a newbie to Ruby on Rails and like many others, I have been working through the depot application in the Agile Web Development book. I was wondering if anyone had enhanced the depot application to include the upload of images for each product? The following describes the sort of thing that I have been asked to produce for a client, so apologies if the information is not
2009 Jun 24
16
Web photo gallery options
Hi all, I'm looking for a web photo gallery for my personal web server at home. Till now I've done the galleries manually from Adobe Photoshop Elements, but I feel that is a dead end, kinda', besides the fact that the galleries created are rather static. I'd like an easier way to do this, eg uploading images in folders directly to the gallery and it will take care of what needs to
2006 Jan 04
8
Trying to display data from two tables
Alrighty folks, I''m really trying here, and want to succeed with Ruby on Rails. I''m trying to display data that is linked from two tables using the Active Record naming conventions, as described in Agile Web book. The stripped-down basics; Database drop table if exists people; CREATE TABLE `people` ( `id` int(6) NOT NULL auto_increment, `lastname` varchar(30) NOT NULL,
2006 Jun 06
8
How do I wrap a <%= link to %> around an image?
I''ve got a bunch of dynamically generated link paths that I want to use to link some dynamically-generated image paths. Specifically, I want to link thumbnails in a gallery to the larger images. But I''m stymied by Rails'' syntax. I can''t figure out how to do this. I tried this: <%= link_to(image_tag("../../images/photos/photo.photogroup/TN_
2006 Aug 14
2
after_create is not being called
Hi all I have the following model: class PhotoGallery < ActiveRecord::Base attr_accessible :title, :description, :file_path, :title_photo_id has_many :photos, :dependent => :destroy belongs_to :title_photo, :class_name => ''Photo'', :foreign_key => ''title_photo_id'' validates_presence_of :title, :description, :file_path
2006 Aug 14
0
Coppermine Photo Gallery Integration
I have a RoR app that currently uses file_column for image upload and display. The app is part of a website that uses CPG for running a photo gallery, and I''d like to know if anyone has interfaced a RoR app to CPG by any chance. I want to dump file_column and let CPG handle my images. -- Posted via http://www.ruby-forum.com/.
2006 Mar 24
1
AJAX & Posting Reccomendation
I''m currently developing a photo gallery website with Rails. Each photo can be commented upon. What I''d like to do is, once the user posts a comment, use AJAX to submit the comment and then automatically update the page with the comment the user just submitted. I also don''t want to use Prototype or the built in AJAX that comes with Rails... it''s too fat
2008 May 12
3
photo rotation.
hi in my application i have a photo gallery page where i showing all my album photos, i want to developed a functionality where i can rotate photo there and and saved backed to file system. how it is possible ? -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on
2006 Feb 03
0
component/ajax variable access problem
I''m trying to embed a little image gallery on each page. The photos need to be different for each page. I just want to use ajax and let them click on the photo and have it show the next image. When the page loads, it shows the correct image. But when clicking on it, it gives an error because it doesn''t know what @images is anymore. On the view for the home page: <div
2009 Jan 30
1
Crash shortly after importing pool
Looks like my main data pool is borked. I''ve got one essentially current backup, and one older backup, plus the photos are mostly backed up on archival optical disks, so this isn''t as disastrous as it might be, but still, recovering several hundred gigabytes on home equipment is a pain. Hence I''d prefer to recover the pool if that''s reasonably possible. When
2008 Apr 17
1
how to use a function in aggregate which accepts matrix and outputs matrix?
Dear netters, suppose I have a matrix X [1,] 'c1' 'r6' '150'[2,] 'c1' 'r4' '70'[3,] 'c1' 'r2' '20'[4,] 'c1' 'r5' '90'[5,] 'c2' 'r2' '20'[6,] 'c3' 'r1' '10'I want to apply some funciton to groups of rows by the first column.If the function is just to
2006 Jul 03
3
Open source gallery suggestion
Hello, I''m a RoR newbie. I need to develop a gallery site for a friend of mine. Can you suggest me an open source gallery I can start from? I just need to manage photos, albums and an admin user in order to modify albums. Thanks .Stefano
2008 Jul 14
1
Computing row means for sets of 2 columns
Is there a better or more efficent approach than this without the use of t() ? > (m <- matrix(1:40, ncol=4)) [,1] [,2] [,3] [,4] [1,] 1 11 21 31 [2,] 2 12 22 32 [3,] 3 13 23 33 [4,] 4 14 24 34 [5,] 5 15 25 35 [6,] 6 16 26 36 [7,] 7 17 27 37 [8,] 8 18 28 38 [9,] 9 19 29 39[10,] 10 20 30 40 >