Library Server Action Has Crazy File Path In The PHP Require Code

Thanks for reporting an issue! Please spend 60 seconds reading this…

  1. Before reporting, make sure you have the latest version of Wappler
  2. If there is a problem with the Server Action not running properly or not doing what it is supposed to do, please first check How to debug problems in Server Connect
  3. Make sure you have searched the forum first for similar issues already reported
  4. If it is a general web related issue - do a Google Search first
  5. Issue tracker is for bugs and feature requests, in English only
  6. Learn how to report bugs effectively

======== TEMPLATE BUG FORM ========

Wappler Version: 3.7.1
Operating System: Windows 10
Server Technology: PHP

Expected behavior

What do you think should happen?

When I break all the Wappler rules and take a look at the code of a Library Server Action, it should have a sensible file path in the header like this:

require('../../../dmxConnectLib/dmxConnect.php');

Actual behavior

What actually happens?

I created a Library Action, edited it a few times adding a couples of lines of action steps along with $_GET, $_POST and $_PARAM variables. I then changed its name and tried unsuccessfully to duplicate it a few times. Afterwards, I looked at the PHP and found this:

require('../../../../../../../../dmxConnectLib/dmxConnect.php');

How to reproduce

  • Detail step by step guide to reproduce the issue
  • A screenshot or short video indicating the problem
  • A copy of your code would help. Include: JS, HTML.
  • Test your steps on a clean page to see if you still have an issue

Do as I listed above.

Could you care to explain what are your breaking exactly?

Library actions are different from API Actions - they don’t have a require in them. So are you breaking everything by saving a Server API Action to the Library location?? You shouldn’t do that manually …

Antony, if you are trying something like:

Please don’t do that.

Hi guys…

I’d like to apologise… I’m not quite sure what happened, maybe it was me fiddling around that caused the problem.

If I find it come up again within a normal use of Wappler I will let you know.

Feel free to de-list this thread.

Best wishes,
Antony.