Demo Discussion
Forum Config Examples Contributions Vulnerabilities
  Discussion forum about ELOG, Page 247 of 807  Not logged in ELOG logo
ID Date Icon Author Author Email Category OS ELOG Versiondown Subject
  68499   Mon Dec 12 14:04:32 2016 Reply Aaron James Longal876@york.ac.ukQuestionWindows3.1.1-3f311c5Re: Highlight code?

Thanks for the quicky reply Stefan. Yes, I had inut the same string! My error was not restarting the server; I've done this and code highlighting works fine.

Stefan Ritt wrote:

All I did was this:

Bottom Text = <link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/highlight.js/9.6.0/styles/default.min.css"><script src="//cdnjs.cloudflare.com/ajax/libs/highlight.js/9.6.0/highlight.min.js"></script><script>hljs.initHighlightingOnLoad();</script>

 

 

Aaron James Long wrote:

Can I ask for some clarification; I would like to include code highlighting for some computational students who will be making use of ELOG. 

In the example you showed, my understanding is that you included a "Bottom text =... " entry in the forums elog config. This included the bare minimum remote call outlined by the highlightjs site. Can you clarify (as I'm having issues setting it up) should the "Bottom text=..." entry take this as a string, or should it be contained in a seperate html file in the same local directory as the cfg?

 

Daniel Sajdyk wrote:

Ok. Thanks a lot :)

Stefan Ritt wrote:

In the HTML editor, you can select the code text, then select from the "Styles" drop-down the style "Computer Code", and on the "Normal" drop-down the formatting "Formatted". This puts the code in <pre>  and <code> tags, so you don't have to manipulate HTML directly.

Daniel Sajdyk wrote:

Looks like it works :)

Code need to be put in tags:

<pre><code class="sql">...</code></pre>

but it works.

Thank you :D

 

Best Regards

Daniel Sajdyk

Stefan Ritt wrote:

I did not know about highlight.js . You can put it into any elog page with "Bottom text = ...". I tried it for this forum and put in some C code:

#include <stdio.h>
int main()
{
   // printf() displays the string inside quotation
   printf("C Programming");
   return 0;
}

Seems like this works nicely. Thanks for that hint.

 

Daniel Sajdyk wrote:

I thought so.

One  more question :) I want manually add that parser (https://highlightjs.org), but I'm newby in that and don't know where ....

I know that downloaded hightlight pack I must put into folder scripts, but where to add this line:

<script>hljs.initHighlightingOnLoad();</script>

 

Stefan Ritt wrote:

You can manually highlight code, but there is no automatic language parser.

Daniel Sajdyk wrote:

Hello :)

Is there any way to highlight code (for example php, SQL) in elogs entries?

Best Regards

Daniel Sajdyk

 

 

 

 

 

 

 

 

 

  68698   Mon Nov 13 12:58:41 2017 Question Sara Vaninivanini.sara@gmail.comBug reportLinux3.1.1-1-1drop-down list not working

Hi,

after ubuntu 16 system upgrade, elog version (3.1.1-1-1) on firefox version 56.0+build6-0ubuntu0.16.04.2 , the drop-down menus (Styles, Font, Size, etc) don't work anymore.

How can I fix it?

Many thanks!

Sara

  68267   Fri Feb 26 08:47:22 2016 Warning Nigel Warrwarr@ikp.uni-koeln.deBug reportLinux3.1.1-1Possible bug in elogd execute_shell

I was just playing around with gcc6's new feature for warning about misleading indentation (which can often hide real bugs) and I think it found one in elog-3.1.1-1 at src/elogd.c:22538. Here there is an if statement, which looks as though it should be inside a loop, but it isn't. The code is:

      for (i = 0; i < MAX_ATTACHMENTS; i++)
         generate_subdir_name(att_file[i], subdir, sizeof(subdir));
         if (att_file[i][0] && strlen(shell_cmd) + strlen(lbs->data_dir) + strl$
             < sizeof(shell_cmd) + 1)
{
            strcpy(p, "\"");
            strcat(p, lbs->data_dir);
            strlcat(str, subdir, sizeof(str));
            strlcpy(str, att_file[i], sizeof(str));
            str_escape(str, sizeof(str));
            strcat(p, str);
            strcat(p, "\" ");
            p += strlen(p);
         }

and the if statment is accessing the loop variable i but it is actually outside the loop. Presumably, there should be some more curly brackets here. gcc6 gave the warning:

