Ralf

Topic: Weird problem using live search with IE & google chrome

When I try to go to another page from my live search result page, the whole header & footer, including css is lost.

You can try at www.jobboard-deutschland.de when you type e.g. "vertrieb" (or just the first 3 characters), you will find the links to next pages. When you click on these pages-links the style is gone and the site looks really bad.

It works fine with FF 4.0.1
It doesn't work with IE 9.0.811...
It doesn't work with Chrome 12.0....

Anyone has the same problem? Anyone has a solution or idea?
Thanks, Ralf

New jobboard for germany: www.jobboard-deutschland.de it's getting better every day!
Thanks to everyone -specially within this forum- for supporting!

Ralf

Re: Weird problem using live search with IE & google chrome

one more hint: at the end of the url (e.g. page 2 from live search) the strange part is

search/home|ver/?p=6

where /home| stands for the page, where you started the live search  (and "ver" is the search word)

Why does it work in FF? Weird!

New jobboard for germany: www.jobboard-deutschland.de it's getting better every day!
Thanks to everyone -specially within this forum- for supporting!

Ralf

Re: Weird problem using live search with IE & google chrome

ok, maybe it's not clear enogh. "Links to the next pages" is the pagination part of the search.

Link to search result page 2 or 3 or 4.

Did someone have that problem before? I was sure I took the code from the standard template - and yes - when I switch back to the default template, I get the same bug.

Any help would be appreciated.
Thanks, Ralf

New jobboard for germany: www.jobboard-deutschland.de it's getting better every day!
Thanks to everyone -specially within this forum- for supporting!

hobo

Re: Weird problem using live search with IE & google chrome

May have something to do with the | in the url.
Little googling found this link, but I have not tried implementing it: http://www.poedit.net/trac/ticket/143

Ralf

Re: Weird problem using live search with IE & google chrome

Hi Hobo - it's 100% sure that | in the URL - removing it shows the site just fine - with the css and everything.

So you think this peace of code could help?

Code:
class mySmarty extends Smarty {
    function _get_auto_filename($auto_base, $auto_source = null, $auto_id = null)
    {
        $_compile_dir_sep =  $this->use_sub_dirs ? DIRECTORY_SEPARATOR : '^';
        $_return = $auto_base . DIRECTORY_SEPARATOR;

        if(isset($auto_id)) {
            // make auto_id safe for directory names
            $auto_id = str_replace('%7C',$_compile_dir_sep,(urlencode($auto_id)));
            // split into separate directories
            $_return .= $auto_id . $_compile_dir_sep;
        }

        if(isset($auto_source)) {
            // make source name safe for filename
            $_filename = urlencode(basename($auto_source));
            $_crc32 = sprintf('%08X', crc32($auto_source));
            // prepend %% to avoid name conflicts with
            // with $params['auto_id'] names
            $_crc32 = substr($_crc32, 0, 2) . $_compile_dir_sep .
                      substr($_crc32, 0, 3) . $_compile_dir_sep . $_crc32;

            // this is where the %% were.
            $_return .= '##' . $_crc32 . '##' . $_filename;
        }

        return $_return;
    }
}

$smarty = new mySmarty();

well - I first have to find out where to change what. I'll look into this as soon as I get a little more time to spend. I'll keep you updated.
Cheers, Ralf

New jobboard for germany: www.jobboard-deutschland.de it's getting better every day!
Thanks to everyone -specially within this forum- for supporting!

Ralf

Re: Weird problem using live search with IE & google chrome

I would appreciate help on this one. Not sure what I should implement here.

Thanks, Ralf

New jobboard for germany: www.jobboard-deutschland.de it's getting better every day!
Thanks to everyone -specially within this forum- for supporting!

Ralf

Re: Weird problem using live search with IE & google chrome

Please! Can someone help? The URL for page 2 should be
URL-of-your-site/search/vertrieb/sap/?p=2
but it is:
URL-of-your-site/search/vertrieb%7Csap/?p=2

it's working in Firefox and Safari thou! Not in IE and Chrome.

Where can I chage the %7C to a slash?

Is it a document description error? Is it wrong coding of source files? Anyone any idea?
(example is for searching "sap" on a category that is called vertrieb)

New jobboard for germany: www.jobboard-deutschland.de it's getting better every day!
Thanks to everyone -specially within this forum- for supporting!

dvtservices

Re: Weird problem using live search with IE & google chrome

if the folder contains any spaces it will work difeerenly in diff, browsers. please send me your URL we can fix the problem

Thanks &Regards
DV Tech Services Pvt Ltd
Email: venkat@dvtservices.com;   www.dvtservices.com  Bangalore. India
                             We are Ready to Resolve your problems ..... And Ready to work for you

Ralf

Re: Weird problem using live search with IE & google chrome

Oh sorry, I didn't see your reply. My URL is www.jobboard-deutschland.de and it works fine with FF. It doesn't work with IE and Chrome (all latest versions).
Thanks, Ralf

New jobboard for germany: www.jobboard-deutschland.de it's getting better every day!
Thanks to everyone -specially within this forum- for supporting!

dvtservices

Re: Weird problem using live search with IE & google chrome

I am not able to find any thing wrong with crome.
could you please send me scree shot

Thanks &Regards
DV Tech Services Pvt Ltd
Email: venkat@dvtservices.com;   www.dvtservices.com  Bangalore. India
                             We are Ready to Resolve your problems ..... And Ready to work for you

Ralf

Re: Weird problem using live search with IE & google chrome

Sorry, you can't reproduce on my site anymore thanks to putypuruty.

But I checked some of the sample sites. E.g. when you search a word where it has a 2nd page, like "job" on this site:
http://jobberies.com/

and go to the 2nd page - you see the problem:

Here is putypurutys solution for everyone:
_________________
Please open page_search.php and replace these lines

if ($id != '')
{
   $tmp = explode('|', $id);

with

if ($id != '')
{
   if (strstr($id, '%7C'))
   {
      $id = str_replace('%7C', '|', $id);
   }

   $tmp = explode('|', $id);
_________________

Thanks a lot for that!

New jobboard for germany: www.jobboard-deutschland.de it's getting better every day!
Thanks to everyone -specially within this forum- for supporting!

dvtservices

Re: Weird problem using live search with IE & google chrome

this is excellent solution we also fixed the problem with similar manner.

Thanks &Regards
DV Tech Services Pvt Ltd
Email: venkat@dvtservices.com;   www.dvtservices.com  Bangalore. India
                             We are Ready to Resolve your problems ..... And Ready to work for you