Active
Project:
Short URL
Version:
6.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Reporter:
Created:
19 Oct 2009 at 19:09 UTC
Updated:
11 Jan 2012 at 10:44 UTC
integrate with the link by creating a formatter so when u create a new node with a field and u enter the link in the link_field there is automatically shortened and at the node display view it is shown the short url but at the edit-node-view it is shown the normal url.
some help:
http://manueg.okkernoot.net/blog/200907/how-create-cck-formatter
Other modules that use formatters for cck fields:
http://drupal.org/project/cck_formatters
http://drupal.org/project/textformatter
http://drupal.org/project/striptags_format
And the link at the link.module issue queue:
http://drupal.org/node/304412
It can be used for affiliation and many other thing.
Comments
Comment #1
summit commentedSubscribing, greetings, Martijn
Comment #2
interestingaftermath commentedYes, this is very important. Anyone interested in helping? How about for $$?
Comment #3
irakli commentedComment #4
deciphered commentedJust cause I'm nice I whipped up a really super quick formatter using the Custom Formatters module.
The formatter is for use with the Link module, but could easily be modified for CCKs standard Text fields.
Settings are:
Name: shorturl
Label: ShortURL
Editor Mode: Advanced
Field type(s): link
PHP:
Below is the exported result of that custom formatter, which can be included in a module (remembering to change mymodule to the name of the module):
Cheers,
Deciphered.
Comment #5
Rameez commentedHi Deciphered,
I did exactly what you said, but after enabling the custome made module, i don't find it anywhere to implement. How to make it work?
Thanks for your help :)
Comment #6
summit commentedHi Raiz, You have to add a .info file also.
greetings, Martijn
Comment #7
dqdComments like #2 are killing the community! Please prevent such offers here in the queues or take a look on the user profiles and the companies they work for. There you 'll find places to talk about such kind of cooperation.
For anyone who is interested in community contribution to get this issue solved together, we discuss this feature over here (#1295160: Options and tools to create Digg like site) to get it implemented regulary in future releases of link module.
Comment #8
summit commentedHi, I would love to have this add on in D7 for the link field!
EDIT: I tried it on my own, see: http://drupal.org/node/1379704#comment-5400646 but no go.
I do not see my new made formatter arise on the screen. The formatter is possible to choose within the link-field, but no go. Help please?
Greetings, Martijn
Comment #9
dqd@ Summit, I am not 100% sure if this is a custom formatter issue. Please retest and state the errors in code to help people by providing patches and to make clear if this is a link or a custom formatter issue. By the way, this is a Drupal 6 discussion here. Please let this issue keep staying on Drupal 6 link topic.
Thanks for understanding.
Comment #10
summit commentedHi, It wasn't a shorturl thingie, see: http://drupal.org/node/1379704#comment-5455156
Greetings, Martijn