Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2008-12-08 19:49:00

qrayg
Member
From: USA
Registered: 2004-08-27
Posts: 81
Website

[feedback] jQuery

Instead of including the actual jQuery js file with TXP it might be better to just do what jQuery.com does to reference the library:

<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.2.6/jquery.min.js"></script>

Google hosts all major JS libraries. We are all free to use them as we see fit.

http://code.google.com/apis/ajaxlibs/

Offline

#2 2008-12-08 20:41:57

the_ghost
Plugin Author
From: Minsk, The Republic of Belarus
Registered: 2007-07-26
Posts: 907
Website

Re: [feedback] jQuery

  1. Cross-domain js including can be closed for some security resones on some systems
  2. Such query will raise the time of loading
  3. What will do users that create sites locally?

Providing help in hacking ATM! Come to courses and don’t forget to bring us notebook and hammer! What for notebook? What a kind of hacker you are without notebok?

Offline

#3 2008-12-08 20:46:46

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 11,446
Website GitHub

Re: [feedback] jQuery

4. I trust Google as far as I can kick them ;-)


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Offline

#4 2008-12-08 20:59:00

masa
Member
From: Asturias, Spain
Registered: 2005-11-25
Posts: 1,091

Re: [feedback] jQuery

The idea behind google’s offering is, that once its hosted jquery has been cached, it won’t need to be downloaded when visiting other sites, that link to it in the same way, which is good.

Regarding local development, wouldn’t that reference be resolved just fine as long as you’re connected to the internet?

Offline

#5 2008-12-08 21:05:27

qrayg
Member
From: USA
Registered: 2004-08-27
Posts: 81
Website

Re: [feedback] jQuery

the_ghost wrote:

  1. Cross-domain js including can be closed for some security resones on some systems
  2. Such query will raise the time of loading
  3. What will do users that create sites locally?

  1. You can access the same file though https as well.
  2. Google’s hosting is very, very fast. After it loads once it is cached.
  3. I use this method to develop sites locally for testing and it works great.

Offline

#6 2008-12-08 23:17:09

graeme
Plugin Author
Registered: 2004-06-21
Posts: 337
Website

Re: [feedback] jQuery

I’m using this method to include the jQuery UI library for the next gbp_permanent_links release (admin interface only – of course) – do people really see this as a problem?

Was considered letting the user define their own URL if they wish to upload the file their own host.

Offline

#7 2008-12-09 02:41:00

MattD
Plugin Author
From: Monterey, California
Registered: 2008-03-21
Posts: 1,254
Website

Re: [feedback] jQuery

graeme wrote:

I’m using this method to include the jQuery UI library for the next gbp_permanent_links release (admin interface only – of course) – do people really see this as a problem?

Isn’t jquery already included in the admin interface?


My Plugins

Piwik Dashboard, Google Analytics Dashboard, Minibar, Article Image Colorpicker, Admin Datepicker, Admin Google Map, Admin Colorpicker

Offline

#8 2008-12-09 03:35:03

Gocom
Developer Emeritus
From: Helsinki, Finland
Registered: 2006-07-14
Posts: 4,533
Website

Re: [feedback] jQuery

  1. Many countries, ISPs and companies have IP blocks. One of them might be Google in some cases.
  2. Some ppl don’t cache JavaScript that they download very long. To avoid memory leaks/filling and so on.
  3. What about if googleapis.com is hacked and file is replaced with something harmful. Yes, it is google so it isn’t going to happen hopefully, but every system is crackable.
  4. I don’t want to google to know my referrers, IPs and so on.

PS. In Finland goverment blocked W3C accidently for a week period, making that domain inaccesable for a millions of ppl. But IP blocking isn’t forced by law in Finland, so internet providers can deside to use it or not. When you think that, you will realise what other know good domains can also be blocked in some companies and countries.

Last edited by Gocom (2008-12-09 03:49:27)

Offline

#9 2008-12-09 03:56:19

hcgtv
Plugin Author
From: Key Largo, Florida
Registered: 2005-11-29
Posts: 2,722
Website

Re: [feedback] jQuery

I came across a small blog app that grabs it’s WYSIWYG article editor from Yahoo!.

At first I thought why, would it be slow to run, but it’s not, and the editor is pretty nice. Another advantage that Brian explains for doing Wordcraft this way, is that he doesn’t have to distribute the code with his app, so it’s a super light download.

Which got me to thinking, maybe it makes sense to have hosted libraries that we all use. I mean how many PHP projects include FCKeditor in their distros. I’ve seen a blog app that 90% of it’s download size is taken up by this WYSIWYG editor.

What Google and Yahoo! are doing is the future, whether we may agree with it or not.

Offline

#10 2008-12-09 06:42:15

wet
Developer Emeritus
From: Schoerfling, Austria
Registered: 2005-06-06
Posts: 3,330
Website Mastodon

Re: [feedback] jQuery

We would earn the advantage of saving a ~30 KiB one-time download and lose the ability to develop offline.

AFAIR, jQuery has changed their hosted library URL twice so far, so in the light of the rather limited benefits of your proposal I’d rather wait a few additional jQuery releases to see which distribution method stabilizes.

Aside: WordPress distributes just about every prominent JS library on earth with their package.

Offline

#11 2008-12-09 08:23:06

graeme
Plugin Author
Registered: 2004-06-21
Posts: 337
Website

Re: [feedback] jQuery

MattD wrote:

Isn’t jquery already included in the admin interface?

I’m talking about jQuery UI

Last edited by graeme (2008-12-09 08:23:50)

Offline

#12 2008-12-09 15:19:49

mrdale
Member
From: Walla Walla
Registered: 2004-11-19
Posts: 2,215
Website

Re: [feedback] jQuery

masa wrote:

Regarding local development, wouldn’t that reference be resolved just fine as long as you’re connected to the internet?

Good idea, but sometimes I design sites on a 5 hour car trip where do net is nicht da. My wife drives of course ;)

Offline

Board footer

Powered by FluxBB