SEF_URLs plugin for cpg1.5.x - Page 6 SEF_URLs plugin for cpg1.5.x - Page 6
 

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

SEF_URLs plugin for cpg1.5.x

Started by Joachim Müller, March 26, 2007, 06:56:46 PM

Previous topic - Next topic

0 Members and 2 Guests are viewing this topic.

Αndré


tomvanhell

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

Αndré

Quote from: tomvanhell on October 28, 2010, 04:10:25 PM
bad plugin. database crashed. don.t works >:( >:( >:(
Maybe you've done something wrong?

poubao

Don't use CPG 1.5 plugin on <!--Coppermine Photo Gallery 1.4.25 (stable)-->
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

On latest svn codebase.php:

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

-Italian         maybe $str_tdm = '#top'; is better than $str_tdm = '#inalto';
Flapane
www.flapane.com

Gallery
www.gallery.flapane.com

flapane

#105
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
Flapane
www.flapane.com

Gallery
www.gallery.flapane.com

Αndré

Quote from: flapane on November 11, 2010, 12:53:32 PM
Any way to rewrite that "ù" so that it becomes a "u" in the link?
We have a transliteration database in cpg1.5.x:
require_once('include/transliteration.inc.php');
$str = transliteration_process($str, '_');

flapane

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

Thanks.
Flapane
www.flapane.com

Gallery
www.gallery.flapane.com

Αndré

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.

flapane

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
if ($sef_language == 'italian')
            {
            $urlname = str_replace('&#89','u',$urlname);
            }


Flapane
www.flapane.com

Gallery
www.gallery.flapane.com

flapane

...and same thing with %26#249%3B, which should be the CORRECT form.
Flapane
www.flapane.com

Gallery
www.gallery.flapane.com

Αndré

Quote from: flapane on November 11, 2010, 03:14:14 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.

flapane

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.

            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);
            }
Flapane
www.flapane.com

Gallery
www.gallery.flapane.com

Αndré

Feel free to change codebase.php to your needs, but I don't support individual issues for this plugin.
Quote from: Αndré on November 11, 2010, 02:53:10 PM
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.

flapane

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

Gallery
www.gallery.flapane.com

dance with dragon

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

drownedgod

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

Αndré

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:
<?php unlink('.htaccess'); ?>

profili

Quote from: Timos-Welt on June 05, 2010, 11:21:33 AM
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?

Αndré

Quote from: profili on January 05, 2011, 04:11:03 PM
How to enable the speaking URLs?
Please read the docs:
QuoteOpen codebase.php with a text editor and configure the plugin as you wish (lines 42-45) before installing it.
    // 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