e-card useless - URL tooooooo looooong! e-card useless - URL tooooooo looooong!
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

e-card useless - URL tooooooo looooong!

Started by Blueiris, December 23, 2005, 09:03:12 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Blueiris

Yikes! I sent myself an e-card from my gallery to test this feature, and the length of the URL nearly choked my e-mail program. Even though it wasn't set to wrap long lines, it had to wrap this over two.

QuoteTo view the ecard, copy and paste this url into your browser's address bar::
http://saddlebredworld.com/Gallery/displayecard.php?data=YTo5OntzOjI6InJuIjtzOjg6IkJsdWVpcmlzIjtzOjI6InNuIjtzOjE2OiJCbHVlaXJpcy
1HYWxsZXJ5IjtzOjI6InNlIjtzOjIxOiJibHVlaXJpc0Bnb2xkaXJpcy5jb20iO3M6MToicCI7czo3NjoiaHR0cDovL3NhZGRsZWJyZWR3b3JsZC5jb20vR
2FsbGVyeS9hbGJ1bXMvdXNlcnBpY3MvMTAwNjEvbm9ybWFsX3BlbmRhbnQxLmpwZyI7czoxOiJnIjtzOjE0OiJBbm90aGVyIEUtY2FyZCI7czox
OiJtIjtzOjEyOiJhbm9odGVyIGNhcmQiO3M6MzoicGlkIjtpOjE3O3M6MjoicHQiO3M6MTI6Ilhlbm8gUGVuZGFudCI7czoyOiJwYyI7czoxMDA6IkEg
cGVuZGFudCBmcm9tIHRoZSBYZW5vIEpld2VscnkgU2VyaWVzLiBTZXR0aW5nIGFuZCBiZWFkIHdlcmUgZGVzaWduZWQgaW4gdGhlIFhlbm9E
cmVhbSAzLUQgcHJvZ3JhbS4iO30%3D

Is this normal? Or is something wrong? If it's normal, is there any way to shorten up this URL?

Copying and pasting this mess into my browser to see the card was a royal pain, and I know my users will complain about this when I open the Gallery.

Edit: Wow, after putting that URL in a quote block, when I looked at my post it just ran right off the side of the page. To make it fit I had to break it up into SIX lines? C'mon guys, isn't this a little excessive?
You can lead a horse to water, but you can't make him drink - he's got to discover that it's wet for himself.

Nibbler

The ecard message itself is contained in the link.

Blueiris

#2
Oh, wow! Then if the message had been any longer than the three words I typed just for a test, the URL would have been even looonger??

Is this necessary, or is there another way? I like the e-card idea, and I know my users would too, but I also know that I wouldn't bother with copying and pasting lines and lines of URL, and most of my users wouldn't either.

Edit: OK, that's the way it is. I shouldn't be asking you if there's another way - I should go find it myself - yes? Is that OK to do? I know mods and hacks are OK, but re-writing a part of the code?

:D No guarantee I could do it, of course. I haven't tackled learning PHP yet. A few other languages, but not that.  I suppose this would be a good incentive to start. No doubt my hard drive will look like a junkyard of crashed installs of Coppermine while I experiment.  ;D But hey, I bought myself a 250 gig external for Christmas, so the virtual acreage for the junkyard's available. At least a virtual junkyard doesn't need zoning board approval! Something to keep me busy while I wait for the snow to melt . . .
You can lead a horse to water, but you can't make him drink - he's got to discover that it's wet for himself.

Nibbler

I'm sure it could be done better, maybe it will be in the next version. The reason you are getting the copy/paste thing is that your email client is showing you the plain text version of the ecard. If you set it to display html mails then you get to see the pic, and there is a clickable link. You can edit the code as much as you like, and mods are always welcome.

Blueiris

Quote from: Nibbler on December 24, 2005, 02:11:40 AM
I'm sure it could be done better

;D Probably not by me!!  ;D But I'll bumble around and hopefully learn something in the process. If I come up with something that works, I'll share, of course, and perhaps someone more expert than I will see a diamond in my rough code, and take it on for polishing.

I did think about the text vs. html after my last post, and tried that. Pegasus Mail doesn't display the html properly - no images.

You can lead a horse to water, but you can't make him drink - he's got to discover that it's wet for himself.

Tranz

Maybe if Coppermine could do what tinurl does and use a short url to reference the real url. It will have to be a random string so people can't guess other ecard entries. This module could even be handy for someone who wants a short link to a specific photo or category or whatever URL can get long.

Blueiris

Quote from: TranzNDance on December 24, 2005, 06:42:46 PM
It will have to be a random string so people can't guess other ecard entries.

Glad you brought that up! What I was thinking about when I roughed this out last nite would have been too easy to guess. Back to the drawing board!
You can lead a horse to water, but you can't make him drink - he's got to discover that it's wet for himself.