Observed this error when attempting to use the ajax interface to add content to a flexible panel: A javascript alert box pops up saying "An error occurred" then refuses to let me add anything to the panes. See attached "error.png"

The indispensable Firebug extension gives some more detail on what is happening:

uncaught exception: Security Error: Content at http://myhost/admin/panels/panel-page/home_panel/edit/content may not load data from http://myhost/panels/ajax/add-content/1/row_2_2.

This is apparently a conflict with Secure Pages, which I have configured to use https for everything under admin*.

Workaround: Added "panels/ajax*" to the list of paths that Secure Pages runs through SSL, et voila, I can add stuff to panes.

CommentFileSizeAuthor
error.png22.82 KBbuzzdecafe

Comments

gordon’s picture

Status: Active » Fixed

Make sure that in the setting page for secure pages the ignore pages contains "*/ajax/*"

This will make sure that the link is not redirected from http to https or vice versa.

Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.

rickmanelius’s picture

Version: 5.x-2.0-alpha13 » 7.x-3.x-dev
Status: Closed (fixed) » Active
Issue tags: +secure pages

It would be nice to add this into secure pages by default. Is there a way to transfer this over to the secure pages queue without adding a new tickets?

Letharion’s picture

Project: Panels » Secure Pages
Version: 7.x-3.x-dev » 7.x-1.x-dev
Issue tags: -secure pages

Yes, by updating the "Project" settings. Passing it over there now.

Please stop abusing the tags, and read the relevant instructions.
Please also remember to update the issue settings for the issue to whatever is relevant for you.

rickmanelius’s picture

Apologies for the abuse. I believe this is the first time I used the tags because it thought it might be more helpful to alert the secure pages folks.

Thanks for the help in accomplishing the goal.

rickmanelius’s picture

Title: Little conflict with Secure Pages module? » Update Secure Pages default parameters to ignore */ajax/* urls
grendzy’s picture

Status: Active » Closed (works as designed)

*/ajax/* was removed from the defaults when #1258200: Ignore requests with X-Requested-With:XMLHttpRequest landed.

rickmanelius’s picture

So is it a security risk to use */ajax/*?

I had to add this in as ubercart was not playing nice without it.

grendzy’s picture

Status: Closed (works as designed) » Postponed (maintainer needs more info)

No, it's not a security risk, but I'd like to understand why the XMLHttpRequest check isn't catching it. Can you see if the header is either not sent, or not detected?

rickmanelius’s picture

Status: Postponed (maintainer needs more info) » Closed (works as designed)

Seems like this was fixed in the later versions of ubercart. No more issues on my production, dev, or local sites.

rickmanelius’s picture

Status: Closed (works as designed) » Active

Nope. It's not working again with ubercart.

To recreate, simply go to checkout and then click the "My billing information is the same as my delivery information." You'll get a 503 error

An AJAX HTTP error occurred.
HTTP Result Code: 503
Debugging information follows.
Path: /system/ajax
StatusText: error
ResponseText:

grendzy’s picture

503 errors generally leave an entry in your apache error_log, can you post the error message here? Thanks.

rickmanelius’s picture

Status: Active » Closed (cannot reproduce)

Hi @grendzy. With ubercart 7.x-2.4 and patch #85 in #1373236: Allow multiple modules to react on checkout Ajax events, I no longer get this error. I'm setting this to "cannot reproduce" for now because it appears something fixed this glitch.

Note, I'm not 100% sure that the patch is necessary, but I'm listing it for completeness just in case it has some impact/influence on this issue.

rickmanelius’s picture

Status: Closed (cannot reproduce) » Active

Opening this thread up again as I discovered a new location where NOT having */ajax/* disables a feature. Basically with panels, I cannot add anything into a pane without this hack/tweak.

Off to debug...

astonvictor’s picture

Issue summary: View changes
Status: Active » Closed (outdated)

I'm closing it because the issue was created a long time ago without any further steps.

if you still need it then raise a new one.
thanks