Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8893711
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T23:18:52+00:00 2026-06-14T23:18:52+00:00

I am trying to compare two PHP projects using PHP Depend (http://pdepend.org). One is

  • 0

I am trying to compare two PHP projects using PHP Depend (http://pdepend.org). One is a page-based PHP application written by a group of students a year ago and the second is mine that I have worked on for the past year. The objective is to provide some quantitative statistics that might help validate that refactoring the project (introducing a MVC architecture and lots of refactoring to better apply OO principles) has led to lower complexity and coupling, among others.

The problem I am facing is that when analyzing the older project, PHP depend ignores the files that were written in a procedural programming style. It only picks up those files that have classes defined. I am not sure why the previous students chose to have this hybrid style of writing code but they did.

Is this how PHP Depend works or is there some setting I can use so that it analyzes all files. The site offers little help. If PHP Depend can only analyze files with defined classes and methods, how can I generate some code metrics to validate my project?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T23:18:53+00:00Added an answer on June 14, 2026 at 11:18 pm

    Actually, PHP depends will generate empty reports for file that do not contain at least a class or a function. This is sadly the expected behavior before someone decides to patch it up.

    You can use PHP LoC, PHP Mess Detector or PHP Code Sniffer to generate some code metrics for both projects. At least PHP LoC will generate all its metrics for unstructured php files, and PHP Code Sniffer and PHP Mess Detector will generate at least some of their metrics.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to compare two urls using PHP, ensuring that the domain name is
I'm trying to compare two strings. One stored in a file, the other retrieved
I'm trying to compare two 2D arrays in PHP and my head is hurting
I have been trying to compare two arrays. Using array_intersect presents no problems. When
I'm trying to compare two strings One string is a normal string that I
I'm trying to pull meta tags out of a html page, to compare two
I am trying to compare two large Visual Studio 2010 solutions using Beyond Compare.
I am trying to compare two Ruby Hashes using the following code: #!/usr/bin/env ruby
I am trying to compare two timestamps to see which one is the latest
I'm trying to compare two dates in PHP and figure out how many days

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.