This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Native.implement([Element, Window, Document], { | |
cloneEventsDeep: function(from, type){ | |
if (this.getChildren().length > 0) { | |
this.getChildren().each(function(item, index) { | |
item.cloneEventsDeep(from.getChildren()[index], type); | |
}); | |
this.cloneEvents(from, type); | |
} else { | |
this.cloneEvents(from, type); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
String.implement({ | |
isNumeric: function() { | |
var r = true; | |
this.split('').each(function(i) { | |
if ('0123456789.,'.indexOf(i) == -1) { | |
r = false; | |
} | |
}); | |
return r; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Stachl | |
* | |
* LICENSE | |
* | |
* This source file is subject to the CC-GNU GPL license that is bundled | |
* with this package in the file LICENSE.txt. | |
* It is also available through the world-wide-web at this URL: | |
* http://creativecommons.org/licenses/GPL/2.0/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Stachl | |
* | |
* LICENSE | |
* | |
* This source file is subject to the CC-GNU GPL license that is bundled | |
* with this package in the file LICENSE.txt. | |
* It is also available through the world-wide-web at this URL: | |
* http://creativecommons.org/licenses/GPL/2.0/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Stachl | |
* | |
* LICENSE | |
* | |
* This source file is subject to the CC-GNU GPL license that is bundled | |
* with this package in the file LICENSE.txt. | |
* It is also available through the world-wide-web at this URL: | |
* http://creativecommons.org/licenses/GPL/2.0/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Search and replace a string in a file as a python one-liner | |
@author Thomas Stachl | |
@created Mar 12, 2011 | |
@license Attribution 3.0 Unported (CC BY 3.0) | |
This work is licensed under the Creative Commons Attribution 3.0 | |
Unported License. To view a copy of this license, visit | |
http://creativecommons.org/licenses/by/3.0/ or send a letter to |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Stachl | |
LICENSE | |
Permission is hereby granted, free of charge, to any person obtaining a copy | |
of this software and associated documentation files (the "Software"), to deal | |
in the Software without restriction, including without limitation the rights | |
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Copyright (c) 2012, Thomas Stachl <thomas@stachl.me> | |
# | |
# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and | |
# associated documentation files (the "Software"), to deal in the Software without restriction, | |
# including without limitation the rights to use, copy, modify, merge, publish, distribute, | |
# sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is | |
# furnished to do so, subject to the following conditions: | |
# | |
# The above copyright notice and this permission notice shall be included in all copies or | |
# substantial portions of the Software. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// if you want to use it inside a visualforce page create a function around it | |
function showFollowUp() { | |
// if you want to use it in a button make sure you require jQuery | |
// {!REQUIRESCRIPT("https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js")} // UNCOMMENT IF IN A BUTTON | |
// get the dialog with your dialog name | |
var d = sfdcPage.dialogs['MyCoolDialog'], close; | |
if (!d) { | |
// if the dialog doesn't exist create one | |
d = sfdcPage.dialogs['MyCoolDialog'] = new SimpleDialog('MyCoolDialog', false); | |
// set general information on your dialog and finally run the create function |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="agent_customer_gravatar"> | |
<span class="a-user-icon"> | |
{{thumb}} {{social_profile}} | |
</span> | |
</div> | |
<div class="agent_customer_section short" > | |
{{first_name}} | |
</div> |
OlderNewer