Use 'site-specific export' for local applications

Thank you for producing Zotero. I am a new convert.

I am wondering if this is possible:

https://www.zotero.org/support/kb/zotero_and_wikipedia says that it is possible to have Zotero export differently for different web sites.

What I'd like is to be able to get different exports for different local applications, or for different file types.

I use R Studio and other LaTeX editors, and create files that are markdown and LaTeX. It would be really helpful for Zotero to give me, say `\cite{Bloggs}` for a LaTeX file and `[@Bloggs]` for a MD file, or the LaTeX version when using TeXShop and the MD version when using RStudio.

Maybe it is as simple as I can't get the correct specification of file path for the applications? Or something more complicated...
  • edited January 12, 2015
    Almost certainly not possible, I'm afraid. Zotero can't detect where something is being dropped — all it can do is put different data formats on the clipboard, and that generally means just plain text and (sometimes) HTML. External applications can accept different kinds of data, but I believe those are OS-specific types, which is a different mechanism from the HTML 5 format mechanism that Mozilla/Zotero uses. So, say, a website could probably be made to accept BibTeX text from Zotero, but I'm not sure an external application could, since the external application would just accept the OS's generic text type, which would have the default output format in it. And in any case, since Zotero isn't aware of the target, for this to work at all Zotero would need to generate all possible formats when the drag began, which would be slow.

    One hack would be to create bookmarks for fake paths on your own domain (or a fake domain that points to 127.0.0.1 in /etc/hosts localhost) and assign site-specific formats to those paths, and then click the bookmark before triggering Quick Copy. (You could also probably use something like Zutilo to assign different shortcut keys to different formats.)
  • It is obvious when someone clever explains it to me!

    I've tried the Zutilo option, but is seems to only allow changing the keyboard short cuts for things it has already defined, and export formats is not one of those as far as I can see.

    I'm trying out the bookmarks option, which does sort of work already. I'm using it as an excuse to set up my own localhost server to serve a site that I can easily add pages for each format I want and to and put html in to remind me of why I put it there.

    Thanks very much for your help.
  • Oh, yeah, localhost probably works fine as the domain. No need for any /etc/hosts entries.
Sign In or Register to comment.