InvalidArgumentException

  • ABPro Support
  • Topic Author
  • Offline
  • Moderator
  • Moderator
More
7 years 9 months ago - 7 years 7 months ago #14898 by ABPro Support
InvalidArgumentException was created by ABPro Support
## Fix below has been updated as of June 14/13
The June 30 releases of ABPro have the fix included
##

In Joomla 2.5.10 and 3.1.1 a new URI check was added that throws the exception 'InvalidArgumentException' and 'Invalid URI detected', if a URI has certain characters in it.

The main problem with their new 'fix' is that it throws an exception if it sees an apostrophe in the data passed with a URL.
If, for example, your customer enters a name with an apostrophe like O'Reilly, the validation call will trigger an exception in Joomla and die.
An apostrophe in a URL is not illegal. The JavaScript functions to encode a URI (encodeURIComponent and encodeURI) do not touch apostrophes so the only way to make the data acceptable to Joomla is to manually replace apostrophes.


The symptom can be an error reported or simply a block of the booking screen submit. Also Chrome and IE browsers are effected more that FF.

My initial examination of the issue seems to be that only the validation call prior to doing a submit is a problem.

A work around for that is to edit file:
\components\com_rsappt_pro2\script.js (for ABPro 2.x under Joomla 2.5.1x)
or
\components\com_rsappt_pro3\script.js (for ABPro 3.x under Joomla 3.1.x)

Around line 766 (ABPro 2) or 762 (ABPro 3)

Look for:
if(document.getElementById("recaptcha_challenge_field")!=null){
	data = data + "&recap_chal=" + document.getElementById("recaptcha_challenge_field").value;  
	data = data + "&recap_resp=" + document.getElementById("recaptcha_response_field").value;
}
		
data = data + "&browser=" + BrowserDetect.browser;

Add red code:
if(document.getElementById("recaptcha_challenge_field")!=null){
data = data + "&recap_chal=" + document.getElementById("recaptcha_challenge_field").value;
data = data + "&recap_resp=" + document.getElementById("recaptcha_response_field").value;
}

data = data + "&browser=" + BrowserDetect.browser;

