From be039f781fcfe9d8edfe880ba8c8b60cd48c742b Mon Sep 17 00:00:00 2001 From: "vincent@cubedesigners.com" Date: Thu, 4 Oct 2018 12:28:58 +0000 Subject: [PATCH] wip #2247 @0.25 --- inc/ws/Controlleur/class.ws.services.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/inc/ws/Controlleur/class.ws.services.php b/inc/ws/Controlleur/class.ws.services.php index 166f75029..5a9ea52a5 100644 --- a/inc/ws/Controlleur/class.ws.services.php +++ b/inc/ws/Controlleur/class.ws.services.php @@ -816,10 +816,14 @@ class wsServices extends cubeFlashGateway $r = $core->con->select('SELECT url FROM flfref WHERE ref="' . $core->con->escape($this->args['ref']) . '"'); if ($r->count()) { - header('Location: http://www.flf.fr' . $r->url . '?tkpub=ecatalogue-com-cata2018-170830&tkcmpg=&utm_source=ecatalogue&utm_medium=com&utm_campaign=cata2018&utm_term=170830&utm_content='); + if(strpos($r->url,'http')===0) { + header('Location: ' . $r->url); + }else{ + header('Location: https://www.flf.fr' . $r->url); + } exit; } - $q = 'site:http://www.flf.fr/formation-professionnelle/ "Code stage : ' . $this->args['ref'] . '"'; + $q = 'site:https://www.flf.fr/formation-professionnelle/ "Code stage : ' . $this->args['ref'] . '"'; header('Location: https://www.google.fr/search?q=' . urlencode($q) . '&ie=utf-8&oe=utf-8&btnI'); exit; } -- 2.39.5