1. Hack rewrite SEO URLs for XFields v.2.0

Hack rewrite SEO URLs for XFields v.2.0

  |   1
Hack rewrite SEO URLs for XFields v.2.0
This is the 2nd version of this hack, developed by Russian developer DomiTori. New hack named FxField (developed by Gameer) + changes by DomiTori. It has three functions: 1. Create SEO rules for xfields. 2. Improves the accuracy of the search for him. 3. Replace the word "xfsearch" with word "find" in the adress of site.

Lets go.

Datalife Engine files to modify

- .htaccess
- engine/engine.php
- engine/modules/show.short.php (Shortstory)
- engine/modules/show.full.php (Fullstory and relatednews)
- engine/modules/show.custom.php (Custom tag articles and search page on DLE 10.1 and newer)
- engine/modules/topnews.php (Top/Popular articles)
- engine/modules/search.php (Search page - DLE 10.0 and older only)

1. Open /engine/modules/show.short.php, /engine/modules/show.custom.php, /engine/modules/show.full.php (2 times!) and engine/modules/topnews.php (and engine/modules/search.php only if you use DLE 10.0 or older) and find

$value3[] = "<a href=\"" . $config['http_home_url'] . "xfsearch/" . urlencode( $value2 ) . "/\">" . $value2 . "</a>";

replace with

$value3[] = "<a href=\"" . $config['http_home_url'] . "find/" . $preg_safe_name . "/" . urlencode( $value2 ) . "/\">" . $value2 . "</a>";

2. Open /engine/engine.php and find

replace with
"find/" . urlencode($xn) . "/"

$xf = @$db->safesql

above paste

$xn = @$db->safesql ( htmlspecialchars ( strip_tags ( stripslashes ( trim ( $_REQUEST['xn'] ) ) ), ENT_QUOTES, $config['charset'] ) );

xfields LIKE '%{$xf}%'

replace with
SUBSTRING_INDEX( SUBSTRING_INDEX( xfields,  '{$xn}|', -1 ) ,  '||', 1 ) LIKE '%$xf%'

3. Open .htaccess and find

RewriteRule ^xfsearch/([^/]*)(/?)+$ index.php?do=xfsearch&xf=$1 [L]
RewriteRule ^xfsearch/([^/]*)/page/([0-9]+)(/?)+$ index.php?do=xfsearch&xf=$1&cstart=$2 [L]

replace with

RewriteRule ^find/([^/]*)/([^/]*)(/?)+$ index.php?do=xfsearch&xn=$1&xf=$2 [L]
RewriteRule ^find/([^/]*)/([^/]*)/page/([0-9]+)(/?)+$ index.php?do=xfsearch&xn=$1&xf=$2&cstart=$3 [L]

Thats all. You can also replace all words find/ in code with another word - sort/ or category/ .......
Dear visitor, you are browsing our website as Guest.
We strongly recommend you to register and login to view hidden contents.



Comments 1

Commented By onchannel on April 20, 2016 (10:15 am)
it seems to be an issue on a dle version 10.5 . I have the autoscroll script and on some of the pages it doesn't load to the next page. I guess it's somthing with the htaccess rules . i've tried other options but still can't make it work.



it shows me

http://site.com/find//Brad+Pitt/page/3/ ) wich is not loading

`Anyone have this issue?

How can it be fixed? or still it doesn't support mutiple pages
N/A 84Forum topics : 8Forum replies : 14Forum likes : 0

full movies
Information!Would you like to leave your comment? Please Login to your account to leave comments. Don't have an account? You can create a free account now.
DLEStarter Notice!Please note...Every hack and every module will get additional queries from your database and some hacks and some modules may result your server overload, so install only what you "need", remove any hacks and modules from your script when you don't need them, all hacks and modules appears in this website are not guaranteed by DLEStarter Team for your script security and compatibility, please read instruction carefully and use hacks and modules at your own risk...Thank you.