質問編集履歴
1
ソースを更新しました
test
CHANGED
File without changes
|
test
CHANGED
@@ -1,25 +1,31 @@
|
|
1
1
|
###前提・実現したいこと
|
2
2
|
|
3
|
-
PHP
|
3
|
+
PHPでファイルパスを管理するクラスを作りたいと思っています。
|
4
4
|
|
5
|
-
|
5
|
+
以下のような感じです。
|
6
|
+
|
7
|
+
|
6
8
|
|
7
9
|
```php
|
8
10
|
|
9
|
-
class Pa
|
11
|
+
class Pass{
|
10
12
|
|
11
|
-
//
|
13
|
+
public static function Get($pass = ''){ //プロジェクトの絶対パス
|
12
14
|
|
13
|
-
|
15
|
+
return '/'.$pass;
|
14
16
|
|
17
|
+
}
|
18
|
+
|
19
|
+
class Assets{
|
20
|
+
|
21
|
+
public static function Get($pass){
|
22
|
+
|
15
|
-
//.
|
23
|
+
return '/assets/'.$pass;
|
24
|
+
|
25
|
+
}
|
16
26
|
|
17
27
|
}
|
18
28
|
|
19
29
|
}
|
20
30
|
|
21
31
|
```
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
どなたか教えてください。
|