routing

SEO URLs with ASP.NET MVC

耗尽温柔 提交于 2019-12-04 07:04:38
Is there a definite DO and DONT when implementing seo urls? A lot of good practise seems fine for .html sites but breaks down on medium/large database sites. AFAIK the url should be www.mysite.com/category/page-name-here If I wish to make a content rich site and be default the category and page are database driven - does this prevent me from having pages such as www.mysite.com/about or www.mysite.com/home as the about and home pages could conflict. Although the routing engine is flexible, is the above feasible and/or worthwhile? -edit- Just to elaborate on my question, is it possible to

Angular 5 EmptyError: no elements in sequence while making child routes

不问归期 提交于 2019-12-04 06:21:36
I am not able to navigate from login page to dashboard page when I use children in routing as follows: const appRoutes: Routes = [ { path: '', redirectTo: 'login', pathMatch: 'full' }, { path: 'login', component: LoginComponent,pathMatch: 'full' }, { path: 'dashboard',pathMatch: 'full', /* canActivate: [AuthGuard], */ component: DashboardComponent , children: [ { path: 'online-submission/:moduleName',pathMatch: 'full', component: OnlineSubmissionComponent, /* canActivate: [AuthGuard], */data:{ breadcrumb: "online-submission" } , children: [ { path: 'batch-upload-members',pathMatch: 'full',

Rewriting URLs in PHP instead of server config

拥有回忆 提交于 2019-12-04 06:17:55
问题 I'm looking for a very lightweight routing framework (to go with php-skel). The first thing I'd like to investigate is specifying rewrite rules in a php file ("not found" handler) in a similar way to how this is specified in the server configs. Here's a potential example (but I'm wanting to know what frameworks provide something this lightweight): File route.php: route('application/api', '/api/index.php'); route('application', '/application/index.php'); File appplication/index.php: route('

Sniffing IGMP messages on the local network

 ̄綄美尐妖づ 提交于 2019-12-04 05:47:29
问题 I'm trying to sniff all IGMP messages on the local network (for crazy reasons not to be discussed ;-)). I have some questions related to this, as I'm not really an IGMP/routing expert. Is it even possible? I know I can read IGMP from a raw socket, and I know you can use Wireshark to monitor the IGMP messages that reach your local computer, but what puzzles me is this: I use a program on another computer (separated from the one running Wireshark by a switch) which will join a multicast address

Angular 2: How do I get params of a route from outside of a router-outlet

こ雲淡風輕ζ 提交于 2019-12-04 05:41:52
Similar question to Angular2 Get router params outside of router-outlet but targeting the release version of Angular 2 (so version 3.0.0 of the router). I have an app with a list of contacts and a router outlet to either display or edit the selected contact. I want to make sure the proper contact is selected at any point (including on page load), so I would like to be able to read the "id" param from the route whenever the route is changed. I can get my hands on routing events by subscribing to the router's events property, but the Event object just gives me access to the raw url, not a parsed

Android - Google Maps routing

点点圈 提交于 2019-12-04 05:32:40
I have added Google maps functionality into my application a now I am asking you, is there any way, how can I add o this mapView routing fnctionality. I will have my coordinates from my GPS (like start) and coordinates of my destination. I would like to draw route, which I should take to reach the finish. Is it possible? Thanks Kartik Domadiya Hmyzak see the most promising solution given by Max Gontar...It worked for me. J2ME/Android/BlackBerry - driving directions, route between two locations Full Source Code : http://code.google.com/p/j2memaprouteprovider/source/browse/trunk

How to create a dynamic root in Rails 3?

你说的曾经没有我的故事 提交于 2019-12-04 05:29:26
I have admins and normal users in my webapp. I want to make their root (/) different depending on who they are. The root is accessed from many different pages, so it would be much easier if I could make this happen in the routes.rb file. Here is my current file. ProjectManager::Application.routes.draw do root :to => "projects#index" end Can someone please link me to an example that can show me the direction to go in? Is there any way to put logic into the routes file? Thanks for all the help. You can just create controller for root route. class RoutesController < ActionController::Base before

symfony 2 routes not found in production

家住魔仙堡 提交于 2019-12-04 05:13:34
I have routes like: /, /login, /register, etc that work fine in dev environment. At first i got 404 error when tried to access my site through app.php instead of app_dev.php Then i followed this advice and cleaned up my cache. But now i'm getting a blank screen trying to access any of the registered routes like app.php/ or app.php/login. I found this message in prod.log: [2012-02-24 11:27:05] request.ERROR: Symfony\Component\HttpKernel\Exception\NotFoundHttpException: No route found for "GET /login" (uncaught exception) at /home/renat/www/ptracker/app/cache/prod/classes.php line 4564 [] []

How can I add the _locale parameter to security paths?

烈酒焚心 提交于 2019-12-04 05:08:14
I setup my security settings to protect everything which is under the root path / , exept for a public page to view the privacy policy, /privacy . Everything works fine. # security.yml access_control: - { path: ^/privacy$, role: IS_AUTHENTICATED_ANONYMOUSLY } - { path: ^/, role: ROLE_USER } Now I added some different translations to the privacy policy page, so that the route changes from /privacy to /{_locale}/privacy . Unfortunately I cannot add the _locale parameter to the security path like this: access_control: ... - { path: ^/{_locale}/privacy$, role: IS_AUTHENTICATED_ANONYMOUSLY } So how

How to use Routing ASP.NET 4 WebForms with Query String?

谁说我不能喝 提交于 2019-12-04 05:05:32
First, this is not MVC, WebForms only.. I'm using routing to keep my site backwards compatible for our clients, while make my project organized. I'm also thinking of moving our encrypted query string to a more friendly url. How this works is our clients have to bookmark a huge encrypted url to prevent them from guessing our other clients by changing an id around. But instead of having this huge url, wanted to add a route like LoginClientName.aspx for each client and have the encrypted query string hard coded or maybe in database. But don't see a way to add a query to the MapPageRoute.. Was