1
0
mirror of https://github.com/e107inc/e107.git synced 2025-07-31 11:50:30 +02:00

Tagwords: URL config refactoring

This commit is contained in:
secretr
2011-12-06 16:09:25 +00:00
parent 5324df60b2
commit a8ca3a1a43
4 changed files with 0 additions and 62 deletions

View File

@@ -1,33 +0,0 @@
<?php
/*
* Copyright e107 Inc e107.org, Licensed under GNU GPL (http://www.gnu.org/licenses/gpl.txt)
* $Id$
*
* eURL configuration script
*/
if (!defined('e107_INIT')) { exit; }
require_once(e_HANDLER.'news_class.php');
define('TAGWORDS_REWRITE', true);
function url_tagwords_main($parms = array())
{
//$base = e_HTTP.$sefbase.$parms['action'];
$base = e_HTTP.(e107::getPref('tagwords_sefbase') ? e107::getPref('tagwords_sefbase').'/' : 'tagwords/');
return $base.urlencode(varset($parms['q']));
}
function parse_url_tagwords_main($request)
{
$request = urldecode($request);
parse_str($request, $request);
if(isset($request['q']))
{
return array('q' => $request['q']);
}
return $request;
}

View File

@@ -1,5 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<urlprofile>
<title>{LAN_EURL_MODREWR_TITLE}</title>
<description>{LAN_EURL_MODREWR_DESCR}</description>
</urlprofile>

View File

@@ -1,24 +0,0 @@
<?php
/*
* Copyright e107 Inc e107.org, Licensed under GNU GPL (http://www.gnu.org/licenses/gpl.txt)
* $Id$
*
* eURL configuration script
*/
if (!defined('e107_INIT')) { exit; }
define('TAGWORDS_REWRITE', false);
function url_tagwords_main($parms = array())
{
$base = e_PLUGIN_ABS.'tagwords/tagwords.php';
if(isset($parms['q'])) return $base.'?q='.urlencode(varset($parms['q']));
return $base;
}
function parse_url_tagwords_main($request)
{
parse_str($request, $parsed);
return $parsed;
}