On 18 September 2014 22:32, Paolo Di Pietro wrote:
> I tried the following and others, but
>
> <%= link_to "some text", factory/demo/user/9 %>
> <%= link_to "some text", factories/demo/chat %>
Those two are not valid as the second parameter you have provided
should be a variable a method or a st
On 18 September 2014 22:27, Paolo Di Pietro wrote:
> Colin,
>
> your suggestion is surely correct. My point is that I'm trying to perform an
> over complex task dealing with a lot of new technologies to integrate.
> I need a kick to bypass this stop.
Work through the tutorial first. A couple of
With the first two the problem might be, that rails/ruby has no idea what
factory, demo and user are - it thinks that those are methods or variables
<%= link_to "test", "/foo/bar/" %>
works when I tried it
On Thursday, September 18, 2014 11:32:04 PM UTC+2, Paolo Di Pietro wrote:
>
> I tried the
I tried the following and others, but
<%= link_to "some text", factory/demo/user/9 %>
<%= link_to "some text", factories/demo/chat %>
<%= link_to "some text","/factory/demo" %>
<%= link_to ("some text","/factory/demo") %>
not clear where 'You don't want to have white space between method name
Colin,
your suggestion is surely correct. My point is that I'm trying to perform
an over complex task dealing with a lot of new technologies to integrate.
I need a kick to bypass this stop.
Il giorno giovedì 18 settembre 2014 23:15:54 UTC+2, Colin Law ha scritto:
>
> On 18 September 2014 22:04,
On 18 September 2014 22:04, Paolo Di Pietro
wrote:
> Done!
>
> Then I put
> <%= link_to "some text", /factory/demo/message/1389/ %>
> in my .erb file
>
>
I think maybe before worrying about generic routes you need to get to grips
with the basics of ruby and rails. I suggest you start by working
You don't want to have white space between method name and brackets so
either
<%= link_to "some text", "/factory/demo/message/1389/" %>
<%= link_to("some text", "/factory/demo/message/1389/") %>
On Thursday, September 18, 2014 11:04:54 PM UTC+2, Paolo Di Pietro wrote:
>
> Done!
>
> Then I pu
1) the route excepts to get 1-3 parts, separated by / and you are trying to
get 4 things to match
2) the real issue, try
<%= link_to "some text", "factory/demo/user/9" %>
So you had missing ')' and probably next thing it would complain is that
variables/methods factory/demo/user are not found..
Done!
Then I put
<%= link_to "some text", /factory/demo/message/1389/ %>
in my .erb file
but getting the following error:
Completed 500 Internal Server Error in 56ms
SyntaxError
(/home/pdipietro/gsn/app/views/identity_providers/index.html.erb:35: syntax
error, unexpected ',', expecting ')'
.
On 18 September 2014 21:52, Paolo Di Pietro
wrote:
> The direction seems to be right, so I created
>
> 1) the route
>
> get ':part1/(:part2/(:part3))' =>'factory#demo'
>
> 2) the factory controller
>
> Then I add the following line to my .erb
>
> <%= link_to "some text", factory/demo/user/9 )
The direction seems to be right, so I created
1) the route
get ':part1/(:part2/(:part3))' =>'factory#demo'
2) the factory controller
Then I add the following line to my .erb
<%= link_to "some text", factory/demo/user/9 ) %>
but it returns the following error:
Completed 500 Internal Serve
Im not sure if I get what exactly you are trying to accomplish, but:
with route
get ':part1/(:part2/(:part3))' =>'demo#demo'
And controller
class DemoController < ApplicationController
def demo
render plain: params.inspect
end
end
And thus /foo, /foo/bar and /foo/bar/baz will use DemoC
No, I still cannot do it.
I cannot use Hobo because I'm using Neo4j NoSql db, which doesn't run with
Hobo.
I just would like to set up an abstract route redirecting everything to my
AbstractController!
Il giorno martedì 16 settembre 2014 10:37:11 UTC+2, Jarmo Isotalo ha
scritto:
>
> Cant yo
Cant you do it already?
On Monday, September 15, 2014 6:34:46 PM UTC+2, Paolo Di Pietro wrote:
>
> Hi all,
>
> I'd like to implement (Rails 4) a very high level (generic) abstract
> controller, able to manage any route and then create a viewer on the fly.
>
> I'd like to call it 'abstracts', and
14 matches
Mail list logo