Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> v2.3 RN Issues
Author Message
gopo
New Member
New Member



Joined: Dec 28, 2005
Posts: 12

PostPosted: Mon Dec 15, 2008 5:31 pm Reply with quote

Its a little something I/m having a hard time fixing. When you search for example "system" the results will only highlight the word system and not System (notice the capital letter), even though results are displayed with and without capital letter. It's not the exact query but to me system and System and SysTem are the same words...If anyone knows a fix for this.
thanx
 
View user's profile Send private message
Guardian2003
Site Admin



Joined: Aug 28, 2003
Posts: 6799
Location: Ha Noi, Viet Nam

PostPosted: Mon Dec 15, 2008 7:41 pm Reply with quote

Which 'search' function are you using? There is one for news, one for the forums.....
 
View user's profile Send private message Send e-mail
gopo







PostPosted: Mon Dec 15, 2008 9:37 pm Reply with quote

in downloads
try this [ Only registered users can see links on this board! Get registered or login! ] [ Only registered users can see links on this board! Get registered or login! ]
 
Palbin
Site Admin



Joined: Mar 30, 2006
Posts: 2583
Location: Pittsburgh, Pennsylvania

PostPosted: Mon Dec 15, 2008 9:59 pm Reply with quote

*** EDIT****

See below post for revised code. Embarassed


Last edited by Palbin on Tue Dec 16, 2008 7:59 pm; edited 1 time in total 
View user's profile Send private message
gopo







PostPosted: Tue Dec 16, 2008 6:46 pm Reply with quote

Palbin
Are you talking about index.php? These are the only files I have in RN2.30 /modules/Downloads/ ... index.php, d_config.php and voteinclude.php
Tryed with index.php but couldn't get it to work
 
Palbin







PostPosted: Tue Dec 16, 2008 7:43 pm Reply with quote

Maybe I over wrote the default download module in my base RN files. I will take a look and get back to you.
 
Palbin







PostPosted: Tue Dec 16, 2008 7:58 pm Reply with quote

Ok apperently I did over write the default module. See below for the correct changes. Embarassed

The following lines of code are in /modules/Downloads/index.php

Find line 1176:
Code:


$title3 = ereg_replace($query, "<b>$query</b>", $title3);

Replace with:
Code:


$title3 = ereg_replace("|$query|i", "<b>$query</b>", $title3);


Find lines 1199:
Code:


$title = ereg_replace($query, "<b>$query</b>", $title);

Replace with:
Code:


$title = ereg_replace("|$query|i", "<b>$query</b>", $title);



Find lines 1211:
Code:


$description = ereg_replace($query, "<font color=\"#CC0000\"><b>$query</b></font>", $description);

Replace with:
Code:


$description = ereg_replace("|$query|i", "<font color=\"#CC0000\"><b>$query</b></font>", $description);
 
Palbin







PostPosted: Tue Dec 16, 2008 8:00 pm Reply with quote

once again let me know if this works Very Happy
 
gopo







PostPosted: Tue Dec 16, 2008 9:28 pm Reply with quote

After changing the last line description is gone Smile magic
 
Palbin







PostPosted: Tue Dec 16, 2008 11:06 pm Reply with quote

Ok i'll have to try it myself and play with it.
 
Palbin







PostPosted: Tue Dec 16, 2008 11:16 pm Reply with quote

I am not sure when I will get to this because I need to setup a clean install. All the sites I have have NSN downloads on them.
 
gopo







PostPosted: Wed Dec 17, 2008 12:18 am Reply with quote

Okay no problem. Thanx for trying!
 
gopo







PostPosted: Sun Dec 21, 2008 3:36 am Reply with quote

... and the solution to my question is eregi_replace . This works!
 
Guardian2003







PostPosted: Sun Dec 21, 2008 5:20 am Reply with quote

gopo That sounds like it could be PHP version specific. Could you possible find out which version of PHP you are using.
 
Palbin







PostPosted: Sun Dec 21, 2008 10:58 am Reply with quote

eregi should work on php 4.x and 5.x
 
gopo







PostPosted: Sun Dec 21, 2008 11:04 am Reply with quote

PHP Version 4.4.6
 
Guardian2003







PostPosted: Sun Dec 21, 2008 11:20 am Reply with quote

Palbin wrote:
eregi should work on php 4.x and 5.x
yes and so should ereg_replace
I know eregi is case insenseitve not sure about ereg

Nice that the problem is solved anyhow Smile
 
Display posts from previous:       
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> v2.3 RN Issues

View next topic
View previous topic
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 vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©