Advanced search  

News:

cpg1.5.46 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter recently discovered vulnerabilities. It is important that all users who run version cpg1.5.44 or older update to this latest version as soon as possible.
[more]

Pages: 1 2 3 4 5 [6] 7 8 9 10 11   Go Down

Author Topic: SEF_URLs plugin for cpg1.5.x  (Read 134686 times)

0 Members and 1 Guest are viewing this topic.

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15415
Re: SEF_URLs plugin for cpg1.5.x
« Reply #100 on: September 22, 2010, 02:14:56 pm »

Added Swedish translation in r7926.
Logged

tomvanhell

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 29
    • Tomnatuurfotografie
Re: SEF_URLs plugin for cpg1.5.x
« Reply #101 on: October 28, 2010, 04:10:25 pm »

bad plugin. database crashed. don.t works >:( >:( >:(
Logged

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15415
Re: SEF_URLs plugin for cpg1.5.x
« Reply #102 on: October 28, 2010, 04:49:01 pm »

bad plugin. database crashed. don.t works >:( >:( >:(
Maybe you've done something wrong?
Logged

poubao

  • Contributor
  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 277
    • le pays lao jadis
Re: SEF_URLs plugin for cpg1.5.x
« Reply #103 on: October 28, 2010, 06:24:28 pm »

Don't use CPG 1.5 plugin on <!--Coppermine Photo Gallery 1.4.25 (stable)-->
Logged
L'incohérence de ceux qui nous dirigent, l'incompétence de ceux qui nous commandent,sont un vibrant hommage pour ceux qui exécutent.
                                          **Général Patton**

flapane

  • Contributor
  • Coppermine frequent poster
  • ***
  • Country: it
  • Offline Offline
  • Gender: Male
  • Posts: 249
    • Flavio's page
Re: SEF_URLs plugin for cpg1.5.x
« Reply #104 on: October 29, 2010, 10:55:08 pm »

On latest svn codebase.php:

-Italian:        $str_contact = 'contatto'    and not 'contacto'

-Italian         maybe $str_tdm = '#top'; is better than $str_tdm = '#inalto';

flapane

  • Contributor
  • Coppermine frequent poster
  • ***
  • Country: it
  • Offline Offline
  • Gender: Male
  • Posts: 249
    • Flavio's page
Re: SEF_URLs plugin for cpg1.5.x
« Reply #105 on: November 11, 2010, 12:53:32 pm »

Oh, another thing:

Let's say that a title of a photo contains an unicode character such as "ù", as in this photo (Piazza del Gesù): http://www.test.com/gallery/mostra-cerca-0-1-_Piazza_del_Ges_.html#top
Any way to rewrite that "ù" so that it becomes a "u" in the link?
http://www.test.com/gallery/mostra-cerca-0-1-_Piazza_del_Ges_.html#top  --> http://www.test.com/gallery/mostra-cerca-0-1-_Piazza_del_Gesu.html#top

The same should apply for "à è ò"...

Bye
« Last Edit: October 02, 2014, 09:34:37 pm by flapane »
Logged

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15415
Re: SEF_URLs plugin for cpg1.5.x
« Reply #106 on: November 11, 2010, 01:49:09 pm »

Any way to rewrite that "ù" so that it becomes a "u" in the link?
We have a transliteration database in cpg1.5.x:
Code: [Select]
require_once('include/transliteration.inc.php');
$str = transliteration_process($str, '_');
Logged

flapane

  • Contributor
  • Coppermine frequent poster
  • ***
  • Country: it
  • Offline Offline
  • Gender: Male
  • Posts: 249
    • Flavio's page
Re: SEF_URLs plugin for cpg1.5.x
« Reply #107 on: November 11, 2010, 02:40:54 pm »

So, if I got it well, the issue can't be handled by the plugin.

Thanks.

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15415
Re: SEF_URLs plugin for cpg1.5.x
« Reply #108 on: November 11, 2010, 02:53:10 pm »

No, it has to be changed in the plugin! I had a short look at codebase.php and found hardcoded umlauts replacement, which could also be handled by the transliteration library. Search the code for $urlname and try to change that lines if you know your way around. Otherwise you'll have to wait until someone fixes that issue.
Logged

flapane

  • Contributor
  • Coppermine frequent poster
  • ***
  • Country: it
  • Offline Offline
  • Gender: Male
  • Posts: 249
    • Flavio's page
Re: SEF_URLs plugin for cpg1.5.x
« Reply #109 on: November 11, 2010, 03:01:37 pm »

Oh, I tought that the transliteration function was hardcoded in the headers of the gallery itself.

I tried with &#249 and &#89, the two representations of the "ù", but nothing happend
Code: [Select]
if ($sef_language == 'italian')
            {
            $urlname = str_replace('&#89','u',$urlname);
            }

flapane

  • Contributor
  • Coppermine frequent poster
  • ***
  • Country: it
  • Offline Offline
  • Gender: Male
  • Posts: 249
    • Flavio's page
Re: SEF_URLs plugin for cpg1.5.x
« Reply #110 on: November 11, 2010, 03:14:14 pm »

...and same thing with
Code: [Select]
%26#249%3B, which should be the CORRECT form.

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15415
Re: SEF_URLs plugin for cpg1.5.x
« Reply #111 on: November 11, 2010, 03:53:57 pm »

which should be the CORRECT form
'ù' is the only correct form of 'ù' imo. The transliteration library only processes characters, but not entities. You have to decode them if they're encoded.
Logged

flapane

  • Contributor
  • Coppermine frequent poster
  • ***
  • Country: it
  • Offline Offline
  • Gender: Male
  • Posts: 249
    • Flavio's page
Re: SEF_URLs plugin for cpg1.5.x
« Reply #112 on: November 11, 2010, 03:57:55 pm »

Code: [Select]
if ($sef_language == 'italian')
            {
$urlname = str_replace('ù','u',$urlname);
            }

Still no results.
I used the html form of "ù" because I copied the german version of the str_replace function.

Code: [Select]
            if ($sef_language == 'german')
            {
              $urlname = str_replace('%C3%B6','oe',$urlname);
              $urlname = str_replace('%C3%BC','ue',$urlname);
              $urlname = str_replace('%C3%9F','ss',$urlname);
              $urlname = str_replace('%C3%A4','ae',$urlname);
              $urlname = str_replace('%C3%9C','Ue',$urlname);
              $urlname = str_replace('%C3%84','Ae',$urlname);
              $urlname = str_replace('%C3%96','Oe',$urlname);
            }

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15415
Re: SEF_URLs plugin for cpg1.5.x
« Reply #113 on: November 11, 2010, 04:04:22 pm »

Feel free to change codebase.php to your needs, but I don't support individual issues for this plugin.
if you know your way around. Otherwise you'll have to wait until someone fixes that issue.
I want to get rid of the hard-coded character replacement and use the transliteration library instead, that's why I replied to your question.
Logged

flapane

  • Contributor
  • Coppermine frequent poster
  • ***
  • Country: it
  • Offline Offline
  • Gender: Male
  • Posts: 249
    • Flavio's page
Re: SEF_URLs plugin for cpg1.5.x
« Reply #114 on: November 11, 2010, 04:12:45 pm »

I'll let you know in case the library will do the trick.
In this case, I'd delete theese hardcoded german letters.

dance with dragon

  • Coppermine newbie
  • Offline Offline
  • Posts: 4
    • Sexy Girls' Pictures
Re: SEF_URLs plugin for cpg1.5.x
« Reply #115 on: November 18, 2010, 02:10:07 am »

I have installed this plugin. It is very cool! Thanks and it's my web:http:www.diggers.tk Welcome!
Logged
Beautiful and sexy girls' pictures in http://www.youmeimei.tk

drownedgod

  • Coppermine newbie
  • Offline Offline
  • Gender: Male
  • Posts: 19
    • TV Screencaps
Re: SEF_URLs plugin for cpg1.5.x
« Reply #116 on: November 19, 2010, 04:17:57 am »

I have uninstalled this but i can't seem to find the .htaccess. now all my images are broken. what do i do?
Logged

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15415
Re: SEF_URLs plugin for cpg1.5.x
« Reply #117 on: November 19, 2010, 09:15:43 am »

The .htaccess file is in your gallery root directory. Some hosts don't list hidden files. In that case, ask your provider to remove that file or use a little php script that removes that file for you:
Code: [Select]
<?php unlink('.htaccess'); ?>
Logged

profili

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 113
Re: SEF_URLs plugin for cpg1.5.x
« Reply #118 on: January 05, 2011, 04:11:03 pm »

This a beta version!

New in version 2.0beta:
- Speaking URL functionality. This means that if you like, the picture title (or its filename if no title is given) will be included into the URL.

Open codebase.php with a text editor and configure the plugin as you wish (lines 42-45) before installing it.

Please note:
The previous versions of this plugin are not 100% stable, and this beta may be even more unstable. So please test carefully before installing this in a productive gallery.

Edit: Removed file, use latest SVN snapshout from first post instead

How to enable the speaking URLs?
Logged

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15415
Re: SEF_URLs plugin for cpg1.5.x
« Reply #119 on: January 05, 2011, 04:26:36 pm »

How to enable the speaking URLs?
Please read the docs:
Quote
Open codebase.php with a text editor and configure the plugin as you wish (lines 42-45) before installing it.
Code: [Select]
    // Configure here
    $sef_language              = 'english';  // set to english, german, french, italian or spanish
    $speakingpic_placeholder   = '-9b6o4';  // set to '' (empty string) to disable speaking URL functionality for files
    $speakingalbum_placeholder = '-65o4c';  // set to '' (empty string) to disable speaking URL functionality for albums
    $speakinguser_placeholder  = '-89occ';  // set to '' (empty string) to disable speaking URL functionality for users
    $number_of_url_chars       = 42;        // max number of chars in speaking URL functionality
Logged
Pages: 1 2 3 4 5 [6] 7 8 9 10 11   Go Up
 

Page created in 0.023 seconds with 20 queries.