Solved

C o o k i e s  A n d  M i l k?

Posted on 1998-11-17
15
276 Views
Last Modified: 2013-12-25
B i g   Q u e s t i o n s - L a r g e r  T h a n  A v e r a g e  R e w a r d

Many questions to follow:  

I have constructed and will be maintaining www.petroleum.org.  The site will be a "Start" page for the petroleum industry.  I have the site devided into 2 sides.  One side being standard html and the other being shockwave.  You will notice that I started with a splash page to introduce the site.  Would/do I need to divide the site into IE4 capable, NS4 capable install a sniffer and then branch to the shockwave?

1.  I would like to give the user the opportunity to select his desired means of browsing, html or shockwave.  I have done this by already but would like to improve on what I already have.

2.  I would like to set a cookie so that when the user comes "home" he will be directed to the area he choose to "subscribe to".  The user will also need to be able to reset their cookie, so that they can make a change to the way they view the site.  I have in no way the comprehension on how to write the cookie, where to place it on my server, download it to their machine, ect.  What I will need is VERY specific instructions on how to do this to include a working example of the code and where to place it within my splash page html.

3.  Under IE4 the splash page buttons are the same size.  In NS4 the stanard html button/link is larger.  I can't figure out why.  Please help.

4.  Would it be better to sniff the browser and reload the window to send the browser to the proper "side" of the site?
If so, please include the html/script that will sniff the browser, java settings, resolution and colors if all that is possible.  I have used another popup window on another site I manage that sniffs the browser.  Will this be effiecent enough (www.odp-inc.com)

5.  I need a better way to manage the menu so that it doesn't reload the menu each time a user selects an item in the menu.  I think an include tag or something like this will work.  I would like the site menu to actually be like MSNBC's site menu (www.msnbc.com) where a click expands and passes the menu to the right of the upper level menu.  Please include the html/script to accomplish this.

6.  You will notice the stock ticker at www.petroleum.org is pretty generic.  The reason it is this way is because you don't have the cookie I received from the server that sets it for me.  I would like to take my cookie (on my local pc) which configures the ticker for the petroleum industry portfolio and set it in the visitors browser so they see the ticker that I want them to see.  Is it safe to upload my cookie to my webserver call it and have it set the cookie on your machine?  Can this be done and how?

8. I also need a one time constructive critic of the TOTAL SITE, its design, colors, flaws, merits, etc.  I do not want to hear it looks bad... it looks good... it sucks.... When anwsering please include your browser type and resolution/colors(hence the large reward of 500 pts, to the individual who awnsers my question completely)

Thank you much in advance.

Kevin
0
Comment
Question by:kpaulk
  • 8
  • 4
  • 2
  • +1
15 Comments
 

Author Comment

by:kpaulk
Comment Utility
Edited text of question
0
 

Author Comment

by:kpaulk
Comment Utility
Edited text of question
0
 

Author Comment

by:kpaulk
Comment Utility
Edited text of question
0
 
LVL 4

Expert Comment

by:pluim
Comment Utility
Kevin,

A word of advice - the points for this questions are most generous, but it's unlikely you're ever going to get any answers.
Think about it, do you really think mad cookie experts are good
at judging the usability of a site, or talented artists know all the technical differences between NS and IE? Splitting this question into 5 pieces would make a lot more sense. Also, the number of answers/comments for this question will quickly become unmanageable.

Concerning the cookies - I suggest you do a quick search on the net and read some of the excellent documentation that's available. Do you really want to deploy technology on a site you're responsible for without understanding it? Also, there are usually 20 different ways of solving a problem. Without all the background, it's quite possible you'll choose a solution that will be incompatible with long term goals.

More generic advice - do you really want to maintain every page in 185 versions (IE3,4, NS3,4, ShockWave/HTML, plus a slew of
the less popular browsers)? That is an incredible amount of work.
Using the lower (not lowest) common denominator (i.e. versions 3+ or versions 4+) is probably a much better option. Keep in
mind that both technology and content rapidly change.

