English 中文(简体)
推广使用相对途径
原标题:Use relative path in Firefox extension

我用捆绑的可起诉档案开发“延伸”,这些档案应该从浏览器开始。

To run process I need get nsIFile or nsILocalFile instance which points to executable file. I know one solution how to get it using directory service:

var file = Components.classes["@mozilla.org/file/directory_service;1"].getService(Components.interfaces.nsIProperties).get("ProfD", Components.interfaces.nsIFile);
file.append("extensions");
file.append("<extension id>");
file.append("<relative path>");

但这一解决办法有两个缺点:

  1. 它没有发展模式的工作,而我只拥有真正推广道路的文本。

  2. 我不敢肯定,它会因为硬通条条条条形形形形色色的“延伸”而对所有代号进行工作。

那么,是否有哪一种可起诉的档案与否延伸?

感谢。

最佳回答
问题回答




相关问题
CSS working only in Firefox

I am trying to create a search text-field like on the Apple website. The HTML looks like this: <div class="frm-search"> <div> <input class="btn" type="image" src="http://www....

jQuery block moving

I wanna move a div block to the top, so I coded like this: CSS part: .movingPart{ margin-top:80px; } jQuery part: $(document).ready(function() { $( #btn ).click(function() { $( .movingPart )....

Private FireFox plugin

I m looking at getting a FireFox plugin developed - but is it possible to create a plugin that is for private use only, so only those I share it with have it and not open to the masses? Need this for ...

Firefox background image horizontal centering oddity

I am building some basic HTML code for a CMS. One of the page-related options in the CMS is "background image" and "stretch page width / height to background image width / height." so that with large ...

Cross-browser development

I m developing a web application for a new service, starting from Firefox 3.5. The interface design is tableless, only using divs + CSS & performance-blessed practices. Now, while being ...

Cross browser way of setting IFrame to "about:blank"?

Does anybody know a proper, cross-browser way to "empty" an IFrame? Is "about:blank" recognized without error across all browsers? Is it valid to give an IFrame an empty src?

热门标签