| 1 |
Drupal Vote up/down Package:
|
| 2 |
---------------------------
|
| 3 |
Author - Fredrik Jonsson fredrik at combonet dot se
|
| 4 |
Requires - Drupal 5
|
| 5 |
License - GPL (see LICENSE)
|
| 6 |
|
| 7 |
|
| 8 |
Overview:
|
| 9 |
--------
|
| 10 |
This project is an attempt to build a digg.com/reddit.com clone.
|
| 11 |
There are voting widgets that mimic both, i.e. +1/-1 and +1 voting.
|
| 12 |
It builds upon a number of other module, se below.
|
| 13 |
|
| 14 |
AJAX functionality is used for voting if the browser supports it
|
| 15 |
(using drupal.js included in Druapl 4.7). Bookmarklets are supported
|
| 16 |
for quickly submitting new story links. A number of RSS feeds are
|
| 17 |
available.
|
| 18 |
|
| 19 |
This is not a point and click solution. This project provide the missing
|
| 20 |
pieces but you need to put them all together. Please try it out and
|
| 21 |
report back with bugs you find and suggestions you have.
|
| 22 |
|
| 23 |
|
| 24 |
Features and files:
|
| 25 |
------------------
|
| 26 |
List of the files and there function:
|
| 27 |
* vote_up_down.module - Provides voting widgets for nodes and comments.
|
| 28 |
* vote_storylink.module - Provides a node type suitable for links to storys.
|
| 29 |
* node-storylink.tpl.php - PHPTemplate theming of story links
|
| 30 |
* alternative/node-storylink.tpl.php - PHPTemplate theming of story links
|
| 31 |
* template.php - PHPTemplate theming of story links
|
| 32 |
* vote_up_down.css - Adds some css style to the above files.
|
| 33 |
* ajax_vote_up_down.js - JavaScript for AJAX functionality
|
| 34 |
|
| 35 |
The "vote_up_down.module" can be used on any node type to allow
|
| 36 |
users to vote +1/-1 on them.
|
| 37 |
|
| 38 |
The "vote_storylink.module" give a new node type that is well suited
|
| 39 |
for a digg.com/reddit.com style site. It provides two blocks.
|
| 40 |
* A user navigation block with links to, "submit new story", "my account",
|
| 41 |
"my posts" and "log out".
|
| 42 |
* A "Top story links" block with links to "this day", "this week",
|
| 43 |
"this month", "this year" and "all time".
|
| 44 |
|
| 45 |
Pages that are generated by "vote_up_down.module":
|
| 46 |
* admin/vote_up_down
|
| 47 |
* admin/vote_up_down/user_votes
|
| 48 |
* node/[nid]/votes
|
| 49 |
|
| 50 |
Pages that are generated by "vote_storylink.module":
|
| 51 |
* storylink (same as storylink/new)
|
| 52 |
* storylink/new
|
| 53 |
* storylink/queue
|
| 54 |
* storylink/top
|
| 55 |
* storylink/top/day
|
| 56 |
* storylink/top/week
|
| 57 |
* storylink/top/month
|
| 58 |
* storylink/top/year
|
| 59 |
* storylink/[uid] (all posts for a user)
|
| 60 |
|
| 61 |
Feed that are generated by "vote_storylink.module":
|
| 62 |
* storylink/new/feed
|
| 63 |
* storylink/queue/feed
|
| 64 |
* storylink/top/feed
|
| 65 |
* storylink/top/week/feed
|
| 66 |
* storylink/top/month/feed
|
| 67 |
* storylink/top/year/feed
|
| 68 |
* storylink/[uid]/feed
|
| 69 |
|
| 70 |
|
| 71 |
Installation and configuration:
|
| 72 |
------------------------------
|
| 73 |
See INSTALL.txt contributed by Ron Williams.
|
| 74 |
|
| 75 |
|
| 76 |
Theme story links:
|
| 77 |
-----------------
|
| 78 |
If you use a PHPTemplate theme you can theme story links nodes with a
|
| 79 |
"node-storylink.tpl.php" file.
|
| 80 |
|
| 81 |
An example "node-storylink.tpl.php" and "template.php" is included.
|
| 82 |
Place them in the folder of your theme. The examples are styled with the
|
| 83 |
css file "vote_up_down.css" in the vote_up_down module folder.
|
| 84 |
|
| 85 |
In "alternative" there are a "node-storylink.tpl.php" for use with the
|
| 86 |
"Alternative +1 vote style" (digg style) voting widget.
|
| 87 |
|
| 88 |
The example include these functions:
|
| 89 |
* Make the title an external link to the submitted story.
|
| 90 |
* Inserts the voting widget directly for greater control.
|
| 91 |
* Inserts the domain of the submitted story url like "(via example.com)".
|
| 92 |
* Displays a small user picture above the voting widget.
|
| 93 |
|
| 94 |
OBS! When using "node-storylink.tpl.php" you must turn off
|
| 95 |
"Vote widget display..." in "admin/settings/vote_up_down" to avoid
|
| 96 |
getting double voting widgets.
|
| 97 |
|
| 98 |
|
| 99 |
Bookmarklet to submit story links:
|
| 100 |
---------------------------------
|
| 101 |
javascript:location.href='http://www.example.com/node/add/storylink?edit[url]='+encodeURIComponent(location.href)+'&edit[title]='+encodeURIComponent(document.title)
|
| 102 |
|
| 103 |
Replace "www.example.com" with your domain.
|
| 104 |
|
| 105 |
|
| 106 |
Contributions:
|
| 107 |
-------------
|
| 108 |
* INSTALL.txt contributed by Ron Williams.
|
| 109 |
This has cut down on the support requst considerbly and
|
| 110 |
has made the package much more accessible for users.
|
| 111 |
|
| 112 |
* jQuery verision of ajax_vote_up_down.js by Nedjo Rogers.
|
| 113 |
The Drupal 5 version whould have taken a *lot* longer
|
| 114 |
if I have had to do this myself.
|
| 115 |
|
| 116 |
|
| 117 |
Last updated:
|
| 118 |
------------
|
| 119 |
$Id: README.txt,v 1.13 2007/02/17 10:19:06 frjo Exp $
|