More to the point - saving the HTML/ShockWave preference in a cookie is not a bad plan. Replace your homepage with a CGI program that reads the cookie and redirects the browser to the correct homepage for HTML or ShockWave.

Concerning point 4 - do you really want to take the users screen resolution into account? If your site has more than half a dozen pages, you've either got too much time or a very large budget. The standard these days is 800x600 with 256 colours.
Besides, not everyone likes having their browser maximized.

I'm quite sure the experts here will be happy to help with all the issues you listed, but in the current form it's rather overwhelming. Don't get me wrong, I'm not trying to be negative.
I took a quick peek at the site and graphically it looks great.


pluim.


0
 
LVL 10

Expert Comment

by:MasseyM
Comment Utility
Just a comment:

Visited your site.  and WOW!  The graphics look wonderful.  I am using IE 4.x w/ 1024x768 screen @ 16bit color.  A suggestion though may be to remove the top graphic.  I think that the large "PETROLEUM.ORG©: Indstry Headquarters" with the cicle behind is enough at first.  It seems a little crowded there at the top.  Also would recommend removing the "Experience PETROLEUM.ORG" at the top.

The bottom "bar" is a very good idea. I would however, remove the "version 2.2" from it because it gives the people a "computer" like interface.  You want to get your visitors to "get into" the site and people, even the ones surfing the net, seem to shy away from computer stuff.  

Ticker is good.  May be able to configure the colors?  Not sure if you can.

Also, a not about the graphic right above the ticker.  It doesn't fade very well with the background on the left.  It is too light over there.  

Also, the link in the bottom left of the bar, when clicked, pops up a new window.  ou need to cnahge content1 to main in your frame definition page.  

Personally would not use the "mouseover" buttons on such a professional site.  To me, they look a little tacky.

Visited the site.... The menu, like you said, doesn't need to reload.  This about frames?  Maybe something like @ microsoft's site.

On the shockwave version... VERY Good animation... I like that a lot.  Maybe have the menu automatically opened.  kind of hard to find if you do not know what you are looking for.  Also, help at bottom right is a little hard to find.  I just accidently ran my mouse over it.


Hope this helped a little.

- Matt


0
 

Author Comment

by:kpaulk
Comment Utility
Thank you for your comments.  Taking everything into consideration that everyone so far has mentioned.  I did make some changes, but my questions still really haven't been awnsered.  I suppose the most important questions that I have concern the cookie and the different size of the two round buttons on the splash page.

Thank you again
0
 
LVL 10

Expert Comment

by:MasseyM
Comment Utility
What type of server is this running on?
0
Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

 

Author Comment

by:kpaulk
Comment Utility
Compaq Alpha running Digital Unix 4.0; Apache Ver. 1.2.6 Frontpage Extensions up to date. The site is hosted via Mindspring.  I have about 99.9% access to all areas of the hosted site.  I do have access to run perl, cgi, and other scripts and programs.  =)  I think..

Kevin

0
 
LVL 10

Expert Comment

by:MasseyM
Comment Utility
Hmm I was going to say that if you had ASP, I could help with the cookies, but I am not well versed in other internet languages.
0
 

Author Comment

by:kpaulk
Comment Utility
Nope, I don't have ASP capabilities as of yet.  I have been begging Mindspring to install ASP functionallity.  
0
 

Author Comment

by:kpaulk
Comment Utility
Is anyone going to try and awnser this question?  If not is it possible to get the points back?
0
 
LVL 10

Expert Comment

by:MasseyM
Comment Utility
Yes, you can get the points back by
1) waiting till it falls off (after ~ month)
2) send a message to linda in the experts exchange forum and tell her to remove question Q.10099425


0
 
LVL 3

Accepted Solution

by:
NullTerminator earned 500 total points
Comment Utility
Following is some javascript you can use to manipulate cookies on the client side. Connect to the onclick event of your interface elments that control the user choices.  the cookie lives on the client.  It gets sent to the server.  You can see it in Request.Cookies("PRESENTATIONMODE")

