jquery - URL of server.php/123 still received by server.php -


so have been fiddling around backbone.js today , thinking how php code work ajax requests this:

$.ajax({     url : "server.php/123",     data : "empty string",     type : "post" // or "get" - interested in both }); 

just messing around, discovered if above url sent, "server.php" still receives request. surprised see this, expected need sort of mod_rewrite nonsense work.

based upon discovery, have couple of questions:

  1. is common most/all servers? i'm running wamp localhost zend.
  2. is possible, in server.php, access information sent after "/" without doing mod_rewrite stuff (e.g., call of "server.php/123" want access "123" server.php). realize that, in backbone's case, sends information part of json, me trying learn how php works.

yes, common, , yes can access it:

$url_parts = explode('/', $_server['request_uri']); print_r($url_parts); 

Comments

Popular posts from this blog

How to remove text and logo OR add Overflow on Android ActionBar using AppCompat on API 8? -

html - How to style widget with post count different than without post count -

url rewriting - How to redirect a http POST with urlrewritefilter -