The Joomla! Forum ™



Forum rules


Forumregeln



Post new topic Reply to topic  [ 4 posts ] 
Author Message
 Post subject: JRouter für ein Module
PostPosted: Thu Nov 04, 2010 9:45 am 
Joomla! Apprentice
Joomla! Apprentice

Joined: Fri Jan 11, 2008 2:01 pm
Posts: 7
Hallo,

ich suche schon seit einiger Zeit nach einem Beispiel für die Nutzung des JRouter Objekts in einem Module. In meinem Module werden 12 Links wie folgt erzeugt "index.php?p=1" .... "index.php?p=12" . Wie muss ich das JRouter Objekt im Module implementieren damit meine URL statt p=1 inZukunft /1 .... /12 als Endung hat?

Gruss,
Albrechtino


Top
 Profile  
 
PostPosted: Fri Nov 05, 2010 10:29 am 
Joomla! Intern
Joomla! Intern

Joined: Sat Feb 06, 2010 10:20 am
Posts: 57
Don't touch the core!

Dafür schreibt man ein Plugin, Gruppe "system" für das Event onAfterRender. Für alles Weitere befrage die Suchmaschine deiner Wahl.

Arnd

_________________
Arnd Scharwächter
Chapter2 - The next chapter of design


Top
 Profile  
 
PostPosted: Tue Nov 23, 2010 5:17 pm 
Joomla! Apprentice
Joomla! Apprentice

Joined: Fri Jan 11, 2008 2:01 pm
Posts: 7
Quote:
Don't touch the core!

Dafür schreibt man ein Plugin, Gruppe "system" für das Event onAfterRender. Für alles Weitere befrage die Suchmaschine deiner Wahl.

Arnd


Dafür kann man kein Plugin schreiben da sichergestellt sein muss das attachBuildRule und attachParseRule nur von dem Module ausgeführt werden darf das diese Informationen liefert und wieder verarbeitet. Der Event onAfterRender ist viel zu spät das das vollständige Routing bereits erfolgt ist. Verwendet man in einem Plugin onAfterInitialize oder onAfterDispatch wird attachParseRule nicht aufgerufen da ja auch nicht bekannt ist wofür. (Mit Debugger getestet)

Es gibt nichts an Informationen im Internet zum bereits beschriebenen Problem.

Albrechtino


Top
 Profile  
 
PostPosted: Sat Feb 19, 2011 9:41 am 
User avatar
Joomla! Intern
Joomla! Intern

Joined: Sat Sep 03, 2005 5:10 am
Posts: 80
Location: Auckland, NZ
albrechtino wrote:
Quote:
Don't touch the core!

Dafür schreibt man ein Plugin, Gruppe "system" für das Event onAfterRender. Für alles Weitere befrage die Suchmaschine deiner Wahl.

Arnd


Dafür kann man kein Plugin schreiben da sichergestellt sein muss das attachBuildRule und attachParseRule nur von dem Module ausgeführt werden darf das diese Informationen liefert und wieder verarbeitet. Der Event onAfterRender ist viel zu spät das das vollständige Routing bereits erfolgt ist. Verwendet man in einem Plugin onAfterInitialize oder onAfterDispatch wird attachParseRule nicht aufgerufen da ja auch nicht bekannt ist wofür. (Mit Debugger getestet)

Es gibt nichts an Informationen im Internet zum bereits beschriebenen Problem.

Albrechtino


Hallo,

mit der obengenannten Methode kann man einfach die gesammte Web page auslesen und dann per Regular expression die Links entsprechend anpassen. Wir benutzten diese Methode weitlaeufig und zuverlaessig.

Hoffe das Hilft,

Jochen

_________________
http://www.automatem.co.nz - web applications, web 2.0 applications, custom web applications, software solutions, automation in business, automated web application, web database, Joomla web hosting, screen scrape, website backup, database backup


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 



Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB® Forum Software © phpBB Group