Hi Jeff,

I'm working on a port of this module to Drupal 7, actually, it is on an advanced stage, and I expect to finish a kind of "beta release" in the next few days.

I'm really excited with that, and would be happy to become a co-maintainer of this module, helping to add new features and solving bugs.

Comments

jjeff’s picture

VERY exciting! I'd been hoping to update but wasn't sure when I'd have the time.

I've done most of the development and revision control of ShURLy through GitHub at https://github.com/Lullabot/shurly. In fact, due to my frustrations with CVS, not all of the latest changes are in the Drupal repository -- most notably the Safari extension (which shouldn't need to be upgraded for Drupal 7). We should probably continue to use GitHub until Drupal.org gets fully moved over to Git.

Are you Git-savvy?

lnunesbr’s picture

My GitHub user is lnunesbr, I'm already following you in there. But, anyway, is it possible to assign me as a co-maintainer of this module? I intend to request a CVS account here in d.o..

dave reid’s picture

/me works on a github fork that uses redirect.module as its base

lnunesbr’s picture

It's with a great satisfaction and happiness to inform that the drupal 7 port is ready for testing. For now it's available in Github (https://github.com/lnunesbr/shurly/tree/drupal-7).

It's just a initial release, and you may find some bugs, so feel free to report them and we can work together to build a stable release.

lnunesbr

alexweber’s picture

+1 I tested the module in a clean Drupal 7 install and it works as advertised, exactly the same as D6 version.

(I also forked the github project and submitted back a pull request for a php notice I found)

lnunesbr’s picture

Thanks alexweber for testing and improving.

sw3b’s picture

Oh yeah, it work great ! This is a nice replacement of Short Url with Drupal 7 ! I use it with Shorten URL in combination with Services links ! Work like a charm !

Nice work guys !

Visible Noise’s picture

Just tested this on a fresh install and works perfectly! Well done!

alexweber’s picture

This looks pretty solid, can we get a pull & official release? :)

capnjav’s picture

Not sure if anyone else is experiencing this. On a clean install of Drupal to a folder in the root directory, everything appears fine. Though when I shorten a link via /shurly (with a custom URL) I receive the following error:
* Notice: Undefined index: rate in shurly_rate_limit_allowed() (line 613 of /home/*/public_html/*/sites/all/modules/shurly/shurly.module).
* Notice: Undefined index: query in shurly_validate_long() (line 742 of /home/*/public_html/*/sites/all/modules/shurly/shurly.module).
* Notice: Undefined offset: 1 in shurly_validate_long() (line 748 of /home/*/public_html/*/sites/all/modules/shurly/shurly.module).
* Notice: Undefined index: q in shurly_validate_long() (line 751 of /home/*/public_html/*/sites/all/modules/shurly/shurly.module).
* Notice: Undefined index: path in shurly_validate_long() (line 756 of /home/*/public_html/*/sites/all/modules/shurly/shurly.module).

When I attempt without a custom URL I receive the following:
Notice: Undefined index: rate in shurly_rate_limit_allowed() (line 613 of /home/*/public_html/*/sites/all/modules/shurly/shurly.module).

(I replaced some of the folders names with a * for the sake of privacy)

capnjav’s picture

I should have noted that the link is created, I simply get the errors (no other problem).

-- In addition when I use the Shorten URLs module to create the link via /shorten and using the shurly service I do not receive the aforementioned error.

--- In the event it matters ~ contributed modules installed :
ctools 7.x-1.0-alpha2
views 7.x-3.0-alpha1
shorten 7.x-1.0
shurly (lnunesbr-shurly-361df16)



---- Update: Also occurs for regular users (with no custom URL):

Notice: Undefined index: rate in shurly_rate_limit_allowed() (line 613 of /home/*/public_html/*/sites/all/modules/shurly/shurly.module).



----- Update: With limits set via "admin/config/system/shurly" the "undefined index: rate" error does not occur.

Not sure if this is what resolved the other errors when "custom url" is used, but they are not appearing anymore. So that seems resolved also, hmm.



------ Update: The error received when using the custom URL only occurs when creating a shortened link to a link on the same domain... example:

long url: domain1.com/this-long-link/long.html
custom short: domain1.com/short1

Results in error:
* Notice: Undefined offset: 1 in shurly_validate_long() (line 748 of /home/*/public_html/*/sites/all/modules/shurly/shurly.module).
* Notice: Undefined index: q in shurly_validate_long() (line 751 of /home/*/public_html/*/sites/all/modules/shurly/shurly.module).
* Notice: Undefined index: path in shurly_validate_long() (line 756 of /home/*/public_html/*/sites/all/modules/shurly/shurly.module).



