Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8251337
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T00:12:10+00:00 2026-06-08T00:12:10+00:00

How do I set the url for a semantic form tag in an activeAdmin

  • 0

How do I set the url for a “semantic form” tag in an activeAdmin custom page partial for collection_action in my activeAdmin controller?

I have:

item.rb

ActiveAdmin.register Item, :as => "MyItems" do
  menu :parent => "My", :label => "My Items"

  collection_action :add_me, :method => :post do
    redirect_to "/" # just for testing
  end
end

custom page ActiveAdmin controller

ActiveAdmin.register_page "MyItemsCustomPage" do
  content do
    @items = Item.all
    render "item", { :items => @items }
  end
end

_item.html.erb (for custom page)

<%= semantic_form_for :item_add_me, :url => add_me_admin_items_path do |f| %>
    <%= f.buttons :commit %>
<% end %>

And after going to the custom page I have the error:

undefined local variable or method `add_me_admin_items_path' for #<#<Class:0x00000006c3ff40>:0x00000005f8bd80>

btw, semantic form for admin_items_path works well for item add action.

PS. If I change the url to /admin/items/add_me and set the :method to :post, I get the routing error: No route matches [POST] "/admin/items/add_me"

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T00:12:12+00:00Added an answer on June 8, 2026 at 12:12 am

    Found the problem.

    After removing :as => "MyItems" in item.rb:

    ActiveAdmin.register Item do
    

    All works ok.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

My permalink structure is set so I have url.com/page I made a basic PHP
Is it possible to set a base url on a page with a relative
I have a variable set for my AppDelegate which stores the current URL that
I have this SQL DECLARE @url varchar(100) SET @url = 'http://mysite.com/%' SELECT [UserSessionSequenceID] ,[SiteID]
I have the following code that allows me to load a set URL each
I'm learning Yii and got into url routing problem. I have a controller as
What I am trying to do is basically set the URL to take you
I created a Facebook Application, i set the canvas url domain to the website
I would like to set values on an url like this: <a href='http://$data_url/viewyournote.php?chapter='$name_of_chapter'&note='$id_note'&user='$username'> Then
I am trying to set and catch the URL variable It begins with a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.