Hi Frank,

that was my first idea. But when you start to implement it like that, you very soon find out that you need a lot more modules. Then I stopped because my thought was: "Just for adding a simple param one needs to create a handful of modules? This is way too complicated! There must be a better way. " That's why I ask here. My hope is that someone says: "Hey, it's easy - just call method X in class Y and off you go". Or if Mr Someone decides to not say anything because it really is not possible in a fast/easy way, I hope that OXID will implement something like that in future releases.

Best regards,

Daniel Schlichtholz

Am 05.07.2013 16:02, schrieb Frank Zunderer:

Hi Daniel,

best practice i don't know, but maybe something like the following module
for search could be useful:

<?php
class addparam_search extends addparam_search_parent
{
     public function getAdditionalParams()
     {
         $sParams = parent::getAdditionalParams();
         return $this->_addSpecialParam( $sParams );
     }
     protected function _addPageNrParam( $sUrl, $iPage, $iLang = null )
     {
         $sUrl = parent::_addPageNrParam( $sUrl, $iPage, $iLang );
         return $this->_addSpecialParam( $sUrl );
     }
     protected function _addSpecialParam( $sUrl ){
         $sUrl .= "&amp;test=test";
         return ( $sUrl );
     }
}

Regards,
Frank Zunderer

Zunderer IT Beratung
Waldstr. 22
82205 Gilching

08105-777250
0173-8362768
it-berat...@zunderer.de




-----Ursprüngliche Nachricht-----
Von: dev-general-boun...@lists.oxidforge.org
[mailto:dev-general-boun...@lists.oxidforge.org] Im Auftrag von Daniel
Schlichtholz
Gesendet: Freitag, 5. Juli 2013 13:49
An: Oxid Dev-List
Betreff: [oxid-dev-general] Adding params to oxlocator

Hi list,

I need to add a param to all actions that are triggered via the locator-bar
on the search result page.
But since each sub part (Pagination, View, Products per page and
Sorting) does build the link target differently, I do break my ass to add a
param that is reflected in all generated link targets.

What is the best practice to do so?

--
Best regards,

Daniel Schlichtholz
Zu den Brauckstücken 5
58313 Herdecke

_______________________________________________
dev-general mailing list
dev-general@lists.oxidforge.org
http://dir.gmane.org/gmane.comp.php.oxid.general

_______________________________________________
dev-general mailing list
dev-general@lists.oxidforge.org
http://dir.gmane.org/gmane.comp.php.oxid.general

_______________________________________________
dev-general mailing list
dev-general@lists.oxidforge.org
http://dir.gmane.org/gmane.comp.php.oxid.general

Reply via email to