long url: domain2.com/this-long-link/long.html
custom short: domain1.com/short1

Does not result in error



The error is not repeated when using the Shorten module with the ShURLy service. Example:

long url: domain1.com/this-long-link/long.html
creates short: domain1.com/ZqU

capnjav’s picture

I also notice that when going to: "admin/build/shurly/settings" there are no options to set rate or any other settings for that matter. Instead it only displays all the URLs, with an option to search/filter them.

-- Update: it can now be found here: "admin/config/system/shurly"

maastrix’s picture

Any updates on the Drupal 7 port?

jeffwidman’s picture

subscribe

nigobo’s picture

subscribe

wizonesolutions’s picture

I grabbed this from GitHub and am going to give it a shot in the wild! Wish me luck!

macmladen’s picture

I used it on my Drupal 7 site: http:/dx.rs, version from Git by lnunesbr and it works as it should be.

Drupal has moved to Git and D7 is major version so please promote it to regular version on d.o.

I still didn't find any flaw but will report if anything is weird.

I think edit is needed option as I said on #1004560: Make ShURLy more use case non-specific: Add ability to edit, reactivate, and completely delete URLs and quite welcome QR code generation #961502: Add QR Codes with Mobile Codes, where analytics #1070706: Analyze where clicked? and #904506: Is it possible to have a different root for short urls? with option also to have custom shortening link would improve usability as branding tool. Maybe we ask too much but being flexible is all about Drupal, isn't it?

My suggestion on all these request is just to make them configurable with nice defaults.

This is fantastic module!

toxiclung’s picture

subscribe

wizonesolutions’s picture

Version: 6.x-1.0-rc2 » 6.x-1.x-dev
Status: Active » Reviewed & tested by the community

Oh, I never reported back on this. It worked fine. http://wiz1.us

I'd like to see lnunesbr's port get inducted at the D7 version of this module here...jjeff, are you up for giving him or me co-maintainer rights to do so? We interacted a bit in email and decided it was best to ask you, which I'm now finally doing!

lnunesbr’s picture

Thanks WizOneSolutions and MacMladen for the feedback.

I'll check the possibilities to implement some new goodies as suggested by macmladen, and also fell free to fork the github project to implement new features...

dddave’s picture

sub

Taxoman’s picture

Title: Drupal 7 port » D7 port of ShURLy

Subscribing

Carnix’s picture

I received this error:
Notice: Undefined index: rate in shurly_rate_limit_allowed() (line 613 of D:\Data\Projects\Drupal\ariba.com\sites\local.ari.ba\modules\shurly\shurly.module).

This was a mostly clean version of Acquia Drupal 7 running via the Destop Dev console. The only other module installed is the most recent Drupal 7 version of Views (7.x-3.0-rc1) using the most recent version from GitHub.

I have an additional requirement that isn't covered under any URL shortening that I need to include some additional metadata within the shortened URL for internal tracking and use. That tracking isn't part of the URL, but needs to be appended to the URL on redirect...

I'll probably use ShURLy as the basis for that though as it seems pretty solid. What I might actually do is write my additional functionality as a separate module that uses ShURLy as a requirement rather than hack my way through it.

capnjav’s picture

@Carnix, as per my resolution in comment #11 set limits via "admin/config/system/shurly" and the "undefined index: rate" should not occur.

Could you also test what happens if you try to create a custom shortened url for a url on the same domain as the shortener? For example:
domain1.com/this-url-is-long/super-long.html
with the custom url: domain1.com/ThiS

lnunesbr’s picture

just fixed "rate in shurly_rate_limit_allowed" notice, and also implemented configure link in modules overview page... now available in my github fork (comment #4).

lnunesbr’s picture

also fixed notices when trying to short a long URL that belongs to the same Shurly URL

capnjav’s picture

Thanks @lnunesbr, look forward to testing/implementing the updates. Your contribution is very much appreciated!

mattbanks’s picture

subscribing

lnunesbr’s picture

Status: Reviewed & tested by the community » Closed (fixed)

Hey folks,

shurly has now a D7 release here in drupal.org.

tregismoreira’s picture

Hey, guys. Great work on this port to D7 :)

But... I'm still receive the same 'shurly_rate_limit_allowed' error when I short link:

Notice: Undefined offset: 2 em shurly_rate_limit_allowed() (linha 625 de /Applications/XAMPP/xamppfiles/htdocs/mysite/sites/all/modules/contrib/shurly/shurly.module).

Anyone knows what's up?

mspirit’s picture

Issue summary: View changes

sub