Hosam Hassan wrote:
> Hello Sergiu,
> 
> The $doc.displayTitle still removes the spaces from the title. As for the 
> 
> $doc.name.replaceAll('([a-z])([A-Z])', '$1 $2')
> 
> I get that exception when I execute it

That's a problem with the current backlink gathering mechanism. Try using:

$doc.name.replaceAll('([a-z])([AB-Z])', '$1 $2')

> Original Message:
> 
> Hosam Hassan wrote:
> <br />> Yes I know this already but for example if u want to create a new 
> page called
> <br />> 
> <br />> World cup
> <br />> 
> <br />> The page will be called worldcup
> <br />> 
> <br />> if u do a [$doc.name] Here the name of the link will be normal "World 
> Cup"
> <br />> 
> <br />> BUT if u do a $doc.name u will get worldcup.
> <br />> 
> <br />> My problem is i want to get the normal name of the page which is 
> displayed when u do a [$doc.name]
> <br />> 
> <br />
> <br />That is not the document name, but the document title. You can get it
> <br />with $doc.displayTitle
> <br />
> <br />If you want to camelcase the document name, you can use:
> <br />

-- 
Sergiu Dumitriu
http://purl.org/net/sergiu/
_______________________________________________
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users

Reply via email to