Forum Moderators: not2easy
<div style="display: flex">
<div style="display: block; width: 29px; overflow: hidden; white-space:nowrap">Wednesday</div>
<div>, January 10, 2024</div>
</div> <?php echo "Date: ".date("m-d-Y"); ?>for Date: 01-10-2024 ?
numbers instead of words so it would be like "01-10-2024"That could be perilous, unless you're absolutely certain all users of the site live in the same region, using the same date format. Is it the tenth of January, or the first of October?
<span class = "abbrev">Thu</span><span class = "full">Thursday</span> 11 <span class = "abbrev">Jan</span><span class = "full">January</span> 2024
<div class="datestamp">
<span class="abbreviation">Wed</span><span>nesday</span>,
January 10, 2024
</div>
@media (max-width: 640px) {
.datestamp > span:not(.abbreviation) {
display: none;
}
}
csdude, are you just going to sit there munching popcorn while the rest of us get into it?
$weekdays = [
'Mon' => 'Monday',
'Tue' => 'Tuesday',
'Wed' => 'Wednesday',
...
];
// use date() to get a string like this
$date = 'Wed, January 10, 2024';
// result looks like this
// <span class='short'>Wed</span><span class='long'>Wednesday</span>, January 10, 2024
$newDate = preg_replace_callback('#^(...)#', function ($matches) {
global $weekdays;
return "<span class='short'>" . $matches[1] . "</span><span class='long'>" . $weekdays[$matches[1]] . "</span>";
}, $date); User: for cell (note, they meant "for sale")
Me (auto reply):
Thanks for reaching out! We do not check Facebook for messages, but you can email us at me@example.com
You can find the classifieds here:
www.example.com/classifieds
User: classifieds
User: Classifieds
User: for cell classifieds
User: for sell classifieds
User: for sale classifieds
User: google classifieds
User: google example classifieds