Monday, January 31, 2005

RSL:PD Online

Started working on getting RSL:PD ready for our site. FM doesn't want to spend a lot of time on it, but I'm not sure it'll go that well. The code for the HTML and other documents is in bad shape in some places. Plus this project was created before CSS really took a foothold. I'm going to try to keep my fixes to a minimum, but I'm already looking at a healthy amount of work because FM wants to replace frames throughout the product. At least that'll give me the opportunity to work on all the documents to a certain extent, cleaning up the code to remove the most obvious problems.

I also have to modify the Flash-based tutorial on how to use the product. In the end I've got a lot of work cut out for me, hopefully I can finish it by the end of the week. Considering what lies ahead, though, I suspect I may be working on it for a couple of weeks.

Mass Mailing

Sent out a mail today reminding people of the upcoming workshop early-bird registration deadline. The e-mail went to our Web site update list, which is currently at 2343 users.

One interesting event on this "blast" ... the swt.edu (Texas State University - San Marcos) domain name servers no longer respond with any info for the domain. Somebody's gonna get hell for that one. Initially I was removing the e-mail addresses, but the shear number made me realize this was due to DNS problems and not invalid e-mail addresses.

Also of note, fixed a minor problem with the send scripts I had introduced when performing some other updates. I hadn't tested these updates because they weren't integral to the ASP code but were part of the JavaScript interface code (and were fairly minor to boot). I think I un-did a code fix I had used when initially creating the code. The JavaScript in question creates a standard footer for text-based e-mail. A combination of factors was causing theh ASP interpreter to think it needed to process a portion of the code:
  • The footer indicated the user's e-mail address for reference purposes using the format <user@address.com>.
  • Since this is generated for each address I needed to use a placeholder for the e-mail address. This is currently of the form %MASSMAIL_RECIPIENT%.
  • The combination of the two produces the ASP-like code <%MASSMAIL_RECIPIENT%> which throws and error for a couple of reasons.
So that it would not be processed by the ASP interpreter, I modified the JavaScript code as follows:
"<" + "%MASSMAIL_RECIPIENT%>"

Checking the locks

One item of note (otherwise I wouldn't bother to post on this subject). Somebody attempted to log in to our FTP server using a variety of names. Though it's nothing we haven't seen before we don't see much else as far as attack vectors go these days. I would report it, but it was a user at a large ISP ... not worth it. No doubt an unwitting user with a hacked machine on their network.

Friday, January 28, 2005

HS Bio Textbook Report

I've spent the past few days making some modifications and corrections to the report. I think we're about done, though that always seems to be the case until something else pops up. Most of the modifications were fairly minor ... move something here, edit text there. A few more pop-ups were created. I had thought about an icon to indicate that a window will be a pop-up, but I don't think that's necessary.

I made some modifications to the show/hide script. The "new text" indicator is now an optional item set by a js variable. I could probably make it even more flexible and add back in my "growing" text effect. Perhaps I'll investigate that for a future revision. I also made it so that links to which the show/hide script apply have a modified underline (dashed instead of solid). This could probably be a little more modular as well. Again, something to consider for a future revision.

I still need to do the documentation plus code-commenting for the scripts. I don't plan on doing it today, but I'll probably have it done early next week. There are two scripts that are modular enough for reuse that need to be commented. Plus I'd like to try and do some more general documentation on the templates and coding (to note the coding style, browser support, etc.).

Monday, January 24, 2005

IERI Utility

The detailed report is complete. The script is not the prettiest or most efficient, but it should get the job done. The script makes a number of calls to the database and works extensively with the dataset open. This has the potential of slowing things down, but the fairly linear nature should help somewhat with speed. Plus I don't expect a lot of people to be running reports at once. The portions of the sript dealing with the enacted analysis are particularly poorly written. Part of it is the complexity of the database design, which was necessitated due to the complex relationship between all the data. A lot of data pulled from the db is from other users reports. It's not displayed, but the work-arounds wouldn't be necessary if the SQL statements and scripting were better crafted.

Usability wise, the report is a bit unweildy if you're looking at a couple of activities that each have a number of sightings. A number of interface enhancements could improve things (such as turn-downs, a tabbed structure, and summary/drill-downs). But I think the report is readable regardless of the problems.

Still, this is just a temporary fix until a new version is available. Perpetually on the drawing board, but hopefully I'll get to it sometime this year.

Friday, January 21, 2005

IERI Utility

I've completed the literal portion of the reporting functionality. It looks decent, though usability could be improved somewhat by making the report more modular using a show/hide scenario or something like that. As it is, the document gets pretty large depending on the number of activities chosen from a sequence.

The enacted sequence is taking a bit longer to prepare, but I think it's coming along. I've got the framework down for getting the information. The basic info for an activity is being pulled same as with the literal, but I need to make a few modifications to allow for the sighting details to be pulled.

I'll need to do quite a bit of testing to ensure that the report accurately reflects the data stored in the database. I'm not as concerned about the data itself but of the various posibilities when data is not present (omitted, never entered, etc). Plus I'll need to make a few stylistic decisions on how to represent the various situations. I want to ensure that the representation of these various possibilities is accurate in the report. I should be able to do a comparison between the editing screens and report screens to get a good feel for whether or not the accuracy is there.

Wednesday, January 19, 2005

IERI Utility

I finished the "selection" portion of the summary report script. It's basically a question/answer kind of thing in order to narrow down the activity sequence that the user wants to summarize. Once the sequence has been identified the user is given a list of all the activities in that report. The user checks a box next to each activity and submits the form, which then presents the details of each activity. I guess it's not really a summary report since what's returned is all the information related to the activity it's more of a detail report.

I'm currently working on the actual report page. I haven't gotten very far just yet, but I suspect that I can hammer this out in a day (Friday to be exact). I have sequence info listed and the beginning of the activity info. I should be able to duplicate some of the script relating to the sightings from other portions of the utility. Of course, the trick comes from making the script generic enough to handle both enacted and literal while at the same time providing the information specific to each analysis. Thinking about all the data related to each type of analysis and all the possible stages of analysis can be a bit mind-boggling at times (what needs to be included, what tables need to be linked, how the data is to be represented, what if something has yet to be rated, etc.).

I think it may help to have a summary of the results somewhere on the document. Maybe at the top before the activity details are presented. I'll have to talk to KM about that.

Tuesday, January 18, 2005

IERI Utility

I'm working on a summary generator for the analyses.

So far I've got the pages for selecting the specific analysis to view. For the most part the script to this point has been generic.

I'm currently stuck at the activity listing, however, for enacted analyses. I'm having to include some if/then statements to accommodate some of the differences between the enacted and literal. For some reason all the enacted don't show up. It could be related to some of the problems that were fixed earlier.

I haven't really gotten to the difficult part, the summary page itself. It may not be as difficult as I imagine since I should be able to do a little bit of code recycling. I'm just worried that it could take longer than I have.

I need to have this done tomorrow, so hopefully I'll be able to resolve any problems quickly. But I guess if I have to put it off until Friday KM will be ok with that (she's pretty understanding).