data = data.replace(/'/g, "&rsquo;"); // <-- updated June 14


As this is a change to the client side JavaScript code, after you have uploaded the fix, you will need to refresh your browser to bring the new code in.

Current release if ABPro now contains the above fix.


## UPDATE ##
The Joomla 2.5.11/3.1.1 change causes problems for the mobile app as it sends lots of data as JSON objects which are delimited with ' so Joomla is blocking all the legitimate calls.
Updated versions of the mobile apps are now available to work under the new Joomla changes.


## UPDATE 2 May 30/13 ##
One customer found that having <strong> </strong> in a UDF to make it bold also caused the 'Invalid URI detected' error.
I have been unable to reproduce this but if you put the above fix in and still encounter 'Invalid URI detected', try un-publishing all UDFS then add them back one at a time until you find the one causing the error.
Last edit: 7 years 7 months ago by ABPro Support.
The following user(s) said Thank You: Frank Westerhout

Please Log in to join the conversation.

Time to create page: 0.072 seconds
Powered by Kunena Forum

Just thought I'd pass along some positive feedback from my client:
"All of us are excited about our new online booking!! Shanyn & Chelsea said it’s “fun”; even I’m getting the hang of it!  There are still a few glitches so we’re having another meeting on Tuesday - but all of us are thrilled!  Thank you! Thank you!"

The "glitches" they mentioned are all minor and I've tweaked a few settings and answered a few questions to address them. Overall they're very happy. "
Chris C


"Hi, im back 
 After using appbooking pro for 3 years successfully i have tried another booking system for a new site that was more expensive, promised a lot but full of errors and the developers wanted to suck the $$ for every little request.

Anyways, great to be back here "
roll82


"thanks for all the help you have given me over the past few months. We have managed to get the system to work so that multiple businesses around the country can log into our website and manage appointments for their own businesses through the ABPro System."

owen_molloy October 2013


Just thought I'd pass along some positive feedback from my client:
"All of us are excited about our new online booking!! Shanyn & Chelsea said it’s “fun”; even I’m getting the hang of it!  There are still a few glitches so we’re having another meeting on Tuesday - but all of us are thrilled!  Thank you! Thank you!"

The "glitches" they mentioned are all minor and I've tweaked a few settings and answered a few questions to address them. Overall they're very happy. "
Chris C


"Hi, im back 
 After using appbooking pro for 3 years successfully i have tried another booking system for a new site that was more expensive, promised a lot but full of errors and the developers wanted to suck the $$ for every little request.

Anyways, great to be back here "
roll82


"thanks for all the help you have given me over the past few months. We have managed to get the system to work so that multiple businesses around the country can log into our website and manage appointments for their own businesses through the ABPro System."

owen_molloy October 2013


Just thought I'd pass along some positive feedback from my client:
"All of us are excited about our new online booking!! Shanyn & Chelsea said it’s “fun”; even I’m getting the hang of it!  There are still a few glitches so we’re having another meeting on Tuesday - but all of us are thrilled!  Thank you! Thank you!"

The "glitches" they mentioned are all minor and I've tweaked a few settings and answered a few questions to address them. Overall they're very happy. "
Chris C


"Hi, im back 
 After using appbooking pro for 3 years successfully i have tried another booking system for a new site that was more expensive, promised a lot but full of errors and the developers wanted to suck the $$ for every little request.

Anyways, great to be back here "
roll82


"thanks for all the help you have given me over the past few months. We have managed to get the system to work so that multiple businesses around the country can log into our website and manage appointments for their own businesses through the ABPro System."

owen_molloy October 2013


Just thought I'd pass along some positive feedback from my client:
"All of us are excited about our new online booking!! Shanyn & Chelsea said it’s “fun”; even I’m getting the hang of it!  There are still a few glitches so we’re having another meeting on Tuesday - but all of us are thrilled!  Thank you! Thank you!"

The "glitches" they mentioned are all minor and I've tweaked a few settings and answered a few questions to address them. Overall they're very happy. "
Chris C


"Hi, im back 
 After using appbooking pro for 3 years successfully i have tried another booking system for a new site that was more expensive, promised a lot but full of errors and the developers wanted to suck the $$ for every little request.

Anyways, great to be back here "
roll82


"thanks for all the help you have given me over the past few months. We have managed to get the system to work so that multiple businesses around the country can log into our website and manage appointments for their own businesses through the ABPro System."

owen_molloy October 2013


Just thought I'd pass along some positive feedback from my client:
"All of us are excited about our new online booking!! Shanyn & Chelsea said it’s “fun”; even I’m getting the hang of it!  There are still a few glitches so we’re having another meeting on Tuesday - but all of us are thrilled!  Thank you! Thank you!"

The "glitches" they mentioned are all minor and I've tweaked a few settings and answered a few questions to address them. Overall they're very happy. "
Chris C


"Hi, im back 
 After using appbooking pro for 3 years successfully i have tried another booking system for a new site that was more expensive, promised a lot but full of errors and the developers wanted to suck the $$ for every little request.

Anyways, great to be back here "
roll82


"thanks for all the help you have given me over the past few months. We have managed to get the system to work so that multiple businesses around the country can log into our website and manage appointments for their own businesses through the ABPro System."

owen_molloy October 2013


Just thought I'd pass along some positive feedback from my client:
"All of us are excited about our new online booking!! Shanyn & Chelsea said it’s “fun”; even I’m getting the hang of it!  There are still a few glitches so we’re having another meeting on Tuesday - but all of us are thrilled!  Thank you! Thank you!"

The "glitches" they mentioned are all minor and I've tweaked a few settings and answered a few questions to address them. Overall they're very happy. "
Chris C


"Hi, im back 
 After using appbooking pro for 3 years successfully i have tried another booking system for a new site that was more expensive, promised a lot but full of errors and the developers wanted to suck the $$ for every little request.

Anyways, great to be back here "
roll82


"thanks for all the help you have given me over the past few months. We have managed to get the system to work so that multiple businesses around the country can log into our website and manage appointments for their own businesses through the ABPro System."

owen_molloy October 2013


Just thought I'd pass along some positive feedback from my client:
"All of us are excited about our new online booking!! Shanyn & Chelsea said it’s “fun”; even I’m getting the hang of it!  There are still a few glitches so we’re having another meeting on Tuesday - but all of us are thrilled!  Thank you! Thank you!"

The "glitches" they mentioned are all minor and I've tweaked a few settings and answered a few questions to address them. Overall they're very happy. "
Chris C


"Hi, im back 
 After using appbooking pro for 3 years successfully i have tried another booking system for a new site that was more expensive, promised a lot but full of errors and the developers wanted to suck the $$ for every little request.

Anyways, great to be back here "
roll82


"thanks for all the help you have given me over the past few months. We have managed to get the system to work so that multiple businesses around the country can log into our website and manage appointments for their own businesses through the ABPro System."

owen_molloy October 2013


Just thought I'd pass along some positive feedback from my client:
"All of us are excited about our new online booking!! Shanyn & Chelsea said it’s “fun”; even I’m getting the hang of it!  There are still a few glitches so we’re having another meeting on Tuesday - but all of us are thrilled!  Thank you! Thank you!"

The "glitches" they mentioned are all minor and I've tweaked a few settings and answered a few questions to address them. Overall they're very happy. "
Chris C


"Hi, im back 
 After using appbooking pro for 3 years successfully i have tried another booking system for a new site that was more expensive, promised a lot but full of errors and the developers wanted to suck the $$ for every little request.

Anyways, great to be back here "
roll82


"thanks for all the help you have given me over the past few months. We have managed to get the system to work so that multiple businesses around the country can log into our website and manage appointments for their own businesses through the ABPro System."

owen_molloy October 2013