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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T21:32:11+00:00 2026-05-25T21:32:11+00:00

I had developed project with custom MVC architecture. And I am new to Apache

  • 0

I had developed project with custom MVC architecture. And I am new to Apache world, so I would appreciate help with this matter. On a Web I had found lots of tutorials, but no one like mine interests.

I have URL like this: http://knjiskicrv.comoj.com/index.php?page=book&id=1

I would like to be display like this: http://knjiskicrv.comoj.com/book/id/1

Or this: http://knjiskicrv.comoj.com/index.php?page=faq
Into this: http://knjiskicrv.comoj.com/faq

If there is no page in query (http://knjiskicrv.comoj.com/index.php), I would like to show: http://knjiskicrv.comoj.com/

Also with no page in query (http://knjiskicrv.comoj.com/index.php?category=2), it should be like this http://knjiskicrv.comoj.com/category/2

Hope someone will help. Thanks.

  • 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-25T21:32:12+00:00Added an answer on May 25, 2026 at 9:32 pm

    Actually, your problem is a two step proble. You first need to understand what is “Routing” in MVC. If you have your own implementation of an MVC like framework and you don’t support routing, then it probably means you didn’t even know how it worked before. (Sad but true)

    In an MVC framework you setup routes using a ROUTER and the router analyses the urls for you saying HEY, i found this url that matches your request, go ahead and do work with it.

    So then, your controller receives a request to route into itself and PARSES the url as he sees fit. Such as using explode(‘/’, $_SERVER[‘REQUEST_URI’]) and then reading the different parts of the url to map to expected variables.

    All of this is very theoretical because there are ZILLIONS of way to implement it in a custom way. The only thing you will have to use is a little mod_rewrite magic to pass all requests to your index.php that will route everything. Look at the url below to learn about mod_rewrite, it’s a VERY COMPLEX subject:

    http://www.addedbytes.com/for-beginners/url-rewriting-for-beginners/

    What i usually go for but i don’t have access to it from home is something like this:

    RewriteEngine On
    RewriteCond %{REQUEST_URI} !^assets/
    RewriteRule .* index.php
    

    This will redirect all traffic to index.php and you can then use $_SERVER[‘REQUEST_URI’] to analyze the request. Everything in assets/ folder will not be touched and work correctly.

    Note, i built that part off my hat, it might not work…

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

Sidebar

Related Questions

I had my VB.NET project and associated solution (developed in Visual Studio 2005) in
I recently started at a new position where the project is being developed using
I had to take over a c# project. The guy who developed the software
Background I developed a custom plugin architecture using a derivation of the Observer/Event Pattern
This is a usual MFC project developed in VC++ 2010 but since my client
I recently had to work on a project where the previous developer modified the
I had developed an application in visual Studio 2005. whenever i run that application
I had developed a script, earlier I use to transfer it directly without any
I had developed an API Rest for an iPhone Game and it works properly.
I had developed one website purely in HTML .I have my form with fields

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.