ابدأ بالتواصل مع الأشخاص وتبادل معارفك المهنية

أنشئ حسابًا أو سجّل الدخول للانضمام إلى مجتمعك المهني.

متابعة

What is router in web development?

user-image
تم إضافة السؤال من قبل Milenko Mudrinic , Manager of Sale , Comtradic
تاريخ النشر: 2014/12/23
Alaa  Aldamiri  PMP
من قبل Alaa Aldamiri PMP , Project Manager (PMP, Scrum, Six Sigma Certified) , Saudi Business Machines SBM General Marketing and services representative of IBM in Saudi Arabia

Routes are basically paths the user takes which are attached to code that will be triggered when a user reaches the specific route.

It takes a much cleaner and clearer approach to cut down on the added hierarchy complexity that MVC can add.

Muhammad Majid Saleem
من قبل Muhammad Majid Saleem , Senior PHP Developer / Project Manager , SwaamTech

In simple words:

Router helps web server to fetch an appropriate and exact information for user.

 

It is like Station Master at railway station, who informs to Train Driver to change track for crossing other train.

Mostafa Mohammed Naguib
من قبل Mostafa Mohammed Naguib , Senior back-end developer , Egpay payment solution

Router or routing in web development is more like managing a well-organized redirecting systemwhich mostly would be something like thissay you have a model which called "users"and it contains a method called "new" , "edit" Or even "view"and then you have something like the ID of the userwith a good routing system your link should "user/edit/1"so your app will always take the first arg as a "Model" and find it in your models, then search for the2nd arg as "method" inside that Model, then use the3rd arg as an "id" if needed.the most flexible routing system i'v seen so far is the Zend framework Routing one.

المزيد من الأسئلة المماثلة

هل تحتاج لمساعدة في كتابة سيرة ذاتية تحتوي على الكلمات الدلالية التي يبحث عنها أصحاب العمل؟