Firefox Extensions Tutorial

Aug 18, 2005

Does anybody know of a good firefox extension tutorial?

Basically I have an XML list of things

<term>bleh</term>
<replacement>blehsky</replacement>

and I want to make the extension replace every occurance of bleh on the webpage with blehsky.

I can handle the javascript to do this, but I don't know where to start in making it into an extension.

View 6 Replies


ADVERTISEMENT

JavaScript Native Extensions

Nov 6, 2007

I'd like to announce release 1.0.7 of JNEXT (JavaScript Native
Extensions). JNEXT is an open source framework for securely accessing
the full range of native OS resources (files, databases, sockets etc.)
by using JavaScript from within a Web Page. It is light weight, cross
platform, cross browser and designed with simplicity in mind....

View 3 Replies View Related

Search To Return Only .html Extensions

Feb 7, 2006

I"m trying to do a search on a folder that contains both word docs and
html pages. I want the search to only return back the html pages.
Does anyone know the code for that?

View 3 Replies View Related

Accessing Private Members In Extensions

Mar 2, 2011

I'm trying to create an extensible class with private members.

Suppose I have the following:

Code:

Obviously, only "y" should be available to instantiations:

Code:

But how can I now extend this class and still access the private properties inside the extension?

Code:

How do I access x there? The someOtherFunction extension is part of the prototype, so it should be in the same scope as someFunction, no?

View 1 Replies View Related

Function To Load Files - With .txt Extensions

Mar 16, 2009

i have a function to load text files.

