mirror of
https://github.com/friendica/friendica
synced 2025-04-19 11:10:10 +00:00
Admin users page. some fix to template processor.
This commit is contained in:
parent
c94b809634
commit
ede011cc32
5 changed files with 211 additions and 87 deletions
|
@ -307,3 +307,15 @@
|
|||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* sprintf in javascript
|
||||
* "{0} and {1}".format('zero','uno');
|
||||
**/
|
||||
String.prototype.format = function() {
|
||||
var formatted = this;
|
||||
for (var i = 0; i < arguments.length; i++) {
|
||||
var regexp = new RegExp('\\{'+i+'\\}', 'gi');
|
||||
formatted = formatted.replace(regexp, arguments[i]);
|
||||
}
|
||||
return formatted;
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue