Demo Discussion
Forum Config Examples Contributions Vulnerabilities
  Discussion forum about ELOG, Page 233 of 796  Not logged in ELOG logo
IDup Date Icon Author Author Email Category OS ELOG Version Subject
  1910   Thu Aug 24 11:12:18 2006 Smile Ben Shepherdbjs54@dl.ac.ukRequestLinux | Windows2.6.2-1714Turn off smileys?
Can we please have an option to turn off the thing that changes smileys automatically into pictures?

cheers

ben
  1911   Thu Aug 24 15:52:54 2006 Entry Alan Stonealstone@fnal.govQuestionLinux2.6.2-1714Auto-refresh ELog display
We have multiple LCDs at a console, and usually one is dedicated to displaying a browser
with the local ELog. Meanwhile, others are making entries from another machine. If
no one clicks on refresh, the ELog display becomes stale. Is there a method to have
the ELog reload every X minutes?

Thanks, Alan
  1912   Thu Aug 24 19:02:47 2006 Reply Steve Jonessteve.jones@freescale.comQuestionLinux2.6.2-1714Re: Auto-refresh ELog display
Couldn't a small bit of javascript be added that would accomplish this? Me saying this and I have no idea what I am talking about!!


Alan Stone wrote:
We have multiple LCDs at a console, and usually one is dedicated to displaying a browser
with the local ELog. Meanwhile, others are making entries from another machine. If
no one clicks on refresh, the ELog display becomes stale. Is there a method to have
the ELog reload every X minutes?

Thanks, Alan
  1913   Thu Aug 24 19:28:35 2006 Reply Steve Jonessteve.jones@freescale.comQuestionLinux2.6.2-1714Re: Auto-refresh ELog display

<html>

<head>
<title>Refresh JavaScript Example</title>
<noscript>
<!--
We have the "refresh" meta-tag in case the user's browser does
not correctly support JavaScript or has JavaScript disabled.

Notice that this is nested within a "noscript" block.
-->
<meta http-equiv="refresh" content="2">

</noscript>

<script language="JavaScript">
<!--

var sURL = unescape(window.location.pathname);

function doLoad()
{
// the timeout value should be the same as in the "refresh" meta-tag
setTimeout( "refresh()", 2*1000 );
}

function refresh()
{
// This version of the refresh function will cause a new
// entry in the visitor's history. It is provided for
// those browsers that only support JavaScript 1.0.
//
window.location.href = sURL;
}
//-->
</script>

<script language="JavaScript1.1">
<!--
function refresh()
{
// This version does NOT cause an entry in the browser's
// page view history. Most browsers will always retrieve
// the document from the web-server whether it is already
// in the browsers page-cache or not.
//
window.location.replace( sURL );
}
//-->
</script>

<script language="JavaScript1.2">
<!--
function refresh()
{
// This version of the refresh function will be invoked
// for browsers that support JavaScript version 1.2
//

// The argument to the location.reload function determines
// if the browser should retrieve the document from the
// web-server. In our example all we need to do is cause
// the JavaScript block in the document body to be
// re-evaluated. If we needed to pull the document from
// the web-server again (such as where the document contents
// change dynamically) we would pass the argument as 'true'.
//
window.location.reload( false );
}
//-->
</script>
</head>

<!--
Use the "onload" event to start the refresh process.
-->
<body onload="doLoad()">

<script language="JavaScript">
<!--
// we put this here so we can see something change
document.write('<b>' + (new Date).toLocaleString() + '</b>');
//-->
</script>


</body>

</html>


Steve Jones wrote:
Couldn't a small bit of javascript be added that would accomplish this? Me saying this and I have no idea what I am talking about!!


Alan Stone wrote:
We have multiple LCDs at a console, and usually one is dedicated to displaying a browser
with the local ELog. Meanwhile, others are making entries from another machine. If
no one clicks on refresh, the ELog display becomes stale. Is there a method to have
the ELog reload every X minutes?

Thanks, Alan
  1914   Thu Aug 24 20:16:23 2006 Reply Alan Stonealstone@fnal.govQuestionLinux2.6.2-1714Re: Auto-refresh ELog display
I appreciate your posting of the JavaScript. However, I have no idea what
to do with it. The page appears to be generated by some elog daemon. I do
not know how to hook into that.
Alan


Steve Jones wrote:
Couldn't a small bit of javascript be added that would accomplish this? Me saying this and I have no idea what I am talking about!!


Alan Stone wrote:
We have multiple LCDs at a console, and usually one is dedicated to displaying a browser
with the local ELog. Meanwhile, others are making entries from another machine. If
no one clicks on refresh, the ELog display becomes stale. Is there a method to have
the ELog reload every X minutes?

Thanks, Alan
  1915   Fri Aug 25 05:27:13 2006 Reply Steve Jonessteve.jones@freescale.comQuestionLinux2.6.2-1714Re: Auto-refresh ELog display
eLog allows one to add custom headers or footers as well as include Cascading Style Sheets. I believe there is a post somewhere in here from Stefan indicating that javascript can be added through one of these methods . . . hold on, a simple search, yes Stefan mentions it at http://midas.psi.ch/elogs/Forum/1837


Alan Stone wrote:
I appreciate your posting of the JavaScript. However, I have no idea what
to do with it. The page appears to be generated by some elog daemon. I do
not know how to hook into that.
Alan


Steve Jones wrote:
Couldn't a small bit of javascript be added that would accomplish this? Me saying this and I have no idea what I am talking about!!


Alan Stone wrote:
We have multiple LCDs at a console, and usually one is dedicated to displaying a browser
with the local ELog. Meanwhile, others are making entries from another machine. If
no one clicks on refresh, the ELog display becomes stale. Is there a method to have
the ELog reload every X minutes?

Thanks, Alan
  1916   Mon Aug 28 15:44:38 2006 Question kcminkcmin@mchsi.comQuestionWindows2.6.2Entry Submission Help
I actually have two questions.

1. When an entry is submitted is it possible to have it return to the submit page instead of a summary of the entry. In the ELog.cfg syntax on the site it mentions something about this. However It says something about a file being present in the resource directory. I am not sure what to do here.

2. When you submit an entry is it possible for the fields to stay set to the value that was selected on submission of the last entry. You would need to still be able to change them though.
  1917   Tue Aug 29 15:16:31 2006 Reply Giorgio Croci Candianig.crocic@libero.itBug reportLinux | Windows2.6.1Re: Access to global configuration in v2.6.1
Hi,
after a long time, I thought I could try to investigate the code some further,
and maybe I found some hint.
The page where I expected the options to show was (probably) the one generated by this function:

void show_admin_page(LOGBOOK * lbs, char *top_group)

Inside, it, the buttons are generated by following code snippets:

(elogd.c:10443)
if (is_admin_user_global(getparam("unm"))) {
   sprintf(str, loc("Change %s"), "[global]");
   rsprintf("<input type=submit name=cmd value=\"%s\">\n", str);
}
(elogd.c:10461)
  if (is_admin_user("global", getparam("unm"))) {
     rsprintf("<input type=submit name=cmd value=\"%s\">\n", loc("Delete this logbook"));
     rsprintf("<input type=submit name=cmd value=\"%s\">\n", loc("Rename this logbook"));
     rsprintf("<input type=submit name=cmd value=\"%s\">\n", loc("Create new logbook"));
}

The functions called to validate the user are following:

(elogd.c:21298)
BOOL is_admin_user(char *logbook, char *user):
//...
   if (user == NULL)
      return FALSE;

(elogd.c:21324)

BOOL is_admin_user_global(char *user)
{
//...
   if (user == NULL)
      return FALSE;

Since I assume that I'm probably in the "userless" case (no users are defined in the configuration,
and no usernames are set when launching elog either), I would understand that this causes the options for
global config editing etc etc not to be shown on the admin page.

In my opinion (and given that my interpretation of the code flow isn't wrong), the "null"
user should be indeed considered admin, at least as long as no user management is defined whatsoever.
(If I got it right, if user==NULL, but a password file exists, user management is applied,
thus we're in the case of anonymous user which is correctly not admin).

Again, I might be wrong, but I would be curious to hear an opinion from you about this issue.
Thanks again for your attention.
GiorgioCC
ELOG V3.1.5-2eba886