function load(n){textfile=n;if(n.indexOf("#")!=-1){theleft=n.indexOf("#")+1;textfile=(n.substring(theleft))}
document.mycall.load(textfile+'.txt');origString=textfile;

and it only loads a files with .txt extensions. how to change this function to load files with .doc and .nfo extensions also.

View 2 Replies View Related

String Prototype Extensions - Post Your Best!

Apr 27, 2004

I couldn't find a single thread with the creme de la creme of String prototype extension methods, so I figured I'd start one. Here we go!

String.prototype.lTrim = function () {
return this.replace(/^s+/gm, "");
}

String.prototype.rTrim = function () {
return this.replace(/s+$/gm, "");
}

String.prototype.trim = function () {
return this.rTrim().lTrim();
}Obviously, this one's easy to understand. I'm using multi-line mode so as only to get rid of spaces and tabs before and after words. Single-line mode would replace any newline/carriage return characters as well.


String.prototype.capitalize = function () {
return this.replace(/[a-z]/g, function (str, n) { return str.toUpperCase(); });
}

String.prototype.toCamelCase = function () {
return this.replace(/s[a-z]/g, function (str, n) { return str.toUpperCase(); });
}

String.prototype.unCamelCase = function () {
return this.replace(/[A-Z]/g, function (str, n) { return " " + str.toUpperCase(); });
}This is something I needed today, to turn a camelCased variable value into its Header Format. While I was at it, I wrote the un-do-er.

View 8 Replies View Related

CGI - Frontpage Extensions; Online Forms

Dec 17, 2000

I have been using Frontpage to design web sites and know that online-forms can be created using Frontpage, but the host must have Frontpage Server Extensions installed...

...I was wondering if the online forms were simply CGI scripts??

If so, could i not get DreamWeaver Ultra Dev and write the CGI scripts in there? - I think DreamWeaver is capable of this?

Therefore, if a server supported CGI scripts and i had to pay extra for FRONTPAGE EXT. then i could bypass this problem by using CGI scripts...

...does this make sense? If not, why not?

View 1 Replies View Related

Check File Extensions On Multiple Uploads

Sep 10, 2009

Script works on the first attachment but not the other two?
<script type="text/javascript" language="JavaScript"><!--
function ExtensionsOkay() {
var extension = new Array();
var fieldvalue = new Array();
fieldvalue[0] = document.customApp.attachment_1.value;
fieldvalue[1] = document.customApp.attachment_2.value;
fieldvalue[2] = document.customApp.attachment_3.value;
extension[0] = ".doc";
extension[1] = ".docx";
extension[2] = ".txt";
extension[3] = ".pdf";

// No other customization needed.
for(var f = 0; f < fieldvalue.length; f++) {
var thisext = fieldvalue[f].substr(fieldvalue[f].lastIndexOf('.'));
for(var i = 0; i < extension.length; i++) {
if(thisext == extension[i]) { return true; }}
alert("Your upload field " + f + " contains an unapproved file name.");
return false;
}}
//--></script>

View 4 Replies View Related

Passing Parameters To Custom Element Extensions

Feb 12, 2003

When introducing custom functionality to HTML elements we either use existing attributes to pass configuration parameters (like beetle's fValidate (http://www.peterbailey.net/fValidate/)) or invent our own (like my Tooltips (http://www.vladdy.net/webdesign/ToolTips.html)). While this method is ok for small amount of configuration information, it is not that flexible (you need to edit DTD) and becomes combersome when large amount of configuration parameters is needed.

I figured a more convinient way is to use a CSS like string to pass configuration parameters:
<div myextension="parameter1: value1; parameter2-subparameter1: value2.1; parameter2-subparameter2: value2.2"> </div>

Then initialization routine would contain:
if(myExtensionParameters = divElement.getAttribute('myExtension'))
divElement.myExtension = new myExtensionObject(divElement,myExtensionParameters);


Definition of possible parameters and their values can be done using an array of regular expressions:
myExtensionParamDefenitions = new Array();
myExtensionParamDefenitions['choiceparameter'] = /^s*(value1a|value1b|value1c)s*$/;
myExtensionParamDefenitions['stringparameter'] = /^s*(w+)s*$/;
myExtensionParamDefenitions['integerparameter'] = /^s*(d+)s*$/;

Constructor for the myExtensionObject would containd a parseParameters function:
function myExtensionObject(divElement,myExtensionParameters)
{ this.params=new Array();
parseParameters(this.params,myExtensionParamDefenitions,myExtensionParameters);
//Verify parameter initialization, if you like
str=''
for(e in this.params) str+= e + ': ' + this.params[e] + '
'
alert(str);
//Do whatever you have to do...
}


Function parseParameters has the following code:
function parseParameters(object,definitions,parameters)
{ paramEntries = parameters.split('');
for(var i=0; i<paramEntries.length; i++)
{ paramEntry = paramEntries[i].split(':');
if(paramEntry.length == 2)
{ paramName = paramEntry[0].replace(/^s*([w-]+)s*$/,'$1');
if(definitions[paramName])
{ res = definitions[paramName].exec(paramEntry[1]);
if(res[1])
object[convertCSSName(paramName)] = res[1];
}
}
}
}

Where convertCSSName function converts CSS type name (background-image) to javascript name (backgroundImage)
function convertCSSName(cssName)
{ sn = cssName.split('-');
rs = sn[0];
for(var i=1; i<sn.length; i++)
rs += sn[i].replace(/^(w)(w*)$/,function(str,p1,p2,offset,s){return p1.toUpperCase() + p2;})
return rs;
}

As a result you have params array of myExtensionObject object populated with validated entries. Changes and expansion is done by simply editing myExtensionParamDefenitions array.

PS: The functions are coded more for clarity rather than for brevity - I'm certain there are ways to improve the implementation.

View 3 Replies View Related

Get Tutorial For Prototypes?

Mar 26, 2011

Link me to a good guide or tutorial for prototypes?

View 6 Replies View Related

AJAX Map Tutorial

May 5, 2006

I'm thinking about developing a Google Maps style project for the university I work at. What I'd like to do is have a graphical image of our campus we currently use, but use AJAX to allow people to select a building and have the map dynamically move and point out the location.

The map is quite big so I was thinking of having it like Google Maps where you can drag the map through an iframe without having the page reload.

Does anyone know of some good tutorials on how to do this? While our campus is relatively large, it's not large enough to just use Google Maps instead of developing our own.

View 2 Replies View Related

AJAX Tutorial

Mar 21, 2006

I am looking for some useful tutorial for AJAX. I did search on google, I got few but thought not enough or too basic. I am looking for some tutorials that are useful from your experience.

View 2 Replies View Related

Tutorial On Dynamic SID Generation

May 31, 2006

Is there a tutorial on dynamic SID generation?

View 15 Replies View Related

Human Typing Tutorial ?

Sep 8, 2011

I've made javascript tutorial for those who want to learn more

Here's the tutorial on my front page : [url] or direct link : [url]

View 2 Replies View Related

Get Good Script Tutorial?

Mar 9, 2010

I am a complete beginner to JavaScript (well I know this: document.write and alert) and I kneed a really good tutorial for beginners. Preferably free but I will pay up to �3 (not a lot I know but oh well)

View 1 Replies View Related

Looking For A Tutorial To Create Tabs For Content?

Dec 31, 2009

I'm looking for a tut on how to create tabs for content, not tabs for navigation/menu. Yes, kinda confusing, but here's an example of what I'm after code...

If you scroll down mid way, you will see a tabbed area where it provides the options to check out: Photos, Location, Aeriel and Street View. This is what I want to mimic (not the tabbed navigation up top in the menu bar).

Can you recommend any tutorials that would teach me how to do this?

View 2 Replies View Related

Books / Video Tutorial About Learning JS?

Aug 24, 2009

Can someone tell me how to learn JS? Can you recommend me some books or video tutorials? What is the best?

View 2 Replies View Related

Need Pop Open Boxes Script Or Tutorial

Sep 10, 2005

I'm not sure what the proper term is, so let me give you an example. Imagine visiting a web page and reading the following:

My Groups
Weather
Trivia

If you click "My Groups," an element pops open displaying a list of names. I'm not talking about a pop-up windows that you can move around. This is part of the page. It's invisible until someone clicks "My Groups."

If you click "Weather," another element opens, displaying information on the weather. Clicking "Trivia" opens a box with trivia questions.

I wonder if someone could point me to a good script or tutorial that explains how to do this. I think my preferred default setting would close all the other elements when you open a new element. For example, if you click "Weather," then the Weather box opens, but everything else closes.

However, it would be nice to have the flexibility to modify the open-shut mechanism.

I already have a script that does this, but it got mangled somehow. It requires an included JavaScript file and a style sheet working in tandem, and I haven't been able to recreate it. So I'd like to go back to square one and hopefully find an even better script - one that's a little more user friendly and/or versatile.

View 2 Replies View Related

Moofx Slide Down(Accordion) Tutorial?

Apr 23, 2007

I am after a slide draw type menu system like this one and this one the second actually at moo tools themselves.

I have had a look a round and there doesnt seem to be any tutorials which tell you what to do, so i dont have a clue...

Moofx seem to have the scripts to download but give no indation how they work.

View 3 Replies View Related

4 Dynamic Drop Downs, Any Tutorial Or Link?

Sep 10, 2007

I want to make a dynamic 4 drop down menus with AJAX and PHP/mySQL, like this:

Category->dynamic subCategory

County->dynamic cityCounty

Is there any good tutorial that can teach me how to do this? I managed
to have that Category dynamicly loads subCategory and that County
dynamicly loads cityCounty but I ran into a problem when I already
picked subCategory and than went on to pick a County, because of the
reload.this function in javascript my subCategory gets lost. Can anyone
point me in right direction?

View 1 Replies View Related

Image Rotation Script / Tutorial To Build One?

Jan 24, 2011

I'm trying out scripts previously made but with no luck. I cant get it to work.

Nothing to indepth. Nothing to fancy.

I just want a 4 image swap inside my div.

Can anyone guide me to a tutorial on how to build one?

View 13 Replies View Related

AJAX :: Tutorial Opinion About File Upload

Jan 13, 2009

Last year, just a few days before holidays, I wrote a tutorial about a new feature available in Firefox 3 that allows web developers to do AJAX-style file uploads. Initially I intended to publish this tutorial as a SitePoint article, but it got rejected so I published it on my blog.

Now, I'd love some feedback. So, if there's anyone out there that has enough patience to read an exhaustive tutorial about uploading files with nothing more than JavaScript I'd like to hear her/his opinion. If it's crap just tell me 'cause indifference kills. Anyway, if patience is not your strong point there's a ZIP package containing both a "simple" and a "complex" take on the problem. Try those.

View 1 Replies View Related

Tutorial Or Download Of A Horizontal Accordiong Menu

Apr 17, 2011

I'm trying to find a tutorial or download of a horizontal accordion menu using Javascript / CSS. There are plenty of drop-downs but little-to-no horizontal versions.This is the kind of thing I'm after but aligned left rather than centred.

View 1 Replies View Related

HTML5 Mouseover Area Tutorial - Unable To Use In IE8?

Nov 23, 2011

I was using this HTML5 mouseover tutorial, and realized it doesn't work in IE8. [URL]

View 2 Replies View Related

'Changing Select Element Content On Fly' Tutorial

Jul 5, 2009

My application uses multiple lists in dynamic tables the contents of which change to reflext a user's context. I tried applying your tutorial code for assigning arrays to option values and text using the suggested pipe character "|" delimiter if one was used, but strangely in FireFox .search() to test for the presence of the pipe character returned 0 whether it was there or not! Using another character such as "#" worked fine. Also using DOM methods the text component had to be added by appending a TextNode otherwise the list simply displayed a list of 'undefined' items.My resulting function just unwraps an array of list items into an option group which is then appended to the select element at the calling end:[code]

View 1 Replies View Related

JQuery :: Concise Tutorial To Do Remote Validation Of Forms

Jul 19, 2011

I'm brand new to jQuery, and I am really interested in learning about it because of the potential it offers to enhance my webpages. To give you some background, I am self-taught in PHP and MySQL...not on a master's level, but I have designed and built database-driven sites with success and am confident that I can learn jQuery if only I could get pointed in the right direction. I have perused tutorials, links, forums and recently bought the jQuery Cookbook (I needed SOMETHING to go on and it was one of the few jQuery books at the local bookstore that felt as though it would be of help). My problem is, I am finding gaps in information that, to me, are critical to learning. I am looking for a nut-and-bolt approach, 'Do this, then do that' not the typical generalizations I keep encountering.

All I want to do to start with is to remotely validate a two-item form, you guessed it, username and email, against the contents of my database (the info for the validation plugins is just as vague and general). That's it. But the tutorials and examples are vague to me, and in one instance, a link was posted offering to display the server-side validation code used and the link was dead. I can't be the only person here who is stonewalled by these thoughtful, yet overly-general tutorials and books. if any of you have suggestions where I can find a concise, true step-by-step tutorial or book, I would love to know. Right now, it's just one frustrating day of research after another.

View 3 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved