- 檔案系統模組
- PhantomJS - 屬性
- PhantomJS - 方法
- 系統模組
- PhantomJS - 屬性
- Web 伺服器模組
- PhantomJS - 屬性
- PhantomJS - 方法
- 雜項
- 命令列介面
- PhantomJS - 螢幕截圖
- PhantomJS - 頁面自動化
- PhantomJS - 網路監控
- PhantomJS - 測試
- PhantomJS - REPL
- PhantomJS - 示例
- PhantomJS 有用的資源
- PhantomJS - 快速指南
- PhantomJS - 有用的資源
- PhantomJS - 討論
PhantomJS - 絕對 path
此方法提供 PhantomJS 執行的絕對路徑。
語法
其語法如下 −
fs.absolute();
示例
讓我們看一個 absolute 方法的示例。
var fs = require('fs');
var cwd = fs.absolute(".");
console.log(fs);
以上程式生成以下 輸出。
C:/phantomjs/bin
phantomjs_file_system_module_methods.htm
廣告