Form in sidebar does not work - form in content page does

mweltin 19 Jun, 2009
"You are not allowed to access this URL"

Yeah, I'm getting the blasted above message. I've installed ChronoForms_V3.1_RC5.1.zip and mod_chronocontact J1.5 V1.0.zip on top of Joomla 1.5.10.

Test Server: http://www.n38w77.com

I created a form got it working and into a content page. To get it in the sidebar on every page I'm using Chronocontact.

Here's the problem(s):

The form in the content page (see: http://www.n38w77.com/form ) does not validate, but it does execpt the info, the captcha code and onSubmit will email the information to the designated address. I've also assigned email capabilities to a contect item and tested with not problems.

Now the form in the sidebar acts correctly regarding validation but I get ""You are not allowed to access this URL" in the landing page and no information is emailed on.

I'm at my witts end. I've searched in the forums and haven't quite found any solutions. Any help is appreciated. I'm trying to get this site online and live by early next week.

Best regards and thank you in advance for your help.

M a r g o t t W e l t i n
Washington DC
GreyHead 19 Jun, 2009
Hi Margott,

The validation error is a sneaky one - there is Javascript error called because the reset button field has no name. In the form html look for this line near the end
<input type="reset" value="Reset"/>
and add a name attribute
<input type="reset" value="Reset" name='reset' />
and validation should work again.

Submitting the sidebar form I see a PHP Fatal Error which I think is caused by a missing code line - see this post

Bob
mweltin 20 Jun, 2009
Thanks for the pointer. I added

global $mainframe;

just after line 29 in components/com_chronocontact/libraries/chronoform.php

No luck. The form still goes to a landing page that says "You are not allowed to access this URL" and information is emailed on.

Still scratching my head on this one. I guess i could place the code into each message and nest the div id and float left for the leftcolumn in that. But I have other modules to go in to that column as well.
GreyHead 20 Jun, 2009
Hi Margott,

I wonder if this has something go do with the SEF URLs. The "You are not allowed to access this URL" is shown when the form token isn't found in the session info. I suspect that the session info isn't linking up for some reason

Please try turning 'check Token' to Off in the form General tab and see if this cures the problem.

Bob
mweltin 20 Jun, 2009
Works perfectly now.

Thank you so much.

Margott
GreyHead 20 Jun, 2009
Hi Margott,

Great :-)

There is a small - but probably acceptable - security risk in turning the token off. It is possible that someone could hijack a session opened by someone else and submit some fake and potentially hazardous form contents. It' very unlikely that anyone would bother unless you have a particularly high-profile site - and even then the results should be filtered if you've used JRequest::getVar()

Bob
tokenring 04 Jul, 2009
I'm getting this error now too and I think it has to be due to one of the parameters above not being set right as these are the only things I have changed recently.

I've tried every combination (i think I have) of toggling SEF, Token and debug and I keep on seeing this in the landing page:

You are not allowed to access this URL directly, POST array is empty

or

You are not allowed to access this URL directly


?????
tokenring 05 Jul, 2009
okay I got it working again... and this is the combination of settings that I have to have in order to allow big uploads via the forms.

System - SEF = Disabled
ChronoForms handle my posted arrays: = YES
checkToken: = YES
Enable mambots? = YES


... some of those might not contribute to the error that we have been seeing, but these are the parameters that I was working with at the time of the error.

Aaron
Max_admin 06 Jul, 2009
Hi Aaron,

Thank you for posting this but the post is not related to big files uploads issues ? 🙂

Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
tokenring 07 Jul, 2009
I know... but I was seeing the same symptom "You are not allowed to access the url" ... and if two different scenarios can reproduce the same error, I think it is good to know about the condition that caused it. BTW, I get the same error on small uploads too.

:-)
This topic is locked and no more replies can be posted.