I want to use the Quotes module for my web design site. So, whenever I use a quote (or testimonial in my case) I want to point people towards the website of the author. I couldn't find an inherent way to do this through the module as is, so I made this little patch to change the citation in a block (if it is a URL) into a link.

This patch works fine as is, but could be better. All it does now is change the citation when it's in a block. I dug around a little bit in the quotes.module file and I couldn't figure out how to change the citation every time that it is retrieved. If anyone knows how to do that, please post a new patch or something. It would be great for the citation to be a link in pages, blocks, etc.

Hope this is helpful for someone. Any suggestions or thoughts for making this better would be appreciated. Thanks.

Chris

CommentFileSizeAuthor
citation_link.patch924 bytescallison

Comments

callison’s picture

Version: master » 6.x-1.x-dev

Updated to correct version.

nancydru’s picture

Status: Needs review » Fixed

Thank you very much for the patch. In the end I did not, unfortunately, use it. I borrowed an idea we came up with on Web Links and added a setting to specify an input format (filter) that can be used for the author, citation, and bios fields that can be different from the node input format (which was being used on those fields too). You can set up a different filter that uses the URL Filter and/or allows the <a> tag. Note that it needs to also allow the <cite> tag for the citation.

Committed to 6.x-1.x-dev.

nancydru’s picture

Status: Fixed » Closed (fixed)

Included in 6.x-1.40

Anonymous’s picture

Really appreciate this functionality. Thanks!

Is there any way to get Views to render the <a href= in the citation or author fields of a page view instead of printing the code itself?

callison’s picture

Are you using 6.x-1.40 or the patch in the original post?

nancydru’s picture

BTW, IMHO, the best way to link back to a submittor's site is to use the RealName module and enable the "submitted by" line for Quotes (and/or the Submitted By module.

Anonymous’s picture

@callison 6.x-1.40

@NancyDru thanks will check those out - wouldn't have known they were 'solutions' unless you'd suggested them.

Anonymous’s picture

Status: Closed (fixed) » Active

@NancyDru - Have checked out those modules you recommended but they don't seem to do what I am after. Thanks anyway.

In Quotes: Author, Citation and Bio are checked to allow Full HTML.

A Views page will only comfortably display Body and Author. Adding 'Citation' as a field writes the full html of a linked URL on the page.

Site now running/upgraded to:

Quotes 6.x-1.40
Views 6.x-2.8
Drupal 6.15

Is this a Views issue or a Quotes one?

Thanks

ctmattice1’s picture

@Quartz: "Is this a Views issue or a Quotes one?"

This is a quotes thing. It has limited views functionality at present. I'll dig around some and see if we can make it more views friendly, might take me a while as I don't know views too well or use it unless it's required by a module.

Anonymous’s picture

ctmattice1

Thanks for clarifying and being willing to roll up your cuffs and get stuck in - I simply wouldn't know where to start.

I really like Quotes; and I use Views on almost all sites ;) (How do you get away from not using it? Do you code tpls?)

ctmattice1’s picture

@Quartz: :I really like Quotes; and I use Views on almost all sites ;) (How do you
get away from not using it? Do you code tpls?) "

Yep, but they can be a PITA getting right.

nancydru’s picture

Status: Active » Closed (won't fix)

The Views functionality is dated and largely a copy of what was in the 5.x version. For example, it does not recognize the newer author capability. This module exists because I don't use Views on very many of my sites - too much overhead. Personally, I think you'd be far better off using a custom theme template than Views for this.

Since I don't know Views very well either, I will have to mark this as "won't fix." I do go back and occasionally look at all so marked and decide if I can change my mind.