Im having this code
%button.aristo-default.accept{:href => "#", :onclick => "$.post('/sessions/accept_invite', { user_id: 1, friend_id: 1 }) " }
Would like to place @friend.id inside the 1’s so I can have variables instead of the hardcoded 1, what would be the way to do it? must be simple but I tried several ways to no avail. thx
You can use
#{@friend.id}to get the actual value: