/    Sign up×
Community /Pin to ProfileBookmark

Help with Javascript Form?

I have inherited a website for a client that features a custom-coded JavaScript form which customers use to make a family mediation referral. The user submits the form and then a ColdFusion script hosted on a Lucee server is called that generates a PDF and then emails this to the client, using MailGun. Nothing has been actively changed however the form has stopped working in the sense that a successful submission message is returned to the user however no PDF is generated.

The previous developer has provided the following advice as to how I can identify the error, however could someone clarify how I execute the first step he has suggested (creating a test URL string using PAW) as this isn’t something I’ve done before and want to make sure that I’m doing it correctly so I can rely on the output of PAW to be accurate.

His advice is as follows:

“Assuming nothing has been done to the Lucee server that generates the PDFs, I would start by tracing back to identify where the problem lies. I would manually create a test URL string that submits the form on referral.wyfms.co.uk and see what the output is, using the JS that’s in the HTML form submission code. You could use something like Paw to assist you with this if its something you’re not familiar with (https://paw.cloud).

That would be the first port of call as its injecting the homepage HTML into the ‘done’ message via Ajax upon the form submission, suggesting there’s an issue with the output of the form, and rather than showing an error its defaulting to forwarding to the homepage.

Given that the Lucee server has never fallen over before when there’s been no changes to it or the code its executing I suspect its something simple but I would try manual form submission first to try to pin down any error messages first. This would also ensure that no DNS or IIS changes have been made that make the Lucee server on referral.wyfms.co.uk not to function. Ideally you want to trigger a Lucee error to see that its active. These are a distinct mustard colour.

Another useful tool is Charles that acts as a web proxy to see what’s going on with Ajax scripts that are being executed and can decrypt SSL when configured correctly (https://www.charlesproxy.com), but try the above first.”

Any help would be much appreciated.

Thanks Jack

to post a comment
HTMLJavaScript

1 Comments(s)

Copy linkTweet thisAlerts:
@GHDSPORTSMay 06.2020 — Of all the hats JavaScript can wear, its form processing features are among the most sought and used. ... It is typically used to transfer data from an HTML form to the server. With JavaScript at your side, you can process simple forms without invoking the server.
×

Success!

Help @jackmattison spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 4.26,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,

tipper: @Samric24,
tipped: article
amount: 1000 SATS,
)...