[]
Home response.text()) .then(data => new DOMParser().parseFromString(data, “text/html”)) .then(dom => dom.querySelector(“div.uos-sitemap”)) .then(sitemap => getBreadcrumbsFromSitemap(sitemap)) .catch(() => getBreadcrumbsFromPath()) .then(breadcrumbs => buildBreadcrumbsHtml(breadcrumbs)) function findElementToStartFrom(sitemap) { let element = sitemap.querySelector(“a[href='” + windowPath + “?’]”) || sitemap.querySelector(“a[href='” + windowPath + “‘]”) if (element) { return element } let pathParts = windowPath.split(“/”).filter(part => part !== ”) for(let i = pathParts.length; i >=1 ; i–) { let path = (‘/’ + pathParts.slice(0, i).join(‘/’)) let element = sitemap.querySelector(“a[href='” + path + “‘]”) || sitemap.querySelector(“a[href='” + path + “/index.page’]”) || sitemap.querySelector(“a[href='” + path + “?’]”) || sitemap.querySelector(“a[href='” + path + “/index.page?’]”) if (element) { return element } } throw new Error(“Can’t find starting element in sitemap”) } function getBreadcrumbsFromSitemap(sitemap) { let breadcrumbs = [] let element = findElementToStartFrom(sitemap); while (element) { breadcrumbs.push(makeBreadcrumb((new URL(element.href)).pathname, element.innerText.trim())) element = getParentLink(element) } let homeTitle = sitemap.querySelector(“h2”).innerText.trim() let homeUrl = sitemap.querySelector(“a”).href.trim() breadcrumbs.push(makeBreadcrumb((new URL(homeUrl).pathname), homeTitle)) return breadcrumbs.reverse() } function getBreadcrumbsFromPath() { console.log(“Building breadcrumbs from path”) let breadcrumbs = [] let pathParts = windowPath.split(“/”).filter(part => part !== ”) for(let i = 1; i char.toUpperCase()) breadcrumbs.push(makeBreadcrumb(url, title)) } return breadcrumbs } function makeBreadcrumb(url, name) { return {href: url.trim(), name: name.trim()} } function buildBreadcrumbsHtml(breadcrumbs) { let rootElement = document.querySelector(“#BreadcrumbListNavElem”) breadcrumbs.forEach(crumb => { if (crumb.href === windowPath) { return } let rootDiv = document.createElement(“div”) rootDiv.setAttribute(“typeof”, “ListItem”) rootDiv.setAttribute(“property”, “itemListElement”) rootDiv.setAttribute(“class”, “uos-breadcrumb-child”) let link = document.createElement(“a”) link.href = crumb.href link.setAttribute(“title”, crumb.name) link.setAttribute(“typeOf”, “WebPage”) link.setAttribute(“property”, “item”) let titleSpan = document.createElement(“span”) titleSpan.innerText = crumb.name rootDiv.appendChild(link) link.appendChild(titleSpan) rootElement.innerHTML += “>” rootElement.appendChild(rootDiv) }) } function getParentLink(element) { while (element.tagName !== “UL”) { element = element.parentElement if (!element) { return null } } return Array.from(element.parentElement.children).find(item => item.tagName === “A”) } ]]>

Published: 2024-07-11 15:11:00

Grid image of 10 people The ’Pioneers’

The University of Southampton’s India Centre has celebrated its fifth anniversary with a high-profile event to share the inspiring outcomes of a major research project.

This is the first time the personal stories of 10 highly influential South Asians have been recorded and archived, with the Pioneers project charting how each of them has significantly shaped modern Britain, ensuring that their legacies are not forgotten.

Watch the video below to hear more about the project.

The culmination of the first phase of this research project – along with the fifth anniversary of the university’s India Centre for Inclusive Growth and Sustainable Development – was celebrated at a colourful event at the Turner Sims concert hall on Wednesday 10 July. The celebrations coincide with the national South Asian Heritage Month which starts on Thursday 18 July.

Vice-Chancellor Professor Mark E. Smith said: “The University of Southampton has a long and much valued relationship with India. This research project will play an important role in giving the historical context, showing how these pioneers have influenced people and shaped Britain. This is a wonderful way to celebrate the fifth anniversary of the India Centre, which has grown so significantly.”

By admin