i created a small patch which allows to add a remove link, for example at a views table without extra theming

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

dawehner’s picture

added a remove/add field, which displays add to favourite if its not a favorite yet

dawehner’s picture

this is really working version!!

dawehner’s picture

some more features:
select wether to return to view or to userprofile

kbahey’s picture

Status: Active » Needs work

- "favouite" is mispelled and inconsistent.
- Patch does not apply on current DRUPAL-5 tag

Hunk #1 FAILED at 554.
Hunk #2 FAILED at 663.
2 out of 2 hunks FAILED -- saving rejects to file favorite_nodes.module.rej

itsGOTtobegroovy’s picture

No need for a patch or extra theming. Here's what to do:

For the My Favorites page, go to Views"
Add field Node:nid
Check the box for "Output this field as a link"
In the box, put: favorite_nodes/delete/[nid]
You can check the box "Rewrite output for this field" in order to create your own link text. I used "Remove from favorites"

I figured this out by hovering over the "remove from favorites" link in the node view to see what URL was generated.

itsGOTtobegroovy’s picture

Forgot to mention that favorite_nodes/delete/[nid] should go in the Link Path field

itsGOTtobegroovy’s picture

Status: Needs work » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.