(defun concord-images-encode-url-as-id (url)
(let (ret)
(cond
- ((string-match "^http://hng\\.chise\\.org/images/iiif/" url)
+ ((string-match "^http://\\(hng\\|image\\)\\.\\(chise\\.org\\|kanji\\.zinbun\\.kyoto-u\\.ac\\.jp\\)/images/iiif/" url)
(setq ret (substring url (match-end 0)))
(if (string-match "\\.[a-zA-Z0-9]+$" ret)
(substring ret 0 (match-beginning 0))
ret)
)
- ((string-match "^http://hng\\.chise\\.org/images/" url)
+ ((string-match "^http://\\(hng\\|image\\)\\.\\(chise\\.org\\|kanji\\.zinbun\\.kyoto-u\\.ac\\.jp\\)/images/" url)
(setq ret (substring url (match-end 0)))
(if (string-match "\\.[a-zA-Z0-9]+$" ret)
(substring ret 0 (match-beginning 0))