Applying WordPress Coding Standards and Optimizations to Maintain a Legacy Application

The client of swft #507 has a web application which facilitates the users of the Fortune 500, Federal, State and Government agencies to generate USPS labels, scan report and tracking status. The legacy application was developed using Caspio Bridge and Endicia on WordPress with Avada Theme by his ex-developer.

Initially, the automation of all the back-office work processes was required to reduce the overall running cost of the client’s business. Later, he wanted vteams to incorporate some new features such as Excel Batch Labels generation in the application to compete with his industry rivals.

At first, engineer Nabeel Javaid analyzed the quality of code and checked the reliability and scalability of the legacy app. The following major technical issues were identified during the legacy app analysis:

  • Outdated Avada Theme
  • Business logic fully dependent on Themes
  • Excessive usage of Templates
  • Poor user experience
  • Coding standards were not followed
  • Not a scalable application

swft #507 communicated the nature of these issues to the client and suggested him to standardize and optimize the application completely upon which he agreed.

Implementation

vteams engineer Nabeel started creating a custom WordPress plugin and developing a powerful framework architecture from scratch. To standardize and optimize the application, the following steps were implemented:

  1. Moved all the business logic from templates into the newly developed framework architecture
  2. Improved the code of all the existing modules according to the WordPress standards
  3. Two extensive SOAP libraries for Caspio and Endicia were developed
  4. Added a few helpers for flash messages, form builder, Mailer and FTP
    Note: With the help of libraries and helpers, the size of code was reduced
  5. Some special jQuery plugins such as Validation, Sweatalert and UIBlock were utilized to enhance the overall user experience.

Conclusion

After applying all the above mentioned optimizations, the target was achieved within the given deadline. As a result, a standardized application following WordPress standards was developed. It became quite easy for the client to maintain and scale the application as required. Additionally, the loading speed of web pageswas improved.