<script language="JavaScript">
// Use this function to retrieve a cookie.
function getCookie(name){
var cname = name + "=";              
var dc = document.cookie;            
    if (dc.length > 0) {              
    begin = dc.indexOf(cname);      
        if (begin != -1) {          
        begin += cname.length;      
        end = dc.indexOf(";", begin);
            if (end == -1) end = dc.length;
            return unescape(dc.substring(begin, end));
        }
    }
return null;
}

// Use this function to save a cookie.
function setCookie(name, value, expires) {
document.cookie = name + "=" + escape(value) + "; path=/" +
((expires == null) ? "" : "; expires=" + expires.toGMTString());
}

// Use this function to delete a cookie.
function delCookie(name) {
document.cookie = name + "=; expires=Thu, 01-Jan-70 00:00:01 GMT" +  "; path=/";
}

function removePlusSigns(name){
var strTemp = "";
var i = 0;            

    for (i = 0; i < (name.length); i++)      
      {                        
            if (name.substring(i, i+1) == "+")
            //if (name.substr(i, 1) == "+")
            {      // A '+' was encountered, substitute a space.
                  strTemp+= " ";
            }
            else
            {
                  //strTemp+= name.substr(i, 1);            
                  strTemp+= name.substring(i, i+1);
            }      // end else            
      }            
return strTemp;
}      // end removePlusSigns

// end of  Cookie functions -->

// use this var for expires if you want a 30 day timeout set.
var exp = new Date();                                  
exp.setTime(exp.getTime() + (1000 * 60 * 60 * 24 * 31));

function setPresentation(argPresentation) {
    if ( argPresentation == "HTML") {
        setCookie("PRESENTATIONMODE", "HTML");
        }
    else {
        setCookie("PRESENTATIONMODE", "SHOCKWAVE");
        }
}     // END FUNCTION
</script>

<!-- put this where the users can select their options -->
<form name="something" action="canbeAdummyNameIfThereIsNoSubmitButton">
<input type="button" name="whatKindOfPage"
value="Click Me For ShOCkwave Pages"  onclick="setPresentation('Shockwave')">
<br>
<input type="button" name="whatKindOfPage"
value="Click Me For HTML Pages"  onclick="setPresentation('HTML')">
</form


The first page you send them could then be the HTML version
<html><head><title>Home page</title</head>
<body>
<!--- inline script gets executed immediately --->
<script language="javascript">
if (getCookie("PRESENTATIONMODE")=="SHOCKWAVE") {
    document.location.href = "http://server.com/theshockwavepage"
    }
</script>
<!--- other normal body content --->

</body></html>

0
 
LVL 3

Expert Comment

by:NullTerminator
Comment Utility
PS.  I forgot in the setPresentation function,  include the 3rd argument to setCookie to make it live for 30 days.

setCookie("PRESENTATIONMODE", "SHOCKWAVE", exp);

Note the var exp has been iniitalised to now + 30 days for you.

'\0'
0
 

Author Comment

by:kpaulk
Comment Utility
I'll try it out eventually...sorry took me so long to get back to you.  Thanks for the help.  
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Password hashing is better than message digests or encryption, and you should be using it instead of message digests or encryption.  Find out why and how in this article, which supplements the original article on PHP Client Registration, Login, Logo…
Although it can be difficult to imagine, someday your child will have a career of his or her own. He or she will likely start a family, buy a home and start having their own children. So, while being a kid is still extremely important, it’s also …
Viewers will get an overview of the benefits and risks of using Bitcoin to accept payments. What Bitcoin is: Legality: Risks: Benefits: Which businesses are best suited?: Other things you should know: How to get started:
This tutorial walks through the best practices in adding a local business to Google Maps including how to properly search for duplicates, marker placement, and inputing business details. Login to your Google Account, then search for "Google Mapmaker…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

6 Experts available now in Live!

Get 1:1 Help Now