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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T04:19:05+00:00 2026-05-27T04:19:05+00:00

I already create my web with the main index is in /localhost/store In the

  • 0

I already create my web with the main index is in /localhost/store
In the main body, there is a right sidebar with a profile information.

What I want to do is …
When I browsing to my detail post where the url is /localhost/posts/3, I want to change my right sidebar with another list of the new posting (like similar question on stackoverflow when I type my question). Is there any way I can detect my url (change from store to posts)?

Kindly your help please..

  • 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-05-27T04:19:06+00:00Added an answer on May 27, 2026 at 4:19 am

    Not sure what you are asking exactly, but i think this is what you want to do
    In you views, you can detect the current page by using the following:

    <% if current_page?(:controller => "", :action => "index") %> 
        ....original right sidebar code.......
    <% elsif current_page?(:controller => "posts", :action => "show") %>
        ....new right sidebar code.......
    <% else %>
        ....do something else.......
    <% end %>
    

    I am using jquery to this with some ajax on my site(bit more complicated), but i think this might be sufficient for what you are asking. Hope it helps.

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

Sidebar

Related Questions

I want to create a project that uses source files already on my filesystem,
How to select a same database? I want to create a table from already
I know there already are a lot of posts floating on the web regarding
I would like to create a Web Service in Eclipse. I already wrote a
I want to create a web service for my clients so they can display
Goal I want to create a web app with a horizontal GUI bar that
I already create a virtual directory (cgi-bin) with permission : Scripts and Executable... When
I already implemented to create the XML file below with XmlTextWriter when application initialization.
I have already search for some time over the net on how to create
I have an already existing stored procedure. But when I am trying to create

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.