HS Bio Textbook Report

I know I said I was done, but are you ever truly done when your publishing medium is the web? I didn't think so.

Putting the last finishing touches on the javascript for the files. Last week I finished the "creeping" menu (stalker menu ... whatever you want to call it). Today I completed a modification to the show/hide script. Previously it wasn't obvious that something was appearing below the clicked area so we wanted some kind of visual indication.

I came up with a nifty one where the text actually grew out of nothingness. It wasn't a particularly difficult trick since I just modified the font size from .1em to 1em. Though I thought it looked nice it was a little too flashy for everyone else. I'd have to agree, particularly for how often the affect would be used.

The method we ended up choosing is definitely less flashy. FM suggested and we adopted a left-side border that fades in and out. It's not the prettiest method, but I think it works well enough.

I'm sure we'll get a few comments on it. I've already thought of another method if our chosen one is ultimately given the kibosh ... having the text fade in. It would probably also be a bit much, but I think it's a good start as another option. We'll see what happens.

Thursday, January 13, 2005

HS Bio Textbook Report

Saga of the Scrolling Menu

I think I've come up with a pretty good solution to one of the problems I noted with the menu script. I've found a way to avoid overlap of the menu with items above it.

First, inside the HTML I've created a wrapper div around the menu and content (note: I could probably just place the wrapper around the menu itself). The wrapper is relatively positioned at 0/0. Since this item will automatically fall below the header content it provides a "safe" area in which to scroll the menu.

Second, the CSS was adjusted to take into account that an absolutely positioned node is positioned relative to any parent node that is also positioned. Since the top of the wrapper div also indicates the top of the content area I specify an absolute positioning of 10 from the top.

Third, the JS uses a script from QuirksMode to calculate the position of the menu relative to the document rather than the wrapper div. This allows me to specify a fixed position that is below the header with Mozilla, thus avoiding overlap with that browser. With IE I determine the position of the menu relative to the wrapper div (taking into account the starting position of the menu relative to the document). I was going to just use the same procedure for IE and Mozilla in the script, but it turns out Mozilla has buggy support for the onScroll event.

I've ignored two other possibile problems for now: the menu extending beyond the lower bound of the browser window, and the menu overlapping the footer.

It's always the bit player ...

