I have a PHP function:
function output_errors($errors) {
return '<ul><li>' . implode('</li><li>', $errors) . '</li></ul>';
}
But instead of <ul> and <li>s I wish to use jQuery to show errors:
$(function() {
$.pnotify({
title: 'Update Successful!',
text: '<p>Error text here!</p>',
});
});
I tried a lot of combinations but it doesn’t work.
What specifically doesnt work ? Just Simply implode with a comma :