ez 3.10 urls and files accents

Author Message

Jean-Luc Nguyen

Tuesday 27 November 2007 1:40:16 am

Hello there,

I have just installed a clean version of ez 3.10, and we are developping a french website. French may contain accents, like "Traité de modélisation". When we are creating content with accents, the ezoperator ezurl should delete all accents (it was in 3.9), and ez 3.10 also creates bad files or images names on storage, like "Môn-produït-à véc-dès-accènts.jpg". Is it a bug for ez 3.10?

Thanks a lot for your help, ez rules!

http://www.acidre.com

Paul Leclercq

Tuesday 27 November 2007 8:59:25 am

No this isn't a bug for 3.10. ezurl will not get ride of the accents in a string.
All ezurl operator will do is check the various siteaccesses and find the which file it should use.

You can also specify 2 options to |ezurl('no', 'full')

'no' will get ride of the quotes surrounding your url and 'full' will specify the full url such as http://www.mydomaine.com/index.php/siteaccess/myurlalias

What you are suppose to do is

<a href={$node.url_alias|ezurl()}>my link</a>

here is the doc for ezurl:
http://ez.no/doc/ez_publish/technical_manual/3_10/reference/template_operators/urls/ezurl

This may be a little off the subject:
But In some obscure moment you may not be able to access the url_alias of your object and you will only get the string. Then this would be the code for your operator:

function convertToAlias($string){
include_once( 'kernel/classes/ezurlalias.php' );
$new_string = eZURLAlias::convertToAlias($string );
return $new_string;
}

And he is the documentation on how to create an operator:
http://ez.no/ezpublish/documentation/development/extensions/template_operator

Jean-Luc Nguyen

Thursday 29 November 2007 9:33:01 am

Yes I actually saw that, thanks a lot. When you are installing ez 3.10, after that, if you have unicode website but you wish to have standard urls like on 3.9, you have to add on site.ini:

[URLTranslator]
TransformationGroup=urlalias_compat

More info here: http://ez.no/doc/ez_publish/technical_manual/3_10/features/multi_language_support_for_url_aliases

I hope this will help!

http://www.acidre.com

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 18 2025 19:24:44
Script start
Timing: Jan 18 2025 19:24:44
Module start 'layout'
Timing: Jan 18 2025 19:24:44
Module start 'content'
Timing: Jan 18 2025 19:24:45
Module end 'content'
Timing: Jan 18 2025 19:24:45
Script end

Main resources:

Total runtime0.6407 sec
Peak memory usage4,096.0000 KB
Database Queries57

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0069 587.9141152.6250
Module start 'layout' 0.00690.0043 740.539139.4453
Module start 'content' 0.01130.6277 779.9844549.2266
Module end 'content' 0.63900.0016 1,329.210912.1641
Script end 0.6406  1,341.3750 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00390.6102160.0002
Check MTime0.00180.2833160.0001
Mysql Total
Database connection0.00070.104110.0007
Mysqli_queries0.578390.2614570.0101
Looping result0.00050.0836550.0000
Template Total0.604894.420.3024
Template load0.00220.340520.0011
Template processing0.602694.059120.3013
Template load and register function0.00010.015410.0001
states
state_id_array0.00210.325310.0021
state_identifier_array0.00120.182520.0006
Override
Cache load0.00180.2846320.0001
Sytem overhead
Fetch class attribute can translate value0.00090.137920.0004
Fetch class attribute name0.00130.209850.0003
XML
Image XML parsing0.00090.147020.0005
class_abstraction
Instantiating content class attribute0.00000.002260.0000
General
dbfile0.00090.1343210.0000
String conversion0.00000.001740.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
3content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
3content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
8content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
5content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1content/datatype/view/ezxmltags/literal.tpl<No override>extension/community/design/standard/templates/content/datatype/view/ezxmltags/literal.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 22
 Number of unique templates used: 7

Time used to render debug report: 0.0003 secs