Welcome Guest, Not a member yet? Register   Sign In
calling base_url() or site_url() in the external js file
#3

[eluser]jairoh_[/eluser]
[quote author="anis2505" date="1372808560"]Hi, I don't think that's possible. the best way -as I think- you just create a js script and create these two function and include this script at the top of you web pages

Code:
JS File

var baseUrl = "you/base/url";
var siteUrl ="your/site/url";
var index="yourindex.php";

function base_url(uri){
return baseUrl+uri;
}

function site_url(uri){
  return siteUrl+index+"/"+uri;
}
[/quote]

yeah. tsk. anyway thankyou sir.


Messages In This Thread
calling base_url() or site_url() in the external js file - by El Forum - 07-02-2013, 07:03 PM



Theme © iAndrew 2016 - Forum software by © MyBB