JAVA Scripts used by Joomla

Discussion and education for beginner / novice programmers interested in embarking on the development process to take advantage of the extensible nature of the Joomla! CMS.

Moderators: tjay, seadap, Rogue4ngel, matthewhayashida

Forum rules
Post Reply
User avatar
jalil
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 128
Joined: Wed Jul 04, 2007 4:54 am
Location: Kuala Lumpur, Malaysia
Contact:

JAVA Scripts used by Joomla

Post by jalil » Wed Dec 26, 2007 4:08 pm

Does anyone know where information on Java used by Joomla can be obtained ?

This is to avoid duplicate work of writing Java routines and Java/PHP interacton routines ( so called AJAX ),
using the Joomla in built Java scripts would be excellent for developers, rather than reinventing the wheel, as is done by most developers now and in the past i noticed, and i think this is because of lack of information and tutorial on this subject.

thanks.

User avatar
CirTap
Joomla! Intern
Joomla! Intern
Posts: 73
Joined: Mon Dec 12, 2005 5:34 pm
Contact:

Re: JavaScripts used by Joomla

Post by CirTap » Thu Jan 10, 2008 4:14 pm

Hi,

I don't want to sound picky or rude, but if you were searching for information using all the same wrong terms and relations like in your question, I'm not surprised you don't find anything useful ;-)

You'll find valuable information and documentation about the "Mootools JavaScript Library" used in Joomla! 1.5 on the Mootools website itself: http://mootools.net/
I doubt there'll be any documentation of theirs API someplace on a joomla.org site 'cos that'd would be duplicate work.
A lot of the JavaScript code that comes with J! 1.5 is based on Mootools and IMHO very task and extension specific, not necessarily "generic" in order to be useful/useable in any 3rd party code at good will.
As you speak of "AJAX routines": they are barely interchangeable since they're just an alternative method of using a form. And like there are no (true) generic FORM routines, there are no (true) generic AJAX routines; they always require custom code to process the data. The basic objects and tools are available in Mootools.
However, the JHTML class provides several "tools" that also take care of the JS code or file, a particular feature may need (i.e. the panes & sliders, admin toolbar & buttons, or the fancy uploader.)

jalil wrote:Does anyone know where information on Java used by Joomla can be obtained ?

simple answer: nowhere, because Joomla! doesn't use any JAVA ;)
Joomla! uses JavaScript -- single word! -- which doesn't have and never had anything to do with Java -- except for the (once marketing-related) usage of the first four letters in its name when it was first introduced by Netscape in "Navigator 3" about some 10+ years ago, and before that known as "LiveScript", a server-side scripting language.

jalil wrote:This is to avoid duplicate work of writing JavaScript routines and JavaScript/PHP interacton routines ( so called AJAX ),

AJAX = "Asynchronous JavaScript And XML" and is not related or bound to PHP either, but PHP and thus the J! Framework are both capable to create XML based content for use in client side scripts, provided they know how to deal with such a response.

jalil wrote:using the Joomla in built JavaScripts would be excellent for developers, rather than reinventing the wheel, as is done by most developers now and in the past i noticed, and i think this is because of lack of information and tutorial on this subject.


Have fun,
CirTap
You can have programs written fast, well, and cheap, but you only get to pick 2 ...

"I love deadlines. I like the whooshing sound they make as they fly by." Douglas Adams

User avatar
jalil
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 128
Joined: Wed Jul 04, 2007 4:54 am
Location: Kuala Lumpur, Malaysia
Contact:

Re: JavaScripts used by Joomla

Post by jalil » Fri Jan 11, 2008 1:20 am

i would like to discuss your points slight further, as i think it would benefit many...

CirTap wrote:Hi,

I don't want to sound picky or rude, but if you were searching for information using all the same wrong terms and relations like in your question, I'm not surprised you don't find anything useful ;-)


Rude, no. Picky Yes.  ;D

CirTap wrote:You'll find valuable information and documentation about the "Mootools JavaScript Library" used in Joomla! 1.5 on the Mootools website itself: http://mootools.net/
I doubt there'll be any documentation of theirs API someplace on a joomla.org site 'cos that'd would be duplicate work.


