PDA

View Full Version : placing search code using SSI



rogersjr
03-10-2005, 08:09 PM
Instead of going through each webpage and adding the code required to enable zoomsearch to Jump to match and highlight within document I am placing the code in a txt file and referencing it by placing the following code at the bottom of each webpage.




So as not to have to change each page's extension from html to shtml I have placed the following code in my htaccess file.



Options Indexes FollowSymLinks Includes
AddType application/x-httpd-cgi .cgi
AddType text/x-server-parsed-html .html

This enables zoomsearch to Jump to match and highlight within document which is a great feature. As I have also placed my stats code and part of my menu code in footer.txt I would like to reference the file from php pages. I realise that Jump to match and highlight within document will not work with php pages but wish the stats and menu sections to work from footer.txt.

Does anyone know if it is simply a matter of adding another line to the above code in the htaccess file so that php files will reference footer.txt? If so what code needs to be added?

Ray
03-11-2005, 05:39 AM
You can use the "Jump to match/highlight" JS files on a PHP page. You just need to output the <script> link etc. as part of the HTML output.

As for your footer, you would be better off using the PHP equivalent of a #include to perform the SSI on a PHP page. Consult the PHP documentation for the virtual() function:
http://www.php.net/manual/en/function.virtual.php

inspiron97
08-12-2010, 08:51 PM
Jump to match and highlight within a document will not work with my php pages while no problem with html pages.
example:
does not work!
http://localhost:2010/pmwiki.php?n=Unix.AIX?zoom_highlight=memory
works fine:
http://localhost:2010/unix_aix.html?zoom_highlight=memory (this is just the obove generated html stored in a file)

Any suggestions how I can jump and match with my php pages (by using pmwiki)? I did not understand your hint with the virtual() function.
Any virtual() function example available?

wrensoft
08-12-2010, 11:11 PM
You have posted in the V4 form and reopened a 5 year old post.

We no longer support V4 of the software.
Can you upgrade to V6 and see if you still have the problem. The highlighting script was almost totally written between V4 and V6.

The comment about virtual() above has nothing to do with the highlight script..

inspiron97
08-13-2010, 07:27 AM
Sorry, I posted my request into the wrong folder. I already have V6 and I still have the problem. I will post my same request in V6 Forum