Fix for issue #19

Having to implement a checking for parameter "count" as %PAGES% returns amount of articles in results set, whereas %TOTALPAGES% returns total number ignoring count. Is an inline if statement good here, otherwise may need to switch it up into it's own if, or conjoin with the checking if count param is not equal to null.