Is there any way to force javascrips use the root as the path?Rather then writing the cookie with the path like this

domain.com/path

I am having troubles using cookies in other directories because of this.