Among some of the other problems I'm experiencing with Safari, I'm having a problem with the menu script. For some reason Safari does not display the scrolling menu correctly after the initialization script is run. A visual inspection of the values at the end of the init script (using an alert statement) gives the expected answer. However, the menu is positioned on some pages as if the new top value has not been set; Safari appears to be using the original value set in the CSS files instead of the javascript-defined value for display. This behavior, unfortunately, is not consistent throughout the site. On top of the inconsistency, Safari only seems to have this problem if the positioning is set to fixed at the same time as the value for the top style is set. Perhaps all those conditions will lead me to a clue regarding the source of the problem. I'll have to investigate further tomorrow.

Update 2005-01-14: I seem to have solved the menu problem in Safari. Unfortunately, it requires a bit of a hack because Safari appears to have bug when using javascript to set the positioning style of an object to fixed while modifying the left/top parameters at the same time. The bug only rears it's head in a very specific circumstance and does not appear to be consistent (but is at the very least highly likely).

The layout: HTML document containing nested divs. The outer div is positioned relatively at 0/0 (allowing the inner div to have an absolutle position that is relative to the outer one). The inner div is positioned absolutely at the desired starting point.

The procedure: The style of the inner div is modified after the page loads to fixed positioning. Since fixed positioning is relative to the viewport (the browser window in this case) the visual position of the div will change. To avoid this we determine the position of the div relative to the document and reset the left/top information (well, just the top in the case of the menu).

The above procedure is used with browsers that are DOM- and CSS2-compliant. No problems are encountered with Mozilla. Safari, however, ignores the adjusted left/top settings if the positioning style is set to fixed at the same time. This can be avoided by setting the positioning style after a delay (using setTimeout).

One more step is required, however. Safari correctly positions the menu, but leaves a ghost of the menu in the previous position. The ghost disappears on scroll and so is some sort of display artifact. To work around this problem the menu display style is set to none prior to adjusting the positioning style. The final step sets the display style to block. Safari appears to have no further problems with the menu.

I'm going to submit a bug report to Apple, and perhaps post this on a newsgroup as well.

Update 2005-01-14: It appears that the bug requires an even larger confluence of events than originally imagined. I had only been adjusting the top value and not the left one as well. This appears to be the true source of the problem. If both left and top values are set then there are no problems with Safari (and thus no work-around needed).

I may still report this to Apple, but it seems less of an issue now than before.

CCMS Web Site

EK created a "survey" for the CCMS doctoral students and postdoctoral fellows. The purpose is to gather information so that a profile can be made about these people. I didn't have much of a hand in the development, even though the principles had originally envisioned something a little more robust.

At any rate, it was posted today (or released ... I dunno). EK took off before any actual use and it turns out some of the scripts had not been updated for their current location. Orignially the scripts were developed in a CCMS sub-directory and still referred specifically to that directory. It probably would have been better to not specify the directory at all since the scripts all reside in the same directory.

At any rate, the students and fellows were asked to fill out the survey. Naturally, 404 errors were encountered as people attempted to register. I was asked to take a look and immediately saw the problem. But another problem kept me from fixing this minor error, EK was the only person who had write permissions on the files in question. I'm not too fond of the Mac's very rudimentary file system security. Sadly, it's just an inheretence from the unix-style core of the system and expect Apple will address the shortcomings in the future. At present, however, Microsoft has far surpassed Apple in this regard.

Of course, Apple's web server is based on Apache and has a number of features microsoft would be wise to invest in. One of those is aliasing and redirecting. Entire URLs can be re-written based on a regular expression match. Apple's interface to the functionality leaves a little to be desired, but I was able to set up an alias that points all referrals to the ccms sub-directory back to the root.

My other option was to create a ccms sub-directory and copy all the files to it. The above solution, however, is a much better option.

Friday, January 07, 2005

HS Bio Textbook Report

A few problems of note with my menu script:
  • It doesn't take into account flowed objects above or below it. If there are header elements that span the width of the page this can cause the menu to overlap these elements if they expand too far below the hard-coded distance of the menu from the top of the page.
  • If the text size is increased by the user too much (using the browser text size controls) the menu itself could run off the bottom of the page.
Naturally there are solutions to these problems, but that will create more complexity within the script than I had originally intended. I wanted to keep it simple, but in order to have a flexible menu that doesn't interfere with the actual content I would need to make it a little more complex. There are just too many possible ways it can affect the display in an undesireable manner.

Some level of coding prowess will always be required to implement something like this if one wants to ensure that no problems will crop up in the process, there are just too many variables that can affect the implementation. So in the end this isn't truly drop-in code (at the very least certain formatting guidelines must be followed). I could probably make some changes to the script that would allow it to be more flexible, but at what cost?

