Expand my Community achievements bar.

Dive into Adobe Summit 2024! Explore curated list of AEM sessions & labs, register, connect with experts, ask questions, engage, and share insights. Don't miss the excitement.
SOLVED

Header content is not loading in AEM publish instance while accessing using IP and also not working in dispatcher

Avatar

Level 2

Hi Team,

 

I tried accessing the pages in Author environment and the page header and footer content is loading properly while loading the page .

http://localhost:4502/editor.html/content/we-retail/us/en.html

It is also loading properly in publish instance .

http://localhost:4503/editor.html/content/we-retail/us/en.html

 But the header and footer is not loading if I try accessing it through ip instead of localhost.

I faced this issue in my project then I tried for we-retail page and I can see the issue exists ther as well.

 

Can anyone help with this issue?

 

Thanks in advance.

 

 

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

I just tried on AEM 6.5 with below url and it worked fine-

http://<ipaddress>:4503/content/we-retail/us/en.html

 

Without loggin in its working fine with proper header and footer.

Try to see the logs.

View solution in original post

6 Replies

Avatar

Level 2
It was loading after I login to the url . I need to know how it can be loaded without login in dispatcher.

Avatar

Community Advisor

You need to remove editor mode as published page should be public and not in author mode. i.e. http://localhost:4503/content/we-retail/us/en.html

Try out and let me know if it works.

 

Thanks,

Diksha

Hi diksha_mishra ,

 

I have removed the editor in publish mode. It is working when I login to the publish instance and my question is when I open the publish instance with my ip address instead of localhost the page is loaded without headers.

 

I want to open the page by default without any login credentials.

Avatar

Employee

You need to configure your dispatcher to pass through the headers for a HTML page to be displayed correctly. HTML won't be parsed correctly by some browsers if the headers are incorrect.

This can be done by specifying the passthrough headers in the /clientheaders section. A sample configuration will look as below:

/clientheaders
{
   "referer"
   "user-agent"
   "authorization"
   "from"
   "content-type"
   "content-length"
   "accept-charset"
   "accept-encoding"
   "accept-language"
   "accept"
   "host"
   "cookie"
}

See https://docs.adobe.com/docs/en/dispatcher/disp-config.html for more details.

You will also need to setup the ModMimeUsePathInfo for your Apache web server as describer over here.

Dispatcher depends on the mod_mime Apache module to correctly identify the documents to cache. This is one of the minimum configuration that is required on the httpd server for correct functioning of the Dispatcher module.

A simple configuration to enable mod_mime will be as below:

<Directory />
   <IfModule disp_apache2.c>
      SetHandler dispatcher-handler
      ModMimeUsePathInfo On
   </IfModule>
</Directory>

Avatar

Correct answer by
Community Advisor

I just tried on AEM 6.5 with below url and it worked fine-

http://<ipaddress>:4503/content/we-retail/us/en.html

 

Without loggin in its working fine with proper header and footer.

Try to see the logs.

Avatar

Level 2

I am facing this issues in AEM 6.5 only. You can compare the headers before and after login.

After Login:

Before loggin.png

Before Login:

Before loggin.png