From 3a6ceba0de238b7cda9be632bf3032b6fda67ee1 Mon Sep 17 00:00:00 2001 From: Gilb's Date: Sat, 10 Dec 2016 22:06:40 +0100 Subject: Don't display button if not link is provided --- layouts/partials/scripts.html | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/layouts/partials/scripts.html b/layouts/partials/scripts.html index b2c5fa4..19b1fdf 100644 --- a/layouts/partials/scripts.html +++ b/layouts/partials/scripts.html @@ -306,7 +306,14 @@ this.$title.html( eldata.title ); this.$description.html( eldata.description ); - this.$href.attr( 'href', eldata.href ); + + if (eldata.href) { + this.$href.attr( 'href', eldata.href ); + this.$href.show(); + } + else { + this.$href.hide(); + } var self = this; @@ -427,4 +434,4 @@ $(function() { Grid.init(); }); - \ No newline at end of file + -- cgit v1.2.3