Highlighted

Script not found : Custom Layout is not accessible without login on publisher

Avatar

Avatar

rahulpandey0102

Avatar

rahulpandey0102

rahulpandey0102

04-05-2018

Hello,

We have created a custom form layout and kept in /apps/myapp/layouts/ folder. we use this layout in our form template. when we are logged in @ publisher it works fine but if we try to access the page without login it shows Script not found exception for the custom layout - /libs/myapp/layouts/mylayout/mylayout.jsp is not found.

not able to find what is causing this issue. tried giving absolute path as well.

Replies

Highlighted

Avatar

Avatar

smacdonald2008

Total Posts

12.7K

Likes

1.4K

Correct Answer

2.3K

Avatar

smacdonald2008

Total Posts

12.7K

Likes

1.4K

Correct Answer

2.3K
smacdonald2008

04-05-2018

You Pub instance sounds like its configured as an Author - requiring login to access data.

Highlighted

Avatar

Avatar

rahulpandey0102

Avatar

rahulpandey0102

rahulpandey0102

04-05-2018

No, It works fine with all other components. Even If i change my forms layout resource type to the Out of the Box layout it works fine.

It is not finding the only layouts which are kept inside /apps.

Highlighted

Avatar

Avatar

smacdonald2008

Total Posts

12.7K

Likes

1.4K

Correct Answer

2.3K

Avatar

smacdonald2008

Total Posts

12.7K

Likes

1.4K

Correct Answer

2.3K
smacdonald2008

04-05-2018

Is that the only content under /apps that cannot be found.

Highlighted

Avatar

Avatar

rahulpandey0102

Avatar

rahulpandey0102

rahulpandey0102

04-05-2018

For Now I can say Yes. we are getting

Could not find script /libs/chassis/layouts/defaultGuideLayout/defaultGuideLayout.jsp

but the actual script is inside /apps .

tried giving absolute path as it was suggested in few help threads. but no luck.

Highlighted

Avatar

Avatar

Rima_Mittal

Avatar

Rima_Mittal

Rima_Mittal

04-05-2018

Quick question - Is it that your form template is referring to /apps/myapp/layouts/ and the error you see is '/libs/myapp/layouts/mylayout/mylayout.jsp not found'??

Highlighted

Avatar

Avatar

Rima_Mittal

Avatar

Rima_Mittal

Rima_Mittal

04-05-2018

Can you make sure the Apache Sling Resource Resolver Configuration is not modified and it refers to /apps before /libs?

Screen Shot 2018-05-04 at 2.39.08 PM.png

Highlighted

Avatar

Avatar

rahulpandey0102

Avatar

rahulpandey0102

rahulpandey0102

05-05-2018

No, We are using default configuration(which looks like same as you shared), even in our local we tried with fresh publisher instance but did not work.
Having doubt, if we have any limitation in overlaying or creating new defaultGuildeLayout. Can we create our own defaultGuildeLayout ?

As things are fine with other custom layouts, only this one is not working.