I get the following message when trying to display an archive list of posts for a particular date:
Notice: Undefined offset: 2 in /Library/WebServer/Documents/wp-linda/wp-content/themes/portfolio-press/extensions/portfolio-helpers.php on line 154
I had a quick look at the code which is not checking the length of the $matches array returned and hence it can fail if the array has only one element.
I get the following message when trying to display an archive list of posts for a particular date:
Notice: Undefined offset: 2 in /Library/WebServer/Documents/wp-linda/wp-content/themes/portfolio-press/extensions/portfolio-helpers.php on line 154
I had a quick look at the code which is not checking the length of the $matches array returned and hence it can fail if the array has only one element.
Link: https://wordpress.org/support/topic/notice-undefined-offset-when-viewing-posts-archive
https://github.com/devinsays/portfolio-press/blob/master/extensions/portfolio-helpers.php#L152