Skip to content

Commit c45ef00

Browse files
committed
Add common function is_windows
1 parent 45fc39c commit c45ef00

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

system/core/Common.php

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,19 @@ function is_php($version)
7676

7777
// ------------------------------------------------------------------------
7878

79+
if ( ! function_exists('is_windows'))
80+
{
81+
/**
82+
* Check if we're running on a Windows platform
83+
*/
84+
function is_windows()
85+
{
86+
return DIRECTORY_SEPARATOR === '\\';
87+
}
88+
}
89+
90+
// ------------------------------------------------------------------------
91+
7992
if ( ! function_exists('is_really_writable'))
8093
{
8194
/**

0 commit comments

Comments
 (0)