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

How to remove date which gets display ...

Hello All,

I am using  <apex:inputfield id="dt" value="{!User.Date__c}" /> through which I am collecting the date from

use.While displayig the calendar I am also able to see the todays date which gets display just near to textbox 

how to remove that?





Thanks ,




Best Answer chosen by Admin (Salesforce Developers) 

.dateFormat{ display:none; }


All Answers

Since that is a standard SF control, it might be tricky to override it. Simplest approach might be to locate the "Today" button in the DOM and write a little CSS to hide in (display: none;)

if you prefer the controller code you can use this:->



 value.format('MMM dd, yyyy','GMT - 8:00');


where value = DateTime object.Like wise there are some more formats for DateTime.Please check in the Apex language reference


.dateFormat{ display:none; }


This was selected as the best answer

Thank you very much it worked !!!!!!!!!!