[Rails] Form Ajax in Rails ?

2016-02-28 Thread Le Hung
I'm new in Rails. I'm trying to add a form with ajax.It's just typing a text and submit to file 'ex/act' and show the param in form. My code: function loadDoc(url, cfunc) { var xhttp; xhttp=new XMLHttpRequest(); xhttp.onreadystatechange = function() { if (xhttp.re

[Rails] Adding Image icon to a Blog title post

2016-02-28 Thread Elysee Montissol
I created a simple blog and I'm using paperclip to be able to add images to a Post. I installed the 'themify-icons-rails' gem and what I want to do is automatically add a picture icon next to the title of a post when the post has a image that's been uploaded, to show that the post has a image. I'm

Re: [Rails] adding descriptions to images displayed in bluimp image gallery

2016-02-28 Thread fugee ohu
On Sunday, February 28, 2016 at 3:01:35 PM UTC-5, Walter Lee Davis wrote: > > > > On Feb 28, 2016, at 12:36 PM, fugee ohu > > wrote: > > > > > > > > On Sunday, February 28, 2016 at 8:51:51 AM UTC-5, Colin Law wrote: > > On 28 February 2016 at 11:44, fugee ohu wrote: > > > Why is adding de

Re: [Rails] variables in views

2016-02-28 Thread fugee ohu
On Sunday, February 28, 2016 at 4:41:28 AM UTC-5, Colin Law wrote: > > On 28 February 2016 at 04:37, fugee ohu > > wrote: > > .. > > Hi again and thanks again Tam I got it working like this > > <%= image_tag(task.name.thumb) > %> > > > > Unless I am missing something, this might be cleare

Re: [Rails] variables in views

2016-02-28 Thread fugee ohu
On Saturday, February 27, 2016 at 11:08:35 PM UTC-5, tamouse wrote: > > > On Sat, Feb 27, 2016 at 9:14 PM, fugee ohu > wrote: > > > I'm trying to build some links from this statement <% for task in > > row_tasks %> where task.name and task.name.thumb are full path image > > file names and

Re: [Rails] adding descriptions to images displayed in bluimp image gallery

2016-02-28 Thread Walter Lee Davis
> On Feb 28, 2016, at 12:36 PM, fugee ohu wrote: > > > > On Sunday, February 28, 2016 at 8:51:51 AM UTC-5, Colin Law wrote: > On 28 February 2016 at 11:44, fugee ohu wrote: > > Why is adding descriptions a whole javascript task in bluimp image gallery > > Couldn't the author have worked it

Re: [Rails] adding descriptions to images displayed in bluimp image gallery

2016-02-28 Thread fugee ohu
On Sunday, February 28, 2016 at 8:51:51 AM UTC-5, Colin Law wrote: > > On 28 February 2016 at 11:44, fugee ohu > > wrote: > > Why is adding descriptions a whole javascript task in bluimp image > gallery > > Couldn't the author have worked it out so that all I'd have to do is > provide > > t

Re: [Rails] adding descriptions to images displayed in bluimp image gallery

2016-02-28 Thread fugee ohu
On Sunday, February 28, 2016 at 8:51:51 AM UTC-5, Colin Law wrote: > > On 28 February 2016 at 11:44, fugee ohu > > wrote: > > Why is adding descriptions a whole javascript task in bluimp image > gallery > > Couldn't the author have worked it out so that all I'd have to do is > provide > > t

Re: [Rails] adding descriptions to images displayed in bluimp image gallery

2016-02-28 Thread fugee ohu
Why's it great ? I might agree but I'm beginning to ask myself what I needed it for in the first place I could have loaded another page to display images with captions or whatever i want What do i need them displayed in javascript for anyway Can you tell me what makes bluimp image gallery a bet

Re: [Rails] adding descriptions to images displayed in bluimp image gallery

2016-02-28 Thread Colin Law
On 28 February 2016 at 11:44, fugee ohu wrote: > Why is adding descriptions a whole javascript task in bluimp image gallery > Couldn't the author have worked it out so that all I'd have to do is provide > the descriptions in the html They provide a data-description option to use > in my html ancho

[Rails] adding descriptions to images displayed in bluimp image gallery

2016-02-28 Thread fugee ohu
Why is adding descriptions a whole javascript task in bluimp image gallery Couldn't the author have worked it out so that all I'd have to do is provide the descriptions in the html They provide a data-description option to use in my html anchor containers but that doesn't do anything by itself

Re: [Rails] variables in views

2016-02-28 Thread Colin Law
On 28 February 2016 at 04:37, fugee ohu wrote: > .. > Hi again and thanks again Tam I got it working like this > <%= image_tag(task.name.thumb) %> > Unless I am missing something, this might be clearer <%= link_to image_tag(task.name.thumb), task.name %> Colin -- You received this message

[Rails] Re: PostgreSQL setup for Rails@Ubuntu

2016-02-28 Thread krfg
If posgresql is installed via PostgreSQL apt repository, in order for Rails to use the 'pg' gem it is also necessary to install the 'libpq-dev' package, otherwise bundle install will fail. See at Stackoverflow Can't find the 'libpq-fe.h header when trying to install pg gem.