function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Feroz Khan.ax1229Feroz Khan.ax1229 

Showing date time in Apex:outputText

 

Hi All,

 

   Am tring to display the date time in the site visualforce pages using the <apex:outputtext>

             

<apex:outputText value="{0,date,M/d/yyyy hh:mm a}">
<apex:param value="{!event.Start_date_and_time__c}"/>
</apex:outputText>

 

in the developer mode its working fine.but in the external pages(means external site) time is differ.

 

Time Zone(GMT-05:00) Eastern Standard Time (America/New_York)

 

LocaleEnglish (United States)

 

company default timezone is also same.

 

in the admin port time is 1/20/2012 5:39 AM but in the external Site time is 1/20/1012 10:39 AM (+5 hours).

 

am using <apex:ouputField> also but no luck.

 

why its differ any one help.

bob_buzzardbob_buzzard

Is this for a public site - i.e. unauthenticated access?

Feroz Khan.ax1229Feroz Khan.ax1229

Hi Bob,

    Thanks for reply,

   

    Yes it is unauthenticated access public site.

 

   --

Regards

FerozKhan

bob_buzzardbob_buzzard

In that case I'd suspect the user record associated with the guest user profile.

 

To check this:

 

Navigate to the site setup page and click the 'Public Access Settings' page.  This will take you to the guest user profile.  At the top of that page is a button 'View Users'.  Click that and you'll see the single user in the list.  Click the user name and that will take you to the user record.  Halfway down on the lefthand side is the timezone setting.  

Feroz Khan.ax1229Feroz Khan.ax1229

 

Hi,

 

    Thanks for reply,

 

    i did but no luck,

 

company profile :

  

Default Time Zone(GMT-05:00) Eastern Standard Time (America/New_York)

 

Default LocaleEnglish (United States)

 

User profile:

 

Default Time Zone(GMT-05:00) Eastern Standard Time (America/New_York)

 

Default LocaleEnglish (United States)


no luck.

 

--

Regards:

FerozKhan

 

 

GlenSteinhardtGlenSteinhardt

I'm having the same issue occur...but in an authenticated site (linked to the Customer Portal)

 

Can you please explain what might be occurring?  I can see the date and time in developer mode, but when i log into the site, it does not display the date and time.

 

Thanks.

bob_buzzardbob_buzzard

Is the field in question available to the authenticated web site profile?