Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I am using plainurl.bst style, Miktex 2.8, pdflatex to generate a pdf file. It gives explicitly the URL of my bib file. I would like to get this link attached to the title (i.e. embedded below the title) instead. Essentially the explicit url is most often too long and generate a bad box and if the URL changes the printed and pdf version does not change.

Opening plainurl.bst I find

% The following constants may be adjusted by hand, if desired

% The first set allow you to enable or disable certain functionality.
#1 'addeprints :=         % 0=no eprints; 1=include eprints
#1 'adddoiresolver :=     % 0=no DOI resolver; 1=include it
#1 'addpubmedresolver :=     % 0=no PUBMED resolver; 1=include it
#2 'hrefform :=           % 0=no crossrefs; 1=hypertex xrefs; 2=hyperref refs
#0 'inlinelinks :=       % 0=URLs explicit; 1=URLs attached to titles

I just don't know how to adjust by hand inlinelinks := 1. If I write 1 in the code above I get the message

:= 1 is an unknown function---line 72 of file plainurl.bst

I also tried in the tex file to write \bibliographystyle{plainurl}[inlinelinks :=1] not better.

So it is just a question of how and where I can adjust, I guess it was obvious for the code writer, but I did not find a documentation for it.

share|improve this question
4  
You should copy plainurl.bst under another name, say myplainurl.bst and change #0 'inlinelinks := into #1 'inlinelinks :=. Then call \bibliographystyle{myplainurl}; save the modified file in the same directory as your document. –  egreg Sep 6 '12 at 22:16
    
Perfect answer, thanks a lot @egreg. The question can be closed, ... I don't know how! –  c05772 Sep 6 '12 at 22:36
add comment

1 Answer 1

You should copy plainurl.bst under another name, say myplainurl.bst.

Change the line

#0 'inlinelinks :=

into

#1 'inlinelinks :=

Then call \bibliographystyle{myplainurl}; save the modified file in the same directory as your document.

The # tells that the following token is to be interpreted as an integer. More important is that the language used in .bst files is in reverse Polish notation, so

#0 'inlinelinks :=

means "set the variable inlinelinks to the integer value 0".

More information on the language is in "Tame the BeaST", available on TeX Live distribution by texdoc tamethebeast (the file is called ttb_en.bst).

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.