Page 1 of 1
Quicksearch/Suche: Color for border ?
Posted: Sun Mar 20, 2005 1:31 pm
by Marcel
I'd like to modify the color of the border around the input box of Quicksearch/Suche (in the side bars).
Can anybody tell me what item I have to modify/insert into my template's CSS file?
Thanks!
Re: Quicksearch/Suche: Color for border ?
Posted: Mon Mar 21, 2005 10:33 am
by garvinhicking
I need to know which Serendipity version you are using and if you are using the 'Livesearch' Event plugin. Then I can give you directions.
Regards,
Garvin
Posted: Mon Mar 21, 2005 4:30 pm
by Guest
Hi Garvin
I'm using 0.8-beta4 and the standard search plugin (which is installed by default)
Thanks for your help!
Marcel
Posted: Mon Mar 21, 2005 5:24 pm
by garvinhicking
Then edit your style.css and use this:
Code: Select all
#serendipityQuickSearchTermField {
border: 10px solid red;
}
Regards,
garvin
Posted: Wed Mar 23, 2005 11:46 am
by Guest
Thanks, Garvin!
Regards, Marcel
Posted: Wed Mar 23, 2005 11:49 am
by Marcel
The guest above was me, sorry!
Marcel
Posted: Tue Aug 23, 2005 6:17 am
by destraynor
Hi again,
Quick question, I am trying to get the serendipity livesearch working, but it doesn't display anything after saying "Waiting Sending Request". I have previously edited the look/feel of my input search box, and my question is Could that be the reason?
http://www.minds.may.ie/~dez/blog/
Thanks in advance.
Posted: Tue Aug 23, 2005 1:55 pm
by garvinhicking
Destraynor,
your problem seems to be that the search function fails. Please open your plugins/serendipity_event_livesearch/serendipity_event_livesearch.php plugin.
Search this code:
Code: Select all
case 'ls':
$res = serendipity_searchEntries($_REQUEST['s']);
if (is_array($res) && count($res) > 0) {
echo '<?xml version="1.0" encoding="utf-8" ?>';
echo '<div class="serendipity_livesearch_result">';
foreach($res AS $id => $entry) {
echo '<div class="serendipity_livesearch_row"><a href="' . serendipity_archiveURL($entry['id'], $entry['title'], 'baseURL', true, array('timestamp' => $entry['timestamp'])) . '">' . htmlspecialchars($entry['title']) . '</a></div>';
}
echo '</div>';
}
break;
and modify this to:
Code: Select all
case 'ls':
header('X-Search: ' . $_REQUEST['s']);
$res = serendipity_searchEntries($_REQUEST['s']);
echo '<?xml version="1.0" encoding="utf-8" ?>';
echo '<div class="serendipity_livesearch_result">';
if (is_array($res) && count($res) > 0) {
foreach($res AS $id => $entry) {
echo '<div class="serendipity_livesearch_row"><a href="' . serendipity_archiveURL($entry['id'], $entry['title'], 'baseURL', true, array('timestamp' => $entry['timestamp'])) . '">' . htmlspecialchars($entry['title']) . '</a></div>';
}
echo '</div>';
} else {
echo '<div class="serendipity_livesearch_row">' . print_r($res, true) . '</div>';
}
break;
That should give us important new results. You can check the new output by opening this URL:
Code: Select all
http://www.minds.may.ie/~dez/serendipity/index.php?/plugin/ls&s=coffee
Please tell us when you'Ve entered that so that I can have a look at it!
Regards,
Garvin
Posted: Tue Aug 23, 2005 3:54 pm
by destraynor
Hi Garvin,
I have done that, my new livesearch.php can be seen here...
http://www.minds.nuim.ie/~dez/serendipi ... earch.phps
(the s at the end is not a typo, its the only way you can see the file)
But for some reason, I amn't seeing anything here:
http://www.minds.may.ie/~dez/serendipit ... s&s=coffee
Garvin, you've been extremely helpful and patient with me so far so thanks.
If it seems like I am asking loads of questions, its because I am the
person responsible for making all the s9y blogs work on Planet Minds.
I'll be picking something off your wishlist for you soon.
Des
Posted: Tue Aug 23, 2005 4:12 pm
by garvinhicking
Hm, okay. It seems that the URL matching is not doing properly. Please modify the block again to read:
Code: Select all
case 'ls':
header('X-Search: ' . htmlspecialchars($eventData) . ' leads to ' . preg_replace('@[^a-z0-9 \.\-_]@i', '', $_REQUEST['s']));
$res = serendipity_searchEntries($_REQUEST['s']);
echo '<?xml version="1.0" encoding="utf-8" ?>';
echo '<div class="serendipity_livesearch_result">';
if (is_array($res) && count($res) > 0) {
foreach($res AS $id => $entry) {
echo '<div class="serendipity_livesearch_row"><a href="' . serendipity_archiveURL($entry['id'], $entry['title'], 'baseURL', true, array('timestamp' => $entry['timestamp'])) . '">' . htmlspecialchars($entry['title']) . '</a></div>';
}
} else {
echo '<div class="serendipity_livesearch_row">' . print_r($res, true) . '</div>';
}
echo '</div>';
break;
That will give me an additional HTTP header output I can use to debug what's going on!
You're not asking too much, so no problem here
Regards,
Garvin
Posted: Wed Aug 24, 2005 4:46 pm
by destraynor
Okay , I have modified the livesearch.php,
http://www.minds.may.ie/~dez/serendipit ... s&s=coffee
This still returns nothing however.
You can see the modified file here:
http://www.minds.nuim.ie/~dez/serendipi ... earch.phps
I'm pretty stumped, is it possible that this could be a permissions issue or something odd like that ?
Posted: Wed Aug 24, 2005 10:55 pm
by garvinhicking
I got the error!
Please download
http://svn.berlios.de/viewcvs/*checkout ... search.php and replace it with your file.
The change is to replace
Code: Select all
lsbase = "' . $serendipity['baseURL'] . ($serendipity['rewrite'] == 'none' ? $serendipity['indexFile'] . '?/' : '') . 'plugin/ls' . ($serendipity['rewrite'] == 'none' ? '&' : '?') . '";
with
Code: Select all
lsbase = "' . $serendipity['baseURL'] . ($serendipity['rewrite'] == 'none' ? $serendipity['indexFile'] . '?/' : '') . 'plugin/ls' . ($serendipity['rewrite'] == 'none' ? '_&' : '?') . '";
Note the "&" getting replaced to "&_". The error could occur like in your case when people are not using any URL rewriting.
HTH,
Garvin
Posted: Thu Aug 25, 2005 2:38 am
by destraynor
That worked perfectly,
Thanks a million Garvin.