Share » Forums » Setup & design » eznode link rendering

eznode link rendering

eznode link rendering

Wednesday 01 February 2006 3:26:25 am - 4 replies

Author Message

Børge Warvik

Thursday 02 February 2006 2:21:18 am

I believe you have to use the .htaccess file and write a rewrite_rule.

Vjeran Vlahovic

Thursday 02 February 2006 4:07:36 am

Thanks Borge for your reply.

Yes, I have rewrite rule which assures that links without index.php work properly. But now I want ez to generate links without index.php suffix. Modifying templates (menus, links to content views, etc.) is an easy task - i just use ezroot operator instead of ezurl. But links to content that are generated through eznode protocol in ezxml datatype are handled somewhere deeply. Anyone who has a clue where?

http://www.netgen.hr/eng

Ciprian Popovici

Tuesday 09 May 2006 7:45:21 am

Override content/datatype/view/ezxmltags/link.tpl, ask for a copy of the original (not a blank file), then edit that template and bingo, you can customize all links inside XML blocks.

What you want is done by changing ezurl with ezroot, but you can think of more advanced uses, such as explicitly marking external links (that lead off-site).

Here's mine:

<a href={if eq($href|extract_left(1),'#')}{$href|ezurl}{else}"{$href|ezroot(no)}/"{/if}{section show=$id} id="{$id}"{/section}{section show=$title} title="{$title}"{/section}{section show=$target} target="{$target}"{/section}{section show=ne($classification|trim,'')} class="{$classification|wash}"{/section}>{$content}</a>

Also search the forums and docs for PathPrefix, it's worth it.

André R.

Tuesday 09 May 2006 1:51:02 pm

This can be done without modifing the template files.
Search for virtualhost mode on this forum for more info.

Among one of the things that could work is:

[SiteAccessSettings]
ForceVirtualHost=true

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu