<section class="form-wrapper social-hub-filter" id="hub">
<form>
<div class="form-group">
<label for="social-hub-menu">Choose a feed:</label>
<div>
<select class="form-control" id="social-hub-menu" name="social-hub-menu">
<option value="">-- Please choose --</option>
<option value="30973" selected>Official #DerbyUni</option>
<option value="49875">Union of Students</option>
<option value="68646">#DerbyUniSuccess</option>
<option value="68647">University life</option>
<option value="68464">#DerbyGrad</option>
<option value="67808">Business, Law and Social Sciences</option>
<option value="73879">Arts, Humanities and Education</option>
<option value="73882">Engineering and Technology</option>
<option value="73881">Health and Social Care</option>
<option value="73880">Life and Natural Sciences</option>
</select>
</div>
</div>
</form>
</section>
<!-- Stackla Widget Embed Code (start) -->
<section class="stackla-widget__container">
<div class="stackla-widget" data-alias="universityofderby.stackla.com" data-ct="" data-hash="596de4f0c51e9" data-id="26780" data-title="Main UoD channels social media" data-ttl="30"></div>
<script type="text/javascript">
(function(d, id) {
var t, el = d.scripts[d.scripts.length - 1].previousElementSibling;
if (el) el.dataset.initTimestamp = (new Date()).getTime();
if (d.getElementById(id)) return;
t = d.createElement('script');
t.src = '//assetscdn.stackla.com/media/js/widget/fluid-embed.js';
t.id = id;
(d.getElementsByTagName('head')[0] || d.getElementsByTagName('body')[0]).appendChild(t);
}(document, 'stackla-widget-js'));
</script>
<!-- Stackla Widget Embed Code (end) -->
<div class="spinner"></div>
</section>
<section class="form-wrapper social-hub-filter" id="hub">
<form>
{% include '@dropdown' with {
id: 'social-hub-menu',
name: 'social-hub-menu',
label: 'Choose a feed:',
ariaLabel: 'Choose a feed',
options : [
{
label: 'Official #DerbyUni',
value: '30973',
selected: true,
},
{
label: 'Union of Students',
value: '49875'
},
{
label: '#DerbyUniSuccess',
value: '68646'
},
{
label: 'University life',
value: '68647'
},
{
label: '#DerbyGrad',
value: '68464'
},
{
label: 'Business, Law and Social Sciences',
value: '67808'
},
{
label: 'Arts, Humanities and Education',
value: '73879'
},
{
label: 'Engineering and Technology',
value: '73882'
},
{
label: 'Health and Social Care',
value: '73881'
},
{
label: 'Life and Natural Sciences',
value: '73880'
},
]
} %}
</form>
</section>
<!-- Stackla Widget Embed Code (start) -->
<section class="stackla-widget__container">
<div class="stackla-widget" data-alias="universityofderby.stackla.com" data-ct="" data-hash="596de4f0c51e9" data-id="26780" data-title="Main UoD channels social media" data-ttl="30"></div>
<script type="text/javascript">
(function(d, id) {
var t, el = d.scripts[d.scripts.length - 1].previousElementSibling;
if (el) el.dataset.initTimestamp = (new Date()).getTime();
if (d.getElementById(id)) return;
t = d.createElement('script');
t.src = '//assetscdn.stackla.com/media/js/widget/fluid-embed.js';
t.id = id;
(d.getElementsByTagName('head')[0] || d.getElementsByTagName('body')[0]).appendChild(t);
}(document, 'stackla-widget-js'));
</script>
<!-- Stackla Widget Embed Code (end) -->
<div class="spinner"></div>
</section>
/* No context defined for this component. */
function getUrlParameter(name) {
name = name.replace(/[\[]/, '\\[').replace(/[\]]/, '\\]');
var regex = new RegExp('[\\?&]' + name + '=([^&#]*)');
var results = regex.exec(location.search);
return results === null ? '' : decodeURIComponent(results[1].replace(/\+/g, ' '));
};
window.widgetId = 26780; // manually added
$(document).ready(function() {
$('#social-hub-menu').on("change", function(){
var newFilter = $(this).val();
Stackla.WidgetManager.changeFilter(window.widgetId, newFilter);
});
});
$(window).on('load', function() {
var feedId = getUrlParameter('feed');
if (feedId) {
Stackla.WidgetManager.changeFilter(window.widgetId, feedId);
}
});
section.form-wrapper.social-hub-filter {
border: none !important;
padding: 0;
margin: 0;
margin-bottom: 4em;
}
section.stackla-widget__container {
position: relative;
min-height: 300px;
.spinner {
position: absolute;
left: 0;
right: 0;
top: 0;
}
}
There are no notes for this item.