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 8878717
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T19:46:50+00:00 2026-06-14T19:46:50+00:00

I am facing a weird error in my code while using HAML where my

  • 0

I am facing a weird error in my code while using HAML where my code is working on my Local Machine but when I am deploying it I am getting the following error

ActionView::Template::Error (Illegal nesting: nesting within plain text is illegal.):

My code looks like this

  %td{ :style => 'width:10px' }
= link_to('Dashboard',   dashboard_admin_clients_account_path(client)) if client.is_member?
= link_to('Edit',   edit_admin_clients_account_path(client))
- if client.removed_at.nil?
  = link_to('Delete', admin_clients_account_path(client), :method => :delete, :confirm => 'Are you sure you want to delete')
- else
  = link_to('Restore', restore_admin_clients_account_path(client))

I am new to HAML

  • 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-14T19:46:51+00:00Added an answer on June 14, 2026 at 7:46 pm
    1. If you want your links to be inside the %td, they should be 1 tab righter (td – 0 tab, links – 1 tabs from the left side)
    2. you should use the same method to make indents (for example always use tab instad of spaces).
    3. it looks like the problem is not in this code. Is it partitial or part of some other code?

    Because ‘illegal nesting’ usually happens when you do like this:

    %td{ :style => 'width:10px' }
        justtext
          =link_to ....
    

    Try this code:

    %td{ :style => 'width:10px' }
        = link_to('Dashboard',   dashboard_admin_clients_account_path(client)) if client.is_member?
        = link_to('Edit',   edit_admin_clients_account_path(client))
        - if client.removed_at.nil?
            = link_to('Delete', admin_clients_account_path(client), :method => :delete, :confirm => 'Are you sure you want to delete')
        - else
            = link_to('Restore', restore_admin_clients_account_path(client))
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am facing a weird error.I have set up my code in IntelliJ Idea.
this time, I'm facing a really weird problem. I've the following code: $xml =
I am facing a weird problem. While browsing the C code of a project,
jquery datepicker is a great fun but I am facing a weird error. I
I am facing a really weird error,while trying to insert into a table called
I am facing a weird error while printing one of my Link List named
I'm currently facing a weird problem while executing a command from my bash script.
I am working on one of the opensource projects. I am facing a weird
I am facing a really weird problem. I am using swfupload to upload multiple
I have created web-application using JSF 2.0 & JSP and facing some weird problem.

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.