Closed (fixed)
Project:
Fasttoggle
Version:
master
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Reporter:
Created:
21 Jan 2007 at 05:32 UTC
Updated:
5 Feb 2007 at 16:02 UTC
I added node links which toggle published/sticky/promoted. the links appear on every node view. this is for exercising very fast editorial decisions, when reading a site. we will use this on groups.drupal.org.
I refactored the node_status() function so it worked for all node options.
great module!
| Comment | File | Size | Author |
|---|---|---|---|
| patch_187 | 3.43 KB | moshe weitzman |
Comments
Comment #1
kkaefer commentedThanks! Comitted to CVS with some modifications:
node_access()withuser_access()because these settings don’t depend on the user’s ability to update the node but on the “administer nodes” permissionComment #2
kkaefer commentedComment #3
moshe weitzman commentedclicking on a node link, i see the confirm form also calling theme('page') so I get a drupal page within a page. i will try to debug more.
note that you can avoid confirm form and still be safe from CSRF by using tokens on the links. i thought that info would be on http://drupal.org/node/89999 but it isn't.
thanks for committing this so fast.
Comment #4
moshe weitzman commentedi think the technique is just to check with drupal_valid_token() when you receive the request to toggle.
Comment #5
kkaefer commentedMoshe confirmed on IRC that the double page error was due to a cached script and that this error is now gone.
Comment #6
(not verified) commented