covcom / 205CDE

Developing the Modern Web
6 stars 24 forks source link

Multiple labs: worksheet code formatting #16

Closed JoseUusitalo closed 9 years ago

JoseUusitalo commented 9 years ago

These examples are from the Introduction to PHP worksheet.

Several worksheets have bad/nonexistent code formatting, like for example:

Printing out variable values using a non-interpreted string looks like this: print ' Values '.$number.' and '.$f_number.' ';

It would be much clearer if a PHP code block was used:

Printing out variable values using a non-interpreted string looks like this:

print 'Values '.$number.' and '.$f_number.'.';

It would also help the readability if Markdown inline code blocks were used elsewhere in the worksheets as well. Like for example here:

Examples: $str = "Writing PHP is cool"; $printed = "Values $number and $f_number"; $str2 = 'This is also a string';

Adding the language name at the start of a code block to add syntax highlighting would also be quite nice. At the moment none of the code blocks have syntax highlighting.

erja commented 9 years ago

Good point, I hope I found most of them.