/[pliva-si]/inc/fix_msshit.inc
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Annotation of /inc/fix_msshit.inc

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (hide annotations)
Sun Jul 22 18:02:40 2001 UTC (22 years, 9 months ago) by dpavlin
Branch: MAIN
fix included html files

1 dpavlin 1.1 <?
2    
3     // decode all entities to iso8859-2
4    
5     function fix_msshit($s) {
6    
7     $s=str_replace('&#200;','È',$s);
8     $s=str_replace('&#232;','è',$s);
9     $s=str_replace('&#198;','Æ',$s);
10     $s=str_replace('&#230;','æ',$s);
11     $s=str_replace('&#208;','Ð',$s);
12     $s=str_replace('&#240;','ð',$s);
13     $s=str_replace('&#138;','Š',$s);
14     $s=str_replace('&Scaron;','Š',$s);
15     $s=str_replace('&#154;','š',$s);
16     $s=str_replace('&scaron;','š',$s);
17     $s=str_replace('&#142;','Ž',$s);
18     $s=str_replace('&#381;','Ž',$s);
19     $s=str_replace('&#158;','ž',$s);
20     $s=str_replace('&#382;','ž',$s);
21     $s=str_replace('&egrave;','è',$s);
22     $s=str_replace('&#269;','è',$s);;
23     $s=str_replace('&Egrave;','È',$s);
24     $s=str_replace('&#268;','È',$s);
25     $s=str_replace('&aelig;','æ',$s);
26     $s=str_replace('&#263;','æ',$s);
27     $s=str_replace('&AElig;','Æ',$s);
28     $s=str_replace('&#262;','Æ',$s);
29     $s=str_replace('&eth;','ð',$s);
30     $s=str_replace('&#273;','ð',$s);
31     $s=str_replace('&Eth;','Ð',$s);
32     $s=str_replace('&#133;','...',$s);
33     $s=str_replace('&#9;','\t',$s);
34     # $s=str_replace('&nbsp;',' ',$s);
35     # $s=str_replace('&amp;','&',$s);
36    
37     $s=strtr($s,'šðžèæŠÐŽÈÆ','¹ð¾èæ©Ð®ÈÆ'); # 1250 -> iso8859-2
38    
39     // remove paths from source
40     $s=str_replace('src="/data/pliva-si/','src="',$s);
41    
42     // nuke <html>
43     $s=ereg_replace('</*html>','',$s);
44    
45     return $s;
46     }
47    
48     ?>

  ViewVC Help
Powered by ViewVC 1.1.26