Whitter Posted April 27, 2015 Share Posted April 27, 2015 How to change "font size" in PHP? $print_username = "Username: $GetPlayerName"; $print_score = "Score: $GetPlayerScore"; $print_money = "Money: $GetPlayerMoney"; Font size is small, I want to make it bigger. Quote Link to comment Share on other sites More sharing options...
Solution Barand Posted April 27, 2015 Solution Share Posted April 27, 2015 (edited) You can't in PHP. You use CSS on the client. EG <html>> <head> <style type="text/css"> body { font-size: 24pt; } </style> </head> <body> <?php echo "Hello World";?> </body> </html> Edited April 27, 2015 by Barand Quote Link to comment Share on other sites More sharing options...
Whitter Posted April 27, 2015 Author Share Posted April 27, 2015 Thanks. Another thing, how can I do "outline" text in php? Quote Link to comment Share on other sites More sharing options...
Barand Posted April 27, 2015 Share Posted April 27, 2015 See my previous reply. AFAIK CSS doesn't support outline font-style so you may need to specify an outline font. Quote Link to comment Share on other sites More sharing options...
Psycho Posted April 27, 2015 Share Posted April 27, 2015 Yes, you can do outline font in CSS, although it won't be supported in all browsers: https://css-tricks.com/adding-stroke-to-web-text/ body { font-size: 24pt; -webkit-text-fill-color: #ffffff; -webkit-text-stroke-width: 1px; -webkit-text-stroke-color: #000000; } Quote Link to comment Share on other sites More sharing options...
Barand Posted April 27, 2015 Share Posted April 27, 2015 I'm guessing you could also do it using SVG text. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.