DrupalBin
Submit Code
About
Recent Posts
Can't create Event nodes programatically
1 hour 28 min
ago
Fix for login d6
1 hour 59 min
ago
login d6
2 hours 5 min
ago
tab hack with the use of tab module
3 hours 3 min
ago
more
Tags
CCK
drupal
fapi
jquery
menu
module
Panels
simpletest
template.php
test
theme
views
more tags
User login
Log in using OpenID:
What is OpenID?
Username:
*
Password:
*
Create new account
Request new password
Log in using OpenID
Cancel OpenID login
Home
javascript
Fix for Add JavaScript to specific node
August 20, 2008 - 6:59pm — Anonymous
/**
* Add JavaScript
*/
if
(
arg
(
0
)
==
'node'
&&
arg
(
1
)
==
$nid
&& !
arg
(
2
)
)
{
drupal_add_js
(
base_path
(
)
.
path_to_theme
(
)
.
'/js/jquery.scrollTo-1.3.3-min.js'
,
'theme'
,
'header'
,
FALSE
,
$cache
)
;
javascript
jquery
template.php
Read more
Add JavaScript to specific node
August 20, 2008 - 6:48pm — Anonymous
/**
* Add JavaScript
*/
if
(
$_GET
[
'q'
]
==
'node/14'
)
{
function
drupal_add_custom_js
(
$data =
NULL
, $type =
'theme'
, $scope =
'header'
, $defer =
FALSE
, $cache =
TRUE
)
{
javascript
jquery
template.php
Read more
JavaScript Convert the Temperature Code
July 29, 2008 - 12:18am — Anonymous
<html>
<head>
<title>Convert the Temperature</title>
<script type=
"text/javascript"
>
//This Code was created by David A. and Matt I. on July 28, 2008
//You may use this code freely
celcius
celsius
centigrade
Code
convert
converting
fahrenheit
java
javascript
temperature
the
to
Read more
ie8.js mini module
July 24, 2008 - 12:24pm — Anonymous
<?php
/**
* Author: Nicolas Borda - http://nic.ipwa.net
* Display help and module information
* This module adds to your site the ie8 JavaScript library from Google Code
*
*/
drupal_add_js
javascript
module
Read more
Fix for Swap out javascript (jQuery) files
July 13, 2008 - 9:37am — Anonymous
We talked a little about the
"best"
way to swap out javascript files and the way we
've been doing it recently for sites that require 1.2 and higher, you can use this method.
javascript
jquery
theming
Read more
Fix for Overriding Drupal.jsUpload.prototype.oncomplete
July 2, 2008 - 1:42am — Anonymous
var
_oncomplete = Drupal.
jsUpload
.
prototype
.
oncomplete
;
Drupal.
jsUpload
.
prototype
.
oncomplete
=
function
(
data
)
{
// Your custom code here
_oncomplete
(
data
)
;
}
javascript
Overriding Drupal.jsUpload.prototype.oncomplete
July 2, 2008 - 1:32am — Anonymous
var
_oncomplete = Drupal.
jsUpload
.
prototype
.
oncomplete
;
Drupal.
jsUpload
.
prototype
.
oncomplete
(
data
)
{
// Your custom code here
_oncomplete
(
data
)
;
}
javascript
JS that makes IE crash…
May 18, 2008 - 6:02pm —
Wim Leers
cfg.
context
=
function
(
configId
)
{
if
(
configId === undefined
)
{
return
$
(
'.hierarchical-select-config-form'
)
;
}
else
{
return
$
(
'#hierarchical-select-config-form-'
+ configId
)
;
javascript
Read more
Fix for Javascript: Select multiple checkbox
March 19, 2008 - 3:26pm — Anonymous
<script type=
"text/javascript"
>
<!--
/* status da seleção dos checkbox do formulário */
var
checked =
false
;
/**
* doCheck
*
javascript
multiple checkbox
Read more
Fix for Form Input Example Plugin
February 27, 2008 - 9:28pm —
Rob Loach
/*
* jQuery Example Plugin 1.2.1
* Populate form inputs with example text that disappears on focus.
*
* e.g.
* $('input#name').example('Bob Smith');
javascript
jquery
Read more
1
2
next ›
last »