Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
bc68c4bc70 | ||
|
|
82279c376b | ||
|
|
8b096e770c | ||
|
|
6bf57bd4c6 | ||
|
|
ea55f3880e | ||
|
|
19e0ea60a7 | ||
|
|
7831d9dfb6 | ||
|
|
907db24187 | ||
|
|
5a424d5977 | ||
|
|
6c4353fffe | ||
|
|
fd1ec11ad1 | ||
|
|
9f89455b3c | ||
|
|
7d8e2e4fdd | ||
|
|
0aa4ae0b96 | ||
|
|
04620f2475 | ||
|
|
6cfb34ab22 | ||
|
|
e46af305a9 | ||
|
|
2fe00e5e96 | ||
|
|
2c7f9bd449 | ||
|
|
d1ee1eb4e1 | ||
|
|
f9dd7644cc | ||
|
|
3f94d86db4 | ||
|
|
9882234645 | ||
|
|
838f1a0678 | ||
|
|
c111b2beaf | ||
|
|
ebad7240cc | ||
|
|
8ed85a5fb4 | ||
|
|
3beaf71e16 | ||
|
|
38f1e838a5 | ||
|
|
0f4ec77ac0 | ||
|
|
28d079e83f | ||
|
|
5970f2a577 | ||
|
|
9dea1a40db | ||
|
|
dbe131633a | ||
|
|
277ce801e6 | ||
|
|
7e5e973d09 | ||
|
|
36fff814bf | ||
|
|
94cb7f7956 | ||
|
|
edbefc256b | ||
|
|
8af8e13686 | ||
|
|
3d2d3b9948 | ||
|
|
91f60763d8 | ||
|
|
54401165e8 | ||
|
|
b99efb8fc8 | ||
|
|
ad102421cb | ||
|
|
9be00683d9 | ||
|
|
e76f36a1be | ||
|
|
70b62a6c6a | ||
|
|
61b3fe4ebd | ||
|
|
30a93dbef7 | ||
|
|
b6956bd6fd | ||
|
|
7a4b7e23c5 | ||
|
|
b34a7610f5 | ||
|
|
cf680e43d8 | ||
|
|
3a311906bf | ||
|
|
d9789a636e | ||
|
|
cd8a9078d5 | ||
|
|
121d369ab8 | ||
|
|
1a0eb48b97 | ||
|
|
14e863930c | ||
|
|
6f5775381a | ||
|
|
ee9f85628d | ||
|
|
3000fc0b35 | ||
|
|
bab7fa1f39 | ||
|
|
9b8588df79 | ||
|
|
df97fa71a0 | ||
|
|
b9f1b4e170 | ||
|
|
d89acfd01d | ||
|
|
3ea7b8e03e | ||
|
|
59881232bf | ||
|
|
0575cdab18 | ||
|
|
7f6b5d1b58 | ||
|
|
f365e8abe1 | ||
|
|
b7edd3fa26 | ||
|
|
367a210996 | ||
|
|
e056323677 | ||
|
|
3ee82c38d5 | ||
|
|
c9e85d3159 | ||
|
|
d755a42530 | ||
|
|
674a7f3f57 | ||
|
|
f70df1fff2 | ||
|
|
2553e6464b | ||
|
|
746e04cf23 | ||
|
|
cecc163230 | ||
|
|
edef3b961a | ||
|
|
254583a135 | ||
|
|
08b8d1e3e2 | ||
|
|
c2a2a11be3 | ||
|
|
54abbddbe5 | ||
|
|
c6425adffc | ||
|
|
20f658ffbb | ||
|
|
ed957cf6b3 | ||
|
|
ce03af265e | ||
|
|
5ba87d9933 | ||
|
|
db32bcfc06 | ||
|
|
11038348a3 | ||
|
|
ac780beb2c | ||
|
|
4d4c781a8e | ||
|
|
85ace455da | ||
|
|
8e09983805 | ||
|
|
0991adb756 | ||
|
|
c1008c87a7 | ||
|
|
02e4ec4584 | ||
|
|
3e707708ec | ||
|
|
727eeb74fe | ||
|
|
ecc7690046 | ||
|
|
1f5e3e0daa | ||
|
|
b69720836b | ||
|
|
468cca81d1 | ||
|
|
5c866ae133 | ||
|
|
2401620dc6 | ||
|
|
2457b96f7d | ||
|
|
9655c53a3b | ||
|
|
3b382c0642 | ||
|
|
a4ffdb0316 | ||
|
|
08fc272f1b | ||
|
|
c23f6c0161 | ||
|
|
c1eab8e3c7 | ||
|
|
fbe30c7ad6 | ||
|
|
acc3ede87d | ||
|
|
a79def43c5 | ||
|
|
b5592b8466 | ||
|
|
cb327e902f | ||
|
|
2a9e72da41 | ||
|
|
e724ef7291 | ||
|
|
dfc2c110d6 | ||
|
|
32235cfd9d | ||
|
|
6457eded48 | ||
|
|
5cc41e8455 | ||
|
|
cb51396c80 | ||
|
|
2a6e2c0450 | ||
|
|
e22b4ec085 | ||
|
|
71efd5c97f | ||
|
|
b4a83c1969 | ||
|
|
ee35ce9839 | ||
|
|
7a8a4fe71d | ||
|
|
2e36c0a662 | ||
|
|
71b403bbe1 | ||
|
|
c5d22ace25 | ||
|
|
81671abd01 | ||
|
|
da1b302a34 | ||
|
|
3f7068541f | ||
|
|
2fdc93b3fd | ||
|
|
907dcd829a | ||
|
|
b2ef314960 | ||
|
|
6af75013d4 | ||
|
|
fd381a9a93 | ||
|
|
e29ea66e41 | ||
|
|
d7e218350c | ||
|
|
569dfb5502 | ||
|
|
a14689f66b | ||
|
|
ee702ff641 | ||
|
|
1a142e5250 | ||
|
|
c9a4697473 | ||
|
|
4b38d93aa9 | ||
|
|
5d2851de36 | ||
|
|
f6e6a73b4d | ||
|
|
3674acc4f1 | ||
|
|
ab5365423b | ||
|
|
e5aedd5cb1 | ||
|
|
60ea7fde8a | ||
|
|
7db9a33cef | ||
|
|
88c95375f0 | ||
|
|
d2785543b4 | ||
|
|
9df86d771e | ||
|
|
714d64afb6 | ||
|
|
f3abd57925 | ||
|
|
e9023340dd | ||
|
|
43f4b2c5fb | ||
|
|
cd72e1c06b | ||
|
|
92210edc16 | ||
|
|
5111f026e6 | ||
|
|
6327e2a5dc | ||
|
|
604f007a30 | ||
|
|
38596ca77f | ||
|
|
c0a2a13efe | ||
|
|
35c2bac898 | ||
|
|
fb3f11a93f | ||
|
|
8629b0418d | ||
|
|
af4e5ae9de | ||
|
|
1f951556fc | ||
|
|
87446cfcb3 | ||
|
|
943e9994c8 | ||
|
|
bd57ac57a5 | ||
|
|
db3519a559 | ||
|
|
33e9d1e1d0 | ||
|
|
32d09cff7d | ||
|
|
976c9d0f9b | ||
|
|
b261465599 | ||
|
|
67a0d97f60 | ||
|
|
5ebd5632c4 | ||
|
|
141c9f8986 | ||
|
|
dbb6ab7fdf | ||
|
|
8cf09955fc | ||
|
|
19cde16194 | ||
|
|
6a7659b59e | ||
|
|
31349a62b6 | ||
|
|
d8995d15f7 | ||
|
|
2f822d4ee4 | ||
|
|
02cfe7a453 | ||
|
|
8ea57846fa | ||
|
|
f704fd7ea4 | ||
|
|
bb3167d5c4 | ||
|
|
235f196152 | ||
|
|
adbc9b1a22 | ||
|
|
cd445a2acd | ||
|
|
210ee5285c | ||
|
|
644250f3f3 | ||
|
|
34c633ebb9 | ||
|
|
c5da8c4a5a | ||
|
|
6aeb32bf3f | ||
|
|
531817f553 | ||
|
|
80d72627b0 | ||
|
|
37e45d81be | ||
|
|
7324ab1060 | ||
|
|
2c866ef2bb | ||
|
|
9ed1ecfcb4 | ||
|
|
e93cc1c920 | ||
|
|
d77231ae1a | ||
|
|
5bd41ba2f4 | ||
|
|
b29af7898a | ||
|
|
03e129618d | ||
|
|
f0ae5ffeef | ||
|
|
a80e634776 | ||
|
|
96612f11e1 | ||
|
|
c465c860ca | ||
|
|
db1d1d26fc | ||
|
|
6a2cbbe075 | ||
|
|
7d132fdbfa | ||
|
|
0b66b11ae0 | ||
|
|
8566183f0d | ||
|
|
f755f96cb1 | ||
|
|
341f599840 | ||
|
|
c1842b0155 | ||
|
|
8bbf5bcc1c | ||
|
|
1febdfd7a8 | ||
|
|
481174b1d2 | ||
|
|
724a15866c | ||
|
|
f1c56fe70c | ||
|
|
e016679e67 | ||
|
|
5073f57167 | ||
|
|
e8dede3910 | ||
|
|
47433e4b42 | ||
|
|
0618fd53dc | ||
|
|
799e0ee367 | ||
|
|
c29dfab48f | ||
|
|
44fc7a257b | ||
|
|
dc8fbb05ef | ||
|
|
41ee457cc7 | ||
|
|
b14facc9dc | ||
|
|
6e24064711 | ||
|
|
66d2401494 | ||
|
|
93d0220517 | ||
|
|
311867f730 | ||
|
|
b38cbf8ae5 | ||
|
|
ba186254fd | ||
|
|
517e5d117b | ||
|
|
20302f8312 | ||
|
|
b5ccb5448b | ||
|
|
7d3b6d12c0 | ||
|
|
fc2fb92d7b | ||
|
|
795b5bdf55 | ||
|
|
e2aec15879 | ||
|
|
3741c53e8b | ||
|
|
5b6d99a126 | ||
|
|
688bc53da9 | ||
|
|
b456c0feae | ||
|
|
69e068f80b | ||
|
|
d11f67ba2e | ||
|
|
921fa1ec08 | ||
|
|
0a4a9e3f47 | ||
|
|
5cf2074338 | ||
|
|
0bad4aa1c0 | ||
|
|
dfd0c5f758 | ||
|
|
0bf1f545c1 | ||
|
|
85d00b6aca | ||
|
|
b90672ae0e | ||
|
|
ccd04e73b1 | ||
|
|
5321ce17d4 | ||
|
|
9337c6d7aa | ||
|
|
3b0744dcd3 | ||
|
|
36e88a6a2d | ||
|
|
58902f97c4 | ||
|
|
e1ef69a0c4 | ||
|
|
46fa0f3cd0 | ||
|
|
1d3edaf62e | ||
|
|
adeb007cb0 | ||
|
|
45e6bcf26f | ||
|
|
5ba1a602fe | ||
|
|
7d4d645935 | ||
|
|
23f56520e2 | ||
|
|
ee8e184c10 | ||
|
|
db83fba992 | ||
|
|
c103b9e6f3 | ||
|
|
a757c437e2 | ||
|
|
49a07c4ea0 | ||
|
|
41a2f6803d | ||
|
|
d7e3d03c73 | ||
|
|
4c999721bb | ||
|
|
f5ad535387 | ||
|
|
f79ca0f232 | ||
|
|
8da71f60ed | ||
|
|
ecd4a337ff | ||
|
|
04d8d9b704 | ||
|
|
01bc89dd04 | ||
|
|
4d619286c3 | ||
|
|
22a3c1c4db | ||
|
|
b61dced93b | ||
|
|
346a049c18 | ||
|
|
bc65502fe9 | ||
|
|
aa1c155123 | ||
|
|
b2bfe11743 | ||
|
|
164944dd0c | ||
|
|
9356fdfaa8 | ||
|
|
27cd6e6e5b | ||
|
|
f74e8f7250 | ||
|
|
aa140eb846 | ||
|
|
54aa905699 | ||
|
|
2fc315c51e | ||
|
|
45244de78e | ||
|
|
99137d8fef | ||
|
|
0735847508 | ||
|
|
e8ea8c8da3 | ||
|
|
d50d618e01 | ||
|
|
02310f2319 | ||
|
|
f23f0d259c | ||
|
|
327369a761 | ||
|
|
c56498a529 | ||
|
|
16114cb3bd | ||
|
|
808ac0f0e6 | ||
|
|
b4b24aadfd | ||
|
|
cbe9c53262 | ||
|
|
4c2591af36 | ||
|
|
1b8069eec8 | ||
|
|
52a03dadbe | ||
|
|
4d9e6be394 | ||
|
|
cc91e49f7b | ||
|
|
605933c516 | ||
|
|
7ed4c7fac9 | ||
|
|
7224f97781 | ||
|
|
1a2f4251ed | ||
|
|
ab30d5981d | ||
|
|
458aecdf7b | ||
|
|
78bcc97591 | ||
|
|
029444f7be | ||
|
|
d3fdc11e56 | ||
|
|
b5dd51a579 | ||
|
|
1e13e8f8a3 | ||
|
|
c9b8d1a11a | ||
|
|
5932aefdb0 | ||
|
|
53e921dc7f | ||
|
|
0835753299 | ||
|
|
d701f840db | ||
|
|
08f7c21fc2 | ||
|
|
5dfdcb1d85 | ||
|
|
049b5d8039 | ||
|
|
3923dc9a33 | ||
|
|
b6d84674f6 | ||
|
|
9cb8f73738 | ||
|
|
cb1b15dbcc | ||
|
|
6020933f6d | ||
|
|
ae583aea1e | ||
|
|
8cd37c5c61 | ||
|
|
36427eb4b7 | ||
|
|
1e6f22ce59 | ||
|
|
8584d710c0 | ||
|
|
90440786b8 | ||
|
|
f97a26c6cb | ||
|
|
8d342c099e | ||
|
|
bed3d9982c | ||
|
|
588a1a7c9d | ||
|
|
e28acc8495 | ||
|
|
3ee5fa6d86 | ||
|
|
2717346e9d | ||
|
|
31d5e384e2 | ||
|
|
13cf64cf2e | ||
|
|
4bd82f7b01 | ||
|
|
efe7855776 | ||
|
|
dca1e67105 | ||
|
|
6695abda2f | ||
|
|
ae3601af92 | ||
|
|
b25ec93d14 | ||
|
|
bd557fbdb4 | ||
|
|
4b8485b087 | ||
|
|
89dd109a18 | ||
|
|
846c4500f7 | ||
|
|
445da5447d | ||
|
|
78afba5c29 | ||
|
|
46c6001c9d | ||
|
|
3b365d330a | ||
|
|
a9bdc255df | ||
|
|
4fb32fad37 | ||
|
|
b34d31f6a7 | ||
|
|
78d87038aa | ||
|
|
be27a72d86 | ||
|
|
aa86158caf | ||
|
|
de00ac1622 | ||
|
|
ed41272e81 | ||
|
|
7af0db9631 | ||
|
|
799ba3bc46 | ||
|
|
60f378839c | ||
|
|
72fa34a5cf | ||
|
|
e7521f0246 | ||
|
|
bb4dff1caa | ||
|
|
7312385dd6 | ||
|
|
8bd4f8b23c | ||
|
|
e80f294e80 | ||
|
|
b57e70ad30 | ||
|
|
9ac651afd5 | ||
|
|
00a8dee744 | ||
|
|
63270d9a4e | ||
|
|
f1242397be | ||
|
|
7957f8553c | ||
|
|
c4967cf252 | ||
|
|
af3da468ee | ||
|
|
a722af88e0 | ||
|
|
525117f3fd | ||
|
|
f35bf05726 | ||
|
|
01902c981c | ||
|
|
72489b0979 | ||
|
|
fa793a828b | ||
|
|
d2a1501e82 | ||
|
|
892c67bae5 | ||
|
|
fe35a8c782 | ||
|
|
b608efa5da | ||
|
|
8c0b7e45de | ||
|
|
3b7e42c280 | ||
|
|
c6199fa00d | ||
|
|
e3db3728f9 | ||
|
|
f3cd3a4e24 | ||
|
|
634d85c763 | ||
|
|
18e09702f3 | ||
|
|
4ee0fd5c54 | ||
|
|
a752574f66 | ||
|
|
f2d574fab5 | ||
|
|
2cf6a67a53 | ||
|
|
3857ab22d3 | ||
|
|
de8af9c9f1 | ||
|
|
cc12f9863e | ||
|
|
a5f671fa76 | ||
|
|
c6fe8397a7 | ||
|
|
d3154bd94f | ||
|
|
3639509a69 | ||
|
|
4c8349fbb5 | ||
|
|
fcf518353c | ||
|
|
e7c1835b19 | ||
|
|
5f12b870e6 | ||
|
|
9ef65f3f25 | ||
|
|
c6552d0b60 | ||
|
|
78fa0cb41b | ||
|
|
d98c8242af | ||
|
|
4ae4cc2169 | ||
|
|
9ac6bdbeaa | ||
|
|
8fc6f81f8d | ||
|
|
9a4363a6a5 | ||
|
|
50c42776e7 | ||
|
|
fb8b63cffa | ||
|
|
36e6d53374 | ||
|
|
9cc14af668 | ||
|
|
46f484461f | ||
|
|
7863d42834 | ||
|
|
743c206bc7 | ||
|
|
9691405fd4 | ||
|
|
12f9a05106 | ||
|
|
be8c7e3ee5 | ||
|
|
f3b6f58344 | ||
|
|
f65540dd19 | ||
|
|
6fb06a0564 | ||
|
|
acbd99f2ed | ||
|
|
541cb5244d | ||
|
|
9214b4a5da | ||
|
|
9cbff6835b | ||
|
|
8818f7b7e5 | ||
|
|
8fc0bc98f3 | ||
|
|
021048d95e | ||
|
|
aa46c9fb27 | ||
|
|
3fe9bfc719 | ||
|
|
4ca027de06 | ||
|
|
bc79530c52 | ||
|
|
aecc1adbaf | ||
|
|
582de7c18c | ||
|
|
f6a1fa94d3 | ||
|
|
51c3f8a378 | ||
|
|
05b40efddf | ||
|
|
7f379482a8 | ||
|
|
06eb66840a | ||
|
|
5dad177d3e | ||
|
|
5077a3d43f | ||
|
|
dae6437421 | ||
|
|
68c08ba9eb | ||
|
|
71b15b08eb | ||
|
|
afd6447581 | ||
|
|
e923fb045e | ||
|
|
5cb4415032 | ||
|
|
7b1a7fd20e | ||
|
|
38bda21f84 | ||
|
|
3997bebb76 | ||
|
|
9a4b3034ea | ||
|
|
f26a418a87 | ||
|
|
729e7ef6d5 | ||
|
|
09f0530d57 | ||
|
|
6ef722e7ea | ||
|
|
c7c112ee71 | ||
|
|
42682120ef | ||
|
|
6bb27c3b24 | ||
|
|
dd95b638e8 | ||
|
|
cb6fe2d32c | ||
|
|
a6bd17fa01 | ||
|
|
4ddc6294e1 | ||
|
|
916f079ecc | ||
|
|
426004e795 | ||
|
|
09f68b767c | ||
|
|
c3a7da959e | ||
|
|
5068b081c9 | ||
|
|
19054ea5f2 | ||
|
|
1ecc87ab26 | ||
|
|
b7e947b915 | ||
|
|
3eed685906 | ||
|
|
80a52d8c3c | ||
|
|
ec8f2368da | ||
|
|
b89592b84f | ||
|
|
2d5f24b4de | ||
|
|
a82579dc60 | ||
|
|
4d4113fccc | ||
|
|
1cc13235cf | ||
|
|
a1e11d9521 | ||
|
|
e72c78cd7f | ||
|
|
37e3424782 | ||
|
|
768ef23f29 | ||
|
|
64cf90313d | ||
|
|
ca7b488f4d | ||
|
|
bcab73a2f5 | ||
|
|
86a7dfeba5 | ||
|
|
84e4f6fee8 | ||
|
|
4d115fd895 | ||
|
|
3100f342c3 | ||
|
|
41d9638ce6 | ||
|
|
83eab8e5c5 | ||
|
|
8d2d10b15a | ||
|
|
eb30cf84b4 | ||
|
|
b5abe21889 | ||
|
|
0b4fe3148f | ||
|
|
e4c2841444 | ||
|
|
941e2ee411 | ||
|
|
8705232ea3 | ||
|
|
3c104111a0 | ||
|
|
02f7e386a4 | ||
|
|
a006bbed98 | ||
|
|
12b298abd6 | ||
|
|
0018ffb5bb | ||
|
|
6a939480c9 | ||
|
|
2221d27722 | ||
|
|
25af73bee8 | ||
|
|
5d8ae712b5 | ||
|
|
7bdec88efc | ||
|
|
52dbc4b6e7 | ||
|
|
5d1545dd2a | ||
|
|
bfb97db2a5 | ||
|
|
99165f3c82 | ||
|
|
3a8f88b703 | ||
|
|
1950db98ab | ||
|
|
4875dcede0 | ||
|
|
5c58ba44bc | ||
|
|
683cc32a3b | ||
|
|
55e1580363 | ||
|
|
e50144581b | ||
|
|
19e7535a5b | ||
|
|
414b954b92 | ||
|
|
9d8a776bd9 | ||
|
|
264866ab93 | ||
|
|
04cabd15eb | ||
|
|
85930d5564 | ||
|
|
b24a38e42d | ||
|
|
8cb15160ac | ||
|
|
011947daf2 | ||
|
|
0c79231eb9 | ||
|
|
251a01d7ac | ||
|
|
fd7ee9be7a | ||
|
|
6fa9594fef | ||
|
|
51527db42e | ||
|
|
8437058227 | ||
|
|
c885670079 | ||
|
|
1f33d7db0c | ||
|
|
9823909cfd | ||
|
|
e3a242ae56 | ||
|
|
967cfae906 | ||
|
|
2a36ba7d3c | ||
|
|
c73870c129 | ||
|
|
9de6eea4f0 | ||
|
|
fde5420caa | ||
|
|
dbe7b35e38 | ||
|
|
0e5af5accf | ||
|
|
dc1eff24e8 | ||
|
|
697c4b851f | ||
|
|
e0d0a98fdb | ||
|
|
9337df512f | ||
|
|
e1537e3ef6 | ||
|
|
8f67e4d9fe | ||
|
|
164426f88c | ||
|
|
022b78581f | ||
|
|
313de4c467 | ||
|
|
d2b947bedd | ||
|
|
bcaa1ad81d | ||
|
|
c8add75f7c | ||
|
|
99af60cfa3 | ||
|
|
559faf745a | ||
|
|
31a69933e0 | ||
|
|
8f9d9b057a | ||
|
|
765fcbe5da | ||
|
|
f18614588a | ||
|
|
61c2fd4c51 | ||
|
|
9a16993762 | ||
|
|
2adccca817 | ||
|
|
1c90e83ae1 | ||
|
|
091ffc65bd | ||
|
|
7320b911d6 | ||
|
|
452d3e0af6 | ||
|
|
5c10516850 | ||
|
|
a6a537b638 | ||
|
|
6824dbb59a | ||
|
|
43cfe73582 | ||
|
|
4a14538564 | ||
|
|
83799ee4c8 | ||
|
|
ec9d28df7a | ||
|
|
e9c3399d32 | ||
|
|
241613d5cf | ||
|
|
e29e972bf1 | ||
|
|
1c2c443d6d | ||
|
|
14db33addb | ||
|
|
adbc1eace3 | ||
|
|
4191b9f92e | ||
|
|
e422a93883 | ||
|
|
cf396c364b | ||
|
|
38f209a57d | ||
|
|
a9ff55017b | ||
|
|
3e49c0c7f9 | ||
|
|
f733f8c5d9 | ||
|
|
9388ad70b3 | ||
|
|
8ad850072a | ||
|
|
535c8ec92f | ||
|
|
ec075413b3 | ||
|
|
aa2beb7027 | ||
|
|
278c8ac541 | ||
|
|
93419222d3 | ||
|
|
80cf22c97c | ||
|
|
b43149f9d3 | ||
|
|
bc97db94e5 | ||
|
|
24d43d3924 | ||
|
|
3193d8a0cb | ||
|
|
2e06869ae3 | ||
|
|
e645c539a0 | ||
|
|
15b224917a | ||
|
|
67530cc3a5 | ||
|
|
bc6ec9a3d0 | ||
|
|
664a0d9adf | ||
|
|
cb9b2bb73d | ||
|
|
0b6a3930fc | ||
|
|
eeac9dbaf1 | ||
|
|
de1753aebe | ||
|
|
b23b5fa2f1 | ||
|
|
7a81263b34 | ||
|
|
936019736b | ||
|
|
3b163d66f9 | ||
|
|
a2f4c098e3 | ||
|
|
282387cc17 | ||
|
|
d09b992df5 | ||
|
|
5b4bf11250 | ||
|
|
1bb3328a0a | ||
|
|
a046070f8a | ||
|
|
b8a14c1dfa | ||
|
|
87014a0c5c | ||
|
|
f5583edec7 | ||
|
|
344a61d5a5 | ||
|
|
a50f7ce802 | ||
|
|
b6bfef3b65 | ||
|
|
7d7c853045 | ||
|
|
7d95cbad71 | ||
|
|
2fc1c05d6f | ||
|
|
2f51cee555 | ||
|
|
43f89063e0 | ||
|
|
edc67d6aa5 | ||
|
|
7a72955ec8 | ||
|
|
9bfb92cf74 | ||
|
|
fde7a4bc1f | ||
|
|
99ee16b438 | ||
|
|
7eaec845fc | ||
|
|
dea015592f | ||
|
|
8914eeeaf8 | ||
|
|
8a407bebbb | ||
|
|
b52c9d7fa3 | ||
|
|
15ce2ae731 | ||
|
|
2e296abd93 | ||
|
|
a6b62c89a2 | ||
|
|
45d6fa2047 | ||
|
|
7492d404c0 | ||
|
|
13cdf776f5 | ||
|
|
f65314bd94 | ||
|
|
53636a3453 | ||
|
|
23fb25fc17 | ||
|
|
b03949626e | ||
|
|
55408ece40 | ||
|
|
d0391b5f29 | ||
|
|
afc4e4536f | ||
|
|
83fe14288a | ||
|
|
5ce0ad1221 | ||
|
|
9593cf952d | ||
|
|
0e313d792a | ||
|
|
0dcb83a5a5 | ||
|
|
e377355ef1 | ||
|
|
55799985e9 | ||
|
|
ae7dba63b2 | ||
|
|
f1c33e30a2 | ||
|
|
2d769a83ce | ||
|
|
2065819ab9 | ||
|
|
36b0ad66cf | ||
|
|
eeef799bf7 | ||
|
|
1c9f0f6018 | ||
|
|
e61c402067 | ||
|
|
a09ad95cc0 | ||
|
|
a9ba11f35f | ||
|
|
4df8f09549 | ||
|
|
c197036c1f | ||
|
|
d9aa817221 | ||
|
|
c2f6a8fc22 | ||
|
|
d96fda1575 | ||
|
|
5242f3918e | ||
|
|
3128f8d336 | ||
|
|
19c3297538 | ||
|
|
f1c4018d8f | ||
|
|
e4a4b91dce | ||
|
|
50bf45770a | ||
|
|
1e84bc6f1d | ||
|
|
e9e1f9713f | ||
|
|
9c0d1000a1 | ||
|
|
fc974bf9d4 | ||
|
|
bcc013bdcf | ||
|
|
41a3385e99 | ||
|
|
99163201c6 | ||
|
|
0093e835f4 | ||
|
|
92a746de78 | ||
|
|
58dec25bbb | ||
|
|
021d3d4147 | ||
|
|
34977008e6 | ||
|
|
b7464f45ad | ||
|
|
f84de48e15 | ||
|
|
4ddd09df85 | ||
|
|
b52d3dd331 | ||
|
|
51ac32547f | ||
|
|
2e4aaf2f3b | ||
|
|
6c34162bb0 | ||
|
|
4ec7219318 | ||
|
|
cdef10dcef | ||
|
|
00ac8deba3 | ||
|
|
bcc275e244 | ||
|
|
899cd74b01 | ||
|
|
9595e64334 | ||
|
|
bc2108dd5a | ||
|
|
7bd358b53b | ||
|
|
e738eed8d7 | ||
|
|
dd43ca449e | ||
|
|
51a65f746b | ||
|
|
cb32063b68 | ||
|
|
f160a9091a | ||
|
|
6927401c1d | ||
|
|
384e4243bc | ||
|
|
95267cb88b | ||
|
|
e9d3de1859 | ||
|
|
038ebeb0f8 | ||
|
|
1099680118 | ||
|
|
c9455d27da | ||
|
|
f13edd77c9 | ||
|
|
cabbaa0acd | ||
|
|
6eec6985c2 | ||
|
|
052597513d | ||
|
|
04624beeaa | ||
|
|
3c3bfc2b8f | ||
|
|
2fbd3e66fa | ||
|
|
791457e0fe | ||
|
|
22519cd731 | ||
|
|
bf0eb143a6 | ||
|
|
08fe7ee42a | ||
|
|
848e0ae505 | ||
|
|
2e8c7a9acd | ||
|
|
f868b4bebb | ||
|
|
4b259031f3 | ||
|
|
1764aa3b3a | ||
|
|
b97d07df3d | ||
|
|
e34d535b61 | ||
|
|
e1d4956175 | ||
|
|
738bc9e968 | ||
|
|
15b2813abc | ||
|
|
c0fa8cefd1 | ||
|
|
50c98dab19 | ||
|
|
2421a655cf | ||
|
|
0c35a1fa24 | ||
|
|
17812bf744 | ||
|
|
463d81a27c | ||
|
|
c37c1fbb2c | ||
|
|
343de88d62 | ||
|
|
f368d7cb9d | ||
|
|
db07567e64 | ||
|
|
8a81b42e0c | ||
|
|
7952268226 | ||
|
|
2d13c3b4b4 | ||
|
|
ab37de4292 | ||
|
|
c45cb58dbc | ||
|
|
1a70218a74 | ||
|
|
1ec3ad24ef | ||
|
|
b0a2e0ce33 | ||
|
|
ddd1726bf1 | ||
|
|
ebb6a1c63a | ||
|
|
817bfebb71 | ||
|
|
94822deddc | ||
|
|
cc7e1a4b2f | ||
|
|
defd0bd38a | ||
|
|
80b4ca0841 | ||
|
|
f9c087e93a | ||
|
|
c9e0ea7566 | ||
|
|
5f69257625 | ||
|
|
acb22024a9 | ||
|
|
f12e63436a | ||
|
|
c7d457d373 | ||
|
|
08b6b901a9 | ||
|
|
f6df7c905b | ||
|
|
df9a0086d5 | ||
|
|
07176252c8 | ||
|
|
0541ec9947 | ||
|
|
abc9d205a5 | ||
|
|
31e24fa77b | ||
|
|
44976c8eb9 | ||
|
|
d61e6dd01d | ||
|
|
89b146a2c4 | ||
|
|
f32379d492 | ||
|
|
1872296417 | ||
|
|
bc1cfad1c2 | ||
|
|
7bd383b7cf | ||
|
|
aa66a87579 | ||
|
|
847df782b5 | ||
|
|
95d697a99a | ||
|
|
a7604e02c4 | ||
|
|
f15e41f8d9 | ||
|
|
920d7d4f07 | ||
|
|
5ac03ea3b9 | ||
|
|
ca51542b16 | ||
|
|
a770007e4d | ||
|
|
9624eeb11a | ||
|
|
7c7d329541 | ||
|
|
2c223a90e6 | ||
|
|
619e5c223c | ||
|
|
a320e22d19 | ||
|
|
3e62a88f97 | ||
|
|
fa5cee60d5 | ||
|
|
b0b305f4af | ||
|
|
98bd098999 | ||
|
|
12d37186a3 | ||
|
|
294d8ad651 | ||
|
|
efb8f08c74 | ||
|
|
08f2f09f52 | ||
|
|
347f9c1562 | ||
|
|
40c25713ac | ||
|
|
c4113e661d | ||
|
|
0463ecc23f | ||
|
|
496cdba896 | ||
|
|
da37d92265 | ||
|
|
ca8f21c2bc | ||
|
|
8a312b393f | ||
|
|
5baa2b884a | ||
|
|
15cb9221dc | ||
|
|
43b36716ae | ||
|
|
e926288f3e | ||
|
|
33df7f0d41 | ||
|
|
1c552404c0 | ||
|
|
cd6cb1f36c | ||
|
|
257343852f | ||
|
|
3cf14ad066 | ||
|
|
d404a7cdcb | ||
|
|
1d536974ab | ||
|
|
c9cd0307c6 | ||
|
|
2ec3b1d0f2 | ||
|
|
e4a17902fd | ||
|
|
752ccd8502 | ||
|
|
2e474b8dd6 | ||
|
|
f72db5731e | ||
|
|
17c6458f0b | ||
|
|
77d92f5c23 | ||
|
|
9f308f6aae | ||
|
|
ad149439ba | ||
|
|
520ed9204c | ||
|
|
b34c61f00d | ||
|
|
f87c10686f | ||
|
|
47c41077d5 | ||
|
|
2a6f46e820 | ||
|
|
3c0982974b | ||
|
|
eeac929ca6 | ||
|
|
b6f76f8885 | ||
|
|
26d41b11f3 | ||
|
|
013f47ada2 | ||
|
|
8b50062f86 | ||
|
|
2178764db1 | ||
|
|
57dd91955b | ||
|
|
bf74f24eb2 | ||
|
|
46700f351c | ||
|
|
9132316971 | ||
|
|
514a663b1d | ||
|
|
facdfd564f | ||
|
|
d6a46b86e2 | ||
|
|
771ecba016 | ||
|
|
b675b02604 | ||
|
|
8b30857701 | ||
|
|
2bdee0f848 | ||
|
|
80af2a0f8c | ||
|
|
9a11d40a6a | ||
|
|
91274eb7c1 | ||
|
|
9bc3eb1faf | ||
|
|
d3b1c4c053 | ||
|
|
a66d998810 | ||
|
|
96a1cf8bc5 | ||
|
|
29d16b90d9 | ||
|
|
28165a06f6 | ||
|
|
adaca820b5 | ||
|
|
26d976b684 | ||
|
|
e46cdb41fc | ||
|
|
2c6e901eb6 | ||
|
|
244b33600f | ||
|
|
cb0f0f195d | ||
|
|
4c44421169 | ||
|
|
702a75dd67 | ||
|
|
a502508d73 | ||
|
|
559d9b573c | ||
|
|
d7009ba6f3 | ||
|
|
6c6785442d | ||
|
|
372ba9104e | ||
|
|
963d43a336 | ||
|
|
546da0d579 | ||
|
|
85a8051e66 | ||
|
|
0cdaa1fd2d | ||
|
|
4261c92f61 | ||
|
|
7e7e9c17b7 | ||
|
|
d51ed5166c | ||
|
|
b3b295f721 | ||
|
|
bf16687aa6 | ||
|
|
4a61fe197c | ||
|
|
c99e22cec0 | ||
|
|
6c71fcdc3b | ||
|
|
1ad8cbda8a | ||
|
|
80ed9701e4 | ||
|
|
dda4b73f26 | ||
|
|
67c5ca876a | ||
|
|
a69ce967dc | ||
|
|
24130959c9 | ||
|
|
491f012828 | ||
|
|
4ed1743a71 | ||
|
|
7f669023f6 | ||
|
|
098bdf7156 | ||
|
|
d55e23081a | ||
|
|
58ebc6b7fd | ||
|
|
6965be7ba2 | ||
|
|
6030e21aad | ||
|
|
14bd0f1eaa | ||
|
|
12380f1274 | ||
|
|
b2251d9ea8 | ||
|
|
a8735faf63 | ||
|
|
5ea604d500 | ||
|
|
f9daab0dbe | ||
|
|
e1bd079043 | ||
|
|
eb434eaf3d | ||
|
|
22536144e7 | ||
|
|
d425dd635c | ||
|
|
025f321977 | ||
|
|
d6c4f4f98d | ||
|
|
9f109f203e | ||
|
|
ee269c66ad | ||
|
|
b5bf60cbce | ||
|
|
7d8a0f7b91 | ||
|
|
148b2c74af | ||
|
|
2d8473e34d | ||
|
|
ec341bda32 | ||
|
|
eb703318ce | ||
|
|
947571dcf3 | ||
|
|
2169008082 | ||
|
|
6ede63da73 | ||
|
|
59d7b90a41 | ||
|
|
744d4983e5 | ||
|
|
f0c280256e | ||
|
|
e679e91687 | ||
|
|
16fa0eb1e1 | ||
|
|
fb5261a24c | ||
|
|
c51012c131 | ||
|
|
1bb1129194 | ||
|
|
1d5746f2ad | ||
|
|
6a27505c1f | ||
|
|
5e462f6816 | ||
|
|
8e7805d105 | ||
|
|
07f50b56fc | ||
|
|
146cfe99fc | ||
|
|
4486f779ae | ||
|
|
6f7c354c19 | ||
|
|
3ab3b6ed27 | ||
|
|
c752fffe88 | ||
|
|
d5fcfc5220 | ||
|
|
3b40214552 | ||
|
|
c371b2266d | ||
|
|
6ddf735857 | ||
|
|
47b2db40fb | ||
|
|
c10dab1bea | ||
|
|
fe6f0cfb67 | ||
|
|
2d074b3886 | ||
|
|
151cd706b2 | ||
|
|
a2cbf6090c | ||
|
|
180b3e9aa0 | ||
|
|
a21aee9ca5 | ||
|
|
ace271e6bf | ||
|
|
7171188068 | ||
|
|
0f6f5d4059 | ||
|
|
760fb35f3a | ||
|
|
d08bd4aa6f | ||
|
|
3f8720c57e | ||
|
|
5da57d0e6b | ||
|
|
7a517cd5d6 | ||
|
|
460ec2444b | ||
|
|
fbab970c4b | ||
|
|
61c78397cc | ||
|
|
28fe25f56f | ||
|
|
aa01000991 | ||
|
|
85840f77ec | ||
|
|
6a344d1438 | ||
|
|
a2e6ba132d | ||
|
|
1822ff7295 | ||
|
|
e1fb2464c7 | ||
|
|
1c67cf8ef3 | ||
|
|
0ad6b58a9f | ||
|
|
955071e5f8 | ||
|
|
4231fc8aa4 | ||
|
|
64372b20d4 | ||
|
|
ef709c75eb | ||
|
|
bb5b2d0336 | ||
|
|
a5149bf17d | ||
|
|
abf9c3b769 | ||
|
|
92b6c975bd | ||
|
|
f6dc1ec7a8 | ||
|
|
b50980e880 | ||
|
|
206cff9d34 | ||
|
|
14fe0a4e03 | ||
|
|
ab26411136 | ||
|
|
cf1fddd832 | ||
|
|
ab2c38e882 | ||
|
|
f3c8c35f39 | ||
|
|
e50ce4f158 | ||
|
|
212d86b347 | ||
|
|
4a5312221c | ||
|
|
5277e4b17b | ||
|
|
ad5a5327d6 | ||
|
|
49fc96a22a | ||
|
|
d7deeb04e0 | ||
|
|
a941936907 | ||
|
|
808908717d | ||
|
|
6e80e62585 | ||
|
|
d2f2f1193c | ||
|
|
3dcef5a235 | ||
|
|
2541a70ab7 | ||
|
|
003a3ccd18 | ||
|
|
a45caca7ee | ||
|
|
6b7142565e | ||
|
|
fb8b3283ec | ||
|
|
e92e852145 | ||
|
|
c05d81cf29 | ||
|
|
43d018f11e | ||
|
|
f67669969e | ||
|
|
7698589c56 | ||
|
|
2e7f04b877 | ||
|
|
2be3d0511c | ||
|
|
081ad552a0 | ||
|
|
dadb15eb63 | ||
|
|
c306a8ae4f | ||
|
|
7bfc0bb91b | ||
|
|
8854b106d9 | ||
|
|
80acfb73f0 | ||
|
|
2137529555 | ||
|
|
01bcac7f0a | ||
|
|
5bbf616997 | ||
|
|
627ccfdb9c | ||
|
|
4a27575731 | ||
|
|
0aae98108b | ||
|
|
d432e749bb | ||
|
|
36f915ae20 | ||
|
|
7036efc269 | ||
|
|
d46988592d | ||
|
|
8d1e7cb4fb | ||
|
|
3e732b63b5 | ||
|
|
9249afe585 | ||
|
|
4f53a0a3f4 | ||
|
|
2ebbb01854 | ||
|
|
036e0f072c | ||
|
|
00b7a3dc87 | ||
|
|
88961b00ce | ||
|
|
1c61678ebc | ||
|
|
2d07809a88 | ||
|
|
111222720a | ||
|
|
30d133e4ff | ||
|
|
2c6931107f | ||
|
|
2e2983095b | ||
|
|
d4ad2cbe37 | ||
|
|
28e6de04c6 | ||
|
|
4210b25657 | ||
|
|
e93e829fb6 | ||
|
|
41b1abedc9 | ||
|
|
a1aa2b61f6 | ||
|
|
fa3d93dac2 | ||
|
|
b60a509ae6 | ||
|
|
526e250898 | ||
|
|
f820932e1f | ||
|
|
38d0d5ab7f | ||
|
|
582e1146d0 | ||
|
|
a689502c11 | ||
|
|
89c55c1704 | ||
|
|
f282d39646 | ||
|
|
393bd4900a | ||
|
|
07ee026220 | ||
|
|
c07c00659f | ||
|
|
c74c7cd726 | ||
|
|
cb3e4a55cd | ||
|
|
7c6335fb47 | ||
|
|
dbe8c45fa5 | ||
|
|
11dc677020 | ||
|
|
450682f810 | ||
|
|
5a670fa304 | ||
|
|
effc8231ac | ||
|
|
dcf57f6567 | ||
|
|
9e32d84dff | ||
|
|
6fd275c5af | ||
|
|
ad198c40e8 | ||
|
|
c36313ce5a | ||
|
|
9d6eda165a | ||
|
|
3816645aae | ||
|
|
d77bf259aa | ||
|
|
000c7376a0 | ||
|
|
23fb89c6e3 | ||
|
|
b42ef72337 | ||
|
|
19ad51dc91 | ||
|
|
cac8c45c51 | ||
|
|
c1bdc13a7a | ||
|
|
c357423681 | ||
|
|
d50ab5353d | ||
|
|
d000bb120b | ||
|
|
c128a86bf3 | ||
|
|
35a7ab09c1 | ||
|
|
5b13693601 | ||
|
|
848e9ff54f | ||
|
|
37b09e63bf | ||
|
|
fee3813b50 | ||
|
|
2a9f144e0d | ||
|
|
9e4b6c635a | ||
|
|
d0d8e3d2b7 | ||
|
|
223c271399 | ||
|
|
5fa4af1c9c | ||
|
|
b38aa084d9 | ||
|
|
6c88914bf0 | ||
|
|
a25042b2a4 | ||
|
|
cc1a955a7f | ||
|
|
0edefbe3f9 | ||
|
|
2bbbfe4553 | ||
|
|
24a0148ebc | ||
|
|
34f04e76ec | ||
|
|
f95cae2ee5 | ||
|
|
65c7ed8095 | ||
|
|
03260932ee | ||
|
|
372793cb7a | ||
|
|
b9961bf8be | ||
|
|
1a0364ee62 | ||
|
|
d2a0b54dfc | ||
|
|
6a3b81499a | ||
|
|
70560cd537 | ||
|
|
77680ff29f | ||
|
|
76c6970e4f | ||
|
|
5de52ec045 | ||
|
|
278fcebe02 | ||
|
|
ed2404ce57 | ||
|
|
fa7b2b4fe3 | ||
|
|
278da2459f | ||
|
|
204a3fd83c | ||
|
|
745802eaea | ||
|
|
cba59f0b70 | ||
|
|
0473e9f081 | ||
|
|
6a83623170 | ||
|
|
a1b226f8a3 | ||
|
|
f74603dcef | ||
|
|
9c2b3b1c46 | ||
|
|
d9dfdbf474 | ||
|
|
a442437201 | ||
|
|
f0bc1d5586 | ||
|
|
904baa3db2 | ||
|
|
73524bd7b4 | ||
|
|
6d4ddc7ee3 | ||
|
|
a451a124f6 | ||
|
|
fae4241fb7 | ||
|
|
f5e13b38cd | ||
|
|
207f458186 | ||
|
|
6d86f35b02 | ||
|
|
bc8ef2d4c6 | ||
|
|
994f0c5905 | ||
|
|
3ce235581e | ||
|
|
b23cbfea16 | ||
|
|
680990d6d2 | ||
|
|
b64e05b3c7 | ||
|
|
712082dc8f | ||
|
|
8252129dd0 | ||
|
|
65f5262476 | ||
|
|
0fbb63a64c | ||
|
|
f2a5866c52 | ||
|
|
e2f2780a51 | ||
|
|
6f5803bb3c | ||
|
|
1dbaf4b5d6 | ||
|
|
80643e9090 | ||
|
|
aac541afb9 | ||
|
|
8e2fabbfae | ||
|
|
51938f0a2b | ||
|
|
cfd8db6b9e | ||
|
|
1192b139bd | ||
|
|
3caba47f5e | ||
|
|
5b25a05bcc | ||
|
|
88824eb7b9 | ||
|
|
c39eb7f019 | ||
|
|
e0fce28cbe | ||
|
|
a9bdbc6394 | ||
|
|
b9c3c2d186 | ||
|
|
421cff3457 | ||
|
|
f2d63ee9be | ||
|
|
03dd38b040 | ||
|
|
a6d5486554 | ||
|
|
224dc0679a | ||
|
|
a253bea015 | ||
|
|
6500ba3270 | ||
|
|
617008f802 | ||
|
|
300aeca890 | ||
|
|
f5d54b0332 | ||
|
|
ca19758ef1 | ||
|
|
97a86865fb | ||
|
|
7bd9d5cca0 | ||
|
|
f6fd7d0f6e | ||
|
|
b18b19c703 | ||
|
|
0d529803d2 | ||
|
|
fb0b5839b0 | ||
|
|
1668ed095b | ||
|
|
ad3b75ab3c | ||
|
|
dfa4ba9e01 | ||
|
|
ee1923d558 | ||
|
|
c40457c1cf | ||
|
|
6b196d7b04 | ||
|
|
f2d073c8ba | ||
|
|
ad84629fa3 | ||
|
|
d5e3dbc115 | ||
|
|
4be2995c98 | ||
|
|
a43628a0eb | ||
|
|
09215c8b39 | ||
|
|
62f25b27a7 | ||
|
|
a3ea9ebee9 | ||
|
|
23fd497041 | ||
|
|
e969fff0a8 | ||
|
|
a1a70086ac | ||
|
|
c2fcdfc2c7 | ||
|
|
ff707fc932 | ||
|
|
fa6c798f06 | ||
|
|
a817c11590 | ||
|
|
d4da2fbd06 | ||
|
|
5b9661be59 | ||
|
|
6569f03fba | ||
|
|
a6051aa758 | ||
|
|
a31d0d9961 | ||
|
|
2a6e9fc94c | ||
|
|
8969f499be | ||
|
|
1c0d38097f | ||
|
|
3897bff774 | ||
|
|
37922ab699 | ||
|
|
0a1259b3a5 | ||
|
|
effebec8aa | ||
|
|
d9af5216e0 | ||
|
|
d29b3f1e63 | ||
|
|
34b31715dc | ||
|
|
f5bae01550 | ||
|
|
aed9ef05c1 | ||
|
|
5a6b84a924 | ||
|
|
7db2f889b1 | ||
|
|
7ea8bfd3c9 | ||
|
|
99c43b6d58 | ||
|
|
69d6b7a0b5 | ||
|
|
8dddaccde6 | ||
|
|
7753b5e04d | ||
|
|
c987dc857e | ||
|
|
b88c274e72 | ||
|
|
da73358a66 | ||
|
|
b98d72a1e6 | ||
|
|
a31fdfa004 | ||
|
|
d2c6f622a9 | ||
|
|
e85b238ac1 | ||
|
|
f603e4c565 | ||
|
|
b4de497107 | ||
|
|
e9a0e77b90 | ||
|
|
21eaa1962d | ||
|
|
210c8d89c6 | ||
|
|
e25a403bea | ||
|
|
485720dcbf | ||
|
|
4571c91fcd | ||
|
|
0495d3adb0 | ||
|
|
9bcb84097d | ||
|
|
5d332663d6 | ||
|
|
720b70acba | ||
|
|
0b2e174e97 | ||
|
|
eaf88fb55a | ||
|
|
949f1215b6 | ||
|
|
e402036ff7 | ||
|
|
07a482985a | ||
|
|
8e820d3f89 | ||
|
|
700a433ae5 | ||
|
|
fd46aefadd | ||
|
|
2fe494347d | ||
|
|
41d21074b5 | ||
|
|
04c3efa279 |
+12
-3
@@ -176,7 +176,7 @@ function get_theme_config_value($dir, $key='*')
|
||||
$tconfig = array();
|
||||
|
||||
$theme_config_file = G5_PATH.'/'.G5_THEME_DIR.'/'.$dir.'/theme.config.php';
|
||||
if(is_file) {
|
||||
if(is_file($theme_config_file)) {
|
||||
include($theme_config_file);
|
||||
|
||||
if($key == '*') {
|
||||
@@ -382,15 +382,24 @@ function admin_referer_check($return=false)
|
||||
}
|
||||
|
||||
$p = @parse_url($referer);
|
||||
|
||||
$host = preg_replace('/:[0-9]+$/', '', $_SERVER['HTTP_HOST']);
|
||||
$msg = '';
|
||||
|
||||
if($host != $p['host']) {
|
||||
$msg = '올바른 방법으로 이용해 주십시오.';
|
||||
}
|
||||
|
||||
if($return)
|
||||
if( $p['path'] && ! preg_match( '/\/'.preg_quote(G5_ADMIN_DIR).'\//i', $p['path'] ) ){
|
||||
$msg = '올바른 방법으로 이용해 주십시오';
|
||||
}
|
||||
|
||||
if( $msg ){
|
||||
if($return) {
|
||||
return $msg;
|
||||
else
|
||||
} else {
|
||||
alert($msg, G5_URL);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+3
-1
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
if (!defined('_GNUBOARD_')) exit;
|
||||
|
||||
$print_version = defined('G5_YOUNGCART_VER') ? 'YoungCart Version '.G5_YOUNGCART_VER : 'Version '.G5_GNUBOARD_VER;
|
||||
?>
|
||||
|
||||
<noscript>
|
||||
@@ -14,7 +16,7 @@ if (!defined('_GNUBOARD_')) exit;
|
||||
|
||||
<footer id="ft">
|
||||
<p>
|
||||
Copyright © <?php echo $_SERVER['HTTP_HOST']; ?>. All rights reserved.<br>
|
||||
Copyright © <?php echo $_SERVER['HTTP_HOST']; ?>. All rights reserved. <?php echo $print_version; ?><br>
|
||||
<a href="#">상단으로</a>
|
||||
</p>
|
||||
</footer>
|
||||
|
||||
@@ -21,7 +21,7 @@ if ($file = $_POST['bo_include_head']) {
|
||||
$purl = parse_url($file);
|
||||
$file = $purl['path'];
|
||||
if (!preg_match("/\.(php|htm['l']?)$/i", $file)) {
|
||||
alert('상단 파일 경로가 php, html 파일이 아닙니다.');
|
||||
alert('상단 파일 경로의 확장자는 php, html 만 허용합니다.');
|
||||
}
|
||||
$_POST['bo_include_head'] = $file;
|
||||
}
|
||||
@@ -30,16 +30,16 @@ if ($file = $_POST['bo_include_tail']) {
|
||||
$purl = parse_url($file);
|
||||
$file = $purl['path'];
|
||||
if (!preg_match("/\.(php|htm['l']?)$/i", $file)) {
|
||||
alert('하단 파일 경로가 php, html 파일이 아닙니다.');
|
||||
alert('하단 파일 경로의 확장자는 php, html 만 허용합니다.');
|
||||
}
|
||||
$_POST['bo_include_tail'] = $file;
|
||||
}
|
||||
|
||||
if(!is_include_path_check($_POST['bo_include_head'])) {
|
||||
if(!is_include_path_check($_POST['bo_include_head'], 1)) {
|
||||
alert('/data/file/ 또는 /data/editor/ 포함된 문자를 상단 파일 경로에 포함시킬수 없습니다.');
|
||||
}
|
||||
|
||||
if(!is_include_path_check($_POST['bo_include_tail'])) {
|
||||
if(!is_include_path_check($_POST['bo_include_tail'], 1)) {
|
||||
alert('/data/file/ 또는 /data/editor/ 포함된 문자를 하단 파일 경로에 포함시킬수 없습니다.');
|
||||
}
|
||||
|
||||
|
||||
@@ -62,7 +62,10 @@ if ($_POST['act_button'] == "선택수정") {
|
||||
|
||||
// include 전에 $bo_table 값을 반드시 넘겨야 함
|
||||
$tmp_bo_table = trim($_POST['board_table'][$k]);
|
||||
include ('./board_delete.inc.php');
|
||||
|
||||
if( preg_match("/^[A-Za-z0-9_]+$/", $tmp_bo_table) ){
|
||||
include ('./board_delete.inc.php');
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
+1
-1
@@ -1099,7 +1099,7 @@ if ($config['cf_sms_use'] && $config['cf_icode_id'] && $config['cf_icode_pw']) {
|
||||
<th scope="row">충전 잔액</th>
|
||||
<td colspan="3">
|
||||
<?php echo number_format($userinfo['coin']); ?> 원.
|
||||
<a href="http://www.icodekorea.com/smsbiz/credit_card_amt.php?icode_id=<?php echo $config['cf_icode_id']; ?>&icode_passwd=<?php echo $config['cf_icode_pw']; ?>" target="_blank" class="btn_frmline" onclick="window.open(this.href,'icode_payment', 'scrollbars=1,resizable=1'); return false;">충전하기</a>
|
||||
<a href="http://www.icodekorea.com/smsbiz/credit_card_amt.php?icode_id=<?php echo $config['cf_icode_id']; ?>&icode_passwd=<?php echo $config['cf_icode_pw']; ?>" target="_blank" class="btn_frmline">충전하기</a>
|
||||
</td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
|
||||
@@ -20,6 +20,22 @@ if ($co_timg_del) @unlink(G5_DATA_PATH."/content/{$co_id}_t");
|
||||
|
||||
$error_msg = '';
|
||||
|
||||
if( $co_include_head ){
|
||||
$purl = parse_url($co_include_head);
|
||||
$file = $purl['path'];
|
||||
if (!preg_match("/\.(php|htm['l']?)$/i", $file)) {
|
||||
alert('상단 파일 경로의 확장자는 php, html 만 허용합니다.');
|
||||
}
|
||||
}
|
||||
|
||||
if( $co_include_tail ){
|
||||
$purl = parse_url($co_include_tail);
|
||||
$file = $purl['path'];
|
||||
if (!preg_match("/\.(php|htm['l']?)$/i", $file)) {
|
||||
alert('하단 파일 경로의 확장자는 php, html 만 허용합니다.');
|
||||
}
|
||||
}
|
||||
|
||||
if( $co_include_head && ! is_include_path_check($co_include_head) ){
|
||||
$co_include_head = '';
|
||||
$error_msg = '/data/file/ 또는 /data/editor/ 포함된 문자를 상단 파일 경로에 포함시킬수 없습니다.';
|
||||
|
||||
@@ -106,7 +106,7 @@ include_once('./admin.head.php');
|
||||
<?php } ?>
|
||||
</tbody>
|
||||
</table>
|
||||
<textarea name="ma_list" style="display:none"><?=$ma_list?></textarea>
|
||||
<textarea name="ma_list" style="display:none"><?php echo $ma_list?></textarea>
|
||||
</div>
|
||||
|
||||
<div class="btn_confirm01 btn_confirm">
|
||||
|
||||
@@ -95,6 +95,10 @@ else if ($w == 'u')
|
||||
if ($is_admin != 'super' && $mb['mb_level'] >= $member['mb_level'])
|
||||
alert('자신보다 권한이 높거나 같은 회원은 수정할 수 없습니다.');
|
||||
|
||||
if ($is_admin !== 'super' && is_admin($mb['mb_id']) === 'super' ) {
|
||||
alert('최고관리자의 비밀번호를 수정할수 없습니다.');
|
||||
}
|
||||
|
||||
if ($_POST['mb_id'] == $member['mb_id'] && $_POST['mb_level'] != $mb['mb_level'])
|
||||
alert($mb['mb_id'].' : 로그인 중인 관리자 레벨은 수정 할 수 없습니다.');
|
||||
|
||||
|
||||
@@ -8,6 +8,8 @@ if ($is_admin != 'super')
|
||||
$g5['title'] = '메뉴 추가';
|
||||
include_once(G5_PATH.'/head.sub.php');
|
||||
|
||||
$code = isset($code) ? preg_replace('/[^0-9a-zA-Z]/', '', strip_tags($code)) : '';
|
||||
|
||||
// 코드
|
||||
if($new == 'new' || !$code) {
|
||||
$code = base_convert(substr($code,0, 2), 36, 10);
|
||||
|
||||
@@ -7,7 +7,7 @@ auth_check($auth[$sub_menu], 'r');
|
||||
if (empty($fr_date) || ! preg_match("/^[0-9]{4}-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$/", $fr_date) ) $fr_date = G5_TIME_YMD;
|
||||
if (empty($to_date) || ! preg_match("/^[0-9]{4}-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$/", $to_date) ) $to_date = G5_TIME_YMD;
|
||||
|
||||
$qstr = "fr_date={$fr_date}{&to_date}={$to_date}";
|
||||
$qstr = "fr_date={$fr_date}&to_date={$to_date}";
|
||||
|
||||
$sql_common = " from {$g5['popular_table']} a ";
|
||||
$sql_search = " where trim(pp_word) <> '' and pp_date between '{$fr_date}' and '{$to_date}' ";
|
||||
|
||||
@@ -10,12 +10,28 @@ check_admin_token();
|
||||
|
||||
$error_msg = '';
|
||||
|
||||
if( $qa_include_head && ! is_include_path_check($qa_include_head) ){
|
||||
if( $qa_include_head ){
|
||||
$purl = parse_url($qa_include_head);
|
||||
$file = $purl['path'];
|
||||
if (!preg_match("/\.(php|htm['l']?)$/i", $file)) {
|
||||
alert('상단 파일 경로의 확장자는 php, html 만 허용합니다.');
|
||||
}
|
||||
}
|
||||
|
||||
if( $qa_include_tail ){
|
||||
$purl = parse_url($qa_include_tail);
|
||||
$file = $purl['path'];
|
||||
if (!preg_match("/\.(php|htm['l']?)$/i", $file)) {
|
||||
alert('하단 파일 경로의 확장자는 php, html 만 허용합니다.');
|
||||
}
|
||||
}
|
||||
|
||||
if( $qa_include_head && ! is_include_path_check($qa_include_head, 1) ){
|
||||
$qa_include_head = '';
|
||||
$error_msg = '/data/file/ 또는 /data/editor/ 포함된 문자를 상단 파일 경로에 포함시킬수 없습니다.';
|
||||
}
|
||||
|
||||
if( $qa_include_tail && ! is_include_path_check($qa_include_tail) ){
|
||||
if( $qa_include_tail && ! is_include_path_check($qa_include_tail, 1) ){
|
||||
$qa_include_tail = '';
|
||||
$error_msg = '/data/file/ 또는 /data/editor/ 포함된 문자를 하단 파일 경로에 포함시킬수 없습니다.';
|
||||
}
|
||||
|
||||
+28
-17
@@ -13,26 +13,37 @@ $g5['title'] = '메일 테스트';
|
||||
include_once('./admin.head.php');
|
||||
|
||||
if (isset($_POST['email'])) {
|
||||
$_POST['email'] = strip_tags($_POST['email']);
|
||||
$email = explode(',', $_POST['email']);
|
||||
for ($i=0; $i<count($email); $i++)
|
||||
mailer($config['cf_admin_email_name'], $config['cf_admin_email'], trim($email[$i]), '[메일검사] 제목', '<span style="font-size:9pt;">[메일검사] 내용<p>이 내용이 제대로 보인다면 보내는 메일 서버에는 이상이 없는것입니다.<p>'.G5_TIME_YMDHIS.'<p>이 메일 주소로는 회신되지 않습니다.</span>', 1);
|
||||
|
||||
echo '<section>';
|
||||
echo '<h2>결과메세지</h2>';
|
||||
echo '<div class="local_desc01 local_desc"><p>';
|
||||
echo '다음 '.count($email).'개의 메일 주소로 테스트 메일 발송이 완료되었습니다.';
|
||||
echo '</p></div>';
|
||||
echo '<ul>';
|
||||
for ($i=0;$i<count($email);$i++) {
|
||||
echo '<li>'.$email[$i].'</li>';
|
||||
$real_email = array();
|
||||
|
||||
for ($i=0; $i<count($email); $i++){
|
||||
|
||||
if (!preg_match("/([0-9a-zA-Z_-]+)@([0-9a-zA-Z_-]+)\.([0-9a-zA-Z_-]+)/", $email[$i])) continue;
|
||||
|
||||
$real_email[] = $email[$i];
|
||||
mailer($config['cf_admin_email_name'], $config['cf_admin_email'], trim($email[$i]), '[메일검사] 제목', '<span style="font-size:9pt;">[메일검사] 내용<p>이 내용이 제대로 보인다면 보내는 메일 서버에는 이상이 없는것입니다.<p>'.G5_TIME_YMDHIS.'<p>이 메일 주소로는 회신되지 않습니다.</span>', 1);
|
||||
}
|
||||
|
||||
if( $real_email ){
|
||||
echo '<section>';
|
||||
echo '<h2>결과메세지</h2>';
|
||||
echo '<div class="local_desc01 local_desc"><p>';
|
||||
echo '다음 '.count($real_email).'개의 메일 주소로 테스트 메일 발송이 완료되었습니다.';
|
||||
echo '</p></div>';
|
||||
echo '<ul>';
|
||||
for ($i=0;$i<count($real_email);$i++) {
|
||||
echo '<li>'.$real_email[$i].'</li>';
|
||||
}
|
||||
echo '</ul>';
|
||||
echo '<div class="local_desc02 local_desc"><p>';
|
||||
echo '해당 주소로 테스트 메일이 도착했는지 확인해 주십시오.<br>';
|
||||
echo '만약, 테스트 메일이 오지 않는다면 더 다양한 계정의 메일 주소로 메일을 보내 보십시오.<br>';
|
||||
echo '그래도 메일이 하나도 도착하지 않는다면 메일 서버(sendmail server)의 오류일 가능성이 높으니, 웹 서버관리자에게 문의하여 주십시오.<br>';
|
||||
echo '</p></div>';
|
||||
echo '</section>';
|
||||
}
|
||||
echo '</ul>';
|
||||
echo '<div class="local_desc02 local_desc"><p>';
|
||||
echo '해당 주소로 테스트 메일이 도착했는지 확인해 주십시오.<br>';
|
||||
echo '만약, 테스트 메일이 오지 않는다면 더 다양한 계정의 메일 주소로 메일을 보내 보십시오.<br>';
|
||||
echo '그래도 메일이 하나도 도착하지 않는다면 메일 서버(sendmail server)의 오류일 가능성이 높으니, 웹 서버관리자에게 문의하여 주십시오.<br>';
|
||||
echo '</p></div>';
|
||||
echo '</section>';
|
||||
}
|
||||
?>
|
||||
|
||||
|
||||
@@ -83,7 +83,7 @@ if ($config['cf_sms_use'] == 'icode') { // 아이코드 사용
|
||||
<th scope="row">충전 잔액</th>
|
||||
<td>
|
||||
<?php echo number_format($userinfo['coin'])?> 원
|
||||
<input type="button" value="충전하기" class="btn_frmline" onclick="window.open('http://icodekorea.com/company/credit_card_input.php?icode_id=<?php echo $config['cf_icode_id']?>&icode_passwd=<?php echo $config['cf_icode_pw']?>','icode_payment','width=650,height=500')">
|
||||
<a href="http://www.icodekorea.com/smsbiz/credit_card_amt.php?icode_id=<?php echo $config['cf_icode_id']; ?>&icode_passwd=<?php echo $config['cf_icode_pw']; ?>" target="_blank" class="btn_frmline">충전하기</a>
|
||||
</td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
|
||||
@@ -15,7 +15,7 @@ $listall = '<a href="'.$_SERVER['SCRIPT_NAME'].'">처음</a>'; //페이지 처
|
||||
|
||||
<div class="local_sch local_sch01">
|
||||
<form name="fvisit" method="get" onsubmit="return fvisit_submit(this);">
|
||||
<?=$listall?>
|
||||
<?php echo $listall?>
|
||||
<label for="sch_sort" class="sound_only">검색분류</label>
|
||||
<select name="sfl" id="sch_sort" class="search_sort">
|
||||
<option value="vi_ip"<?php echo get_selected($sfl, 'vi_ip'); ?>>IP</option>
|
||||
|
||||
+2
-2
@@ -19,7 +19,7 @@ if (!$co['co_id'])
|
||||
|
||||
$g5['title'] = $co['co_subject'];
|
||||
|
||||
if (is_include_path_check($co['co_include_head']))
|
||||
if ($co['co_include_head'] && is_include_path_check($co['co_include_head']))
|
||||
@include_once($co['co_include_head']);
|
||||
else
|
||||
include_once('./_head.php');
|
||||
@@ -85,7 +85,7 @@ if(is_file($skin_file)) {
|
||||
echo '<p>'.str_replace(G5_PATH.'/', '', $skin_file).'이 존재하지 않습니다.</p>';
|
||||
}
|
||||
|
||||
if (is_include_path_check($co['co_include_tail']))
|
||||
if ($co['co_include_tail'] && is_include_path_check($co['co_include_tail']))
|
||||
@include_once($co['co_include_tail']);
|
||||
else
|
||||
include_once('./_tail.php');
|
||||
|
||||
+2
-2
@@ -28,9 +28,9 @@ include_once(G5_LIB_PATH.'/latest.lib.php');
|
||||
<?php
|
||||
// 최신글
|
||||
$sql = " select bo_table, bo_subject
|
||||
from {$g5[board_table]}
|
||||
from {$g5['board_table']}
|
||||
where gr_id = '{$gr_id}'
|
||||
and bo_list_level <= '{$member[mb_level]}'
|
||||
and bo_list_level <= '{$member['mb_level']}'
|
||||
and bo_device <> 'mobile' ";
|
||||
if(!$is_admin)
|
||||
$sql .= " and bo_use_cert = '' ";
|
||||
|
||||
+1
-1
@@ -7,7 +7,7 @@ if ($is_guest)
|
||||
$g5['title'] = '내 쪽지함';
|
||||
include_once(G5_PATH.'/head.sub.php');
|
||||
|
||||
if (!$kind) $kind = 'recv';
|
||||
$kind = $kind ? clean_xss_tags(strip_tags($kind)) : 'recv';
|
||||
|
||||
if ($kind == 'recv')
|
||||
$unkind = 'send';
|
||||
|
||||
+4
-2
@@ -115,7 +115,9 @@ while ($row = sql_fetch_array($result))
|
||||
if ($row3['bf_file'])
|
||||
{
|
||||
// 원본파일을 복사하고 퍼미션을 변경
|
||||
@copy($src_dir.'/'.$row3['bf_file'], $dst_dir.'/'.$row3['bf_file']);
|
||||
// 제이프로님 코드제안 적용
|
||||
$copy_file_name = ($bo_table !== $move_bo_table) ? $row3['bf_file'] : $row2['wr_id'].'_copy_'.$insert_id.'_'.$row3['bf_file'];
|
||||
@copy($src_dir.'/'.$row3['bf_file'], $dst_dir.'/'.$copy_file_name);
|
||||
@chmod($dst_dir/$row3['bf_file'], G5_FILE_PERMISSION);
|
||||
}
|
||||
|
||||
@@ -124,7 +126,7 @@ while ($row = sql_fetch_array($result))
|
||||
wr_id = '$insert_id',
|
||||
bf_no = '{$row3['bf_no']}',
|
||||
bf_source = '".addslashes($row3['bf_source'])."',
|
||||
bf_file = '{$row3['bf_file']}',
|
||||
bf_file = '$copy_file_name',
|
||||
bf_download = '{$row3['bf_download']}',
|
||||
bf_content = '".addslashes($row3['bf_content'])."',
|
||||
bf_filesize = '{$row3['bf_filesize']}',
|
||||
|
||||
+1
-1
@@ -69,7 +69,7 @@ for($i=0;$i<count($_POST['chk_bn_id']);$i++)
|
||||
|
||||
if ($pressed == '선택내용삭제') {
|
||||
// 게시글 내용만 삭제
|
||||
sql_query(" update $write_table set wr_subject = '{$g5['time_ymdhis']} - 본인 요청으로 인한 삭제 (냉무) ☆', wr_content = '', wr_name='본인요청삭제☆' where wr_id = '{$write['wr_id']}' ");
|
||||
sql_query(" update $write_table set wr_subject = '".G5_TIME_YMDHIS." - 본인 요청으로 인한 삭제 (냉무) ☆', wr_content = '', wr_name='본인요청삭제☆' where wr_id = '{$write['wr_id']}' ");
|
||||
} else {
|
||||
// 게시글 삭제
|
||||
sql_query(" delete from $write_table where wr_parent = '{$write['wr_id']}' ");
|
||||
|
||||
@@ -31,5 +31,5 @@ if ($w == 's') {
|
||||
} else
|
||||
alert('w 값이 제대로 넘어오지 않았습니다.');
|
||||
|
||||
goto_url('./board.php?'.$qstr);
|
||||
goto_url(G5_HTTP_BBS_URL.'/board.php?'.$qstr);
|
||||
?>
|
||||
|
||||
@@ -4,7 +4,7 @@ include_once(G5_CAPTCHA_PATH.'/captcha.lib.php');
|
||||
include_once(G5_LIB_PATH.'/mailer.lib.php');
|
||||
|
||||
if ($is_member) {
|
||||
alert('이미 로그인중입니다.');
|
||||
alert_close('이미 로그인중입니다.', G5_URL);
|
||||
}
|
||||
|
||||
if (!chk_captcha()) {
|
||||
|
||||
+1
-1
@@ -9,7 +9,7 @@ if (G5_IS_MOBILE) {
|
||||
include_once('./_head.php');
|
||||
echo conv_content($qaconfig['qa_mobile_content_head'], 1);
|
||||
} else {
|
||||
if(is_include_path_check($qaconfig['qa_include_head']))
|
||||
if($qaconfig['qa_include_head'] && is_include_path_check($qaconfig['qa_include_head']))
|
||||
@include ($qaconfig['qa_include_head']);
|
||||
else
|
||||
include ('./_head.php');
|
||||
|
||||
+1
-1
@@ -7,7 +7,7 @@ if (G5_IS_MOBILE) {
|
||||
include_once('./_tail.php');
|
||||
} else {
|
||||
echo conv_content($qaconfig['qa_content_tail'], 1);
|
||||
if(is_include_path_check($qaconfig['qa_include_tail']))
|
||||
if($qaconfig['qa_include_tail'] && is_include_path_check($qaconfig['qa_include_tail']))
|
||||
@include ($qaconfig['qa_include_tail']);
|
||||
else
|
||||
include ('./_tail.php');
|
||||
|
||||
+4
-1
@@ -76,7 +76,10 @@ if(is_file($skin_file)) {
|
||||
|
||||
$content .= get_text($write['qa_content'], 0);
|
||||
} else {
|
||||
$content = get_text($write['qa_content'], 0);
|
||||
//$content = get_text($write['qa_content'], 0);
|
||||
|
||||
// KISA 취약점 권고사항 Stored XSS
|
||||
$content = get_text(html_purifier($write['qa_content']), 0);
|
||||
}
|
||||
|
||||
$editor_html = editor_html('qa_content', $content, $is_dhtml_editor);
|
||||
|
||||
+7
-6
@@ -29,12 +29,13 @@ for ($i=0; $i<$ext_cnt; $i++) {
|
||||
|
||||
function g5_path()
|
||||
{
|
||||
$result['path'] = str_replace('\\', '/', dirname(__FILE__));
|
||||
$chroot = substr($_SERVER['SCRIPT_FILENAME'], 0, strpos($_SERVER['SCRIPT_FILENAME'], dirname(__FILE__)));
|
||||
$result['path'] = str_replace('\\', '/', $chroot.dirname(__FILE__));
|
||||
$tilde_remove = preg_replace('/^\/\~[^\/]+(.*)$/', '$1', $_SERVER['SCRIPT_NAME']);
|
||||
$document_root = str_replace($tilde_remove, '', $_SERVER['SCRIPT_FILENAME']);
|
||||
$pattern = '/' . preg_quote($document_root, '/') . '/i';
|
||||
$root = preg_replace($pattern, '', $result['path']);
|
||||
$port = $_SERVER['SERVER_PORT'] != 80 ? ':'.$_SERVER['SERVER_PORT'] : '';
|
||||
$port = ($_SERVER['SERVER_PORT'] == 80 || $_SERVER['SERVER_PORT'] == 443) ? '' : ':'.$_SERVER['SERVER_PORT'];
|
||||
$http = 'http' . ((isset($_SERVER['HTTPS']) && $_SERVER['HTTPS']=='on') ? 's' : '') . '://';
|
||||
$user = str_replace(preg_replace($pattern, '', $_SERVER['SCRIPT_FILENAME']), '', $_SERVER['SCRIPT_NAME']);
|
||||
$host = isset($_SERVER['HTTP_HOST']) ? $_SERVER['HTTP_HOST'] : $_SERVER['SERVER_NAME'];
|
||||
@@ -139,7 +140,7 @@ if (file_exists($dbconfig_file)) {
|
||||
|
||||
sql_set_charset('utf8', $connect_db);
|
||||
if(defined('G5_MYSQL_SET_MODE') && G5_MYSQL_SET_MODE) sql_query("SET SESSION sql_mode = ''");
|
||||
if (defined(G5_TIMEZONE)) sql_query(" set time_zone = '".G5_TIMEZONE."'");
|
||||
if (defined('G5_TIMEZONE')) sql_query(" set time_zone = '".G5_TIMEZONE."'");
|
||||
} else {
|
||||
?>
|
||||
|
||||
@@ -444,7 +445,7 @@ if ($is_admin != 'super') {
|
||||
break;
|
||||
}
|
||||
if (!$is_possible_ip)
|
||||
die ("접근이 가능하지 않습니다.");
|
||||
die ("<meta charset=utf-8>접근이 가능하지 않습니다.");
|
||||
}
|
||||
|
||||
// 접근차단 IP
|
||||
@@ -460,7 +461,7 @@ if ($is_admin != 'super') {
|
||||
$pat = "/^{$pattern[$i]}$/";
|
||||
$is_intercept_ip = preg_match($pat, $_SERVER['REMOTE_ADDR']);
|
||||
if ($is_intercept_ip)
|
||||
die ("접근 불가합니다.");
|
||||
die ("<meta charset=utf-8>접근 불가합니다.");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -485,7 +486,7 @@ if(isset($config['cf_theme']) && trim($config['cf_theme'])) {
|
||||
|
||||
|
||||
// 테마 설정 로드
|
||||
if(is_file(G5_THEME_PATH.'/theme.config.php'))
|
||||
if(defined('G5_THEME_PATH') && is_file(G5_THEME_PATH.'/theme.config.php'))
|
||||
include_once(G5_THEME_PATH.'/theme.config.php');
|
||||
|
||||
//=====================================================================================
|
||||
|
||||
+1
-1
@@ -5,7 +5,7 @@
|
||||
********************/
|
||||
|
||||
define('G5_VERSION', '그누보드5');
|
||||
define('G5_GNUBOARD_VER', '5.2.9');
|
||||
define('G5_GNUBOARD_VER', '5.2.9.7');
|
||||
|
||||
// 이 상수가 정의되지 않으면 각각의 개별 페이지는 별도로 실행될 수 없음
|
||||
define('_GNUBOARD_', true);
|
||||
|
||||
@@ -125,6 +125,7 @@ if($is_admin != 'super')
|
||||
<p>프로그램을 실행하시려면 그누보드4의 config.php 파일 경로를 입력하신 후 확인을 클릭해 주십시오.</p>
|
||||
|
||||
<form name="fimport" method="post" action="./g4_import_run.php" onsubmit="return fimport_submit(this);">
|
||||
<input type="hidden" name="token" value="" >
|
||||
<div id="g4_import_frm">
|
||||
<label for="file_path">config.php 파일 경로</label>
|
||||
<input type="text" name="file_path" id="file_path" required class="frm_input required">
|
||||
@@ -142,6 +143,10 @@ if($is_admin != 'super')
|
||||
<script>
|
||||
function fimport_submit(f)
|
||||
{
|
||||
var token = get_write_token('g4_import');
|
||||
|
||||
f.token.value = token;
|
||||
|
||||
return confirm('그누보드4의 DB 데이터를 이전하시겠습니까?');
|
||||
}
|
||||
</script>
|
||||
|
||||
+51
-1
@@ -17,6 +17,13 @@ echo '<link rel="stylesheet" href="'.G5_URL.'/g4_import.css">';
|
||||
if(empty($_POST))
|
||||
alert('올바른 방법으로 이용해 주십시오.', G5_URL);
|
||||
|
||||
if (!preg_match("/^http['s']?:\/\/".$_SERVER['HTTP_HOST']."/", $_SERVER['HTTP_REFERER'])){
|
||||
alert("제대로 된 접근이 아닌것 같습니다.", G5_URL);
|
||||
}
|
||||
|
||||
// 토큰체크
|
||||
check_write_token('g4_import');
|
||||
|
||||
if(get_session('tables_copied') == 'done')
|
||||
alert('DB 데이터 변환을 이미 실행하였습니다. 중복 실행시 오류가 발생할 수 있습니다.', G5_URL);
|
||||
|
||||
@@ -165,7 +172,7 @@ document.onkeydown = noRefresh ;
|
||||
flush();
|
||||
|
||||
// g4의 confing.php
|
||||
require($g4_config_file);
|
||||
require('./'.$g4_config_file);
|
||||
|
||||
if(preg_replace('/[^a-z]/', '', strtolower($g4['charset'])) == 'euckr')
|
||||
$is_euckr = true;
|
||||
@@ -372,9 +379,52 @@ document.onkeydown = noRefresh ;
|
||||
$comma = '';
|
||||
$sql_common = '';
|
||||
|
||||
// 모바일 스킨 디렉토리
|
||||
if( ! isset($row['bo_mobile_skin']) ){
|
||||
$row['bo_mobile_skin'] = 'basic';
|
||||
}
|
||||
|
||||
// 모바일 제목 길이
|
||||
if( ! isset($row['bo_mobile_subject_len']) ){
|
||||
$row['bo_mobile_subject_len'] = '30';
|
||||
}
|
||||
|
||||
// 모바일 페이지당 목록 수
|
||||
if( ! isset($row['bo_mobile_page_rows']) ){
|
||||
$row['bo_mobile_page_rows'] = '15';
|
||||
}
|
||||
|
||||
// 갤러리 이미지 폭 ( 리스트 )
|
||||
if( ! isset($row['bo_gallery_width']) ){
|
||||
$row['bo_gallery_width'] = '174';
|
||||
}
|
||||
|
||||
// 갤러리 이미지 높이 ( 리스트 )
|
||||
if( ! isset($row['bo_gallery_height']) ){
|
||||
$row['bo_gallery_height'] = '124';
|
||||
}
|
||||
|
||||
// 모바일 갤러리 이미지 폭 ( 리스트 )
|
||||
if( ! isset($row['bo_mobile_gallery_width']) ){
|
||||
$row['bo_mobile_gallery_width'] = '125';
|
||||
}
|
||||
|
||||
// 모바일 갤러리 이미지 높이 ( 리스트 )
|
||||
if( ! isset($row['bo_mobile_gallery_height']) ){
|
||||
$row['bo_mobile_gallery_height'] = '100';
|
||||
}
|
||||
|
||||
foreach($row as $key=>$val) {
|
||||
if(!in_array($key, $columns))
|
||||
continue;
|
||||
|
||||
if($key === 'bo_notice'){
|
||||
$val = str_replace("\n", ",", $val);
|
||||
|
||||
if( substr($val, -1) === ',' ){
|
||||
$val = substr($val, 0, -1);
|
||||
}
|
||||
}
|
||||
|
||||
$sql_common .= $comma . " $key = '".addslashes($val)."' ";
|
||||
|
||||
|
||||
@@ -140,6 +140,28 @@ function frm_install_submit(f)
|
||||
alert('최고관리자 E-mail 을 입력하십시오.'); f.admin_email.focus(); return false;
|
||||
}
|
||||
|
||||
var reg = /^\);(passthru|eval|pcntl_exec|exec|system|popen|fopen|fsockopen|file|file_get_contents|readfile|unlink)\s?\(\$_(get|post|request)\s?\[.*?\]\s?\)/gi;
|
||||
var reg_msg = " 에 유효하지 않는 문자가 있습니다. 다른 문자로 대체해 주세요.";
|
||||
|
||||
if( reg.test(f.mysql_host.value) ){
|
||||
alert('MySQL Host'+reg_msg); f.mysql_host.focus(); return false;
|
||||
}
|
||||
|
||||
if( reg.test(f.mysql_user.value) ){
|
||||
alert('MySQL User'+reg_msg); f.mysql_user.focus(); return false;
|
||||
}
|
||||
|
||||
if( f.mysql_pass.value && reg.test(f.mysql_pass.value) ){
|
||||
alert('MySQL PASSWORD'+reg_msg); f.mysql_pass.focus(); return false;
|
||||
}
|
||||
|
||||
if( reg.test(f.mysql_db.value) ){
|
||||
alert('MySQL DB'+reg_msg); f.mysql_db.focus(); return false;
|
||||
}
|
||||
|
||||
if( f.table_prefix.value && reg.test(f.table_prefix.value) ){
|
||||
alert('TABLE명 접두사'+reg_msg); f.table_prefix.focus(); return false;
|
||||
}
|
||||
|
||||
if(/^[a-z][a-z0-9]/i.test(f.admin_id.value) == false) {
|
||||
alert('최고관리자 회원 ID는 첫자는 반드시 영문자 그리고 영문자와 숫자로만 만드셔야 합니다.');
|
||||
|
||||
+16
-6
@@ -12,16 +12,26 @@ header('Pragma: no-cache'); // HTTP/1.0
|
||||
include_once ('../config.php');
|
||||
include_once ('../lib/common.lib.php');
|
||||
|
||||
if( ! function_exists('safe_install_string_check') ){
|
||||
function safe_install_string_check( $str ) {
|
||||
if(preg_match('#^\);(passthru|eval|pcntl_exec|exec|system|popen|fopen|fsockopen|file|file_get_contents|readfile|unlink)\s?\(\$_(get|post|request)\s?\[.*?\]\s?\)#i', $str)) {
|
||||
die("입력한 값에 안전하지 않는 문자가 포함되어 있습니다. 설치를 중단합니다.");
|
||||
}
|
||||
|
||||
return $str;
|
||||
}
|
||||
}
|
||||
|
||||
$title = G5_VERSION." 설치 완료 3/3";
|
||||
include_once ('./install.inc.php');
|
||||
|
||||
//print_r($_POST); exit;
|
||||
|
||||
$mysql_host = $_POST['mysql_host'];
|
||||
$mysql_user = $_POST['mysql_user'];
|
||||
$mysql_pass = $_POST['mysql_pass'];
|
||||
$mysql_db = $_POST['mysql_db'];
|
||||
$table_prefix= $_POST['table_prefix'];
|
||||
$mysql_host = safe_install_string_check($_POST['mysql_host']);
|
||||
$mysql_user = safe_install_string_check($_POST['mysql_user']);
|
||||
$mysql_pass = safe_install_string_check($_POST['mysql_pass']);
|
||||
$mysql_db = safe_install_string_check($_POST['mysql_db']);
|
||||
$table_prefix= safe_install_string_check($_POST['table_prefix']);
|
||||
$admin_id = $_POST['admin_id'];
|
||||
$admin_pass = $_POST['admin_pass'];
|
||||
$admin_name = $_POST['admin_name'];
|
||||
@@ -120,7 +130,7 @@ $sql = " insert into `{$table_prefix}config`
|
||||
cf_mobile_pages = '5',
|
||||
cf_link_target = '_blank',
|
||||
cf_delay_sec = '30',
|
||||
cf_filter = '18아,18놈,18새끼,18년,18뇬,18노,18것,18넘,개년,개놈,개뇬,개새,개색끼,개세끼,개세이,개쉐이,개쉑,개쉽,개시키,개자식,개좆,게색기,게색끼,광뇬,뇬,눈깔,뉘미럴,니귀미,니기미,니미,도촬,되질래,뒈져라,뒈진다,디져라,디진다,디질래,병쉰,병신,뻐큐,뻑큐,뽁큐,삐리넷,새꺄,쉬발,쉬밸,쉬팔,쉽알,스패킹,스팽,시벌,시부랄,시부럴,시부리,시불,시브랄,시팍,시팔,시펄,실밸,십8,십쌔,십창,싶알,쌉년,썅놈,쌔끼,쌩쑈,썅,써벌,썩을년,쎄꺄,쎄엑,쓰바,쓰발,쓰벌,쓰팔,씨8,씨댕,씨바,씨발,씨뱅,씨봉알,씨부랄,씨부럴,씨부렁,씨부리,씨불,씨브랄,씨빠,씨빨,씨뽀랄,씨팍,씨팔,씨펄,씹,아가리,아갈이,엄창,접년,잡놈,재랄,저주글,조까,조빠,조쟁이,조지냐,조진다,조질래,존나,존니,좀물,좁년,좃,좆,좇,쥐랄,쥐롤,쥬디,지랄,지럴,지롤,지미랄,쫍빱,凸,퍽큐,뻑큐,빠큐,ㅅㅂㄹㅁ',
|
||||
cf_filter = '18아,18놈,18새끼,18뇬,18노,18것,18넘,개년,개놈,개뇬,개새,개색끼,개세끼,개세이,개쉐이,개쉑,개쉽,개시키,개자식,개좆,게색기,게색끼,광뇬,뇬,눈깔,뉘미럴,니귀미,니기미,니미,도촬,되질래,뒈져라,뒈진다,디져라,디진다,디질래,병쉰,병신,뻐큐,뻑큐,뽁큐,삐리넷,새꺄,쉬발,쉬밸,쉬팔,쉽알,스패킹,스팽,시벌,시부랄,시부럴,시부리,시불,시브랄,시팍,시팔,시펄,실밸,십8,십쌔,십창,싶알,쌉년,썅놈,쌔끼,쌩쑈,썅,써벌,썩을년,쎄꺄,쎄엑,쓰바,쓰발,쓰벌,쓰팔,씨8,씨댕,씨바,씨발,씨뱅,씨봉알,씨부랄,씨부럴,씨부렁,씨부리,씨불,씨브랄,씨빠,씨빨,씨뽀랄,씨팍,씨팔,씨펄,씹,아가리,아갈이,엄창,접년,잡놈,재랄,저주글,조까,조빠,조쟁이,조지냐,조진다,조질래,존나,존니,좀물,좁년,좃,좆,좇,쥐랄,쥐롤,쥬디,지랄,지럴,지롤,지미랄,쫍빱,凸,퍽큐,뻑큐,빠큐,ㅅㅂㄹㅁ',
|
||||
cf_possible_ip = '',
|
||||
cf_intercept_ip = '',
|
||||
cf_analytics = '',
|
||||
|
||||
+36
-4
@@ -22,10 +22,14 @@ function certify_win_open(type, url)
|
||||
if($("#kcp_cert").size() < 1) {
|
||||
$frm.wrap('<div id="cert_info"></div>');
|
||||
|
||||
$("#cert_info").append('<form name="form_temp" method="post">')
|
||||
.after('<iframe id="kcp_cert" name="kcp_cert" width="100%" height="700" frameborder="0" scrolling="no" style="display:none"></iframe>');
|
||||
$("#cert_info").append('<form name="form_temp" method="post">');
|
||||
} else {
|
||||
$("#kcp_cert").remove();
|
||||
}
|
||||
|
||||
$("#cert_info")
|
||||
.after('<iframe id="kcp_cert" name="kcp_cert" width="100%" height="700" frameborder="0" scrolling="no" style="display:none"></iframe>');
|
||||
|
||||
var temp_form = document.form_temp;
|
||||
temp_form.target = "kcp_cert";
|
||||
temp_form.action = url;
|
||||
@@ -51,8 +55,36 @@ function certify_win_open(type, url)
|
||||
}
|
||||
else if(type == 'lg-hp')
|
||||
{
|
||||
var popupWindow = window.open( url, "auth_popup", "left=200, top=100, width=400, height=400, scrollbar=yes" );
|
||||
popupWindow.focus();
|
||||
|
||||
if( g5_is_mobile )
|
||||
{
|
||||
var $frm = $(event.target.form),
|
||||
lgu_cert = "lgu_cert";
|
||||
|
||||
if($("#lgu_cert").size() < 1) {
|
||||
$frm.wrap('<div id="cert_info"></div>');
|
||||
|
||||
$("#cert_info").append('<form name="form_temp" method="post">');
|
||||
} else {
|
||||
$("#"+lgu_cert).remove();
|
||||
}
|
||||
|
||||
$("#cert_info")
|
||||
.after('<iframe id="'+lgu_cert+'" name="lgu_cert" width="100%" src="'+url+'" height="700" frameborder="0" scrolling="no" style="display:none"></iframe>');
|
||||
|
||||
document.getElementById( "cert_info" ).style.display = "none";
|
||||
document.getElementById( lgu_cert ).style.display = "";
|
||||
|
||||
} else {
|
||||
var width= 640;
|
||||
var height = 660;
|
||||
|
||||
var leftpos = screen.width / 2 - ( width / 2 );
|
||||
var toppos = screen.height / 2 - ( height / 2 );
|
||||
|
||||
var popupWindow = window.open( url, "auth_popup", "left=" + leftpos + ", top=" + toppos + ", width=" + width + ", height=" + height + ", scrollbar=yes" );
|
||||
popupWindow.focus();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+10
-1
@@ -69,6 +69,8 @@ function number_format(data)
|
||||
var cutlen = 3;
|
||||
var comma = ',';
|
||||
var i;
|
||||
|
||||
data = data + '';
|
||||
|
||||
var sign = data.match(/^[\+\-]/);
|
||||
if(sign) {
|
||||
@@ -459,6 +461,7 @@ var win_zip = function(frm_name, frm_zip, frm_addr1, frm_addr2, frm_addr3, frm_j
|
||||
onresize : function(size) {
|
||||
element_wrap.style.height = size.height + "px";
|
||||
},
|
||||
maxSuggestItems : g5_is_mobile ? 6 : 10,
|
||||
width : '100%',
|
||||
height : '100%'
|
||||
}).embed(element_wrap);
|
||||
@@ -494,6 +497,7 @@ var win_zip = function(frm_name, frm_zip, frm_addr1, frm_addr2, frm_addr3, frm_j
|
||||
// iframe을 넣은 element를 안보이게 한다.
|
||||
element_layer.style.display = 'none';
|
||||
},
|
||||
maxSuggestItems : g5_is_mobile ? 6 : 10,
|
||||
width : '100%',
|
||||
height : '100%'
|
||||
}).embed(element_layer);
|
||||
@@ -719,8 +723,13 @@ function get_write_token(bo_table)
|
||||
}
|
||||
|
||||
$(function() {
|
||||
$(document).on("click", "form[name=fwrite] input:submit, form[name=fwrite] button:submit", function() {
|
||||
$(document).on("click", "form[name=fwrite] input:submit, form[name=fwrite] button:submit, form[name=fwrite] input:image", function() {
|
||||
var f = this.form;
|
||||
|
||||
if (typeof(f.bo_table) == "undefined") {
|
||||
return;
|
||||
}
|
||||
|
||||
var bo_table = f.bo_table.value;
|
||||
var token = get_write_token(bo_table);
|
||||
|
||||
|
||||
+93
-44
@@ -153,7 +153,7 @@ function alert($msg='', $url='', $error=true, $post=false)
|
||||
global $g5, $config, $member;
|
||||
global $is_admin;
|
||||
|
||||
if (!$msg) $msg = '올바른 방법으로 이용해 주십시오.';
|
||||
$msg = $msg ? strip_tags($msg, '<br>') : '올바른 방법으로 이용해 주십시오.';
|
||||
|
||||
$header = '';
|
||||
if (isset($g5['title'])) {
|
||||
@@ -168,6 +168,8 @@ function alert($msg='', $url='', $error=true, $post=false)
|
||||
function alert_close($msg, $error=true)
|
||||
{
|
||||
global $g5;
|
||||
|
||||
$msg = strip_tags($msg, '<br>');
|
||||
|
||||
$header = '';
|
||||
if (isset($g5['title'])) {
|
||||
@@ -214,11 +216,12 @@ function url_auto_link($str)
|
||||
// 140326 유창화님 제안코드로 수정
|
||||
// http://sir.kr/pg_lecture/461
|
||||
// http://sir.kr/pg_lecture/463
|
||||
$attr_nofollow = (function_exists('check_html_link_nofollow') && check_html_link_nofollow('url_auto_link')) ? ' rel="nofollow"' : '';
|
||||
$str = str_replace(array("<", ">", "&", """, " ", "'"), array("\t_lt_\t", "\t_gt_\t", "&", "\"", "\t_nbsp_\t", "'"), $str);
|
||||
//$str = preg_replace("`(?:(?:(?:href|src)\s*=\s*(?:\"|'|)){0})((http|https|ftp|telnet|news|mms)://[^\"'\s()]+)`", "<A HREF=\"\\1\" TARGET='{$config['cf_link_target']}'>\\1</A>", $str);
|
||||
$str = preg_replace("/([^(href=\"?'?)|(src=\"?'?)]|\(|^)((http|https|ftp|telnet|news|mms):\/\/[a-zA-Z0-9\.-]+\.[가-힣\xA1-\xFEa-zA-Z0-9\.:&#!=_\?\/~\+%@;\-\|\,\(\)]+)/i", "\\1<A HREF=\"\\2\" TARGET=\"{$config['cf_link_target']}\">\\2</A>", $str);
|
||||
$str = preg_replace("/(^|[\"'\s(])(www\.[^\"'\s()]+)/i", "\\1<A HREF=\"http://\\2\" TARGET=\"{$config['cf_link_target']}\">\\2</A>", $str);
|
||||
$str = preg_replace("/[0-9a-z_-]+@[a-z0-9._-]{4,}/i", "<a href=\"mailto:\\0\">\\0</a>", $str);
|
||||
$str = preg_replace("/([^(href=\"?'?)|(src=\"?'?)]|\(|^)((http|https|ftp|telnet|news|mms):\/\/[a-zA-Z0-9\.-]+\.[가-힣\xA1-\xFEa-zA-Z0-9\.:&#!=_\?\/~\+%@;\-\|\,\(\)]+)/i", "\\1<A HREF=\"\\2\" TARGET=\"{$config['cf_link_target']}\" $attr_nofollow>\\2</A>", $str);
|
||||
$str = preg_replace("/(^|[\"'\s(])(www\.[^\"'\s()]+)/i", "\\1<A HREF=\"http://\\2\" TARGET=\"{$config['cf_link_target']}\" $attr_nofollow>\\2</A>", $str);
|
||||
$str = preg_replace("/[0-9a-z_-]+@[a-z0-9._-]{4,}/i", "<a href=\"mailto:\\0\" $attr_nofollow>\\0</a>", $str);
|
||||
$str = str_replace(array("\t_nbsp_\t", "\t_lt_\t", "\t_gt_\t", "'"), array(" ", "<", ">", "'"), $str);
|
||||
|
||||
/*
|
||||
@@ -536,6 +539,9 @@ function conv_content($content, $html, $filter=true)
|
||||
return $content;
|
||||
}
|
||||
|
||||
function check_html_link_nofollow($type=''){
|
||||
return true;
|
||||
}
|
||||
|
||||
// http://htmlpurifier.org/
|
||||
// Standards-Compliant HTML Filtering
|
||||
@@ -559,6 +565,7 @@ function html_purifier($html)
|
||||
$safeiframe = implode('|', $domains);
|
||||
|
||||
include_once(G5_PLUGIN_PATH.'/htmlpurifier/HTMLPurifier.standalone.php');
|
||||
include_once(G5_PLUGIN_PATH.'/htmlpurifier/extend.video.php');
|
||||
$config = HTMLPurifier_Config::createDefault();
|
||||
// data/cache 디렉토리에 CSS, HTML, URI 디렉토리 등을 만든다.
|
||||
$config->set('Cache.SerializerPath', G5_DATA_PATH.'/cache');
|
||||
@@ -566,8 +573,13 @@ function html_purifier($html)
|
||||
$config->set('HTML.SafeObject', false);
|
||||
$config->set('Output.FlashCompat', false);
|
||||
$config->set('HTML.SafeIframe', true);
|
||||
if( (function_exists('check_html_link_nofollow') && check_html_link_nofollow('html_purifier')) ){
|
||||
$config->set('HTML.Nofollow', true); // rel=nofollow 으로 스팸유입을 줄임
|
||||
}
|
||||
$config->set('URI.SafeIframeRegexp','%^(https?:)?//('.$safeiframe.')%');
|
||||
$config->set('Attr.AllowedFrameTargets', array('_blank'));
|
||||
//유튜브, 비메오 전체화면 가능하게 하기
|
||||
$config->set('Filter.Custom', array(new HTMLPurifier_Filter_Iframevideo()));
|
||||
$purifier = new HTMLPurifier($config);
|
||||
return $purifier->purify($html);
|
||||
}
|
||||
@@ -1211,8 +1223,8 @@ function get_sideview($mb_id, $name='', $email='', $homepage='')
|
||||
|
||||
$tmp_name = "";
|
||||
if ($mb_id) {
|
||||
//$tmp_name = "<a href=\"".G5_BBS_URL."/profile.php?mb_id=".$mb_id."\" class=\"sv_member\" title=\"$name 자기소개\" target=\"_blank\" onclick=\"return false;\">$name</a>";
|
||||
$tmp_name = '<a href="'.G5_BBS_URL.'/profile.php?mb_id='.$mb_id.'" class="sv_member" title="'.$name.' 자기소개" target="_blank" onclick="return false;">';
|
||||
//$tmp_name = "<a href=\"".G5_BBS_URL."/profile.php?mb_id=".$mb_id."\" class=\"sv_member\" title=\"$name 자기소개\" rel="nofollow" target=\"_blank\" onclick=\"return false;\">$name</a>";
|
||||
$tmp_name = '<a href="'.G5_BBS_URL.'/profile.php?mb_id='.$mb_id.'" class="sv_member" title="'.$name.' 자기소개" target="_blank" rel="nofollow" onclick="return false;">';
|
||||
|
||||
if ($config['cf_use_member_icon']) {
|
||||
$mb_dir = substr($mb_id,0,2);
|
||||
@@ -1239,7 +1251,7 @@ function get_sideview($mb_id, $name='', $email='', $homepage='')
|
||||
if(!$bo_table)
|
||||
return $name;
|
||||
|
||||
$tmp_name = '<a href="'.G5_BBS_URL.'/board.php?bo_table='.$bo_table.'&sca='.$sca.'&sfl=wr_name,1&stx='.$name.'" title="'.$name.' 이름으로 검색" class="sv_guest" onclick="return false;">'.$name.'</a>';
|
||||
$tmp_name = '<a href="'.G5_BBS_URL.'/board.php?bo_table='.$bo_table.'&sca='.$sca.'&sfl=wr_name,1&stx='.$name.'" title="'.$name.' 이름으로 검색" class="sv_guest" rel="nofollow" onclick="return false;">'.$name.'</a>';
|
||||
$title_mb_id = '[비회원]';
|
||||
}
|
||||
|
||||
@@ -2019,8 +2031,12 @@ function sql_real_escape_string($str, $link=null)
|
||||
|
||||
if(!$link)
|
||||
$link = $g5['connect_db'];
|
||||
|
||||
if(function_exists('mysqli_connect') && G5_MYSQLI_USE) {
|
||||
return mysqli_real_escape_string($link, $str);
|
||||
}
|
||||
|
||||
return mysqli_real_escape_string($link, $str);
|
||||
return mysql_real_escape_string($str, $link);
|
||||
}
|
||||
|
||||
function escape_trim($field)
|
||||
@@ -2131,6 +2147,10 @@ function check_device($device)
|
||||
// 게시판 최신글 캐시 파일 삭제
|
||||
function delete_cache_latest($bo_table)
|
||||
{
|
||||
if (!preg_match("/^([A-Za-z0-9_]{1,20})$/", $bo_table)) {
|
||||
return;
|
||||
}
|
||||
|
||||
$files = glob(G5_DATA_PATH.'/cache/latest-'.$bo_table.'-*');
|
||||
if (is_array($files)) {
|
||||
foreach ($files as $filename)
|
||||
@@ -2666,7 +2686,10 @@ if (!function_exists("get_sock")) {
|
||||
$fp = fsockopen ($host, 80, $errno, $errstr, 30);
|
||||
if (!$fp)
|
||||
{
|
||||
die("$errstr ($errno)\n");
|
||||
//die("$errstr ($errno)\n");
|
||||
|
||||
echo "$errstr ($errno)\n";
|
||||
return null;
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -2988,15 +3011,32 @@ function check_url_host($url, $msg='', $return_url=G5_URL)
|
||||
|
||||
$p = @parse_url($url);
|
||||
$host = preg_replace('/:[0-9]+$/', '', $_SERVER['HTTP_HOST']);
|
||||
$is_host_check = false;
|
||||
|
||||
if(stripos($url, 'http:') !== false) {
|
||||
if(!isset($p['scheme']) || !$p['scheme'] || !isset($p['host']) || !$p['host'])
|
||||
alert('url 정보가 올바르지 않습니다.', $return_url);
|
||||
}
|
||||
|
||||
if ((isset($p['scheme']) && $p['scheme']) || (isset($p['host']) && $p['host'])) {
|
||||
//php 5.6.29 이하 버전에서는 parse_url 버그가 존재함
|
||||
if ( (isset($p['host']) && $p['host']) && version_compare(PHP_VERSION, '5.6.29') < 0) {
|
||||
$bool_ch = false;
|
||||
foreach( array('user','host') as $key) {
|
||||
if ( isset( $p[ $key ] ) && strpbrk( $p[ $key ], ':/?#@' ) ) {
|
||||
$bool_ch = true;
|
||||
}
|
||||
}
|
||||
if( $bool_ch ){
|
||||
$regex = '/https?\:\/\/'.$host.'/i';
|
||||
if( ! preg_match($regex, $url) ){
|
||||
$is_host_check = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ((isset($p['scheme']) && $p['scheme']) || (isset($p['host']) && $p['host']) || $is_host_check) {
|
||||
//if ($p['host'].(isset($p['port']) ? ':'.$p['port'] : '') != $_SERVER['HTTP_HOST']) {
|
||||
if ($p['host'] != $host) {
|
||||
if ( ($p['host'] != $host) || $is_host_check ) {
|
||||
echo '<script>'.PHP_EOL;
|
||||
echo 'alert("url에 타 도메인을 지정할 수 없습니다.");'.PHP_EOL;
|
||||
echo 'document.location.href = "'.$return_url.'";'.PHP_EOL;
|
||||
@@ -3282,49 +3322,58 @@ function get_call_func_cache($func, $args=array()){
|
||||
}
|
||||
|
||||
// include 하는 경로에 data file 경로가 포함되어 있는지 체크합니다.
|
||||
function is_include_path_check($path='')
|
||||
function is_include_path_check($path='', $is_input='')
|
||||
{
|
||||
if( $path ){
|
||||
try {
|
||||
// whether $path is unix or not
|
||||
$unipath = strlen($path)==0 || $path{0}!='/';
|
||||
$unc = substr($path,0,2)=='\\\\'?true:false;
|
||||
// attempts to detect if path is relative in which case, add cwd
|
||||
if(strpos($path,':') === false && $unipath && !$unc){
|
||||
$path=getcwd().DIRECTORY_SEPARATOR.$path;
|
||||
if($path{0}=='/'){
|
||||
$unipath = false;
|
||||
if ($is_input){
|
||||
try {
|
||||
// whether $path is unix or not
|
||||
$unipath = strlen($path)==0 || $path{0}!='/';
|
||||
$unc = substr($path,0,2)=='\\\\'?true:false;
|
||||
// attempts to detect if path is relative in which case, add cwd
|
||||
if(strpos($path,':') === false && $unipath && !$unc){
|
||||
$path=getcwd().DIRECTORY_SEPARATOR.$path;
|
||||
if($path{0}=='/'){
|
||||
$unipath = false;
|
||||
}
|
||||
}
|
||||
|
||||
// resolve path parts (single dot, double dot and double delimiters)
|
||||
$path = str_replace(array('/', '\\'), DIRECTORY_SEPARATOR, $path);
|
||||
$parts = array_filter(explode(DIRECTORY_SEPARATOR, $path), 'strlen');
|
||||
$absolutes = array();
|
||||
foreach ($parts as $part) {
|
||||
if ('.' == $part){
|
||||
continue;
|
||||
}
|
||||
if ('..' == $part) {
|
||||
array_pop($absolutes);
|
||||
} else {
|
||||
$absolutes[] = $part;
|
||||
}
|
||||
}
|
||||
$path = implode(DIRECTORY_SEPARATOR, $absolutes);
|
||||
// resolve any symlinks
|
||||
// put initial separator that could have been lost
|
||||
$path = !$unipath ? '/'.$path : $path;
|
||||
$path = $unc ? '\\\\'.$path : $path;
|
||||
} catch (Exception $e) {
|
||||
//echo 'Caught exception: ', $e->getMessage(), "\n";
|
||||
return false;
|
||||
}
|
||||
|
||||
// resolve path parts (single dot, double dot and double delimiters)
|
||||
$path = str_replace(array('/', '\\'), DIRECTORY_SEPARATOR, $path);
|
||||
$parts = array_filter(explode(DIRECTORY_SEPARATOR, $path), 'strlen');
|
||||
$absolutes = array();
|
||||
foreach ($parts as $part) {
|
||||
if ('.' == $part){
|
||||
continue;
|
||||
}
|
||||
if ('..' == $part) {
|
||||
array_pop($absolutes);
|
||||
} else {
|
||||
$absolutes[] = $part;
|
||||
}
|
||||
if( preg_match('/\/data\/(file|editor)\/[A-Za-z0-9_]{1,20}\//', $path) ){
|
||||
return false;
|
||||
}
|
||||
$path = implode(DIRECTORY_SEPARATOR, $absolutes);
|
||||
// resolve any symlinks
|
||||
// put initial separator that could have been lost
|
||||
$path = !$unipath ? '/'.$path : $path;
|
||||
$path = $unc ? '\\\\'.$path : $path;
|
||||
} catch (Exception $e) {
|
||||
//echo 'Caught exception: ', $e->getMessage(), "\n";
|
||||
}
|
||||
|
||||
$extension = pathinfo($path, PATHINFO_EXTENSION);
|
||||
|
||||
if($extension && preg_match('/(jpg|jpeg|png|gif|bmp|conf)$/', $extension)) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if( !$path || preg_match('/\/data\/(file|editor)\/[A-Za-z0-9_]{1,20}\//', $path) ){
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
?>
|
||||
+18
-6
@@ -284,6 +284,7 @@ function thumbnail($filename, $source_path, $target_path, $thumb_width, $thumb_h
|
||||
|
||||
$is_large = true;
|
||||
// width, height 설정
|
||||
|
||||
if($thumb_width) {
|
||||
if(!$thumb_height) {
|
||||
$thumb_height = round(($thumb_width * $size[1]) / $size[0]);
|
||||
@@ -348,7 +349,6 @@ function thumbnail($filename, $source_path, $target_path, $thumb_width, $thumb_h
|
||||
} else { // 비율에 맞게 생성
|
||||
$dst = imagecreatetruecolor($dst_w, $dst_h);
|
||||
$bgcolor = imagecolorallocate($dst, 255, 255, 255); // 배경색
|
||||
|
||||
if($src_w > $src_h) {
|
||||
$tmp_h = round(($dst_w * $src_h) / $src_w);
|
||||
$dst_y = round(($dst_h - $tmp_h) / 2);
|
||||
@@ -384,8 +384,14 @@ function thumbnail($filename, $source_path, $target_path, $thumb_width, $thumb_h
|
||||
|
||||
if($src_w < $dst_w) {
|
||||
if($src_h >= $dst_h) {
|
||||
$dst_x = round(($dst_w - $src_w) / 2);
|
||||
$src_h = $dst_h;
|
||||
if( $src_h > $src_w ){
|
||||
$tmp_w = round(($dst_h * $src_w) / $src_h);
|
||||
$dst_x = round(($dst_w - $tmp_w) / 2);
|
||||
$dst_w = $tmp_w;
|
||||
} else {
|
||||
$dst_x = round(($dst_w - $src_w) / 2);
|
||||
$src_h = $dst_h;
|
||||
}
|
||||
} else {
|
||||
$dst_x = round(($dst_w - $src_w) / 2);
|
||||
$dst_y = round(($dst_h - $src_h) / 2);
|
||||
@@ -394,9 +400,15 @@ function thumbnail($filename, $source_path, $target_path, $thumb_width, $thumb_h
|
||||
}
|
||||
} else {
|
||||
if($src_h < $dst_h) {
|
||||
$dst_y = round(($dst_h - $src_h) / 2);
|
||||
$dst_h = $src_h;
|
||||
$src_w = $dst_w;
|
||||
if( $src_w > $dst_w ){
|
||||
$tmp_h = round(($dst_w * $src_h) / $src_w);
|
||||
$dst_y = round(($dst_h - $tmp_h) / 2);
|
||||
$dst_h = $tmp_h;
|
||||
} else {
|
||||
$dst_y = round(($dst_h - $src_h) / 2);
|
||||
$dst_h = $src_h;
|
||||
$src_w = $dst_w;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -83,7 +83,7 @@ var char_max = parseInt(<?php echo $comment_max ?>); // 최대
|
||||
?>
|
||||
<aside id="bo_vc_w">
|
||||
<h2>댓글쓰기</h2>
|
||||
<form name="fviewcomment" action="./write_comment_update.php" onsubmit="return fviewcomment_submit(this);" method="post" autocomplete="off">
|
||||
<form name="fviewcomment" action="<?php echo $comment_action_url; ?>" onsubmit="return fviewcomment_submit(this);" method="post" autocomplete="off">
|
||||
<input type="hidden" name="w" value="<?php echo $w ?>" id="w">
|
||||
<input type="hidden" name="bo_table" value="<?php echo $bo_table ?>">
|
||||
<input type="hidden" name="wr_id" value="<?php echo $wr_id ?>">
|
||||
|
||||
@@ -83,7 +83,7 @@ var char_max = parseInt(<?php echo $comment_max ?>); // 최대
|
||||
?>
|
||||
<aside id="bo_vc_w">
|
||||
<h2>댓글쓰기</h2>
|
||||
<form name="fviewcomment" action="./write_comment_update.php" onsubmit="return fviewcomment_submit(this);" method="post" autocomplete="off">
|
||||
<form name="fviewcomment" action="<?php echo $comment_action_url; ?>" onsubmit="return fviewcomment_submit(this);" method="post" autocomplete="off">
|
||||
<input type="hidden" name="w" value="<?php echo $w ?>" id="w">
|
||||
<input type="hidden" name="bo_table" value="<?php echo $bo_table ?>">
|
||||
<input type="hidden" name="wr_id" value="<?php echo $wr_id ?>">
|
||||
|
||||
@@ -19,6 +19,13 @@ add_stylesheet('<link rel="stylesheet" href="'.$member_skin_url.'/style.css">',
|
||||
<table>
|
||||
<caption>쪽지쓰기</caption>
|
||||
<tbody>
|
||||
<?php if ($config['cf_memo_send_point']) { ?>
|
||||
<tr>
|
||||
<td colspan="2">
|
||||
<strong>쪽지 보낼때 회원당 <?php echo number_format($config['cf_memo_send_point']); ?>점의 포인트를 차감합니다.</strong>
|
||||
</td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
<tr>
|
||||
<th scope="row"><label for="me_recv_mb_id">받는 회원아이디<strong class="sound_only">필수</strong></label></th>
|
||||
<td>
|
||||
|
||||
@@ -60,7 +60,7 @@ add_stylesheet('<link rel="stylesheet" href="'.$member_skin_url.'/style.css">',
|
||||
if($config['cf_cert_use']) {
|
||||
if($config['cf_cert_ipin'])
|
||||
echo '<button type="button" id="win_ipin_cert" class="btn_frmline">아이핀 본인확인</button>'.PHP_EOL;
|
||||
if($config['cf_cert_hp'] && $config['cf_cert_hp'] != 'lg')
|
||||
if($config['cf_cert_hp'])
|
||||
echo '<button type="button" id="win_hp_cert" class="btn_frmline">휴대폰 본인확인</button>'.PHP_EOL;
|
||||
|
||||
echo '<noscript>본인확인을 위해서는 자바스크립트 사용이 가능해야합니다.</noscript>'.PHP_EOL;
|
||||
@@ -288,6 +288,10 @@ add_stylesheet('<link rel="stylesheet" href="'.$member_skin_url.'/style.css">',
|
||||
$cert_url = G5_KCPCERT_URL.'/kcpcert_form.php';
|
||||
$cert_type = 'kcp-hp';
|
||||
break;
|
||||
case 'lg':
|
||||
$cert_url = G5_LGXPAY_URL.'/AuthOnlyReq.php';
|
||||
$cert_type = 'lg-hp';
|
||||
break;
|
||||
default:
|
||||
echo 'alert("기본환경설정에서 휴대폰 본인확인 설정을 해주십시오");';
|
||||
echo 'return false;';
|
||||
|
||||
@@ -9,9 +9,15 @@ add_stylesheet('<link rel="stylesheet" href="'.$popular_skin_url.'/style.css">',
|
||||
<div>
|
||||
<h2>인기검색어</h2>
|
||||
<ul>
|
||||
<?php for ($i=0; $i<count($list); $i++) { ?>
|
||||
<?php
|
||||
if( isset($list) && is_array($list) ){
|
||||
for ($i=0; $i<count($list); $i++) {
|
||||
?>
|
||||
<li><a href="<?php echo G5_BBS_URL ?>/search.php?sfl=wr_subject&sop=and&stx=<?php echo urlencode($list[$i]['pp_word']) ?>"><?php echo get_text($list[$i]['pp_word']); ?></a></li>
|
||||
<?php } ?>
|
||||
<?php
|
||||
} //end for
|
||||
} //end if
|
||||
?>
|
||||
</ul>
|
||||
</div>
|
||||
</aside>
|
||||
@@ -48,8 +48,8 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script src="./js/jquery-1.8.3.min.js"></script>
|
||||
<script src="./js/jquery-ui.min.js"></script>
|
||||
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js"></script>
|
||||
<script src="//ajax.googleapis.com/ajax/libs/jqueryui/1.9.2/jquery-ui.min.js"></script>
|
||||
<!-- The Iframe Transport is required for browsers without support for XHR file uploads -->
|
||||
<script src="./js/jquery.iframe-transport.js"></script>
|
||||
|
||||
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
+22476
-22097
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,66 @@
|
||||
<?php
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
|
||||
//https://stackoverflow.com/questions/4739284/htmlpurifier-iframe-vimeo-and-youtube-video
|
||||
/**
|
||||
* Based on: http://sachachua.com/blog/2011/08/drupal-html-purifier-embedding-iframes-youtube/
|
||||
* Iframe filter that does some primitive whitelisting in a somewhat recognizable and tweakable way
|
||||
*/
|
||||
|
||||
if( !class_exists('HTMLPurifier_Filter_Iframevideo') ){
|
||||
class HTMLPurifier_Filter_iframevideo extends HTMLPurifier_Filter
|
||||
{
|
||||
public $name = 'Iframevideo';
|
||||
|
||||
/**
|
||||
*
|
||||
* @param string $html
|
||||
* @param HTMLPurifier_Config $config
|
||||
* @param HTMLPurifier_Context $context
|
||||
* @return string
|
||||
*/
|
||||
public function preFilter($html, $config, $context)
|
||||
{
|
||||
$html = preg_replace('#<iframe#i', '<img class="Iframevideo"', $html);
|
||||
$html = preg_replace('#</iframe>#i', '</img>', $html);
|
||||
return $html;
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* @param string $html
|
||||
* @param HTMLPurifier_Config $config
|
||||
* @param HTMLPurifier_Context $context
|
||||
* @return string
|
||||
*/
|
||||
public function postFilter($html, $config, $context)
|
||||
{
|
||||
$post_regex = '#<img class="Iframevideo"([^>]+?)>#';
|
||||
return preg_replace_callback($post_regex, array($this, 'postFilterCallback'), $html);
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* @param array $matches
|
||||
* @return string
|
||||
*/
|
||||
protected function postFilterCallback($matches)
|
||||
{
|
||||
// Domain Whitelist
|
||||
$youTubeMatch = preg_match('#src="https?://www.youtube(-nocookie)?.com/#i', $matches[1]);
|
||||
$vimeoMatch = preg_match('#src="http://player.vimeo.com/#i', $matches[1]);
|
||||
if ($youTubeMatch || $vimeoMatch) {
|
||||
$extra = ' frameborder="0"';
|
||||
if ($youTubeMatch) {
|
||||
$extra .= ' allowfullscreen';
|
||||
} elseif ($vimeoMatch) {
|
||||
$extra .= ' webkitAllowFullScreen mozallowfullscreen allowFullScreen';
|
||||
}
|
||||
return '<iframe ' . $matches[1] . $extra . '></iframe>';
|
||||
} else {
|
||||
return '';
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
?>
|
||||
@@ -1,48 +1,48 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Converts HTMLPurifier_ConfigSchema_Interchange to our runtime
|
||||
* representation used to perform checks on user configuration.
|
||||
*/
|
||||
class HTMLPurifier_ConfigSchema_Builder_ConfigSchema
|
||||
{
|
||||
|
||||
/**
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange $interchange
|
||||
* @return HTMLPurifier_ConfigSchema
|
||||
*/
|
||||
public function build($interchange)
|
||||
{
|
||||
$schema = new HTMLPurifier_ConfigSchema();
|
||||
foreach ($interchange->directives as $d) {
|
||||
$schema->add(
|
||||
$d->id->key,
|
||||
$d->default,
|
||||
$d->type,
|
||||
$d->typeAllowsNull
|
||||
);
|
||||
if ($d->allowed !== null) {
|
||||
$schema->addAllowedValues(
|
||||
$d->id->key,
|
||||
$d->allowed
|
||||
);
|
||||
}
|
||||
foreach ($d->aliases as $alias) {
|
||||
$schema->addAlias(
|
||||
$alias->key,
|
||||
$d->id->key
|
||||
);
|
||||
}
|
||||
if ($d->valueAliases !== null) {
|
||||
$schema->addValueAliases(
|
||||
$d->id->key,
|
||||
$d->valueAliases
|
||||
);
|
||||
}
|
||||
}
|
||||
$schema->postProcess();
|
||||
return $schema;
|
||||
}
|
||||
}
|
||||
|
||||
// vim: et sw=4 sts=4
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Converts HTMLPurifier_ConfigSchema_Interchange to our runtime
|
||||
* representation used to perform checks on user configuration.
|
||||
*/
|
||||
class HTMLPurifier_ConfigSchema_Builder_ConfigSchema
|
||||
{
|
||||
|
||||
/**
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange $interchange
|
||||
* @return HTMLPurifier_ConfigSchema
|
||||
*/
|
||||
public function build($interchange)
|
||||
{
|
||||
$schema = new HTMLPurifier_ConfigSchema();
|
||||
foreach ($interchange->directives as $d) {
|
||||
$schema->add(
|
||||
$d->id->key,
|
||||
$d->default,
|
||||
$d->type,
|
||||
$d->typeAllowsNull
|
||||
);
|
||||
if ($d->allowed !== null) {
|
||||
$schema->addAllowedValues(
|
||||
$d->id->key,
|
||||
$d->allowed
|
||||
);
|
||||
}
|
||||
foreach ($d->aliases as $alias) {
|
||||
$schema->addAlias(
|
||||
$alias->key,
|
||||
$d->id->key
|
||||
);
|
||||
}
|
||||
if ($d->valueAliases !== null) {
|
||||
$schema->addValueAliases(
|
||||
$d->id->key,
|
||||
$d->valueAliases
|
||||
);
|
||||
}
|
||||
}
|
||||
$schema->postProcess();
|
||||
return $schema;
|
||||
}
|
||||
}
|
||||
|
||||
// vim: et sw=4 sts=4
|
||||
|
||||
@@ -1,144 +1,144 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Converts HTMLPurifier_ConfigSchema_Interchange to an XML format,
|
||||
* which can be further processed to generate documentation.
|
||||
*/
|
||||
class HTMLPurifier_ConfigSchema_Builder_Xml extends XMLWriter
|
||||
{
|
||||
|
||||
/**
|
||||
* @type HTMLPurifier_ConfigSchema_Interchange
|
||||
*/
|
||||
protected $interchange;
|
||||
|
||||
/**
|
||||
* @type string
|
||||
*/
|
||||
private $namespace;
|
||||
|
||||
/**
|
||||
* @param string $html
|
||||
*/
|
||||
protected function writeHTMLDiv($html)
|
||||
{
|
||||
$this->startElement('div');
|
||||
|
||||
$purifier = HTMLPurifier::getInstance();
|
||||
$html = $purifier->purify($html);
|
||||
$this->writeAttribute('xmlns', 'http://www.w3.org/1999/xhtml');
|
||||
$this->writeRaw($html);
|
||||
|
||||
$this->endElement(); // div
|
||||
}
|
||||
|
||||
/**
|
||||
* @param mixed $var
|
||||
* @return string
|
||||
*/
|
||||
protected function export($var)
|
||||
{
|
||||
if ($var === array()) {
|
||||
return 'array()';
|
||||
}
|
||||
return var_export($var, true);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange $interchange
|
||||
*/
|
||||
public function build($interchange)
|
||||
{
|
||||
// global access, only use as last resort
|
||||
$this->interchange = $interchange;
|
||||
|
||||
$this->setIndent(true);
|
||||
$this->startDocument('1.0', 'UTF-8');
|
||||
$this->startElement('configdoc');
|
||||
$this->writeElement('title', $interchange->name);
|
||||
|
||||
foreach ($interchange->directives as $directive) {
|
||||
$this->buildDirective($directive);
|
||||
}
|
||||
|
||||
if ($this->namespace) {
|
||||
$this->endElement();
|
||||
} // namespace
|
||||
|
||||
$this->endElement(); // configdoc
|
||||
$this->flush();
|
||||
}
|
||||
|
||||
/**
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange_Directive $directive
|
||||
*/
|
||||
public function buildDirective($directive)
|
||||
{
|
||||
// Kludge, although I suppose having a notion of a "root namespace"
|
||||
// certainly makes things look nicer when documentation is built.
|
||||
// Depends on things being sorted.
|
||||
if (!$this->namespace || $this->namespace !== $directive->id->getRootNamespace()) {
|
||||
if ($this->namespace) {
|
||||
$this->endElement();
|
||||
} // namespace
|
||||
$this->namespace = $directive->id->getRootNamespace();
|
||||
$this->startElement('namespace');
|
||||
$this->writeAttribute('id', $this->namespace);
|
||||
$this->writeElement('name', $this->namespace);
|
||||
}
|
||||
|
||||
$this->startElement('directive');
|
||||
$this->writeAttribute('id', $directive->id->toString());
|
||||
|
||||
$this->writeElement('name', $directive->id->getDirective());
|
||||
|
||||
$this->startElement('aliases');
|
||||
foreach ($directive->aliases as $alias) {
|
||||
$this->writeElement('alias', $alias->toString());
|
||||
}
|
||||
$this->endElement(); // aliases
|
||||
|
||||
$this->startElement('constraints');
|
||||
if ($directive->version) {
|
||||
$this->writeElement('version', $directive->version);
|
||||
}
|
||||
$this->startElement('type');
|
||||
if ($directive->typeAllowsNull) {
|
||||
$this->writeAttribute('allow-null', 'yes');
|
||||
}
|
||||
$this->text($directive->type);
|
||||
$this->endElement(); // type
|
||||
if ($directive->allowed) {
|
||||
$this->startElement('allowed');
|
||||
foreach ($directive->allowed as $value => $x) {
|
||||
$this->writeElement('value', $value);
|
||||
}
|
||||
$this->endElement(); // allowed
|
||||
}
|
||||
$this->writeElement('default', $this->export($directive->default));
|
||||
$this->writeAttribute('xml:space', 'preserve');
|
||||
if ($directive->external) {
|
||||
$this->startElement('external');
|
||||
foreach ($directive->external as $project) {
|
||||
$this->writeElement('project', $project);
|
||||
}
|
||||
$this->endElement();
|
||||
}
|
||||
$this->endElement(); // constraints
|
||||
|
||||
if ($directive->deprecatedVersion) {
|
||||
$this->startElement('deprecated');
|
||||
$this->writeElement('version', $directive->deprecatedVersion);
|
||||
$this->writeElement('use', $directive->deprecatedUse->toString());
|
||||
$this->endElement(); // deprecated
|
||||
}
|
||||
|
||||
$this->startElement('description');
|
||||
$this->writeHTMLDiv($directive->description);
|
||||
$this->endElement(); // description
|
||||
|
||||
$this->endElement(); // directive
|
||||
}
|
||||
}
|
||||
|
||||
// vim: et sw=4 sts=4
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Converts HTMLPurifier_ConfigSchema_Interchange to an XML format,
|
||||
* which can be further processed to generate documentation.
|
||||
*/
|
||||
class HTMLPurifier_ConfigSchema_Builder_Xml extends XMLWriter
|
||||
{
|
||||
|
||||
/**
|
||||
* @type HTMLPurifier_ConfigSchema_Interchange
|
||||
*/
|
||||
protected $interchange;
|
||||
|
||||
/**
|
||||
* @type string
|
||||
*/
|
||||
private $namespace;
|
||||
|
||||
/**
|
||||
* @param string $html
|
||||
*/
|
||||
protected function writeHTMLDiv($html)
|
||||
{
|
||||
$this->startElement('div');
|
||||
|
||||
$purifier = HTMLPurifier::getInstance();
|
||||
$html = $purifier->purify($html);
|
||||
$this->writeAttribute('xmlns', 'http://www.w3.org/1999/xhtml');
|
||||
$this->writeRaw($html);
|
||||
|
||||
$this->endElement(); // div
|
||||
}
|
||||
|
||||
/**
|
||||
* @param mixed $var
|
||||
* @return string
|
||||
*/
|
||||
protected function export($var)
|
||||
{
|
||||
if ($var === array()) {
|
||||
return 'array()';
|
||||
}
|
||||
return var_export($var, true);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange $interchange
|
||||
*/
|
||||
public function build($interchange)
|
||||
{
|
||||
// global access, only use as last resort
|
||||
$this->interchange = $interchange;
|
||||
|
||||
$this->setIndent(true);
|
||||
$this->startDocument('1.0', 'UTF-8');
|
||||
$this->startElement('configdoc');
|
||||
$this->writeElement('title', $interchange->name);
|
||||
|
||||
foreach ($interchange->directives as $directive) {
|
||||
$this->buildDirective($directive);
|
||||
}
|
||||
|
||||
if ($this->namespace) {
|
||||
$this->endElement();
|
||||
} // namespace
|
||||
|
||||
$this->endElement(); // configdoc
|
||||
$this->flush();
|
||||
}
|
||||
|
||||
/**
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange_Directive $directive
|
||||
*/
|
||||
public function buildDirective($directive)
|
||||
{
|
||||
// Kludge, although I suppose having a notion of a "root namespace"
|
||||
// certainly makes things look nicer when documentation is built.
|
||||
// Depends on things being sorted.
|
||||
if (!$this->namespace || $this->namespace !== $directive->id->getRootNamespace()) {
|
||||
if ($this->namespace) {
|
||||
$this->endElement();
|
||||
} // namespace
|
||||
$this->namespace = $directive->id->getRootNamespace();
|
||||
$this->startElement('namespace');
|
||||
$this->writeAttribute('id', $this->namespace);
|
||||
$this->writeElement('name', $this->namespace);
|
||||
}
|
||||
|
||||
$this->startElement('directive');
|
||||
$this->writeAttribute('id', $directive->id->toString());
|
||||
|
||||
$this->writeElement('name', $directive->id->getDirective());
|
||||
|
||||
$this->startElement('aliases');
|
||||
foreach ($directive->aliases as $alias) {
|
||||
$this->writeElement('alias', $alias->toString());
|
||||
}
|
||||
$this->endElement(); // aliases
|
||||
|
||||
$this->startElement('constraints');
|
||||
if ($directive->version) {
|
||||
$this->writeElement('version', $directive->version);
|
||||
}
|
||||
$this->startElement('type');
|
||||
if ($directive->typeAllowsNull) {
|
||||
$this->writeAttribute('allow-null', 'yes');
|
||||
}
|
||||
$this->text($directive->type);
|
||||
$this->endElement(); // type
|
||||
if ($directive->allowed) {
|
||||
$this->startElement('allowed');
|
||||
foreach ($directive->allowed as $value => $x) {
|
||||
$this->writeElement('value', $value);
|
||||
}
|
||||
$this->endElement(); // allowed
|
||||
}
|
||||
$this->writeElement('default', $this->export($directive->default));
|
||||
$this->writeAttribute('xml:space', 'preserve');
|
||||
if ($directive->external) {
|
||||
$this->startElement('external');
|
||||
foreach ($directive->external as $project) {
|
||||
$this->writeElement('project', $project);
|
||||
}
|
||||
$this->endElement();
|
||||
}
|
||||
$this->endElement(); // constraints
|
||||
|
||||
if ($directive->deprecatedVersion) {
|
||||
$this->startElement('deprecated');
|
||||
$this->writeElement('version', $directive->deprecatedVersion);
|
||||
$this->writeElement('use', $directive->deprecatedUse->toString());
|
||||
$this->endElement(); // deprecated
|
||||
}
|
||||
|
||||
$this->startElement('description');
|
||||
$this->writeHTMLDiv($directive->description);
|
||||
$this->endElement(); // description
|
||||
|
||||
$this->endElement(); // directive
|
||||
}
|
||||
}
|
||||
|
||||
// vim: et sw=4 sts=4
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Exceptions related to configuration schema
|
||||
*/
|
||||
class HTMLPurifier_ConfigSchema_Exception extends HTMLPurifier_Exception
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
// vim: et sw=4 sts=4
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Exceptions related to configuration schema
|
||||
*/
|
||||
class HTMLPurifier_ConfigSchema_Exception extends HTMLPurifier_Exception
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
// vim: et sw=4 sts=4
|
||||
|
||||
@@ -1,47 +1,47 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Generic schema interchange format that can be converted to a runtime
|
||||
* representation (HTMLPurifier_ConfigSchema) or HTML documentation. Members
|
||||
* are completely validated.
|
||||
*/
|
||||
class HTMLPurifier_ConfigSchema_Interchange
|
||||
{
|
||||
|
||||
/**
|
||||
* Name of the application this schema is describing.
|
||||
* @type string
|
||||
*/
|
||||
public $name;
|
||||
|
||||
/**
|
||||
* Array of Directive ID => array(directive info)
|
||||
* @type HTMLPurifier_ConfigSchema_Interchange_Directive[]
|
||||
*/
|
||||
public $directives = array();
|
||||
|
||||
/**
|
||||
* Adds a directive array to $directives
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange_Directive $directive
|
||||
* @throws HTMLPurifier_ConfigSchema_Exception
|
||||
*/
|
||||
public function addDirective($directive)
|
||||
{
|
||||
if (isset($this->directives[$i = $directive->id->toString()])) {
|
||||
throw new HTMLPurifier_ConfigSchema_Exception("Cannot redefine directive '$i'");
|
||||
}
|
||||
$this->directives[$i] = $directive;
|
||||
}
|
||||
|
||||
/**
|
||||
* Convenience function to perform standard validation. Throws exception
|
||||
* on failed validation.
|
||||
*/
|
||||
public function validate()
|
||||
{
|
||||
$validator = new HTMLPurifier_ConfigSchema_Validator();
|
||||
return $validator->validate($this);
|
||||
}
|
||||
}
|
||||
|
||||
// vim: et sw=4 sts=4
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Generic schema interchange format that can be converted to a runtime
|
||||
* representation (HTMLPurifier_ConfigSchema) or HTML documentation. Members
|
||||
* are completely validated.
|
||||
*/
|
||||
class HTMLPurifier_ConfigSchema_Interchange
|
||||
{
|
||||
|
||||
/**
|
||||
* Name of the application this schema is describing.
|
||||
* @type string
|
||||
*/
|
||||
public $name;
|
||||
|
||||
/**
|
||||
* Array of Directive ID => array(directive info)
|
||||
* @type HTMLPurifier_ConfigSchema_Interchange_Directive[]
|
||||
*/
|
||||
public $directives = array();
|
||||
|
||||
/**
|
||||
* Adds a directive array to $directives
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange_Directive $directive
|
||||
* @throws HTMLPurifier_ConfigSchema_Exception
|
||||
*/
|
||||
public function addDirective($directive)
|
||||
{
|
||||
if (isset($this->directives[$i = $directive->id->toString()])) {
|
||||
throw new HTMLPurifier_ConfigSchema_Exception("Cannot redefine directive '$i'");
|
||||
}
|
||||
$this->directives[$i] = $directive;
|
||||
}
|
||||
|
||||
/**
|
||||
* Convenience function to perform standard validation. Throws exception
|
||||
* on failed validation.
|
||||
*/
|
||||
public function validate()
|
||||
{
|
||||
$validator = new HTMLPurifier_ConfigSchema_Validator();
|
||||
return $validator->validate($this);
|
||||
}
|
||||
}
|
||||
|
||||
// vim: et sw=4 sts=4
|
||||
|
||||
+89
-89
@@ -1,89 +1,89 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Interchange component class describing configuration directives.
|
||||
*/
|
||||
class HTMLPurifier_ConfigSchema_Interchange_Directive
|
||||
{
|
||||
|
||||
/**
|
||||
* ID of directive.
|
||||
* @type HTMLPurifier_ConfigSchema_Interchange_Id
|
||||
*/
|
||||
public $id;
|
||||
|
||||
/**
|
||||
* Type, e.g. 'integer' or 'istring'.
|
||||
* @type string
|
||||
*/
|
||||
public $type;
|
||||
|
||||
/**
|
||||
* Default value, e.g. 3 or 'DefaultVal'.
|
||||
* @type mixed
|
||||
*/
|
||||
public $default;
|
||||
|
||||
/**
|
||||
* HTML description.
|
||||
* @type string
|
||||
*/
|
||||
public $description;
|
||||
|
||||
/**
|
||||
* Whether or not null is allowed as a value.
|
||||
* @type bool
|
||||
*/
|
||||
public $typeAllowsNull = false;
|
||||
|
||||
/**
|
||||
* Lookup table of allowed scalar values.
|
||||
* e.g. array('allowed' => true).
|
||||
* Null if all values are allowed.
|
||||
* @type array
|
||||
*/
|
||||
public $allowed;
|
||||
|
||||
/**
|
||||
* List of aliases for the directive.
|
||||
* e.g. array(new HTMLPurifier_ConfigSchema_Interchange_Id('Ns', 'Dir'))).
|
||||
* @type HTMLPurifier_ConfigSchema_Interchange_Id[]
|
||||
*/
|
||||
public $aliases = array();
|
||||
|
||||
/**
|
||||
* Hash of value aliases, e.g. array('alt' => 'real'). Null if value
|
||||
* aliasing is disabled (necessary for non-scalar types).
|
||||
* @type array
|
||||
*/
|
||||
public $valueAliases;
|
||||
|
||||
/**
|
||||
* Version of HTML Purifier the directive was introduced, e.g. '1.3.1'.
|
||||
* Null if the directive has always existed.
|
||||
* @type string
|
||||
*/
|
||||
public $version;
|
||||
|
||||
/**
|
||||
* ID of directive that supercedes this old directive.
|
||||
* Null if not deprecated.
|
||||
* @type HTMLPurifier_ConfigSchema_Interchange_Id
|
||||
*/
|
||||
public $deprecatedUse;
|
||||
|
||||
/**
|
||||
* Version of HTML Purifier this directive was deprecated. Null if not
|
||||
* deprecated.
|
||||
* @type string
|
||||
*/
|
||||
public $deprecatedVersion;
|
||||
|
||||
/**
|
||||
* List of external projects this directive depends on, e.g. array('CSSTidy').
|
||||
* @type array
|
||||
*/
|
||||
public $external = array();
|
||||
}
|
||||
|
||||
// vim: et sw=4 sts=4
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Interchange component class describing configuration directives.
|
||||
*/
|
||||
class HTMLPurifier_ConfigSchema_Interchange_Directive
|
||||
{
|
||||
|
||||
/**
|
||||
* ID of directive.
|
||||
* @type HTMLPurifier_ConfigSchema_Interchange_Id
|
||||
*/
|
||||
public $id;
|
||||
|
||||
/**
|
||||
* Type, e.g. 'integer' or 'istring'.
|
||||
* @type string
|
||||
*/
|
||||
public $type;
|
||||
|
||||
/**
|
||||
* Default value, e.g. 3 or 'DefaultVal'.
|
||||
* @type mixed
|
||||
*/
|
||||
public $default;
|
||||
|
||||
/**
|
||||
* HTML description.
|
||||
* @type string
|
||||
*/
|
||||
public $description;
|
||||
|
||||
/**
|
||||
* Whether or not null is allowed as a value.
|
||||
* @type bool
|
||||
*/
|
||||
public $typeAllowsNull = false;
|
||||
|
||||
/**
|
||||
* Lookup table of allowed scalar values.
|
||||
* e.g. array('allowed' => true).
|
||||
* Null if all values are allowed.
|
||||
* @type array
|
||||
*/
|
||||
public $allowed;
|
||||
|
||||
/**
|
||||
* List of aliases for the directive.
|
||||
* e.g. array(new HTMLPurifier_ConfigSchema_Interchange_Id('Ns', 'Dir'))).
|
||||
* @type HTMLPurifier_ConfigSchema_Interchange_Id[]
|
||||
*/
|
||||
public $aliases = array();
|
||||
|
||||
/**
|
||||
* Hash of value aliases, e.g. array('alt' => 'real'). Null if value
|
||||
* aliasing is disabled (necessary for non-scalar types).
|
||||
* @type array
|
||||
*/
|
||||
public $valueAliases;
|
||||
|
||||
/**
|
||||
* Version of HTML Purifier the directive was introduced, e.g. '1.3.1'.
|
||||
* Null if the directive has always existed.
|
||||
* @type string
|
||||
*/
|
||||
public $version;
|
||||
|
||||
/**
|
||||
* ID of directive that supercedes this old directive.
|
||||
* Null if not deprecated.
|
||||
* @type HTMLPurifier_ConfigSchema_Interchange_Id
|
||||
*/
|
||||
public $deprecatedUse;
|
||||
|
||||
/**
|
||||
* Version of HTML Purifier this directive was deprecated. Null if not
|
||||
* deprecated.
|
||||
* @type string
|
||||
*/
|
||||
public $deprecatedVersion;
|
||||
|
||||
/**
|
||||
* List of external projects this directive depends on, e.g. array('CSSTidy').
|
||||
* @type array
|
||||
*/
|
||||
public $external = array();
|
||||
}
|
||||
|
||||
// vim: et sw=4 sts=4
|
||||
|
||||
@@ -1,58 +1,58 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Represents a directive ID in the interchange format.
|
||||
*/
|
||||
class HTMLPurifier_ConfigSchema_Interchange_Id
|
||||
{
|
||||
|
||||
/**
|
||||
* @type string
|
||||
*/
|
||||
public $key;
|
||||
|
||||
/**
|
||||
* @param string $key
|
||||
*/
|
||||
public function __construct($key)
|
||||
{
|
||||
$this->key = $key;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return string
|
||||
* @warning This is NOT magic, to ensure that people don't abuse SPL and
|
||||
* cause problems for PHP 5.0 support.
|
||||
*/
|
||||
public function toString()
|
||||
{
|
||||
return $this->key;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
public function getRootNamespace()
|
||||
{
|
||||
return substr($this->key, 0, strpos($this->key, "."));
|
||||
}
|
||||
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
public function getDirective()
|
||||
{
|
||||
return substr($this->key, strpos($this->key, ".") + 1);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $id
|
||||
* @return HTMLPurifier_ConfigSchema_Interchange_Id
|
||||
*/
|
||||
public static function make($id)
|
||||
{
|
||||
return new HTMLPurifier_ConfigSchema_Interchange_Id($id);
|
||||
}
|
||||
}
|
||||
|
||||
// vim: et sw=4 sts=4
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Represents a directive ID in the interchange format.
|
||||
*/
|
||||
class HTMLPurifier_ConfigSchema_Interchange_Id
|
||||
{
|
||||
|
||||
/**
|
||||
* @type string
|
||||
*/
|
||||
public $key;
|
||||
|
||||
/**
|
||||
* @param string $key
|
||||
*/
|
||||
public function __construct($key)
|
||||
{
|
||||
$this->key = $key;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return string
|
||||
* @warning This is NOT magic, to ensure that people don't abuse SPL and
|
||||
* cause problems for PHP 5.0 support.
|
||||
*/
|
||||
public function toString()
|
||||
{
|
||||
return $this->key;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
public function getRootNamespace()
|
||||
{
|
||||
return substr($this->key, 0, strpos($this->key, "."));
|
||||
}
|
||||
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
public function getDirective()
|
||||
{
|
||||
return substr($this->key, strpos($this->key, ".") + 1);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $id
|
||||
* @return HTMLPurifier_ConfigSchema_Interchange_Id
|
||||
*/
|
||||
public static function make($id)
|
||||
{
|
||||
return new HTMLPurifier_ConfigSchema_Interchange_Id($id);
|
||||
}
|
||||
}
|
||||
|
||||
// vim: et sw=4 sts=4
|
||||
|
||||
@@ -1,226 +1,226 @@
|
||||
<?php
|
||||
|
||||
class HTMLPurifier_ConfigSchema_InterchangeBuilder
|
||||
{
|
||||
|
||||
/**
|
||||
* Used for processing DEFAULT, nothing else.
|
||||
* @type HTMLPurifier_VarParser
|
||||
*/
|
||||
protected $varParser;
|
||||
|
||||
/**
|
||||
* @param HTMLPurifier_VarParser $varParser
|
||||
*/
|
||||
public function __construct($varParser = null)
|
||||
{
|
||||
$this->varParser = $varParser ? $varParser : new HTMLPurifier_VarParser_Native();
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $dir
|
||||
* @return HTMLPurifier_ConfigSchema_Interchange
|
||||
*/
|
||||
public static function buildFromDirectory($dir = null)
|
||||
{
|
||||
$builder = new HTMLPurifier_ConfigSchema_InterchangeBuilder();
|
||||
$interchange = new HTMLPurifier_ConfigSchema_Interchange();
|
||||
return $builder->buildDir($interchange, $dir);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange $interchange
|
||||
* @param string $dir
|
||||
* @return HTMLPurifier_ConfigSchema_Interchange
|
||||
*/
|
||||
public function buildDir($interchange, $dir = null)
|
||||
{
|
||||
if (!$dir) {
|
||||
$dir = HTMLPURIFIER_PREFIX . '/HTMLPurifier/ConfigSchema/schema';
|
||||
}
|
||||
if (file_exists($dir . '/info.ini')) {
|
||||
$info = parse_ini_file($dir . '/info.ini');
|
||||
$interchange->name = $info['name'];
|
||||
}
|
||||
|
||||
$files = array();
|
||||
$dh = opendir($dir);
|
||||
while (false !== ($file = readdir($dh))) {
|
||||
if (!$file || $file[0] == '.' || strrchr($file, '.') !== '.txt') {
|
||||
continue;
|
||||
}
|
||||
$files[] = $file;
|
||||
}
|
||||
closedir($dh);
|
||||
|
||||
sort($files);
|
||||
foreach ($files as $file) {
|
||||
$this->buildFile($interchange, $dir . '/' . $file);
|
||||
}
|
||||
return $interchange;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange $interchange
|
||||
* @param string $file
|
||||
*/
|
||||
public function buildFile($interchange, $file)
|
||||
{
|
||||
$parser = new HTMLPurifier_StringHashParser();
|
||||
$this->build(
|
||||
$interchange,
|
||||
new HTMLPurifier_StringHash($parser->parseFile($file))
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Builds an interchange object based on a hash.
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange $interchange HTMLPurifier_ConfigSchema_Interchange object to build
|
||||
* @param HTMLPurifier_StringHash $hash source data
|
||||
* @throws HTMLPurifier_ConfigSchema_Exception
|
||||
*/
|
||||
public function build($interchange, $hash)
|
||||
{
|
||||
if (!$hash instanceof HTMLPurifier_StringHash) {
|
||||
$hash = new HTMLPurifier_StringHash($hash);
|
||||
}
|
||||
if (!isset($hash['ID'])) {
|
||||
throw new HTMLPurifier_ConfigSchema_Exception('Hash does not have any ID');
|
||||
}
|
||||
if (strpos($hash['ID'], '.') === false) {
|
||||
if (count($hash) == 2 && isset($hash['DESCRIPTION'])) {
|
||||
$hash->offsetGet('DESCRIPTION'); // prevent complaining
|
||||
} else {
|
||||
throw new HTMLPurifier_ConfigSchema_Exception('All directives must have a namespace');
|
||||
}
|
||||
} else {
|
||||
$this->buildDirective($interchange, $hash);
|
||||
}
|
||||
$this->_findUnused($hash);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange $interchange
|
||||
* @param HTMLPurifier_StringHash $hash
|
||||
* @throws HTMLPurifier_ConfigSchema_Exception
|
||||
*/
|
||||
public function buildDirective($interchange, $hash)
|
||||
{
|
||||
$directive = new HTMLPurifier_ConfigSchema_Interchange_Directive();
|
||||
|
||||
// These are required elements:
|
||||
$directive->id = $this->id($hash->offsetGet('ID'));
|
||||
$id = $directive->id->toString(); // convenience
|
||||
|
||||
if (isset($hash['TYPE'])) {
|
||||
$type = explode('/', $hash->offsetGet('TYPE'));
|
||||
if (isset($type[1])) {
|
||||
$directive->typeAllowsNull = true;
|
||||
}
|
||||
$directive->type = $type[0];
|
||||
} else {
|
||||
throw new HTMLPurifier_ConfigSchema_Exception("TYPE in directive hash '$id' not defined");
|
||||
}
|
||||
|
||||
if (isset($hash['DEFAULT'])) {
|
||||
try {
|
||||
$directive->default = $this->varParser->parse(
|
||||
$hash->offsetGet('DEFAULT'),
|
||||
$directive->type,
|
||||
$directive->typeAllowsNull
|
||||
);
|
||||
} catch (HTMLPurifier_VarParserException $e) {
|
||||
throw new HTMLPurifier_ConfigSchema_Exception($e->getMessage() . " in DEFAULT in directive hash '$id'");
|
||||
}
|
||||
}
|
||||
|
||||
if (isset($hash['DESCRIPTION'])) {
|
||||
$directive->description = $hash->offsetGet('DESCRIPTION');
|
||||
}
|
||||
|
||||
if (isset($hash['ALLOWED'])) {
|
||||
$directive->allowed = $this->lookup($this->evalArray($hash->offsetGet('ALLOWED')));
|
||||
}
|
||||
|
||||
if (isset($hash['VALUE-ALIASES'])) {
|
||||
$directive->valueAliases = $this->evalArray($hash->offsetGet('VALUE-ALIASES'));
|
||||
}
|
||||
|
||||
if (isset($hash['ALIASES'])) {
|
||||
$raw_aliases = trim($hash->offsetGet('ALIASES'));
|
||||
$aliases = preg_split('/\s*,\s*/', $raw_aliases);
|
||||
foreach ($aliases as $alias) {
|
||||
$directive->aliases[] = $this->id($alias);
|
||||
}
|
||||
}
|
||||
|
||||
if (isset($hash['VERSION'])) {
|
||||
$directive->version = $hash->offsetGet('VERSION');
|
||||
}
|
||||
|
||||
if (isset($hash['DEPRECATED-USE'])) {
|
||||
$directive->deprecatedUse = $this->id($hash->offsetGet('DEPRECATED-USE'));
|
||||
}
|
||||
|
||||
if (isset($hash['DEPRECATED-VERSION'])) {
|
||||
$directive->deprecatedVersion = $hash->offsetGet('DEPRECATED-VERSION');
|
||||
}
|
||||
|
||||
if (isset($hash['EXTERNAL'])) {
|
||||
$directive->external = preg_split('/\s*,\s*/', trim($hash->offsetGet('EXTERNAL')));
|
||||
}
|
||||
|
||||
$interchange->addDirective($directive);
|
||||
}
|
||||
|
||||
/**
|
||||
* Evaluates an array PHP code string without array() wrapper
|
||||
* @param string $contents
|
||||
*/
|
||||
protected function evalArray($contents)
|
||||
{
|
||||
return eval('return array(' . $contents . ');');
|
||||
}
|
||||
|
||||
/**
|
||||
* Converts an array list into a lookup array.
|
||||
* @param array $array
|
||||
* @return array
|
||||
*/
|
||||
protected function lookup($array)
|
||||
{
|
||||
$ret = array();
|
||||
foreach ($array as $val) {
|
||||
$ret[$val] = true;
|
||||
}
|
||||
return $ret;
|
||||
}
|
||||
|
||||
/**
|
||||
* Convenience function that creates an HTMLPurifier_ConfigSchema_Interchange_Id
|
||||
* object based on a string Id.
|
||||
* @param string $id
|
||||
* @return HTMLPurifier_ConfigSchema_Interchange_Id
|
||||
*/
|
||||
protected function id($id)
|
||||
{
|
||||
return HTMLPurifier_ConfigSchema_Interchange_Id::make($id);
|
||||
}
|
||||
|
||||
/**
|
||||
* Triggers errors for any unused keys passed in the hash; such keys
|
||||
* may indicate typos, missing values, etc.
|
||||
* @param HTMLPurifier_StringHash $hash Hash to check.
|
||||
*/
|
||||
protected function _findUnused($hash)
|
||||
{
|
||||
$accessed = $hash->getAccessed();
|
||||
foreach ($hash as $k => $v) {
|
||||
if (!isset($accessed[$k])) {
|
||||
trigger_error("String hash key '$k' not used by builder", E_USER_NOTICE);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// vim: et sw=4 sts=4
|
||||
<?php
|
||||
|
||||
class HTMLPurifier_ConfigSchema_InterchangeBuilder
|
||||
{
|
||||
|
||||
/**
|
||||
* Used for processing DEFAULT, nothing else.
|
||||
* @type HTMLPurifier_VarParser
|
||||
*/
|
||||
protected $varParser;
|
||||
|
||||
/**
|
||||
* @param HTMLPurifier_VarParser $varParser
|
||||
*/
|
||||
public function __construct($varParser = null)
|
||||
{
|
||||
$this->varParser = $varParser ? $varParser : new HTMLPurifier_VarParser_Native();
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $dir
|
||||
* @return HTMLPurifier_ConfigSchema_Interchange
|
||||
*/
|
||||
public static function buildFromDirectory($dir = null)
|
||||
{
|
||||
$builder = new HTMLPurifier_ConfigSchema_InterchangeBuilder();
|
||||
$interchange = new HTMLPurifier_ConfigSchema_Interchange();
|
||||
return $builder->buildDir($interchange, $dir);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange $interchange
|
||||
* @param string $dir
|
||||
* @return HTMLPurifier_ConfigSchema_Interchange
|
||||
*/
|
||||
public function buildDir($interchange, $dir = null)
|
||||
{
|
||||
if (!$dir) {
|
||||
$dir = HTMLPURIFIER_PREFIX . '/HTMLPurifier/ConfigSchema/schema';
|
||||
}
|
||||
if (file_exists($dir . '/info.ini')) {
|
||||
$info = parse_ini_file($dir . '/info.ini');
|
||||
$interchange->name = $info['name'];
|
||||
}
|
||||
|
||||
$files = array();
|
||||
$dh = opendir($dir);
|
||||
while (false !== ($file = readdir($dh))) {
|
||||
if (!$file || $file[0] == '.' || strrchr($file, '.') !== '.txt') {
|
||||
continue;
|
||||
}
|
||||
$files[] = $file;
|
||||
}
|
||||
closedir($dh);
|
||||
|
||||
sort($files);
|
||||
foreach ($files as $file) {
|
||||
$this->buildFile($interchange, $dir . '/' . $file);
|
||||
}
|
||||
return $interchange;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange $interchange
|
||||
* @param string $file
|
||||
*/
|
||||
public function buildFile($interchange, $file)
|
||||
{
|
||||
$parser = new HTMLPurifier_StringHashParser();
|
||||
$this->build(
|
||||
$interchange,
|
||||
new HTMLPurifier_StringHash($parser->parseFile($file))
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Builds an interchange object based on a hash.
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange $interchange HTMLPurifier_ConfigSchema_Interchange object to build
|
||||
* @param HTMLPurifier_StringHash $hash source data
|
||||
* @throws HTMLPurifier_ConfigSchema_Exception
|
||||
*/
|
||||
public function build($interchange, $hash)
|
||||
{
|
||||
if (!$hash instanceof HTMLPurifier_StringHash) {
|
||||
$hash = new HTMLPurifier_StringHash($hash);
|
||||
}
|
||||
if (!isset($hash['ID'])) {
|
||||
throw new HTMLPurifier_ConfigSchema_Exception('Hash does not have any ID');
|
||||
}
|
||||
if (strpos($hash['ID'], '.') === false) {
|
||||
if (count($hash) == 2 && isset($hash['DESCRIPTION'])) {
|
||||
$hash->offsetGet('DESCRIPTION'); // prevent complaining
|
||||
} else {
|
||||
throw new HTMLPurifier_ConfigSchema_Exception('All directives must have a namespace');
|
||||
}
|
||||
} else {
|
||||
$this->buildDirective($interchange, $hash);
|
||||
}
|
||||
$this->_findUnused($hash);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange $interchange
|
||||
* @param HTMLPurifier_StringHash $hash
|
||||
* @throws HTMLPurifier_ConfigSchema_Exception
|
||||
*/
|
||||
public function buildDirective($interchange, $hash)
|
||||
{
|
||||
$directive = new HTMLPurifier_ConfigSchema_Interchange_Directive();
|
||||
|
||||
// These are required elements:
|
||||
$directive->id = $this->id($hash->offsetGet('ID'));
|
||||
$id = $directive->id->toString(); // convenience
|
||||
|
||||
if (isset($hash['TYPE'])) {
|
||||
$type = explode('/', $hash->offsetGet('TYPE'));
|
||||
if (isset($type[1])) {
|
||||
$directive->typeAllowsNull = true;
|
||||
}
|
||||
$directive->type = $type[0];
|
||||
} else {
|
||||
throw new HTMLPurifier_ConfigSchema_Exception("TYPE in directive hash '$id' not defined");
|
||||
}
|
||||
|
||||
if (isset($hash['DEFAULT'])) {
|
||||
try {
|
||||
$directive->default = $this->varParser->parse(
|
||||
$hash->offsetGet('DEFAULT'),
|
||||
$directive->type,
|
||||
$directive->typeAllowsNull
|
||||
);
|
||||
} catch (HTMLPurifier_VarParserException $e) {
|
||||
throw new HTMLPurifier_ConfigSchema_Exception($e->getMessage() . " in DEFAULT in directive hash '$id'");
|
||||
}
|
||||
}
|
||||
|
||||
if (isset($hash['DESCRIPTION'])) {
|
||||
$directive->description = $hash->offsetGet('DESCRIPTION');
|
||||
}
|
||||
|
||||
if (isset($hash['ALLOWED'])) {
|
||||
$directive->allowed = $this->lookup($this->evalArray($hash->offsetGet('ALLOWED')));
|
||||
}
|
||||
|
||||
if (isset($hash['VALUE-ALIASES'])) {
|
||||
$directive->valueAliases = $this->evalArray($hash->offsetGet('VALUE-ALIASES'));
|
||||
}
|
||||
|
||||
if (isset($hash['ALIASES'])) {
|
||||
$raw_aliases = trim($hash->offsetGet('ALIASES'));
|
||||
$aliases = preg_split('/\s*,\s*/', $raw_aliases);
|
||||
foreach ($aliases as $alias) {
|
||||
$directive->aliases[] = $this->id($alias);
|
||||
}
|
||||
}
|
||||
|
||||
if (isset($hash['VERSION'])) {
|
||||
$directive->version = $hash->offsetGet('VERSION');
|
||||
}
|
||||
|
||||
if (isset($hash['DEPRECATED-USE'])) {
|
||||
$directive->deprecatedUse = $this->id($hash->offsetGet('DEPRECATED-USE'));
|
||||
}
|
||||
|
||||
if (isset($hash['DEPRECATED-VERSION'])) {
|
||||
$directive->deprecatedVersion = $hash->offsetGet('DEPRECATED-VERSION');
|
||||
}
|
||||
|
||||
if (isset($hash['EXTERNAL'])) {
|
||||
$directive->external = preg_split('/\s*,\s*/', trim($hash->offsetGet('EXTERNAL')));
|
||||
}
|
||||
|
||||
$interchange->addDirective($directive);
|
||||
}
|
||||
|
||||
/**
|
||||
* Evaluates an array PHP code string without array() wrapper
|
||||
* @param string $contents
|
||||
*/
|
||||
protected function evalArray($contents)
|
||||
{
|
||||
return eval('return array(' . $contents . ');');
|
||||
}
|
||||
|
||||
/**
|
||||
* Converts an array list into a lookup array.
|
||||
* @param array $array
|
||||
* @return array
|
||||
*/
|
||||
protected function lookup($array)
|
||||
{
|
||||
$ret = array();
|
||||
foreach ($array as $val) {
|
||||
$ret[$val] = true;
|
||||
}
|
||||
return $ret;
|
||||
}
|
||||
|
||||
/**
|
||||
* Convenience function that creates an HTMLPurifier_ConfigSchema_Interchange_Id
|
||||
* object based on a string Id.
|
||||
* @param string $id
|
||||
* @return HTMLPurifier_ConfigSchema_Interchange_Id
|
||||
*/
|
||||
protected function id($id)
|
||||
{
|
||||
return HTMLPurifier_ConfigSchema_Interchange_Id::make($id);
|
||||
}
|
||||
|
||||
/**
|
||||
* Triggers errors for any unused keys passed in the hash; such keys
|
||||
* may indicate typos, missing values, etc.
|
||||
* @param HTMLPurifier_StringHash $hash Hash to check.
|
||||
*/
|
||||
protected function _findUnused($hash)
|
||||
{
|
||||
$accessed = $hash->getAccessed();
|
||||
foreach ($hash as $k => $v) {
|
||||
if (!isset($accessed[$k])) {
|
||||
trigger_error("String hash key '$k' not used by builder", E_USER_NOTICE);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// vim: et sw=4 sts=4
|
||||
|
||||
@@ -1,248 +1,248 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Performs validations on HTMLPurifier_ConfigSchema_Interchange
|
||||
*
|
||||
* @note If you see '// handled by InterchangeBuilder', that means a
|
||||
* design decision in that class would prevent this validation from
|
||||
* ever being necessary. We have them anyway, however, for
|
||||
* redundancy.
|
||||
*/
|
||||
class HTMLPurifier_ConfigSchema_Validator
|
||||
{
|
||||
|
||||
/**
|
||||
* @type HTMLPurifier_ConfigSchema_Interchange
|
||||
*/
|
||||
protected $interchange;
|
||||
|
||||
/**
|
||||
* @type array
|
||||
*/
|
||||
protected $aliases;
|
||||
|
||||
/**
|
||||
* Context-stack to provide easy to read error messages.
|
||||
* @type array
|
||||
*/
|
||||
protected $context = array();
|
||||
|
||||
/**
|
||||
* to test default's type.
|
||||
* @type HTMLPurifier_VarParser
|
||||
*/
|
||||
protected $parser;
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
$this->parser = new HTMLPurifier_VarParser();
|
||||
}
|
||||
|
||||
/**
|
||||
* Validates a fully-formed interchange object.
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange $interchange
|
||||
* @return bool
|
||||
*/
|
||||
public function validate($interchange)
|
||||
{
|
||||
$this->interchange = $interchange;
|
||||
$this->aliases = array();
|
||||
// PHP is a bit lax with integer <=> string conversions in
|
||||
// arrays, so we don't use the identical !== comparison
|
||||
foreach ($interchange->directives as $i => $directive) {
|
||||
$id = $directive->id->toString();
|
||||
if ($i != $id) {
|
||||
$this->error(false, "Integrity violation: key '$i' does not match internal id '$id'");
|
||||
}
|
||||
$this->validateDirective($directive);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Validates a HTMLPurifier_ConfigSchema_Interchange_Id object.
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange_Id $id
|
||||
*/
|
||||
public function validateId($id)
|
||||
{
|
||||
$id_string = $id->toString();
|
||||
$this->context[] = "id '$id_string'";
|
||||
if (!$id instanceof HTMLPurifier_ConfigSchema_Interchange_Id) {
|
||||
// handled by InterchangeBuilder
|
||||
$this->error(false, 'is not an instance of HTMLPurifier_ConfigSchema_Interchange_Id');
|
||||
}
|
||||
// keys are now unconstrained (we might want to narrow down to A-Za-z0-9.)
|
||||
// we probably should check that it has at least one namespace
|
||||
$this->with($id, 'key')
|
||||
->assertNotEmpty()
|
||||
->assertIsString(); // implicit assertIsString handled by InterchangeBuilder
|
||||
array_pop($this->context);
|
||||
}
|
||||
|
||||
/**
|
||||
* Validates a HTMLPurifier_ConfigSchema_Interchange_Directive object.
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange_Directive $d
|
||||
*/
|
||||
public function validateDirective($d)
|
||||
{
|
||||
$id = $d->id->toString();
|
||||
$this->context[] = "directive '$id'";
|
||||
$this->validateId($d->id);
|
||||
|
||||
$this->with($d, 'description')
|
||||
->assertNotEmpty();
|
||||
|
||||
// BEGIN - handled by InterchangeBuilder
|
||||
$this->with($d, 'type')
|
||||
->assertNotEmpty();
|
||||
$this->with($d, 'typeAllowsNull')
|
||||
->assertIsBool();
|
||||
try {
|
||||
// This also tests validity of $d->type
|
||||
$this->parser->parse($d->default, $d->type, $d->typeAllowsNull);
|
||||
} catch (HTMLPurifier_VarParserException $e) {
|
||||
$this->error('default', 'had error: ' . $e->getMessage());
|
||||
}
|
||||
// END - handled by InterchangeBuilder
|
||||
|
||||
if (!is_null($d->allowed) || !empty($d->valueAliases)) {
|
||||
// allowed and valueAliases require that we be dealing with
|
||||
// strings, so check for that early.
|
||||
$d_int = HTMLPurifier_VarParser::$types[$d->type];
|
||||
if (!isset(HTMLPurifier_VarParser::$stringTypes[$d_int])) {
|
||||
$this->error('type', 'must be a string type when used with allowed or value aliases');
|
||||
}
|
||||
}
|
||||
|
||||
$this->validateDirectiveAllowed($d);
|
||||
$this->validateDirectiveValueAliases($d);
|
||||
$this->validateDirectiveAliases($d);
|
||||
|
||||
array_pop($this->context);
|
||||
}
|
||||
|
||||
/**
|
||||
* Extra validation if $allowed member variable of
|
||||
* HTMLPurifier_ConfigSchema_Interchange_Directive is defined.
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange_Directive $d
|
||||
*/
|
||||
public function validateDirectiveAllowed($d)
|
||||
{
|
||||
if (is_null($d->allowed)) {
|
||||
return;
|
||||
}
|
||||
$this->with($d, 'allowed')
|
||||
->assertNotEmpty()
|
||||
->assertIsLookup(); // handled by InterchangeBuilder
|
||||
if (is_string($d->default) && !isset($d->allowed[$d->default])) {
|
||||
$this->error('default', 'must be an allowed value');
|
||||
}
|
||||
$this->context[] = 'allowed';
|
||||
foreach ($d->allowed as $val => $x) {
|
||||
if (!is_string($val)) {
|
||||
$this->error("value $val", 'must be a string');
|
||||
}
|
||||
}
|
||||
array_pop($this->context);
|
||||
}
|
||||
|
||||
/**
|
||||
* Extra validation if $valueAliases member variable of
|
||||
* HTMLPurifier_ConfigSchema_Interchange_Directive is defined.
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange_Directive $d
|
||||
*/
|
||||
public function validateDirectiveValueAliases($d)
|
||||
{
|
||||
if (is_null($d->valueAliases)) {
|
||||
return;
|
||||
}
|
||||
$this->with($d, 'valueAliases')
|
||||
->assertIsArray(); // handled by InterchangeBuilder
|
||||
$this->context[] = 'valueAliases';
|
||||
foreach ($d->valueAliases as $alias => $real) {
|
||||
if (!is_string($alias)) {
|
||||
$this->error("alias $alias", 'must be a string');
|
||||
}
|
||||
if (!is_string($real)) {
|
||||
$this->error("alias target $real from alias '$alias'", 'must be a string');
|
||||
}
|
||||
if ($alias === $real) {
|
||||
$this->error("alias '$alias'", "must not be an alias to itself");
|
||||
}
|
||||
}
|
||||
if (!is_null($d->allowed)) {
|
||||
foreach ($d->valueAliases as $alias => $real) {
|
||||
if (isset($d->allowed[$alias])) {
|
||||
$this->error("alias '$alias'", 'must not be an allowed value');
|
||||
} elseif (!isset($d->allowed[$real])) {
|
||||
$this->error("alias '$alias'", 'must be an alias to an allowed value');
|
||||
}
|
||||
}
|
||||
}
|
||||
array_pop($this->context);
|
||||
}
|
||||
|
||||
/**
|
||||
* Extra validation if $aliases member variable of
|
||||
* HTMLPurifier_ConfigSchema_Interchange_Directive is defined.
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange_Directive $d
|
||||
*/
|
||||
public function validateDirectiveAliases($d)
|
||||
{
|
||||
$this->with($d, 'aliases')
|
||||
->assertIsArray(); // handled by InterchangeBuilder
|
||||
$this->context[] = 'aliases';
|
||||
foreach ($d->aliases as $alias) {
|
||||
$this->validateId($alias);
|
||||
$s = $alias->toString();
|
||||
if (isset($this->interchange->directives[$s])) {
|
||||
$this->error("alias '$s'", 'collides with another directive');
|
||||
}
|
||||
if (isset($this->aliases[$s])) {
|
||||
$other_directive = $this->aliases[$s];
|
||||
$this->error("alias '$s'", "collides with alias for directive '$other_directive'");
|
||||
}
|
||||
$this->aliases[$s] = $d->id->toString();
|
||||
}
|
||||
array_pop($this->context);
|
||||
}
|
||||
|
||||
// protected helper functions
|
||||
|
||||
/**
|
||||
* Convenience function for generating HTMLPurifier_ConfigSchema_ValidatorAtom
|
||||
* for validating simple member variables of objects.
|
||||
* @param $obj
|
||||
* @param $member
|
||||
* @return HTMLPurifier_ConfigSchema_ValidatorAtom
|
||||
*/
|
||||
protected function with($obj, $member)
|
||||
{
|
||||
return new HTMLPurifier_ConfigSchema_ValidatorAtom($this->getFormattedContext(), $obj, $member);
|
||||
}
|
||||
|
||||
/**
|
||||
* Emits an error, providing helpful context.
|
||||
* @throws HTMLPurifier_ConfigSchema_Exception
|
||||
*/
|
||||
protected function error($target, $msg)
|
||||
{
|
||||
if ($target !== false) {
|
||||
$prefix = ucfirst($target) . ' in ' . $this->getFormattedContext();
|
||||
} else {
|
||||
$prefix = ucfirst($this->getFormattedContext());
|
||||
}
|
||||
throw new HTMLPurifier_ConfigSchema_Exception(trim($prefix . ' ' . $msg));
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns a formatted context string.
|
||||
* @return string
|
||||
*/
|
||||
protected function getFormattedContext()
|
||||
{
|
||||
return implode(' in ', array_reverse($this->context));
|
||||
}
|
||||
}
|
||||
|
||||
// vim: et sw=4 sts=4
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Performs validations on HTMLPurifier_ConfigSchema_Interchange
|
||||
*
|
||||
* @note If you see '// handled by InterchangeBuilder', that means a
|
||||
* design decision in that class would prevent this validation from
|
||||
* ever being necessary. We have them anyway, however, for
|
||||
* redundancy.
|
||||
*/
|
||||
class HTMLPurifier_ConfigSchema_Validator
|
||||
{
|
||||
|
||||
/**
|
||||
* @type HTMLPurifier_ConfigSchema_Interchange
|
||||
*/
|
||||
protected $interchange;
|
||||
|
||||
/**
|
||||
* @type array
|
||||
*/
|
||||
protected $aliases;
|
||||
|
||||
/**
|
||||
* Context-stack to provide easy to read error messages.
|
||||
* @type array
|
||||
*/
|
||||
protected $context = array();
|
||||
|
||||
/**
|
||||
* to test default's type.
|
||||
* @type HTMLPurifier_VarParser
|
||||
*/
|
||||
protected $parser;
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
$this->parser = new HTMLPurifier_VarParser();
|
||||
}
|
||||
|
||||
/**
|
||||
* Validates a fully-formed interchange object.
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange $interchange
|
||||
* @return bool
|
||||
*/
|
||||
public function validate($interchange)
|
||||
{
|
||||
$this->interchange = $interchange;
|
||||
$this->aliases = array();
|
||||
// PHP is a bit lax with integer <=> string conversions in
|
||||
// arrays, so we don't use the identical !== comparison
|
||||
foreach ($interchange->directives as $i => $directive) {
|
||||
$id = $directive->id->toString();
|
||||
if ($i != $id) {
|
||||
$this->error(false, "Integrity violation: key '$i' does not match internal id '$id'");
|
||||
}
|
||||
$this->validateDirective($directive);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Validates a HTMLPurifier_ConfigSchema_Interchange_Id object.
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange_Id $id
|
||||
*/
|
||||
public function validateId($id)
|
||||
{
|
||||
$id_string = $id->toString();
|
||||
$this->context[] = "id '$id_string'";
|
||||
if (!$id instanceof HTMLPurifier_ConfigSchema_Interchange_Id) {
|
||||
// handled by InterchangeBuilder
|
||||
$this->error(false, 'is not an instance of HTMLPurifier_ConfigSchema_Interchange_Id');
|
||||
}
|
||||
// keys are now unconstrained (we might want to narrow down to A-Za-z0-9.)
|
||||
// we probably should check that it has at least one namespace
|
||||
$this->with($id, 'key')
|
||||
->assertNotEmpty()
|
||||
->assertIsString(); // implicit assertIsString handled by InterchangeBuilder
|
||||
array_pop($this->context);
|
||||
}
|
||||
|
||||
/**
|
||||
* Validates a HTMLPurifier_ConfigSchema_Interchange_Directive object.
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange_Directive $d
|
||||
*/
|
||||
public function validateDirective($d)
|
||||
{
|
||||
$id = $d->id->toString();
|
||||
$this->context[] = "directive '$id'";
|
||||
$this->validateId($d->id);
|
||||
|
||||
$this->with($d, 'description')
|
||||
->assertNotEmpty();
|
||||
|
||||
// BEGIN - handled by InterchangeBuilder
|
||||
$this->with($d, 'type')
|
||||
->assertNotEmpty();
|
||||
$this->with($d, 'typeAllowsNull')
|
||||
->assertIsBool();
|
||||
try {
|
||||
// This also tests validity of $d->type
|
||||
$this->parser->parse($d->default, $d->type, $d->typeAllowsNull);
|
||||
} catch (HTMLPurifier_VarParserException $e) {
|
||||
$this->error('default', 'had error: ' . $e->getMessage());
|
||||
}
|
||||
// END - handled by InterchangeBuilder
|
||||
|
||||
if (!is_null($d->allowed) || !empty($d->valueAliases)) {
|
||||
// allowed and valueAliases require that we be dealing with
|
||||
// strings, so check for that early.
|
||||
$d_int = HTMLPurifier_VarParser::$types[$d->type];
|
||||
if (!isset(HTMLPurifier_VarParser::$stringTypes[$d_int])) {
|
||||
$this->error('type', 'must be a string type when used with allowed or value aliases');
|
||||
}
|
||||
}
|
||||
|
||||
$this->validateDirectiveAllowed($d);
|
||||
$this->validateDirectiveValueAliases($d);
|
||||
$this->validateDirectiveAliases($d);
|
||||
|
||||
array_pop($this->context);
|
||||
}
|
||||
|
||||
/**
|
||||
* Extra validation if $allowed member variable of
|
||||
* HTMLPurifier_ConfigSchema_Interchange_Directive is defined.
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange_Directive $d
|
||||
*/
|
||||
public function validateDirectiveAllowed($d)
|
||||
{
|
||||
if (is_null($d->allowed)) {
|
||||
return;
|
||||
}
|
||||
$this->with($d, 'allowed')
|
||||
->assertNotEmpty()
|
||||
->assertIsLookup(); // handled by InterchangeBuilder
|
||||
if (is_string($d->default) && !isset($d->allowed[$d->default])) {
|
||||
$this->error('default', 'must be an allowed value');
|
||||
}
|
||||
$this->context[] = 'allowed';
|
||||
foreach ($d->allowed as $val => $x) {
|
||||
if (!is_string($val)) {
|
||||
$this->error("value $val", 'must be a string');
|
||||
}
|
||||
}
|
||||
array_pop($this->context);
|
||||
}
|
||||
|
||||
/**
|
||||
* Extra validation if $valueAliases member variable of
|
||||
* HTMLPurifier_ConfigSchema_Interchange_Directive is defined.
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange_Directive $d
|
||||
*/
|
||||
public function validateDirectiveValueAliases($d)
|
||||
{
|
||||
if (is_null($d->valueAliases)) {
|
||||
return;
|
||||
}
|
||||
$this->with($d, 'valueAliases')
|
||||
->assertIsArray(); // handled by InterchangeBuilder
|
||||
$this->context[] = 'valueAliases';
|
||||
foreach ($d->valueAliases as $alias => $real) {
|
||||
if (!is_string($alias)) {
|
||||
$this->error("alias $alias", 'must be a string');
|
||||
}
|
||||
if (!is_string($real)) {
|
||||
$this->error("alias target $real from alias '$alias'", 'must be a string');
|
||||
}
|
||||
if ($alias === $real) {
|
||||
$this->error("alias '$alias'", "must not be an alias to itself");
|
||||
}
|
||||
}
|
||||
if (!is_null($d->allowed)) {
|
||||
foreach ($d->valueAliases as $alias => $real) {
|
||||
if (isset($d->allowed[$alias])) {
|
||||
$this->error("alias '$alias'", 'must not be an allowed value');
|
||||
} elseif (!isset($d->allowed[$real])) {
|
||||
$this->error("alias '$alias'", 'must be an alias to an allowed value');
|
||||
}
|
||||
}
|
||||
}
|
||||
array_pop($this->context);
|
||||
}
|
||||
|
||||
/**
|
||||
* Extra validation if $aliases member variable of
|
||||
* HTMLPurifier_ConfigSchema_Interchange_Directive is defined.
|
||||
* @param HTMLPurifier_ConfigSchema_Interchange_Directive $d
|
||||
*/
|
||||
public function validateDirectiveAliases($d)
|
||||
{
|
||||
$this->with($d, 'aliases')
|
||||
->assertIsArray(); // handled by InterchangeBuilder
|
||||
$this->context[] = 'aliases';
|
||||
foreach ($d->aliases as $alias) {
|
||||
$this->validateId($alias);
|
||||
$s = $alias->toString();
|
||||
if (isset($this->interchange->directives[$s])) {
|
||||
$this->error("alias '$s'", 'collides with another directive');
|
||||
}
|
||||
if (isset($this->aliases[$s])) {
|
||||
$other_directive = $this->aliases[$s];
|
||||
$this->error("alias '$s'", "collides with alias for directive '$other_directive'");
|
||||
}
|
||||
$this->aliases[$s] = $d->id->toString();
|
||||
}
|
||||
array_pop($this->context);
|
||||
}
|
||||
|
||||
// protected helper functions
|
||||
|
||||
/**
|
||||
* Convenience function for generating HTMLPurifier_ConfigSchema_ValidatorAtom
|
||||
* for validating simple member variables of objects.
|
||||
* @param $obj
|
||||
* @param $member
|
||||
* @return HTMLPurifier_ConfigSchema_ValidatorAtom
|
||||
*/
|
||||
protected function with($obj, $member)
|
||||
{
|
||||
return new HTMLPurifier_ConfigSchema_ValidatorAtom($this->getFormattedContext(), $obj, $member);
|
||||
}
|
||||
|
||||
/**
|
||||
* Emits an error, providing helpful context.
|
||||
* @throws HTMLPurifier_ConfigSchema_Exception
|
||||
*/
|
||||
protected function error($target, $msg)
|
||||
{
|
||||
if ($target !== false) {
|
||||
$prefix = ucfirst($target) . ' in ' . $this->getFormattedContext();
|
||||
} else {
|
||||
$prefix = ucfirst($this->getFormattedContext());
|
||||
}
|
||||
throw new HTMLPurifier_ConfigSchema_Exception(trim($prefix . ' ' . $msg));
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns a formatted context string.
|
||||
* @return string
|
||||
*/
|
||||
protected function getFormattedContext()
|
||||
{
|
||||
return implode(' in ', array_reverse($this->context));
|
||||
}
|
||||
}
|
||||
|
||||
// vim: et sw=4 sts=4
|
||||
|
||||
@@ -1,130 +1,130 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Fluent interface for validating the contents of member variables.
|
||||
* This should be immutable. See HTMLPurifier_ConfigSchema_Validator for
|
||||
* use-cases. We name this an 'atom' because it's ONLY for validations that
|
||||
* are independent and usually scalar.
|
||||
*/
|
||||
class HTMLPurifier_ConfigSchema_ValidatorAtom
|
||||
{
|
||||
/**
|
||||
* @type string
|
||||
*/
|
||||
protected $context;
|
||||
|
||||
/**
|
||||
* @type object
|
||||
*/
|
||||
protected $obj;
|
||||
|
||||
/**
|
||||
* @type string
|
||||
*/
|
||||
protected $member;
|
||||
|
||||
/**
|
||||
* @type mixed
|
||||
*/
|
||||
protected $contents;
|
||||
|
||||
public function __construct($context, $obj, $member)
|
||||
{
|
||||
$this->context = $context;
|
||||
$this->obj = $obj;
|
||||
$this->member = $member;
|
||||
$this->contents =& $obj->$member;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return HTMLPurifier_ConfigSchema_ValidatorAtom
|
||||
*/
|
||||
public function assertIsString()
|
||||
{
|
||||
if (!is_string($this->contents)) {
|
||||
$this->error('must be a string');
|
||||
}
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return HTMLPurifier_ConfigSchema_ValidatorAtom
|
||||
*/
|
||||
public function assertIsBool()
|
||||
{
|
||||
if (!is_bool($this->contents)) {
|
||||
$this->error('must be a boolean');
|
||||
}
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return HTMLPurifier_ConfigSchema_ValidatorAtom
|
||||
*/
|
||||
public function assertIsArray()
|
||||
{
|
||||
if (!is_array($this->contents)) {
|
||||
$this->error('must be an array');
|
||||
}
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return HTMLPurifier_ConfigSchema_ValidatorAtom
|
||||
*/
|
||||
public function assertNotNull()
|
||||
{
|
||||
if ($this->contents === null) {
|
||||
$this->error('must not be null');
|
||||
}
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return HTMLPurifier_ConfigSchema_ValidatorAtom
|
||||
*/
|
||||
public function assertAlnum()
|
||||
{
|
||||
$this->assertIsString();
|
||||
if (!ctype_alnum($this->contents)) {
|
||||
$this->error('must be alphanumeric');
|
||||
}
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return HTMLPurifier_ConfigSchema_ValidatorAtom
|
||||
*/
|
||||
public function assertNotEmpty()
|
||||
{
|
||||
if (empty($this->contents)) {
|
||||
$this->error('must not be empty');
|
||||
}
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return HTMLPurifier_ConfigSchema_ValidatorAtom
|
||||
*/
|
||||
public function assertIsLookup()
|
||||
{
|
||||
$this->assertIsArray();
|
||||
foreach ($this->contents as $v) {
|
||||
if ($v !== true) {
|
||||
$this->error('must be a lookup array');
|
||||
}
|
||||
}
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $msg
|
||||
* @throws HTMLPurifier_ConfigSchema_Exception
|
||||
*/
|
||||
protected function error($msg)
|
||||
{
|
||||
throw new HTMLPurifier_ConfigSchema_Exception(ucfirst($this->member) . ' in ' . $this->context . ' ' . $msg);
|
||||
}
|
||||
}
|
||||
|
||||
// vim: et sw=4 sts=4
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Fluent interface for validating the contents of member variables.
|
||||
* This should be immutable. See HTMLPurifier_ConfigSchema_Validator for
|
||||
* use-cases. We name this an 'atom' because it's ONLY for validations that
|
||||
* are independent and usually scalar.
|
||||
*/
|
||||
class HTMLPurifier_ConfigSchema_ValidatorAtom
|
||||
{
|
||||
/**
|
||||
* @type string
|
||||
*/
|
||||
protected $context;
|
||||
|
||||
/**
|
||||
* @type object
|
||||
*/
|
||||
protected $obj;
|
||||
|
||||
/**
|
||||
* @type string
|
||||
*/
|
||||
protected $member;
|
||||
|
||||
/**
|
||||
* @type mixed
|
||||
*/
|
||||
protected $contents;
|
||||
|
||||
public function __construct($context, $obj, $member)
|
||||
{
|
||||
$this->context = $context;
|
||||
$this->obj = $obj;
|
||||
$this->member = $member;
|
||||
$this->contents =& $obj->$member;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return HTMLPurifier_ConfigSchema_ValidatorAtom
|
||||
*/
|
||||
public function assertIsString()
|
||||
{
|
||||
if (!is_string($this->contents)) {
|
||||
$this->error('must be a string');
|
||||
}
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return HTMLPurifier_ConfigSchema_ValidatorAtom
|
||||
*/
|
||||
public function assertIsBool()
|
||||
{
|
||||
if (!is_bool($this->contents)) {
|
||||
$this->error('must be a boolean');
|
||||
}
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return HTMLPurifier_ConfigSchema_ValidatorAtom
|
||||
*/
|
||||
public function assertIsArray()
|
||||
{
|
||||
if (!is_array($this->contents)) {
|
||||
$this->error('must be an array');
|
||||
}
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return HTMLPurifier_ConfigSchema_ValidatorAtom
|
||||
*/
|
||||
public function assertNotNull()
|
||||
{
|
||||
if ($this->contents === null) {
|
||||
$this->error('must not be null');
|
||||
}
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return HTMLPurifier_ConfigSchema_ValidatorAtom
|
||||
*/
|
||||
public function assertAlnum()
|
||||
{
|
||||
$this->assertIsString();
|
||||
if (!ctype_alnum($this->contents)) {
|
||||
$this->error('must be alphanumeric');
|
||||
}
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return HTMLPurifier_ConfigSchema_ValidatorAtom
|
||||
*/
|
||||
public function assertNotEmpty()
|
||||
{
|
||||
if (empty($this->contents)) {
|
||||
$this->error('must not be empty');
|
||||
}
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return HTMLPurifier_ConfigSchema_ValidatorAtom
|
||||
*/
|
||||
public function assertIsLookup()
|
||||
{
|
||||
$this->assertIsArray();
|
||||
foreach ($this->contents as $v) {
|
||||
if ($v !== true) {
|
||||
$this->error('must be a lookup array');
|
||||
}
|
||||
}
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $msg
|
||||
* @throws HTMLPurifier_ConfigSchema_Exception
|
||||
*/
|
||||
protected function error($msg)
|
||||
{
|
||||
throw new HTMLPurifier_ConfigSchema_Exception(ucfirst($this->member) . ' in ' . $this->context . ' ' . $msg);
|
||||
}
|
||||
}
|
||||
|
||||
// vim: et sw=4 sts=4
|
||||
|
||||
Binary file not shown.
+8
-8
@@ -1,8 +1,8 @@
|
||||
Attr.AllowedClasses
|
||||
TYPE: lookup/null
|
||||
VERSION: 4.0.0
|
||||
DEFAULT: null
|
||||
--DESCRIPTION--
|
||||
List of allowed class values in the class attribute. By default, this is null,
|
||||
which means all classes are allowed.
|
||||
--# vim: et sw=4 sts=4
|
||||
Attr.AllowedClasses
|
||||
TYPE: lookup/null
|
||||
VERSION: 4.0.0
|
||||
DEFAULT: null
|
||||
--DESCRIPTION--
|
||||
List of allowed class values in the class attribute. By default, this is null,
|
||||
which means all classes are allowed.
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+12
-12
@@ -1,12 +1,12 @@
|
||||
Attr.AllowedFrameTargets
|
||||
TYPE: lookup
|
||||
DEFAULT: array()
|
||||
--DESCRIPTION--
|
||||
Lookup table of all allowed link frame targets. Some commonly used link
|
||||
targets include _blank, _self, _parent and _top. Values should be
|
||||
lowercase, as validation will be done in a case-sensitive manner despite
|
||||
W3C's recommendation. XHTML 1.0 Strict does not permit the target attribute
|
||||
so this directive will have no effect in that doctype. XHTML 1.1 does not
|
||||
enable the Target module by default, you will have to manually enable it
|
||||
(see the module documentation for more details.)
|
||||
--# vim: et sw=4 sts=4
|
||||
Attr.AllowedFrameTargets
|
||||
TYPE: lookup
|
||||
DEFAULT: array()
|
||||
--DESCRIPTION--
|
||||
Lookup table of all allowed link frame targets. Some commonly used link
|
||||
targets include _blank, _self, _parent and _top. Values should be
|
||||
lowercase, as validation will be done in a case-sensitive manner despite
|
||||
W3C's recommendation. XHTML 1.0 Strict does not permit the target attribute
|
||||
so this directive will have no effect in that doctype. XHTML 1.1 does not
|
||||
enable the Target module by default, you will have to manually enable it
|
||||
(see the module documentation for more details.)
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
Attr.AllowedRel
|
||||
TYPE: lookup
|
||||
VERSION: 1.6.0
|
||||
DEFAULT: array()
|
||||
--DESCRIPTION--
|
||||
List of allowed forward document relationships in the rel attribute. Common
|
||||
values may be nofollow or print. By default, this is empty, meaning that no
|
||||
document relationships are allowed.
|
||||
--# vim: et sw=4 sts=4
|
||||
Attr.AllowedRel
|
||||
TYPE: lookup
|
||||
VERSION: 1.6.0
|
||||
DEFAULT: array()
|
||||
--DESCRIPTION--
|
||||
List of allowed forward document relationships in the rel attribute. Common
|
||||
values may be nofollow or print. By default, this is empty, meaning that no
|
||||
document relationships are allowed.
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
Attr.AllowedRev
|
||||
TYPE: lookup
|
||||
VERSION: 1.6.0
|
||||
DEFAULT: array()
|
||||
--DESCRIPTION--
|
||||
List of allowed reverse document relationships in the rev attribute. This
|
||||
attribute is a bit of an edge-case; if you don't know what it is for, stay
|
||||
away.
|
||||
--# vim: et sw=4 sts=4
|
||||
Attr.AllowedRev
|
||||
TYPE: lookup
|
||||
VERSION: 1.6.0
|
||||
DEFAULT: array()
|
||||
--DESCRIPTION--
|
||||
List of allowed reverse document relationships in the rev attribute. This
|
||||
attribute is a bit of an edge-case; if you don't know what it is for, stay
|
||||
away.
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+19
-19
@@ -1,19 +1,19 @@
|
||||
Attr.ClassUseCDATA
|
||||
TYPE: bool/null
|
||||
DEFAULT: null
|
||||
VERSION: 4.0.0
|
||||
--DESCRIPTION--
|
||||
If null, class will auto-detect the doctype and, if matching XHTML 1.1 or
|
||||
XHTML 2.0, will use the restrictive NMTOKENS specification of class. Otherwise,
|
||||
it will use a relaxed CDATA definition. If true, the relaxed CDATA definition
|
||||
is forced; if false, the NMTOKENS definition is forced. To get behavior
|
||||
of HTML Purifier prior to 4.0.0, set this directive to false.
|
||||
|
||||
Some rational behind the auto-detection:
|
||||
in previous versions of HTML Purifier, it was assumed that the form of
|
||||
class was NMTOKENS, as specified by the XHTML Modularization (representing
|
||||
XHTML 1.1 and XHTML 2.0). The DTDs for HTML 4.01 and XHTML 1.0, however
|
||||
specify class as CDATA. HTML 5 effectively defines it as CDATA, but
|
||||
with the additional constraint that each name should be unique (this is not
|
||||
explicitly outlined in previous specifications).
|
||||
--# vim: et sw=4 sts=4
|
||||
Attr.ClassUseCDATA
|
||||
TYPE: bool/null
|
||||
DEFAULT: null
|
||||
VERSION: 4.0.0
|
||||
--DESCRIPTION--
|
||||
If null, class will auto-detect the doctype and, if matching XHTML 1.1 or
|
||||
XHTML 2.0, will use the restrictive NMTOKENS specification of class. Otherwise,
|
||||
it will use a relaxed CDATA definition. If true, the relaxed CDATA definition
|
||||
is forced; if false, the NMTOKENS definition is forced. To get behavior
|
||||
of HTML Purifier prior to 4.0.0, set this directive to false.
|
||||
|
||||
Some rational behind the auto-detection:
|
||||
in previous versions of HTML Purifier, it was assumed that the form of
|
||||
class was NMTOKENS, as specified by the XHTML Modularization (representing
|
||||
XHTML 1.1 and XHTML 2.0). The DTDs for HTML 4.01 and XHTML 1.0, however
|
||||
specify class as CDATA. HTML 5 effectively defines it as CDATA, but
|
||||
with the additional constraint that each name should be unique (this is not
|
||||
explicitly outlined in previous specifications).
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+11
-11
@@ -1,11 +1,11 @@
|
||||
Attr.DefaultImageAlt
|
||||
TYPE: string/null
|
||||
DEFAULT: null
|
||||
VERSION: 3.2.0
|
||||
--DESCRIPTION--
|
||||
This is the content of the alt tag of an image if the user had not
|
||||
previously specified an alt attribute. This applies to all images without
|
||||
a valid alt attribute, as opposed to %Attr.DefaultInvalidImageAlt, which
|
||||
only applies to invalid images, and overrides in the case of an invalid image.
|
||||
Default behavior with null is to use the basename of the src tag for the alt.
|
||||
--# vim: et sw=4 sts=4
|
||||
Attr.DefaultImageAlt
|
||||
TYPE: string/null
|
||||
DEFAULT: null
|
||||
VERSION: 3.2.0
|
||||
--DESCRIPTION--
|
||||
This is the content of the alt tag of an image if the user had not
|
||||
previously specified an alt attribute. This applies to all images without
|
||||
a valid alt attribute, as opposed to %Attr.DefaultInvalidImageAlt, which
|
||||
only applies to invalid images, and overrides in the case of an invalid image.
|
||||
Default behavior with null is to use the basename of the src tag for the alt.
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+9
-9
@@ -1,9 +1,9 @@
|
||||
Attr.DefaultInvalidImage
|
||||
TYPE: string
|
||||
DEFAULT: ''
|
||||
--DESCRIPTION--
|
||||
This is the default image an img tag will be pointed to if it does not have
|
||||
a valid src attribute. In future versions, we may allow the image tag to
|
||||
be removed completely, but due to design issues, this is not possible right
|
||||
now.
|
||||
--# vim: et sw=4 sts=4
|
||||
Attr.DefaultInvalidImage
|
||||
TYPE: string
|
||||
DEFAULT: ''
|
||||
--DESCRIPTION--
|
||||
This is the default image an img tag will be pointed to if it does not have
|
||||
a valid src attribute. In future versions, we may allow the image tag to
|
||||
be removed completely, but due to design issues, this is not possible right
|
||||
now.
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+8
-8
@@ -1,8 +1,8 @@
|
||||
Attr.DefaultInvalidImageAlt
|
||||
TYPE: string
|
||||
DEFAULT: 'Invalid image'
|
||||
--DESCRIPTION--
|
||||
This is the content of the alt tag of an invalid image if the user had not
|
||||
previously specified an alt attribute. It has no effect when the image is
|
||||
valid but there was no alt attribute present.
|
||||
--# vim: et sw=4 sts=4
|
||||
Attr.DefaultInvalidImageAlt
|
||||
TYPE: string
|
||||
DEFAULT: 'Invalid image'
|
||||
--DESCRIPTION--
|
||||
This is the content of the alt tag of an invalid image if the user had not
|
||||
previously specified an alt attribute. It has no effect when the image is
|
||||
valid but there was no alt attribute present.
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+10
-10
@@ -1,10 +1,10 @@
|
||||
Attr.DefaultTextDir
|
||||
TYPE: string
|
||||
DEFAULT: 'ltr'
|
||||
--DESCRIPTION--
|
||||
Defines the default text direction (ltr or rtl) of the document being
|
||||
parsed. This generally is the same as the value of the dir attribute in
|
||||
HTML, or ltr if that is not specified.
|
||||
--ALLOWED--
|
||||
'ltr', 'rtl'
|
||||
--# vim: et sw=4 sts=4
|
||||
Attr.DefaultTextDir
|
||||
TYPE: string
|
||||
DEFAULT: 'ltr'
|
||||
--DESCRIPTION--
|
||||
Defines the default text direction (ltr or rtl) of the document being
|
||||
parsed. This generally is the same as the value of the dir attribute in
|
||||
HTML, or ltr if that is not specified.
|
||||
--ALLOWED--
|
||||
'ltr', 'rtl'
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
@@ -1,16 +1,16 @@
|
||||
Attr.EnableID
|
||||
TYPE: bool
|
||||
DEFAULT: false
|
||||
VERSION: 1.2.0
|
||||
--DESCRIPTION--
|
||||
Allows the ID attribute in HTML. This is disabled by default due to the
|
||||
fact that without proper configuration user input can easily break the
|
||||
validation of a webpage by specifying an ID that is already on the
|
||||
surrounding HTML. If you don't mind throwing caution to the wind, enable
|
||||
this directive, but I strongly recommend you also consider blacklisting IDs
|
||||
you use (%Attr.IDBlacklist) or prefixing all user supplied IDs
|
||||
(%Attr.IDPrefix). When set to true HTML Purifier reverts to the behavior of
|
||||
pre-1.2.0 versions.
|
||||
--ALIASES--
|
||||
HTML.EnableAttrID
|
||||
--# vim: et sw=4 sts=4
|
||||
Attr.EnableID
|
||||
TYPE: bool
|
||||
DEFAULT: false
|
||||
VERSION: 1.2.0
|
||||
--DESCRIPTION--
|
||||
Allows the ID attribute in HTML. This is disabled by default due to the
|
||||
fact that without proper configuration user input can easily break the
|
||||
validation of a webpage by specifying an ID that is already on the
|
||||
surrounding HTML. If you don't mind throwing caution to the wind, enable
|
||||
this directive, but I strongly recommend you also consider blacklisting IDs
|
||||
you use (%Attr.IDBlacklist) or prefixing all user supplied IDs
|
||||
(%Attr.IDPrefix). When set to true HTML Purifier reverts to the behavior of
|
||||
pre-1.2.0 versions.
|
||||
--ALIASES--
|
||||
HTML.EnableAttrID
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+8
-8
@@ -1,8 +1,8 @@
|
||||
Attr.ForbiddenClasses
|
||||
TYPE: lookup
|
||||
VERSION: 4.0.0
|
||||
DEFAULT: array()
|
||||
--DESCRIPTION--
|
||||
List of forbidden class values in the class attribute. By default, this is
|
||||
empty, which means that no classes are forbidden. See also %Attr.AllowedClasses.
|
||||
--# vim: et sw=4 sts=4
|
||||
Attr.ForbiddenClasses
|
||||
TYPE: lookup
|
||||
VERSION: 4.0.0
|
||||
DEFAULT: array()
|
||||
--DESCRIPTION--
|
||||
List of forbidden class values in the class attribute. By default, this is
|
||||
empty, which means that no classes are forbidden. See also %Attr.AllowedClasses.
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
Attr.ID.HTML5
|
||||
TYPE: bool/null
|
||||
DEFAULT: null
|
||||
VERSION: 4.8.0
|
||||
--DESCRIPTION--
|
||||
In HTML5, restrictions on the format of the id attribute have been significantly
|
||||
relaxed, such that any string is valid so long as it contains no spaces and
|
||||
is at least one character. In lieu of a general HTML5 compatibility flag,
|
||||
set this configuration directive to true to use the relaxed rules.
|
||||
--# vim: et sw=4 sts=4
|
||||
Attr.ID.HTML5
|
||||
TYPE: bool/null
|
||||
DEFAULT: null
|
||||
VERSION: 4.8.0
|
||||
--DESCRIPTION--
|
||||
In HTML5, restrictions on the format of the id attribute have been significantly
|
||||
relaxed, such that any string is valid so long as it contains no spaces and
|
||||
is at least one character. In lieu of a general HTML5 compatibility flag,
|
||||
set this configuration directive to true to use the relaxed rules.
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+5
-5
@@ -1,5 +1,5 @@
|
||||
Attr.IDBlacklist
|
||||
TYPE: list
|
||||
DEFAULT: array()
|
||||
DESCRIPTION: Array of IDs not allowed in the document.
|
||||
--# vim: et sw=4 sts=4
|
||||
Attr.IDBlacklist
|
||||
TYPE: list
|
||||
DEFAULT: array()
|
||||
DESCRIPTION: Array of IDs not allowed in the document.
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+9
-9
@@ -1,9 +1,9 @@
|
||||
Attr.IDBlacklistRegexp
|
||||
TYPE: string/null
|
||||
VERSION: 1.6.0
|
||||
DEFAULT: NULL
|
||||
--DESCRIPTION--
|
||||
PCRE regular expression to be matched against all IDs. If the expression is
|
||||
matches, the ID is rejected. Use this with care: may cause significant
|
||||
degradation. ID matching is done after all other validation.
|
||||
--# vim: et sw=4 sts=4
|
||||
Attr.IDBlacklistRegexp
|
||||
TYPE: string/null
|
||||
VERSION: 1.6.0
|
||||
DEFAULT: NULL
|
||||
--DESCRIPTION--
|
||||
PCRE regular expression to be matched against all IDs. If the expression is
|
||||
matches, the ID is rejected. Use this with care: may cause significant
|
||||
degradation. ID matching is done after all other validation.
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
Attr.IDPrefix
|
||||
TYPE: string
|
||||
VERSION: 1.2.0
|
||||
DEFAULT: ''
|
||||
--DESCRIPTION--
|
||||
String to prefix to IDs. If you have no idea what IDs your pages may use,
|
||||
you may opt to simply add a prefix to all user-submitted ID attributes so
|
||||
that they are still usable, but will not conflict with core page IDs.
|
||||
Example: setting the directive to 'user_' will result in a user submitted
|
||||
'foo' to become 'user_foo' Be sure to set %HTML.EnableAttrID to true
|
||||
before using this.
|
||||
--# vim: et sw=4 sts=4
|
||||
Attr.IDPrefix
|
||||
TYPE: string
|
||||
VERSION: 1.2.0
|
||||
DEFAULT: ''
|
||||
--DESCRIPTION--
|
||||
String to prefix to IDs. If you have no idea what IDs your pages may use,
|
||||
you may opt to simply add a prefix to all user-submitted ID attributes so
|
||||
that they are still usable, but will not conflict with core page IDs.
|
||||
Example: setting the directive to 'user_' will result in a user submitted
|
||||
'foo' to become 'user_foo' Be sure to set %HTML.EnableAttrID to true
|
||||
before using this.
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+14
-14
@@ -1,14 +1,14 @@
|
||||
Attr.IDPrefixLocal
|
||||
TYPE: string
|
||||
VERSION: 1.2.0
|
||||
DEFAULT: ''
|
||||
--DESCRIPTION--
|
||||
Temporary prefix for IDs used in conjunction with %Attr.IDPrefix. If you
|
||||
need to allow multiple sets of user content on web page, you may need to
|
||||
have a seperate prefix that changes with each iteration. This way,
|
||||
seperately submitted user content displayed on the same page doesn't
|
||||
clobber each other. Ideal values are unique identifiers for the content it
|
||||
represents (i.e. the id of the row in the database). Be sure to add a
|
||||
seperator (like an underscore) at the end. Warning: this directive will
|
||||
not work unless %Attr.IDPrefix is set to a non-empty value!
|
||||
--# vim: et sw=4 sts=4
|
||||
Attr.IDPrefixLocal
|
||||
TYPE: string
|
||||
VERSION: 1.2.0
|
||||
DEFAULT: ''
|
||||
--DESCRIPTION--
|
||||
Temporary prefix for IDs used in conjunction with %Attr.IDPrefix. If you
|
||||
need to allow multiple sets of user content on web page, you may need to
|
||||
have a seperate prefix that changes with each iteration. This way,
|
||||
seperately submitted user content displayed on the same page doesn't
|
||||
clobber each other. Ideal values are unique identifiers for the content it
|
||||
represents (i.e. the id of the row in the database). Be sure to add a
|
||||
seperator (like an underscore) at the end. Warning: this directive will
|
||||
not work unless %Attr.IDPrefix is set to a non-empty value!
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+31
-31
@@ -1,31 +1,31 @@
|
||||
AutoFormat.AutoParagraph
|
||||
TYPE: bool
|
||||
VERSION: 2.0.1
|
||||
DEFAULT: false
|
||||
--DESCRIPTION--
|
||||
|
||||
<p>
|
||||
This directive turns on auto-paragraphing, where double newlines are
|
||||
converted in to paragraphs whenever possible. Auto-paragraphing:
|
||||
</p>
|
||||
<ul>
|
||||
<li>Always applies to inline elements or text in the root node,</li>
|
||||
<li>Applies to inline elements or text with double newlines in nodes
|
||||
that allow paragraph tags,</li>
|
||||
<li>Applies to double newlines in paragraph tags</li>
|
||||
</ul>
|
||||
<p>
|
||||
<code>p</code> tags must be allowed for this directive to take effect.
|
||||
We do not use <code>br</code> tags for paragraphing, as that is
|
||||
semantically incorrect.
|
||||
</p>
|
||||
<p>
|
||||
To prevent auto-paragraphing as a content-producer, refrain from using
|
||||
double-newlines except to specify a new paragraph or in contexts where
|
||||
it has special meaning (whitespace usually has no meaning except in
|
||||
tags like <code>pre</code>, so this should not be difficult.) To prevent
|
||||
the paragraphing of inline text adjacent to block elements, wrap them
|
||||
in <code>div</code> tags (the behavior is slightly different outside of
|
||||
the root node.)
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
AutoFormat.AutoParagraph
|
||||
TYPE: bool
|
||||
VERSION: 2.0.1
|
||||
DEFAULT: false
|
||||
--DESCRIPTION--
|
||||
|
||||
<p>
|
||||
This directive turns on auto-paragraphing, where double newlines are
|
||||
converted in to paragraphs whenever possible. Auto-paragraphing:
|
||||
</p>
|
||||
<ul>
|
||||
<li>Always applies to inline elements or text in the root node,</li>
|
||||
<li>Applies to inline elements or text with double newlines in nodes
|
||||
that allow paragraph tags,</li>
|
||||
<li>Applies to double newlines in paragraph tags</li>
|
||||
</ul>
|
||||
<p>
|
||||
<code>p</code> tags must be allowed for this directive to take effect.
|
||||
We do not use <code>br</code> tags for paragraphing, as that is
|
||||
semantically incorrect.
|
||||
</p>
|
||||
<p>
|
||||
To prevent auto-paragraphing as a content-producer, refrain from using
|
||||
double-newlines except to specify a new paragraph or in contexts where
|
||||
it has special meaning (whitespace usually has no meaning except in
|
||||
tags like <code>pre</code>, so this should not be difficult.) To prevent
|
||||
the paragraphing of inline text adjacent to block elements, wrap them
|
||||
in <code>div</code> tags (the behavior is slightly different outside of
|
||||
the root node.)
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+12
-12
@@ -1,12 +1,12 @@
|
||||
AutoFormat.Custom
|
||||
TYPE: list
|
||||
VERSION: 2.0.1
|
||||
DEFAULT: array()
|
||||
--DESCRIPTION--
|
||||
|
||||
<p>
|
||||
This directive can be used to add custom auto-format injectors.
|
||||
Specify an array of injector names (class name minus the prefix)
|
||||
or concrete implementations. Injector class must exist.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
AutoFormat.Custom
|
||||
TYPE: list
|
||||
VERSION: 2.0.1
|
||||
DEFAULT: array()
|
||||
--DESCRIPTION--
|
||||
|
||||
<p>
|
||||
This directive can be used to add custom auto-format injectors.
|
||||
Specify an array of injector names (class name minus the prefix)
|
||||
or concrete implementations. Injector class must exist.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+11
-11
@@ -1,11 +1,11 @@
|
||||
AutoFormat.DisplayLinkURI
|
||||
TYPE: bool
|
||||
VERSION: 3.2.0
|
||||
DEFAULT: false
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
This directive turns on the in-text display of URIs in <a> tags, and disables
|
||||
those links. For example, <a href="http://example.com">example</a> becomes
|
||||
example (<a>http://example.com</a>).
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
AutoFormat.DisplayLinkURI
|
||||
TYPE: bool
|
||||
VERSION: 3.2.0
|
||||
DEFAULT: false
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
This directive turns on the in-text display of URIs in <a> tags, and disables
|
||||
those links. For example, <a href="http://example.com">example</a> becomes
|
||||
example (<a>http://example.com</a>).
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+12
-12
@@ -1,12 +1,12 @@
|
||||
AutoFormat.Linkify
|
||||
TYPE: bool
|
||||
VERSION: 2.0.1
|
||||
DEFAULT: false
|
||||
--DESCRIPTION--
|
||||
|
||||
<p>
|
||||
This directive turns on linkification, auto-linking http, ftp and
|
||||
https URLs. <code>a</code> tags with the <code>href</code> attribute
|
||||
must be allowed.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
AutoFormat.Linkify
|
||||
TYPE: bool
|
||||
VERSION: 2.0.1
|
||||
DEFAULT: false
|
||||
--DESCRIPTION--
|
||||
|
||||
<p>
|
||||
This directive turns on linkification, auto-linking http, ftp and
|
||||
https URLs. <code>a</code> tags with the <code>href</code> attribute
|
||||
must be allowed.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+12
-12
@@ -1,12 +1,12 @@
|
||||
AutoFormat.PurifierLinkify.DocURL
|
||||
TYPE: string
|
||||
VERSION: 2.0.1
|
||||
DEFAULT: '#%s'
|
||||
ALIASES: AutoFormatParam.PurifierLinkifyDocURL
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
Location of configuration documentation to link to, let %s substitute
|
||||
into the configuration's namespace and directive names sans the percent
|
||||
sign.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
AutoFormat.PurifierLinkify.DocURL
|
||||
TYPE: string
|
||||
VERSION: 2.0.1
|
||||
DEFAULT: '#%s'
|
||||
ALIASES: AutoFormatParam.PurifierLinkifyDocURL
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
Location of configuration documentation to link to, let %s substitute
|
||||
into the configuration's namespace and directive names sans the percent
|
||||
sign.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+12
-12
@@ -1,12 +1,12 @@
|
||||
AutoFormat.PurifierLinkify
|
||||
TYPE: bool
|
||||
VERSION: 2.0.1
|
||||
DEFAULT: false
|
||||
--DESCRIPTION--
|
||||
|
||||
<p>
|
||||
Internal auto-formatter that converts configuration directives in
|
||||
syntax <a>%Namespace.Directive</a> to links. <code>a</code> tags
|
||||
with the <code>href</code> attribute must be allowed.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
AutoFormat.PurifierLinkify
|
||||
TYPE: bool
|
||||
VERSION: 2.0.1
|
||||
DEFAULT: false
|
||||
--DESCRIPTION--
|
||||
|
||||
<p>
|
||||
Internal auto-formatter that converts configuration directives in
|
||||
syntax <a>%Namespace.Directive</a> to links. <code>a</code> tags
|
||||
with the <code>href</code> attribute must be allowed.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+14
-14
@@ -1,14 +1,14 @@
|
||||
AutoFormat.RemoveEmpty.Predicate
|
||||
TYPE: hash
|
||||
VERSION: 4.7.0
|
||||
DEFAULT: array('colgroup' => array(), 'th' => array(), 'td' => array(), 'iframe' => array('src'))
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
Given that an element has no contents, it will be removed by default, unless
|
||||
this predicate dictates otherwise. The predicate can either be an associative
|
||||
map from tag name to list of attributes that must be present for the element
|
||||
to be considered preserved: thus, the default always preserves <code>colgroup</code>,
|
||||
<code>th</code> and <code>td</code>, and also <code>iframe</code> if it
|
||||
has a <code>src</code>.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
AutoFormat.RemoveEmpty.Predicate
|
||||
TYPE: hash
|
||||
VERSION: 4.7.0
|
||||
DEFAULT: array('colgroup' => array(), 'th' => array(), 'td' => array(), 'iframe' => array('src'))
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
Given that an element has no contents, it will be removed by default, unless
|
||||
this predicate dictates otherwise. The predicate can either be an associative
|
||||
map from tag name to list of attributes that must be present for the element
|
||||
to be considered preserved: thus, the default always preserves <code>colgroup</code>,
|
||||
<code>th</code> and <code>td</code>, and also <code>iframe</code> if it
|
||||
has a <code>src</code>.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+11
-11
@@ -1,11 +1,11 @@
|
||||
AutoFormat.RemoveEmpty.RemoveNbsp.Exceptions
|
||||
TYPE: lookup
|
||||
VERSION: 4.0.0
|
||||
DEFAULT: array('td' => true, 'th' => true)
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
When %AutoFormat.RemoveEmpty and %AutoFormat.RemoveEmpty.RemoveNbsp
|
||||
are enabled, this directive defines what HTML elements should not be
|
||||
removede if they have only a non-breaking space in them.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
AutoFormat.RemoveEmpty.RemoveNbsp.Exceptions
|
||||
TYPE: lookup
|
||||
VERSION: 4.0.0
|
||||
DEFAULT: array('td' => true, 'th' => true)
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
When %AutoFormat.RemoveEmpty and %AutoFormat.RemoveEmpty.RemoveNbsp
|
||||
are enabled, this directive defines what HTML elements should not be
|
||||
removede if they have only a non-breaking space in them.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+15
-15
@@ -1,15 +1,15 @@
|
||||
AutoFormat.RemoveEmpty.RemoveNbsp
|
||||
TYPE: bool
|
||||
VERSION: 4.0.0
|
||||
DEFAULT: false
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
When enabled, HTML Purifier will treat any elements that contain only
|
||||
non-breaking spaces as well as regular whitespace as empty, and remove
|
||||
them when %AutoForamt.RemoveEmpty is enabled.
|
||||
</p>
|
||||
<p>
|
||||
See %AutoFormat.RemoveEmpty.RemoveNbsp.Exceptions for a list of elements
|
||||
that don't have this behavior applied to them.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
AutoFormat.RemoveEmpty.RemoveNbsp
|
||||
TYPE: bool
|
||||
VERSION: 4.0.0
|
||||
DEFAULT: false
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
When enabled, HTML Purifier will treat any elements that contain only
|
||||
non-breaking spaces as well as regular whitespace as empty, and remove
|
||||
them when %AutoForamt.RemoveEmpty is enabled.
|
||||
</p>
|
||||
<p>
|
||||
See %AutoFormat.RemoveEmpty.RemoveNbsp.Exceptions for a list of elements
|
||||
that don't have this behavior applied to them.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+46
-46
@@ -1,46 +1,46 @@
|
||||
AutoFormat.RemoveEmpty
|
||||
TYPE: bool
|
||||
VERSION: 3.2.0
|
||||
DEFAULT: false
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
When enabled, HTML Purifier will attempt to remove empty elements that
|
||||
contribute no semantic information to the document. The following types
|
||||
of nodes will be removed:
|
||||
</p>
|
||||
<ul><li>
|
||||
Tags with no attributes and no content, and that are not empty
|
||||
elements (remove <code><a></a></code> but not
|
||||
<code><br /></code>), and
|
||||
</li>
|
||||
<li>
|
||||
Tags with no content, except for:<ul>
|
||||
<li>The <code>colgroup</code> element, or</li>
|
||||
<li>
|
||||
Elements with the <code>id</code> or <code>name</code> attribute,
|
||||
when those attributes are permitted on those elements.
|
||||
</li>
|
||||
</ul></li>
|
||||
</ul>
|
||||
<p>
|
||||
Please be very careful when using this functionality; while it may not
|
||||
seem that empty elements contain useful information, they can alter the
|
||||
layout of a document given appropriate styling. This directive is most
|
||||
useful when you are processing machine-generated HTML, please avoid using
|
||||
it on regular user HTML.
|
||||
</p>
|
||||
<p>
|
||||
Elements that contain only whitespace will be treated as empty. Non-breaking
|
||||
spaces, however, do not count as whitespace. See
|
||||
%AutoFormat.RemoveEmpty.RemoveNbsp for alternate behavior.
|
||||
</p>
|
||||
<p>
|
||||
This algorithm is not perfect; you may still notice some empty tags,
|
||||
particularly if a node had elements, but those elements were later removed
|
||||
because they were not permitted in that context, or tags that, after
|
||||
being auto-closed by another tag, where empty. This is for safety reasons
|
||||
to prevent clever code from breaking validation. The general rule of thumb:
|
||||
if a tag looked empty on the way in, it will get removed; if HTML Purifier
|
||||
made it empty, it will stay.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
AutoFormat.RemoveEmpty
|
||||
TYPE: bool
|
||||
VERSION: 3.2.0
|
||||
DEFAULT: false
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
When enabled, HTML Purifier will attempt to remove empty elements that
|
||||
contribute no semantic information to the document. The following types
|
||||
of nodes will be removed:
|
||||
</p>
|
||||
<ul><li>
|
||||
Tags with no attributes and no content, and that are not empty
|
||||
elements (remove <code><a></a></code> but not
|
||||
<code><br /></code>), and
|
||||
</li>
|
||||
<li>
|
||||
Tags with no content, except for:<ul>
|
||||
<li>The <code>colgroup</code> element, or</li>
|
||||
<li>
|
||||
Elements with the <code>id</code> or <code>name</code> attribute,
|
||||
when those attributes are permitted on those elements.
|
||||
</li>
|
||||
</ul></li>
|
||||
</ul>
|
||||
<p>
|
||||
Please be very careful when using this functionality; while it may not
|
||||
seem that empty elements contain useful information, they can alter the
|
||||
layout of a document given appropriate styling. This directive is most
|
||||
useful when you are processing machine-generated HTML, please avoid using
|
||||
it on regular user HTML.
|
||||
</p>
|
||||
<p>
|
||||
Elements that contain only whitespace will be treated as empty. Non-breaking
|
||||
spaces, however, do not count as whitespace. See
|
||||
%AutoFormat.RemoveEmpty.RemoveNbsp for alternate behavior.
|
||||
</p>
|
||||
<p>
|
||||
This algorithm is not perfect; you may still notice some empty tags,
|
||||
particularly if a node had elements, but those elements were later removed
|
||||
because they were not permitted in that context, or tags that, after
|
||||
being auto-closed by another tag, where empty. This is for safety reasons
|
||||
to prevent clever code from breaking validation. The general rule of thumb:
|
||||
if a tag looked empty on the way in, it will get removed; if HTML Purifier
|
||||
made it empty, it will stay.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+11
-11
@@ -1,11 +1,11 @@
|
||||
AutoFormat.RemoveSpansWithoutAttributes
|
||||
TYPE: bool
|
||||
VERSION: 4.0.1
|
||||
DEFAULT: false
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
This directive causes <code>span</code> tags without any attributes
|
||||
to be removed. It will also remove spans that had all attributes
|
||||
removed during processing.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
AutoFormat.RemoveSpansWithoutAttributes
|
||||
TYPE: bool
|
||||
VERSION: 4.0.1
|
||||
DEFAULT: false
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
This directive causes <code>span</code> tags without any attributes
|
||||
to be removed. It will also remove spans that had all attributes
|
||||
removed during processing.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+11
-11
@@ -1,11 +1,11 @@
|
||||
CSS.AllowDuplicates
|
||||
TYPE: bool
|
||||
DEFAULT: false
|
||||
VERSION: 4.8.0
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
By default, HTML Purifier removes duplicate CSS properties,
|
||||
like <code>color:red; color:blue</code>. If this is set to
|
||||
true, duplicate properties are allowed.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
CSS.AllowDuplicates
|
||||
TYPE: bool
|
||||
DEFAULT: false
|
||||
VERSION: 4.8.0
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
By default, HTML Purifier removes duplicate CSS properties,
|
||||
like <code>color:red; color:blue</code>. If this is set to
|
||||
true, duplicate properties are allowed.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+8
-8
@@ -1,8 +1,8 @@
|
||||
CSS.AllowImportant
|
||||
TYPE: bool
|
||||
DEFAULT: false
|
||||
VERSION: 3.1.0
|
||||
--DESCRIPTION--
|
||||
This parameter determines whether or not !important cascade modifiers should
|
||||
be allowed in user CSS. If false, !important will stripped.
|
||||
--# vim: et sw=4 sts=4
|
||||
CSS.AllowImportant
|
||||
TYPE: bool
|
||||
DEFAULT: false
|
||||
VERSION: 3.1.0
|
||||
--DESCRIPTION--
|
||||
This parameter determines whether or not !important cascade modifiers should
|
||||
be allowed in user CSS. If false, !important will stripped.
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+11
-11
@@ -1,11 +1,11 @@
|
||||
CSS.AllowTricky
|
||||
TYPE: bool
|
||||
DEFAULT: false
|
||||
VERSION: 3.1.0
|
||||
--DESCRIPTION--
|
||||
This parameter determines whether or not to allow "tricky" CSS properties and
|
||||
values. Tricky CSS properties/values can drastically modify page layout or
|
||||
be used for deceptive practices but do not directly constitute a security risk.
|
||||
For example, <code>display:none;</code> is considered a tricky property that
|
||||
will only be allowed if this directive is set to true.
|
||||
--# vim: et sw=4 sts=4
|
||||
CSS.AllowTricky
|
||||
TYPE: bool
|
||||
DEFAULT: false
|
||||
VERSION: 3.1.0
|
||||
--DESCRIPTION--
|
||||
This parameter determines whether or not to allow "tricky" CSS properties and
|
||||
values. Tricky CSS properties/values can drastically modify page layout or
|
||||
be used for deceptive practices but do not directly constitute a security risk.
|
||||
For example, <code>display:none;</code> is considered a tricky property that
|
||||
will only be allowed if this directive is set to true.
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+12
-12
@@ -1,12 +1,12 @@
|
||||
CSS.AllowedFonts
|
||||
TYPE: lookup/null
|
||||
VERSION: 4.3.0
|
||||
DEFAULT: NULL
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
Allows you to manually specify a set of allowed fonts. If
|
||||
<code>NULL</code>, all fonts are allowed. This directive
|
||||
affects generic names (serif, sans-serif, monospace, cursive,
|
||||
fantasy) as well as specific font families.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
CSS.AllowedFonts
|
||||
TYPE: lookup/null
|
||||
VERSION: 4.3.0
|
||||
DEFAULT: NULL
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
Allows you to manually specify a set of allowed fonts. If
|
||||
<code>NULL</code>, all fonts are allowed. This directive
|
||||
affects generic names (serif, sans-serif, monospace, cursive,
|
||||
fantasy) as well as specific font families.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+18
-18
@@ -1,18 +1,18 @@
|
||||
CSS.AllowedProperties
|
||||
TYPE: lookup/null
|
||||
VERSION: 3.1.0
|
||||
DEFAULT: NULL
|
||||
--DESCRIPTION--
|
||||
|
||||
<p>
|
||||
If HTML Purifier's style attributes set is unsatisfactory for your needs,
|
||||
you can overload it with your own list of tags to allow. Note that this
|
||||
method is subtractive: it does its job by taking away from HTML Purifier
|
||||
usual feature set, so you cannot add an attribute that HTML Purifier never
|
||||
supported in the first place.
|
||||
</p>
|
||||
<p>
|
||||
<strong>Warning:</strong> If another directive conflicts with the
|
||||
elements here, <em>that</em> directive will win and override.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
CSS.AllowedProperties
|
||||
TYPE: lookup/null
|
||||
VERSION: 3.1.0
|
||||
DEFAULT: NULL
|
||||
--DESCRIPTION--
|
||||
|
||||
<p>
|
||||
If HTML Purifier's style attributes set is unsatisfactory for your needs,
|
||||
you can overload it with your own list of tags to allow. Note that this
|
||||
method is subtractive: it does its job by taking away from HTML Purifier
|
||||
usual feature set, so you cannot add an attribute that HTML Purifier never
|
||||
supported in the first place.
|
||||
</p>
|
||||
<p>
|
||||
<strong>Warning:</strong> If another directive conflicts with the
|
||||
elements here, <em>that</em> directive will win and override.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+11
-11
@@ -1,11 +1,11 @@
|
||||
CSS.DefinitionRev
|
||||
TYPE: int
|
||||
VERSION: 2.0.0
|
||||
DEFAULT: 1
|
||||
--DESCRIPTION--
|
||||
|
||||
<p>
|
||||
Revision identifier for your custom definition. See
|
||||
%HTML.DefinitionRev for details.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
CSS.DefinitionRev
|
||||
TYPE: int
|
||||
VERSION: 2.0.0
|
||||
DEFAULT: 1
|
||||
--DESCRIPTION--
|
||||
|
||||
<p>
|
||||
Revision identifier for your custom definition. See
|
||||
%HTML.DefinitionRev for details.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+13
-13
@@ -1,13 +1,13 @@
|
||||
CSS.ForbiddenProperties
|
||||
TYPE: lookup
|
||||
VERSION: 4.2.0
|
||||
DEFAULT: array()
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
This is the logical inverse of %CSS.AllowedProperties, and it will
|
||||
override that directive or any other directive. If possible,
|
||||
%CSS.AllowedProperties is recommended over this directive,
|
||||
because it can sometimes be difficult to tell whether or not you've
|
||||
forbidden all of the CSS properties you truly would like to disallow.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
CSS.ForbiddenProperties
|
||||
TYPE: lookup
|
||||
VERSION: 4.2.0
|
||||
DEFAULT: array()
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
This is the logical inverse of %CSS.AllowedProperties, and it will
|
||||
override that directive or any other directive. If possible,
|
||||
%CSS.AllowedProperties is recommended over this directive,
|
||||
because it can sometimes be difficult to tell whether or not you've
|
||||
forbidden all of the CSS properties you truly would like to disallow.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+16
-16
@@ -1,16 +1,16 @@
|
||||
CSS.MaxImgLength
|
||||
TYPE: string/null
|
||||
DEFAULT: '1200px'
|
||||
VERSION: 3.1.1
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
This parameter sets the maximum allowed length on <code>img</code> tags,
|
||||
effectively the <code>width</code> and <code>height</code> properties.
|
||||
Only absolute units of measurement (in, pt, pc, mm, cm) and pixels (px) are allowed. This is
|
||||
in place to prevent imagecrash attacks, disable with null at your own risk.
|
||||
This directive is similar to %HTML.MaxImgLength, and both should be
|
||||
concurrently edited, although there are
|
||||
subtle differences in the input format (the CSS max is a number with
|
||||
a unit).
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
CSS.MaxImgLength
|
||||
TYPE: string/null
|
||||
DEFAULT: '1200px'
|
||||
VERSION: 3.1.1
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
This parameter sets the maximum allowed length on <code>img</code> tags,
|
||||
effectively the <code>width</code> and <code>height</code> properties.
|
||||
Only absolute units of measurement (in, pt, pc, mm, cm) and pixels (px) are allowed. This is
|
||||
in place to prevent imagecrash attacks, disable with null at your own risk.
|
||||
This directive is similar to %HTML.MaxImgLength, and both should be
|
||||
concurrently edited, although there are
|
||||
subtle differences in the input format (the CSS max is a number with
|
||||
a unit).
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+10
-10
@@ -1,10 +1,10 @@
|
||||
CSS.Proprietary
|
||||
TYPE: bool
|
||||
VERSION: 3.0.0
|
||||
DEFAULT: false
|
||||
--DESCRIPTION--
|
||||
|
||||
<p>
|
||||
Whether or not to allow safe, proprietary CSS values.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
CSS.Proprietary
|
||||
TYPE: bool
|
||||
VERSION: 3.0.0
|
||||
DEFAULT: false
|
||||
--DESCRIPTION--
|
||||
|
||||
<p>
|
||||
Whether or not to allow safe, proprietary CSS values.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
CSS.Trusted
|
||||
TYPE: bool
|
||||
VERSION: 4.2.1
|
||||
DEFAULT: false
|
||||
--DESCRIPTION--
|
||||
Indicates whether or not the user's CSS input is trusted or not. If the
|
||||
input is trusted, a more expansive set of allowed properties. See
|
||||
also %HTML.Trusted.
|
||||
--# vim: et sw=4 sts=4
|
||||
CSS.Trusted
|
||||
TYPE: bool
|
||||
VERSION: 4.2.1
|
||||
DEFAULT: false
|
||||
--DESCRIPTION--
|
||||
Indicates whether or not the user's CSS input is trusted or not. If the
|
||||
input is trusted, a more expansive set of allowed properties. See
|
||||
also %HTML.Trusted.
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+14
-14
@@ -1,14 +1,14 @@
|
||||
Cache.DefinitionImpl
|
||||
TYPE: string/null
|
||||
VERSION: 2.0.0
|
||||
DEFAULT: 'Serializer'
|
||||
--DESCRIPTION--
|
||||
|
||||
This directive defines which method to use when caching definitions,
|
||||
the complex data-type that makes HTML Purifier tick. Set to null
|
||||
to disable caching (not recommended, as you will see a definite
|
||||
performance degradation).
|
||||
|
||||
--ALIASES--
|
||||
Core.DefinitionCache
|
||||
--# vim: et sw=4 sts=4
|
||||
Cache.DefinitionImpl
|
||||
TYPE: string/null
|
||||
VERSION: 2.0.0
|
||||
DEFAULT: 'Serializer'
|
||||
--DESCRIPTION--
|
||||
|
||||
This directive defines which method to use when caching definitions,
|
||||
the complex data-type that makes HTML Purifier tick. Set to null
|
||||
to disable caching (not recommended, as you will see a definite
|
||||
performance degradation).
|
||||
|
||||
--ALIASES--
|
||||
Core.DefinitionCache
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+13
-13
@@ -1,13 +1,13 @@
|
||||
Cache.SerializerPath
|
||||
TYPE: string/null
|
||||
VERSION: 2.0.0
|
||||
DEFAULT: NULL
|
||||
--DESCRIPTION--
|
||||
|
||||
<p>
|
||||
Absolute path with no trailing slash to store serialized definitions in.
|
||||
Default is within the
|
||||
HTML Purifier library inside DefinitionCache/Serializer. This
|
||||
path must be writable by the webserver.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
Cache.SerializerPath
|
||||
TYPE: string/null
|
||||
VERSION: 2.0.0
|
||||
DEFAULT: NULL
|
||||
--DESCRIPTION--
|
||||
|
||||
<p>
|
||||
Absolute path with no trailing slash to store serialized definitions in.
|
||||
Default is within the
|
||||
HTML Purifier library inside DefinitionCache/Serializer. This
|
||||
path must be writable by the webserver.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+16
-16
@@ -1,16 +1,16 @@
|
||||
Cache.SerializerPermissions
|
||||
TYPE: int/null
|
||||
VERSION: 4.3.0
|
||||
DEFAULT: 0755
|
||||
--DESCRIPTION--
|
||||
|
||||
<p>
|
||||
Directory permissions of the files and directories created inside
|
||||
the DefinitionCache/Serializer or other custom serializer path.
|
||||
</p>
|
||||
<p>
|
||||
In HTML Purifier 4.8.0, this also supports <code>NULL</code>,
|
||||
which means that no chmod'ing or directory creation shall
|
||||
occur.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
Cache.SerializerPermissions
|
||||
TYPE: int/null
|
||||
VERSION: 4.3.0
|
||||
DEFAULT: 0755
|
||||
--DESCRIPTION--
|
||||
|
||||
<p>
|
||||
Directory permissions of the files and directories created inside
|
||||
the DefinitionCache/Serializer or other custom serializer path.
|
||||
</p>
|
||||
<p>
|
||||
In HTML Purifier 4.8.0, this also supports <code>NULL</code>,
|
||||
which means that no chmod'ing or directory creation shall
|
||||
occur.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+18
-18
@@ -1,18 +1,18 @@
|
||||
Core.AggressivelyFixLt
|
||||
TYPE: bool
|
||||
VERSION: 2.1.0
|
||||
DEFAULT: true
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
This directive enables aggressive pre-filter fixes HTML Purifier can
|
||||
perform in order to ensure that open angled-brackets do not get killed
|
||||
during parsing stage. Enabling this will result in two preg_replace_callback
|
||||
calls and at least two preg_replace calls for every HTML document parsed;
|
||||
if your users make very well-formed HTML, you can set this directive false.
|
||||
This has no effect when DirectLex is used.
|
||||
</p>
|
||||
<p>
|
||||
<strong>Notice:</strong> This directive's default turned from false to true
|
||||
in HTML Purifier 3.2.0.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
Core.AggressivelyFixLt
|
||||
TYPE: bool
|
||||
VERSION: 2.1.0
|
||||
DEFAULT: true
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
This directive enables aggressive pre-filter fixes HTML Purifier can
|
||||
perform in order to ensure that open angled-brackets do not get killed
|
||||
during parsing stage. Enabling this will result in two preg_replace_callback
|
||||
calls and at least two preg_replace calls for every HTML document parsed;
|
||||
if your users make very well-formed HTML, you can set this directive false.
|
||||
This has no effect when DirectLex is used.
|
||||
</p>
|
||||
<p>
|
||||
<strong>Notice:</strong> This directive's default turned from false to true
|
||||
in HTML Purifier 3.2.0.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
Core.AggressivelyRemoveScript
|
||||
TYPE: bool
|
||||
VERSION: 4.9.0
|
||||
DEFAULT: true
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
This directive enables aggressive pre-filter removal of
|
||||
script tags. This is not necessary for security,
|
||||
but it can help work around a bug in libxml where embedded
|
||||
HTML elements inside script sections cause the parser to
|
||||
choke. To revert to pre-4.9.0 behavior, set this to false.
|
||||
This directive has no effect if %Core.Trusted is true,
|
||||
%Core.RemoveScriptContents is false, or %Core.HiddenElements
|
||||
does not contain script.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
+16
-16
@@ -1,16 +1,16 @@
|
||||
Core.AllowHostnameUnderscore
|
||||
TYPE: bool
|
||||
VERSION: 4.6.0
|
||||
DEFAULT: false
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
By RFC 1123, underscores are not permitted in host names.
|
||||
(This is in contrast to the specification for DNS, RFC
|
||||
2181, which allows underscores.)
|
||||
However, most browsers do the right thing when faced with
|
||||
an underscore in the host name, and so some poorly written
|
||||
websites are written with the expectation this should work.
|
||||
Setting this parameter to true relaxes our allowed character
|
||||
check so that underscores are permitted.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
Core.AllowHostnameUnderscore
|
||||
TYPE: bool
|
||||
VERSION: 4.6.0
|
||||
DEFAULT: false
|
||||
--DESCRIPTION--
|
||||
<p>
|
||||
By RFC 1123, underscores are not permitted in host names.
|
||||
(This is in contrast to the specification for DNS, RFC
|
||||
2181, which allows underscores.)
|
||||
However, most browsers do the right thing when faced with
|
||||
an underscore in the host name, and so some poorly written
|
||||
websites are written with the expectation this should work.
|
||||
Setting this parameter to true relaxes our allowed character
|
||||
check so that underscores are permitted.
|
||||
</p>
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+12
-12
@@ -1,12 +1,12 @@
|
||||
Core.CollectErrors
|
||||
TYPE: bool
|
||||
VERSION: 2.0.0
|
||||
DEFAULT: false
|
||||
--DESCRIPTION--
|
||||
|
||||
Whether or not to collect errors found while filtering the document. This
|
||||
is a useful way to give feedback to your users. <strong>Warning:</strong>
|
||||
Currently this feature is very patchy and experimental, with lots of
|
||||
possible error messages not yet implemented. It will not cause any
|
||||
problems, but it may not help your users either.
|
||||
--# vim: et sw=4 sts=4
|
||||
Core.CollectErrors
|
||||
TYPE: bool
|
||||
VERSION: 2.0.0
|
||||
DEFAULT: false
|
||||
--DESCRIPTION--
|
||||
|
||||
Whether or not to collect errors found while filtering the document. This
|
||||
is a useful way to give feedback to your users. <strong>Warning:</strong>
|
||||
Currently this feature is very patchy and experimental, with lots of
|
||||
possible error messages not yet implemented. It will not cause any
|
||||
problems, but it may not help your users either.
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+29
-29
@@ -1,29 +1,29 @@
|
||||
Core.ColorKeywords
|
||||
TYPE: hash
|
||||
VERSION: 2.0.0
|
||||
--DEFAULT--
|
||||
array (
|
||||
'maroon' => '#800000',
|
||||
'red' => '#FF0000',
|
||||
'orange' => '#FFA500',
|
||||
'yellow' => '#FFFF00',
|
||||
'olive' => '#808000',
|
||||
'purple' => '#800080',
|
||||
'fuchsia' => '#FF00FF',
|
||||
'white' => '#FFFFFF',
|
||||
'lime' => '#00FF00',
|
||||
'green' => '#008000',
|
||||
'navy' => '#000080',
|
||||
'blue' => '#0000FF',
|
||||
'aqua' => '#00FFFF',
|
||||
'teal' => '#008080',
|
||||
'black' => '#000000',
|
||||
'silver' => '#C0C0C0',
|
||||
'gray' => '#808080',
|
||||
)
|
||||
--DESCRIPTION--
|
||||
|
||||
Lookup array of color names to six digit hexadecimal number corresponding
|
||||
to color, with preceding hash mark. Used when parsing colors. The lookup
|
||||
is done in a case-insensitive manner.
|
||||
--# vim: et sw=4 sts=4
|
||||
Core.ColorKeywords
|
||||
TYPE: hash
|
||||
VERSION: 2.0.0
|
||||
--DEFAULT--
|
||||
array (
|
||||
'maroon' => '#800000',
|
||||
'red' => '#FF0000',
|
||||
'orange' => '#FFA500',
|
||||
'yellow' => '#FFFF00',
|
||||
'olive' => '#808000',
|
||||
'purple' => '#800080',
|
||||
'fuchsia' => '#FF00FF',
|
||||
'white' => '#FFFFFF',
|
||||
'lime' => '#00FF00',
|
||||
'green' => '#008000',
|
||||
'navy' => '#000080',
|
||||
'blue' => '#0000FF',
|
||||
'aqua' => '#00FFFF',
|
||||
'teal' => '#008080',
|
||||
'black' => '#000000',
|
||||
'silver' => '#C0C0C0',
|
||||
'gray' => '#808080',
|
||||
)
|
||||
--DESCRIPTION--
|
||||
|
||||
Lookup array of color names to six digit hexadecimal number corresponding
|
||||
to color, with preceding hash mark. Used when parsing colors. The lookup
|
||||
is done in a case-insensitive manner.
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
+14
-14
@@ -1,14 +1,14 @@
|
||||
Core.ConvertDocumentToFragment
|
||||
TYPE: bool
|
||||
DEFAULT: true
|
||||
--DESCRIPTION--
|
||||
|
||||
This parameter determines whether or not the filter should convert
|
||||
input that is a full document with html and body tags to a fragment
|
||||
of just the contents of a body tag. This parameter is simply something
|
||||
HTML Purifier can do during an edge-case: for most inputs, this
|
||||
processing is not necessary.
|
||||
|
||||
--ALIASES--
|
||||
Core.AcceptFullDocuments
|
||||
--# vim: et sw=4 sts=4
|
||||
Core.ConvertDocumentToFragment
|
||||
TYPE: bool
|
||||
DEFAULT: true
|
||||
--DESCRIPTION--
|
||||
|
||||
This parameter determines whether or not the filter should convert
|
||||
input that is a full document with html and body tags to a fragment
|
||||
of just the contents of a body tag. This parameter is simply something
|
||||
HTML Purifier can do during an edge-case: for most inputs, this
|
||||
processing is not necessary.
|
||||
|
||||
--ALIASES--
|
||||
Core.AcceptFullDocuments
|
||||
--# vim: et sw=4 sts=4
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user