r is undefined
[Break on this error] if (r.errors !== null && frm) { modx.js (line 290)GAL.config.connector_url = '/url/here.html';
<script type="text/javascript">
Ext.onReady(function() {
GAL.config = {
"assetsUrl":"\/modx\/assets\/components\/gallery\/",
"cssUrl":"\/modx\/assets\/components\/gallery\/css\/",
"jsUrl":"\/modx\/assets\/components\/gallery\/js\/",
"imagesUrl":"\/modx\/assets\/components\/gallery\/images\/",
"connectorUrl":"http:\/\/www.mydomain.ch\/gallery-connector.html",
"corePath":"\/home\/httpd\/vhosts\/mydomain.ch\/subdomains\/sub\/httpdocs\/modx\/core\/components\/gallery\/",
"modelPath":"\/home\/httpd\/vhosts\/mydomain.ch\/subdomains\/sub\/httpdocs\/modx\/core\/components\/gallery\/model\/",
"chunksPath":"\/home\/httpd\/vhosts\/mydomain.ch\/subdomains\/sub\/httpdocs\/modx\/core\/components\/gallery\/elements\/chunks\/",
"pagesPath":"\/home\/httpd\/vhosts\/mydomain.ch\/subdomains\/sub\/httpdocs\/modx\/core\/components\/gallery\/elements\/pages\/",
"snippetsPath":"\/home\/httpd\/vhosts\/mydomain.ch\/subdomains\/sub\/httpdocs\/modx\/core\/components\/gallery\/elements\/snippets\/",
"processorsPath":"\/home\/httpd\/vhosts\/mydomain.ch\/subdomains\/sub\/httpdocs\/modx\/core\/components\/gallery\/processors\/",
"hooksPath":"\/home\/httpd\/vhosts\/mydomain.ch\/subdomains\/sub\/httpdocs\/modx\/core\/components\/gallery\/hooks\/",
"useCss":true,
"loadJQuery":true
};
GAL.config.connector_url = "http://www.mydomain.ch/gallery-connector.html";
GAL.request = {"a":"72"};
});
</script>
{"success":false,"message":"No action specified.","total":0,"data":[],"object":[]}It’s probably because you’re doing a cross-domain XHR (AJAX) request, which the browser wont let you do for security reasons. You’ll have to keep the connector in the same (sub)domain as the mgr.
I just did a test an moved gallery-connector.html back to the web context which is at sub.mydomain.ch/modx/ AND I can create new Albums now!!!!!!! So I guess gallery-connector has to be in web context. not in my custom context. Is that correct? I personally don’t really mind where it is.
What is the reason for gallery-connector?It acts as an AJAX gateway for the Gallery’s custom manager page UI.
Is this the URL where we can fetch json data for creating js Galleries? (If yes should the content type be json?)Yes and no; doing straight AJAX requests or fetches will require MODx session auth, so it’s a bit more complex than that, but theoretically, I’m sure you could.
You too!
Have a nice weekend
What is the reason for gallery-connector?It acts as an AJAX gateway for the Gallery’s custom manager page UI.

Why did you choose to use a document as Ajax connector instead of a file in the assets directory?
<div class="gal-item [[+cls]]">
<a href="[[+image]]" rel="fancybox">
<img class="[[+imgCls]]" src="[[+thumbnail]]" alt="[[+name]]" />
</a>
</div>[[!Gallery? &album=`Gallery`]]
&tag=`one of my tags`
and then I saved it then cleared the cache, to no avail. When I refreshed my gallery page, the images had disappeared, and they aren’t in the source. Is adding it to the chunk what i am supposed to do to achieve this?
[[!Gallery? &album=`Gallery` &thumbTpl=`myGalThumb`]]
By "it doesnt save the change", what do you mean? Do you mean the Resource isn’t saving? The tag code? Or the front-end output? Did you try clearing the cache? Is the tag correctly typed? Can I see the full tag?
Another problem i’m having is when i add theto my code, and save, it doesn’t save the change. Any suggestions?&tag=`one of my tags`