Maybe a duplicate, but it sure would be exremely convenient for users. But ok, fine, it is a policy matter and i respect that.

CirTap wrote:A lot of the JavaScript code that comes with J! 1.5 is based on Mootools and IMHO very task and extension specific, not necessarily "generic" in order to be useful/useable in any 3rd party code at good will.
As you speak of "AJAX routines": they are barely interchangeable since they're just an alternative method of using a form. And like there are no (true) generic FORM routines, there are no (true) generic AJAX routines; they always require custom code to process the data.


I use the Javascripts in 1.0 admin a lot. In fact, the thing will not run without well using the Javascipts provided by joomla.js.
I'm not sure how other developers handle this, but one would have to be extrmeley patient and look at the source codes in joomla to be able to write joomla extensions.

I guess this is the way Joomla approaches, and i have come across seveal mentions that actual extensions makes the best examples. So be it, it is just that this was never an approach i took, as normally i would do a study on the documents with a few simple examples. So this is a new way, it could also be a better way, and the choice of how to appraoch the subject is perhaps a personal choice.
So this is not an issue.


CirTap wrote:The basic objects and tools are available in Mootools.
However, the JHTML class provides several "tools" that also take care of the JS code or file, a particular feature may need (i.e. the panes & sliders, admin toolbar & buttons, or the fancy uploader.)


CirTap wrote:
jalil wrote:Does anyone know where information on Java used by Joomla can be obtained ?

simple answer: nowhere, because Joomla! doesn't use any JAVA ;)
Joomla! uses JavaScript -- single word! -- which doesn't have and never had anything to do with Java -- except for the (once marketing-related) usage of the first four letters in its name when it was first introduced by Netscape in "Navigator 3" about some 10+ years ago, and before that known as "LiveScript", a server-side scripting language.


I meant JavaScripts as per the topic of course! lol...you sure are pciky on the terms!



CirTap wrote:
jalil wrote:This is to avoid duplicate work of writing JavaScript routines and JavaScript/PHP interacton routines ( so called AJAX ),

AJAX = "Asynchronous JavaScript And XML" and is not related or bound to PHP either, but PHP and thus the J! Framework are both capable to create XML based content for use in client side scripts, provided they know how to deal with such a response.


That is exaclty what i mean. Joomla API does not provide this definition, only capability. What i was looking for is a streamlined method to produce some work in Joomla when using JavaScripts, notably AJAX. The example of JHTML you gave is i think an excellent example. The downside of this method is dependency on Joomla procuded codes, but the advantage gained is ease of coding and uniformity.

So JHTML does serve its purpose, and my point would be that there is only JHTML for us to work on. The rest we have to do. Which is not a problem to do, but many of us are dong the same thing in different ways. But if this is what Joomla wants to see, then its ok. My thinking was that Joomla would provide a standard client/server interfaces, and beyond that is up to the developer to.

JavaScript, being languages as like PHP, they do not define anything. It is up to us how we define them. So i would have thought Joomla have its own predefined and perhaps extensive definitions of what XML it would create and what it can be used for. Or is this beyond Joomla ?

Maybe an example would clarify my point. People coming online to the website is an event known only the server side. Other clients can be notified of this, if the client so wishes, by way of AJAX. What the client does with the information is up to the developer and the client, but if the information is made available in a standard and uniform way, it would allow developers to use them to make some very interesting applications using whatever they wish.

At present, each developer would do this in their own way. If there is a "call" available for my JavaScript to access Joomla and obtain this informaion, then i would be able to develop applications on top of that information. Now i have to build everything. The Scripts, the Communications, even the database at times. This makes it slightly more involved to writing simple client/server apps, and is what is meant by my last paragraph.

Thank You.

jalil wrote:using the Joomla in built JavaScripts would be excellent for developers, rather than reinventing the wheel, as is done by most developers now and in the past i noticed, and i think this is because of lack of information and tutorial on this subject.


Have fun,
CirTap

[/quote]


Post Reply