I guess in the end I need to decide how flexible I want this code to be. I could easily fix the code so that it works fine in this project, but would require extra effort if it is implemented in a future project. On the other hand I could try to make the code as general as possible, but that would require a bit of inflexiblity of implementation. I'll need to think about which direction I want to go with this before I put too much more work into it.

HS Bio Textbook Report

The document footer was causing me some grief in Firefox by expanding beyond it's specified 100% width CSS declaration. As suspected, it had to do with the W3C box model and how width is defined. (A box width is applied to the content portion of the box; padding, border, and margin are added on top of that.

Luckily there is a work-around where you can define the box model to apply the width on the border. Firefox currently uses a proprietary CSS property (.moz-box-sizing), but there is one defined in CSS3 (box-sizing). By setting the value to "border-box" the width acts more like I expect it to.

Thanks QuirksMode!

(I guess I should note that margins can still have deliterious effects on the effective width of an element. Something to keep in mind with future development.)

Thursday, January 06, 2005

IERI Utility

Made a minor fix to the enacted activity detail page. It relates to #6 of my previous post. I forgot that similar code (SQL) used to display the list of activities is also used to provide previous/next activity links on the detail page. As a result activities were listed that had not yet been released for analysis. I updated the SQL and all is well.

I'm still not content with the way the work flow is interpreted by the interface in some instances. Hopefully when I start working on earnest on the next revision I'll be able to address some of these quirks.

Monday, January 03, 2005

IERI Utility

Had a meeting with KM about some problems that needed to be addressed with the IERI utility. A quick run-down:

1 - Teacher analysts could previously add new analysts to an enacted activity sequence. This level of capability was something KM did not want these users to have. This was corrected.

2 - Until now, when a user capable of creating/editing enacted activity sequences visited this section of the utility they were presented with the full list of the available sequences. It didn't seem like a desirable (or even usable) feature and I suggested that maybe we only allow them to edit sequences they were assigned to analyze. KM agreed. Teacher analyst now only see enacted activity sequences to which they are assigned when they go to the "Create/Edit enacted analysis" page. This doesn't address the overall usability problem of this page, but it's a start.

3 - Some users had marked as complete their analysis of activities. No reporting or summary feature is currently available within the utility, so it was not possible to review their work. I undid the "mark complete" action on all affected enacted activity sequence analyses. I also temporarily disabled the "mark complete" functionality (though the link is still present). I'm working on setting up summary pages for the literal and enacted analysis. I'll re-enable the "mark complete" functionality once the summary reports are available.

4 - The ability to check/uncheck a movie from the timecoding screen in order to allow/disallow analysis seemed to be broken. Previously this functionality was contingent on users having not started analyzing the activity sequence at all. If any analysis had been done it would not be possible to uncheck a movie, even if the particular movie attempting to be unchecked had not been touched. Now the utility looks to see if users have started working on the specific movie being unchecked to determine if that movie can be unchecked.

5 - There was an error in the code that added a new activity to an enacted activity sequence. While the utility was adding the activity information to the sequence itself, it was not adding the appropriate information to the analyst assignments table if the analyst was assigned to the sequence prior to creation of the new activity. This problem affected any sequence where a new activity was added after analysts had already been assigned. Future activity additions will show up in the list of activities for analysis. (I noticed that the problem also affected duplicated activities, which has been fixed as well.) For any assignments that have already been made I'll have to go and manually add the missing activities.

6 - I found two problems relating to the list of enacted activities available for analysis. One, activities were showing up for analysis even if there was no timecoding done on those activities. Two, activities were showing up if there was a movie assigned to them even if that movie was not yet released. I believe these problems arose because I initially designed the utility such that all movies had to be timecoded and released prior to the enacted activity sequence being analyzed. I modified the code so that activities that are not ready for analysis are no longer presented to the analyst in the list of activities related to a sequence. This may not be the best method of dealing with this issue because the user is given no clue as to how many activities will ultimately need to be analyzed. A better solution would be to list all the activities related to a sequence, but remove the ability to analyze those not yet available.

7 - Edited the text of the "save" buttons for the enacted analysis pages to be consistent. They now all read "Save Analysis Data"

Mass Mailing

Updated the list management scripts (end-user ones) to add the ability to update the e-mail address. First change was to modify the /listpref shortcut so that it points to a management page where the user can choose whether they want to subscribe, unsubscribe, or update. The update page was fairly simple, though it could be improved by using stored procedures on the SQL server. Lots of similar code to accomplish one request. I'm not sure what direction to go with that, however, since FM wants to investigate using more open-source products. EK is heavily into mySQL, but it's not nearly as robust as some other open source databases, such as postgreSQL.

I'll probably just wait. The script will likely have low usage and with the contact management project ramping up it's only a matter of time before the mail scripts are replaced completely.