Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

How can I see all the web service calls that are in a PHP/Zend site

Posted on 2015-02-21
9
46 Views
Last Modified: 2015-04-03
I have been tasked with a duty outside of my skill-set.  I need to pull together a list of all the web services that are called on the various pages.   I have downloaded the site to my local machine. Actually there are two sites, one in zend1 and the other zendFramework2. Is there a method and/or tool out there that will show me the "web services" that are being called on a page as I click through the site?

I don't want to see the code or anything, I just want to see the "web service" name.  I see some of the obvious call references, but suspect that there are some other not so obvious.  

So for example, click on link one, i want something that will show me webser1a and webser2b were called.  I click on the edit link and then see that editWebser51 was called. Click on "see more" link, i want something that will show me webser12h and webser342cb were called and so on.

You know if you use firebug or chrome developer tools, you can see the css files or js files - is there anything that can do this web services - again, i don't want to see the code as you actually with a css file via firebug, i just want to see that xxxx-webservice(s) called.

I have matched up some of the zend calls to the matching SAP web service.

Zend and web services are outside of my skill-set, but inherited a few tasks after developers quit.  After investigating the zend code, i think i see why.  At any rate, I would like to be able to complete this task of tracking down from where each web services is being called
0
Comment
Question by:brandon_walsh
  • 5
  • 4
9 Comments
 
LVL 83

Expert Comment

by:Dave Baldwin
ID: 40623703
That's probably going to require you to go thru the code.  Web Service calls would be done in the background and not show up in your browser.  The things you would be looking for are things like 'file_get_contents' and 'curl' functions.  Once you start finding them, you can use something like Windows Grep http://www.wingrep.com/ to find all the occurrences in all the files.  I find myself using it a lot.
0
 

Author Comment

by:brandon_walsh
ID: 40623708
not sure zend works that way - the file-get_contents part I mean.  it is mvc framework, so in the controller it has "use ????WebSrv" declared at the top, then the view, model, etc to use when/what is needed.  But let me see if there is anything similiar.

And by the way - thanks for the quick response.
0
 
LVL 83

Expert Comment

by:Dave Baldwin
ID: 40623717
Zend in an MVC framework will have the Web Service calls organized better.  But it's still PHP and that isn't the only way to do it.
0
Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
LVL 83

Expert Comment

by:Dave Baldwin
ID: 40623719
I would start then by using WinGrep to find all occurrences of 'WebSrv' in the site files.
0
 

Author Comment

by:brandon_walsh
ID: 40623724
I actually did a find in file search using netbeans ide and found the references to the web services names that are stored in one of the directories of Zend, but I suspect there are more references on other pages that are not so obvious.
0
 

Author Comment

by:brandon_walsh
ID: 40630688
As I am not that familiar with ZendF2 and it's odd mvc structure, should every page that is calling a Web Service have a reference to that service?

So for example, I create page/module called inventory, in that inventory display page, there is an edit button, a summary button.  These are links to "edit.php" which of course has view/model/controller.  What I see is on the "Inventory.php" page a reference to whatever sapService, but I don't see a reference to a service on the edit.php code page or on the summary.php page.
0
 
LVL 83

Expert Comment

by:Dave Baldwin
ID: 40631055
I have no idea, I don't use Zend myself.
0
 

Accepted Solution

by:
brandon_walsh earned 0 total points
ID: 40695204
Changed to codeIgniter framework.  Zend is just over designed.
0
 

Author Closing Comment

by:brandon_walsh
ID: 40704721
so good solution for my use case.
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

In order to have all security and back ups taken care of, WordPress users can sign up for services with WP Engine.
Nothing in an HTTP request can be trusted, including HTTP headers and form data.  A form token is a tool that can be used to guard against request forgeries (CSRF).  This article shows an improved approach to form tokens, making it more difficult to…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…

789 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question