src/elogd.c: In function ‘execute_shell’:
src/elogd.c:22538:10: warning: statement is indented as if it were guarded by... [-Wmisleading-indentation]
          if (att_file[i][0] && strlen(shell_cmd) + strlen(lbs->data_dir) + strlen(subdir) + strlen(att_file[i])
          ^~
src/elogd.c:22536:7: note: ...this ‘for’ clause, but it is not
       for (i = 0; i < MAX_ATTACHMENTS; i++)
       ^~~

  68268   Fri Feb 26 09:09:03 2016 Reply Stefan Rittstefan.ritt@psi.chBug reportLinux3.1.1-1Re: Possible bug in elogd execute_shell

Absolutely correct! Nice to see compilers getting better and better. I changed the code and committed it.

Nigel Warr wrote:

I was just playing around with gcc6's new feature for warning about misleading indentation (which can often hide real bugs) and I think it found one in elog-3.1.1-1 at src/elogd.c:22538. Here there is an if statement, which looks as though it should be inside a loop, but it isn't. The code is:

      for (i = 0; i < MAX_ATTACHMENTS; i++)
         generate_subdir_name(att_file[i], subdir, sizeof(subdir));
         if (att_file[i][0] && strlen(shell_cmd) + strlen(lbs->data_dir) + strl$
             < sizeof(shell_cmd) + 1)
{
            strcpy(p, "\"");
            strcat(p, lbs->data_dir);
            strlcat(str, subdir, sizeof(str));
            strlcpy(str, att_file[i], sizeof(str));
            str_escape(str, sizeof(str));
            strcat(p, str);
            strcat(p, "\" ");
            p += strlen(p);
         }

and the if statment is accessing the loop variable i but it is actually outside the loop. Presumably, there should be some more curly brackets here. gcc6 gave the warning:

src/elogd.c: In function ‘execute_shell’:
src/elogd.c:22538:10: warning: statement is indented as if it were guarded by... [-Wmisleading-indentation]
          if (att_file[i][0] && strlen(shell_cmd) + strlen(lbs->data_dir) + strlen(subdir) + strlen(att_file[i])
          ^~
src/elogd.c:22536:7: note: ...this ‘for’ clause, but it is not
       for (i = 0; i < MAX_ATTACHMENTS; i++)
       ^~~

 

  68358   Tue Jul 12 21:23:13 2016 Entry Austin Reidarreid3@ncsu.eduBug reportOther3.1.1-Email report has incorrect pictures
My group uses the precompiled Debian binary, and I use ELCode to format my log reports. (I've found it to be the easiest way to generate inline images)

Yesterday, I submitted an entry that renders correctly on the elog itself, but the email report that was sent to my collaborators was quite confusing, because every picture in it was the same. Interestingly, all the images used inline in the report were attached to the original, but they were stripped of their context.

I've attached screen shots of both reports.
Attachment 1: emailedversion.jpg
emailedversion.jpg
Attachment 2: okversion.jpg
okversion.jpg
  68919   Mon Mar 25 12:31:34 2019 Question gibelin juliengibelin@unicaen.frQuestionLinux3.1.1 revision elog client through proxy

Dear users,

we started an elog serveur (using ssl) and open to the world which is working fine.

However I am trying to access it via the command line client, from a computer that uses a proxy to connect to internet.

The environnment variable are set :

declare -x ftp_proxy="ftp://myproxy:3128/"
declare -x http_proxy="http://myproxy:3128/"
declare -x https_proxy="https://myproxy:3128/"
declare -x socks_proxy="socks://myproxy:3128/"

 

but when I try to connect

elog  -h myelog -p 443 -l lognote -s 1 -u username passwd  -w last

I have the following message :

Cannot connect to host myelog, port 44

How should I proceed ?

Best regards

JG

:

 

  68923   Thu Apr 4 11:57:46 2019 Reply Stefan Rittstefan.ritt@psi.chQuestionLinux3.1.1 revision Re: elog client through proxy

The "elog" client does unfortunately not support proxies. You could however achieve the same with the "curl" tool. Have a look at elog:68597

Stefan

gibelin julien wrote:

Dear users,

we started an elog serveur (using ssl) and open to the world which is working fine.

However I am trying to access it via the command line client, from a computer that uses a proxy to connect to internet.

The environnment variable are set :

declare -x ftp_proxy="ftp://myproxy:3128/"
declare -x http_proxy="http://myproxy:3128/"
declare -x https_proxy="https://myproxy:3128/"
declare -x socks_proxy="socks://myproxy:3128/"

 

but when I try to connect

elog  -h myelog -p 443 -l lognote -s 1 -u username passwd  -w last

I have the following message :

Cannot connect to host myelog, port 44

How should I proceed ?

Best regards

JG

:

 

 

  68070   Tue Aug 4 15:35:39 2015 Entry Stefan Rittstefan.ritt@psi.chInfoAll3.1.1Version 3.1.1 of elog has been released

Version 3.1.1, released August 4th, 2015

  • Updated CKEditor to version 4.5.1

  • Implemented "Date/Time format <attribute> = ..."

  • Implemented "Use Email Subject Edit = ..."

  • Replaced "Back" by "Delete" button

  • Fixed many issues with Draft Messages

  • CSS file is now in *addition* to the default file elog.css

  • Added LDAP documentation

  • Added "Logout to URL = ..." option

  • Added description of Apacher server authentication

ELOG V3.1.5-3fb85fa6