Skip to content

Clean up unused code on Record and Search#133

Merged
liseli merged 2 commits into
mainfrom
ETT-1117_removeUnusedRefreshBranch
Mar 30, 2026
Merged

Clean up unused code on Record and Search#133
liseli merged 2 commits into
mainfrom
ETT-1117_removeUnusedRefreshBranch

Conversation

@liseli

@liseli liseli commented Mar 25, 2026

Copy link
Copy Markdown
Contributor

This PR removes unused scripts. While reviewing the Catalog documentation, Aaron came across this list of unused code.

I've tested these changes locally, and everything is working fine.

e.g.

http://localhost:8080/Record/100685952.marc
http://localhost:8080/Record/100685952/Cite

Once the tests are completed successfully in GitHub, we'll be all set to merge it.

@liseli liseli requested review from aelkiss and moseshll March 26, 2026 13:50

@moseshll moseshll left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Happy to see the XSL go bye-bye!

There is an additional issue in production that may be related to this, and probably makes sense to fix here:

I looked in a record page source and saw (this is up in the header)
<link rel="alternate" href="/Record/008694574.rdf" type="application/rdf+xml" >
and unfortunately that link goes to a page that just says Method rdf not recognized.

I think we've looked at this before, but only in passing.

The issue is:
./interface/themes/firebird/layout.tpl:48: <link rel="alternate" href="/Record/{$id|escape:"url"}.rdf" type="application/rdf+xml" >

I think we can just get rid of that line. @carylwyatt would probably agree... question mark?

@carylwyatt

Copy link
Copy Markdown
Member

The issue is:
./interface/themes/firebird/layout.tpl:48: <link rel="alternate" href="/Record/{$id|escape:"url"}.rdf" type="application/rdf+xml" >

I have no idea what rdf is 😂 My inclination is always to get rid of things, so go for it!

@aelkiss aelkiss left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very happy to see this all go.

<link rel="alternate" type="application/marc+xml" href="/Record/{$id|escape:"url"}.xml" >
<link rel="alternate" type="application/x-Research-Info-Systems" href="/Record/{$id|escape:"url"}.ris" >
<link rel="alternate" type="application/x-endnote-refer" href="/Record/{$id|escape:"url"}.endnote" >
<link rel="alternate" href="/Record/{$id|escape:"url"}.rdf" type="application/rdf+xml" >

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed this can go -- I don't think it will have worked at least since 2016 when the rdf function in SearchExport was commented out. The rdf.tpl that was referenced there was removed in 2021.

@liseli

liseli commented Mar 27, 2026

Copy link
Copy Markdown
Contributor Author

record page source an

FY: @moseshll and @carylwyatt, I've removed the RDF export, but the page still shows the message Method rdf not recognized Because in SearchExport.php (line 102), that exception is caught when the record method is undefined.

https://catalog.hathitrust.org/Record/008694574.rdf

@liseli liseli merged commit 5f24d87 into main Mar 30, 2026
2 checks passed
@liseli liseli deleted the ETT-1117_removeUnusedRefreshBranch branch March 30, 2026 16:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants