I have a text coming from a sql db that is not capitalized.
In my HTML, I usually apply CSS text-transform to capitalize the text, but now I face an issue:
I want this text to be part of the title of my site. However, I cannot style within the title.
How could I style the text, then grab it on PHP and then plug it into my title?
Here is what I tried which did not work:
<title>Shop - <p style="text-transform:capitalize;"><?php echo $row2['name'];?></p></title>
Thanks!
Use PHP functions ucfirst, ucwords, strtoupper depending on what you need.
ucfirst($row2['name']);