tahu
-
28 votes
tahu
commented
·
oh, bookmarklet’as neveikia, bet kodas, veikia (pastinti į javascript console chrome, arba firebug firefox)
tahu
commented
·
Jau aiškiau :) bet vistiek yra būdas! Tiktų ir JavaScriptu tikrint ar shift’as nuspaustas. Jei taip – tai atidaryt kaip preview :)
Čia kodas saitui:
var files, i, preview, attach;
files = $(‘.file-description .title a’);
preview = function(url, inNewWindow) {
var fakeForm;
if(inNewWindow) {
fakeForm = window.document.createElement(‘form’);
fakeForm.action = url;
fakeForm.method = ‘GET’;
fakeForm.target = ‘_blank’;
fakeForm.submit();
} else {
window.location.href = url;
}
};
attach = function(anchor) {
$(anchor).click(function(event) {
if(event.shiftKey) {
preview(anchor.href + ‘/TODO_indicator_to_open_in_preview’, event.ctrlKey);
event.preventDefault();
return false;
}
});
};
for(i = 0; files[i]; i += 1) {
attach(files[i]);
}Čia tas pats, tik bookmarklet’as (copy paste url bar):
javascript:(function(){var files,i,preview,attach;files=$(‘.file-description.title a’);preview=function(url,inNewWindow){var fakeForm;if(inNewWindow){fakeForm=window.document.createElement(‘form’);fakeForm.action=url;fakeForm.method=‘GET’;fakeForm.target=‘_blank’;fakeForm.submit();}else{window.location.href=url;}};attach=function(anchor){$(anchor).click(function(event){if(event.shiftKey){preview(anchor.href+’/TODO_indicator_to_open_in_preview’,event.ctrlKey);event.preventDefault();return false;}});};for(i=0;files[i];i+=1){attach(files[i]);}})()
tahu
commented
·
Please, paveikslėlius ir PDF neverskit downloadint. Daug žmonių naudojasi Google Chrome, kuris turi labai gerą integruotą PDF skaityklę. Taip pat ir kiti browseriai naudoja Adobe Reader pluginą.
Manau, kad tai yra labai svarbu.
tahu
gave this 3 votes
·
-
24 votes
tahu
gave this 1 vote
·
-
3 votes
tahu
commented
·
Čia kodas teksto ištraukimui iš paveikslėlių: http://code.google.com/p/tesseract-ocr/
Čia kodas teksto ištraukimui iš įvairių ofiso failų:
http://aperture.sourceforge.net/
tahu
shared this idea and gave it 3 votes
·
-
9 votes
tahu
shared this idea and gave it 1 vote
·
-
7 votescompleted ·
Adminjaro
(Admin, Ututi)
responded
Jau galima matyti puslapio redagavimo istoriją, o moderatoriai gali atstatyti wiki puslapį iki senos versijos.
tahu
shared this idea and gave it 1 vote
·
-
17 votescompleted ·
Adminjaro
(Admin, Ututi)
responded
Jau turime integraciją su Facebook connect bei su Google OpenID ;)
Viešai šį atnaujinimą parodysim rugpjūtį.
tahu
gave this 1 vote
·
-
5 votescompleted ·
Adminjaro
(Admin, Ututi)
responded
Ačiū Vytautai, tavo kodas jau veikia ir kiti gali juo pasinaudoti :)
Redaguojant Ututi puslapius tereikia LATEX Math komandas įterptį tarp $$ $$ visą kitą darbą atliks Ututi :)
tahu
commented
·
Beje :) dar būtų gerai galimybė reguliuoti paveikslėlių vertical alignment’ą (šiuo metu UTUTI išima vertical-align css nustatymą), žr. http://ututi.lt/subject/KTU/FMF/matematine_analize/page/4430
tahu
commented
·
Taigi, mano “workaround this issue” tipo pasiūlymas įmest tuos du mygtukus į rich text editoriaus (ckeditor ten lyg ir) toolbar’ą.
Beje, jei tas bookmarklet’o kodas čia išsikraipė, tai galite gerai veikiančius rasti mano blog post’e: http://vytautas.jakutis.lt/archives/295
tahu
commented
·
šiuo metu yra vienas būdas, nelabai patogus, bet veikiantis: kadangi yra toks web servisas http://l.wordpress.com/latex.php?latex=x_1&bg=ffffff&fg=000000 tai galima įterpinėt kaip paveikslėlius. kad žymiai patogiau būtų, aš pasidariau tokius du bookmarkletus:
“latex”: javascript:(function(){var r = function(a, b, c) {return a.split(b).join©;};var b = document.getElementsByClassName(“ckeditor”)0;var a = document.getElementsByClassName(“cke_source”)0; var c = (" “(a?a:b).value” “).split(”$$"); var d = c0; for(var i = 1; i < c.length; i+=2) {c[i] = "\\displaystyle " + c[i]; var e = encodeURIComponent(r(r(c[i], “>”, “>”), “<”, “<”));d+="<img alt="\\"\\"" />" + r(r(c[i], ">", ">"), "<", "<") + "" + c[i+1];};if(b) {b.value=d;}if(a){a.value=d;}return;})();ir “unlatex”: javascript:(function(){var s = document.getElementsByClassName(“ckeditor”);s=s0;var r = function(a, b, c) {return a.split(b).join©;};var a = document.getElementsByClassName(“cke_source”)0; var b = a.value.split(""); var c = ""; for(var i = 0; i < b.length – 1; i++){var o = b[i+1].indexOf("\\displaystyle ");var e = b[i + 1].substring(o === -1 ? 0 : "\\displaystyle “.length, b[i + 1].indexOf(”“));b[i+1]=b[i + 1].substr(b[i + 1].indexOf(”“) + 7);c+=b[i].substr(0, b[i].lastIndexOf(”
")) + "$$" + r(r(e, ">", ">"), "<", "<") + "$$";};c+=b[b.length - 1];a.value=c;s.value=c;return;})();Naudojimas: Rašydami puslapį formules apgaubiame $$, pvz.: “Jei $$\lim_{n \to \infty} f(n) = 0$$, tai $$f(n)$$ yra monotoniškai mažėjanti funkcija.”. Tada, prieš išsaugodami, persijungiame į “šaltinis” vaizdą (jei anksčiau to nepadarėme) ir paspaudžiame “latex” bookmarklet’ą, kuris pavers formulę paveikslėlio html kodu. Vėliau, norėdami pataisyti formulę, vėl pereiname į “šaltinis” vaizdą ir paspaudžiame “unlatex” bookmarklet’ą, kuris paverčia latex paveikslėlius į tą pradinį tekstą su $$.
tahu
shared this idea and gave it 1 vote
·
-
1 vote
tahu
shared this idea and gave it 1 vote
·
-
3 votes
tahu
shared this idea and gave it 1 vote
·
-
13 votescompleted ·
Adminjaro
(Admin, Ututi)
responded
Po Kalėdų jau galima bus paremti Ututi!
Šiuo metu šitas funkcionalumas testuojamas.
tahu
gave this 2 votes
·
-
1 votecompleted ·
Adminjaro
(Admin, Ututi)
responded
Tai buvo python kalbos klaida, kuria mes sėkmingai pataisėm :)
tahu
shared this idea and gave it 1 vote
·
-
2 votes
tahu
commented
·
tahu
shared this idea and gave it 1 vote
·
-
40 votescompleted ·
Adminjaro
(Admin, Ututi)
responded
Padarėme pirminę versiją ir laukiame dėstytojų komentarų ir pageidavimų ;)
Štai pirmieji dėstytojai:
– http://ututi.lt/user/485
– http://ututi.lt/user/624Kiti dėstytojai gali registruotis čia: http://ututi.lt/teacher/register
tahu
gave this 1 vote
·
Veikianti, hakeriškesnė geresnė versija:
var files, i, preview, attach;
files = document.querySelectorAll(‘.title a’);
if(files.length === 0) {
files = document.querySelectorAll(‘a.filename’);
}
preview = function(url, inNewWindow) {
var fakeForm;
if(inNewWindow) {
fakeForm = window.document.createElement(‘form’);
fakeForm.action = url;
fakeForm.method = ‘GET’;
fakeForm.target = ‘_blank’;
fakeForm.submit();
} else {
window.location.href = url;
}
};
attach = function(anchor) {
anchor.addEventListener(‘click’, function(event) {
if(event.shiftKey) {
preview(anchor.href + ‘/TODO_indicator_to_open_in_preview’, event.ctrlKey);
event.preventDefault();
return false;
}
}, false);
};
for(i = 0; files[i]; i += 1) {
attach(files[i]);
}
Bookmarkletas:
javascript:(function(){var files,i,preview,attach;files=document.querySelectorAll(‘.title a’);if(files.length===0){files=document.querySelectorAll(‘a.filename’);}preview=function(url,inNewWindow){var fakeForm;if(inNewWindow){fakeForm=window.document.createElement(‘form’);fakeForm.action=url;fakeForm.method=‘GET’;fakeForm.target=‘_blank’;fakeForm.submit();}else{window.location.href=url;}};attach=function(anchor){anchor.addEventListener(‘click’,function(event){if(event.shiftKey){preview(anchor.href+’/TODO_indicator_to_open_in_preview’,event.ctrlKey);event.preventDefault();return false;}},false);};for(i=0;files[i];i+=1){attach(files[i]);}})()