Use prism for code syntax highlighting
This commit is contained in:
parent
356c9dca43
commit
adf3c67355
54 changed files with 471 additions and 324 deletions
|
@ -7,7 +7,7 @@ use: [posts]
|
|||
---
|
||||
Today, I realised that I hadn't published the code that I used to create the total figures of galleries and photos at the top of the gallery (I said at the end of [Part 2](/blog/create-better-photo-gallery-drupal-part-2/ "Create a Better Photo Gallery in Drupal - Part 2") that I'd include it in [Part 3](/blog/create-better-photo-gallery-drupal-part-3/ "Create a Better Photo Gallery in Drupal - Part 3"), but I forgot). So, here it is:
|
||||
|
||||
~~~php
|
||||
```language-php
|
||||
<?php
|
||||
|
||||
// Queries the database and returns a list of nids of published galleries.
|
||||
|
@ -51,6 +51,6 @@ else {
|
|||
}
|
||||
print '.';
|
||||
?>
|
||||
~~~
|
||||
```
|
||||
|
||||
It was applied to the view as a header which had the input format set to PHP code.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue