Solved

Drupal.settings.basePath...what is this path?

Posted on 2010-08-31
6
2,572 Views
Last Modified: 2012-06-21
Hey all,
I have an script that I'm trying to figure out and it uses the following then appends more to the path.  My question is...what is the path to Drupal.settings.basePath ?

How can I find the url/path for: Drupal.settings.basePath ?

Thank you.
0
Comment
Question by:ModifyMe
  • 3
  • 2
6 Comments
 
LVL 46

Expert Comment

by:tbsgadi
ID: 33567698
Have a look at the following:

http://drupal.org/node/114774#base_path

Gary
0
 

Author Comment

by:ModifyMe
ID: 33567745
Yeah, and I'll be honest...I really could not understand it.  Just wondering if Drupal.settings.basePath is static.  

If so, what is the actual path?  
If not, is there a way to find the url/path it's pointing to?
0
 
LVL 46

Accepted Solution

by:
tbsgadi earned 500 total points
ID: 33567838
0
Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

 

Author Comment

by:ModifyMe
ID: 33567968
Ok Gary, I may be over my head on this one.  A former employee developed this module which did work, but now for some reason does not and I am trying to troubleshoot to fix.

I did review the link you just sent at akchauhan and understand it a bit more.  But my knowledge may be starting to become limited.

In our custom .js script, there is a variable which looks like the following:
var url = Drupal.settings.basePath +  "xxxx/xxxx_url";

So my goal is to figure our what this path is...

Sorry for being vague, this is my first experience with custom module development in Drupal.
0
 
LVL 17

Expert Comment

by:Thomas4019
ID: 33569077
if all you want to do is figure out what is it add this line to your javascript file. It should temporarily make a really annoying popup window with the value.
alert(Drupal.settings.basePath);
0
 

Author Closing Comment

by:ModifyMe
ID: 33643223
Thank you!
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

The task A number given should be formatted for easy reading by separating digits into triads. Format must be made inline via JavaScript, i.e., frameworks / functions are not welcome. So let’s take a number like this “12345678.91¿ and format i…
This article discusses the difference between strict equality operator and equality operator in JavaScript. The Need: Because JavaScript performs an implicit type conversion when performing comparisons, we have to take this into account when wri…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now