Jump to content

RESTful URL


socialmatrix

Recommended Posts

Hello,

 

I have crated a RESTful web service. It has a function called "addit" (adds two numbers). It is located at "http://www.azvaishnav.info/app/" and has a index.php file within which, addit function is implemented.

 

To call this service with REST URL would be http://www.azvaishnav.info/app/addit?num1=1&num2=2 Right?

 

However, above URL doesn't work. Weirdly this works, http://www.azvaishnav.info/app?num1=1&num2=2 (i.e. without function name). Here I am not even specifying what function to call. but it works. How do I change this so that anyone using my services has to specify function they wish to call?

 

Thank You,

Atit

 

 

Link to comment
https://forums.phpfreaks.com/topic/118354-restful-url/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.