Jump to content

Wikipedia:Reference desk/Archives/Computing/2013 January 1

From Wikipedia, the free encyclopedia
Computing desk
< December 31 << Dec | January | Feb >> January 2 >
Welcome to the Wikipedia Computing Reference Desk Archives
The page you are currently viewing is an archive page. While you can leave answers for any questions shown below, please ask new questions on one of the current reference desk pages.


January 1

[edit]

Youtube "sort by" for results is gone? (relevance, view count, etc)?

[edit]

When searching for videos, the normal "Sort by... " is not there. There is no way to sort the videos at all, just scroll through hoping to find the right one. Since this is a very frustrating problem, I would have thought more people would have complained about it, so I assumed it was something only I was getting. If anyone knows how to fix this, or if it's possibly a virus or something on my computer, I'd appreciate the help. Seriously, its just so f__kin ridiculous. What logic is there in removing it??? I think its a perfect example of youtube losing touch with its base...that they would remove something as important as "sort by". Venustar84 (talk) 02:14, 1 January 2013 (UTC)[reply]

There is a button "Filters" just below the search field. When you click on it, the "Sort by..." menu item appears, together with other options. --NorwegianBlue talk 14:56, 1 January 2013 (UTC)[reply]
When they first pushed this new design, these sorting options were missing. They only recently re-added them. Perhaps you are somehow viewing an old version? -- 143.85.199.242 (talk) 14:45, 2 January 2013 (UTC)[reply]
It appears to have to do with language settings, see my response to the third post by VenusStar84 on the subject. --NorwegianBlue talk 22:47, 2 January 2013 (UTC)[reply]

About Cookies in IE

[edit]

Does each website have access to my cookies on all websites I have vistited, or only cookies of their own website?--Inspector (talk) 05:03, 1 January 2013 (UTC)[reply]

Only cookies on their web site. (Specifically, their domain.)—Best Dog Ever (talk) 05:33, 1 January 2013 (UTC)[reply]
Well, that's how it's supposed to be, but there's no guarantee that somebody else couldn't access those cookies. Also, if one company merges with another, they presumably gain access to each other's cookies, meaning wider and wider access as companies combine into bigger ones. StuRat (talk) 06:08, 1 January 2013 (UTC)[reply]
Well, how is the cookie accessed?--Inspector (talk) 06:23, 1 January 2013 (UTC)[reply]
Any type of a virus can access anything on your computer. If cookies were sufficiently encoded, those who access them wouldn't know what info they contain, but, since the companies who store the cookies aren't all that concerned about your privacy, don't expect more than a token level of encryption. StuRat (talk) 06:35, 1 January 2013 (UTC)[reply]
Let's just limit to the methods availible to the website. Is it true that some malicious codes on webpage can allow access to other cookies?--Inspector (talk) 09:14, 1 January 2013 (UTC)[reply]
StuRat is describing a special case of privilege escalation. If your system is working correctly, most software should not have the privilege to view your private web-data. However, malware often attempts to exploit user-error, or software bugs, to gain unauthorized privilege. One such example would be to gain read-permissions to cookies from other websites. A correctly-designed web browser does not permit such unauthorized access. Here is an overview of Internet Explorer 9's security features, explaining how privilege is managed and how the security model works for things like cross-domain requests. Nimur (talk) 09:19, 1 January 2013 (UTC)[reply]
Okay. I write cookies all the time for my sites. Yeah. I guess if someone broke into your house and looked on your computer, they could see the cookie, too, but he really just asked if other sites, by default, can read them. And by default, they can't. Here's why:
Inspector: if you visit a site, like google.com, the web page you're on can write a cookie to your browser either using JavaScript or by sending the cookie in the response header to any of the requests you send to the site. If you return to that page sometime in the future, your browser lets the site know it has a cookie from a previous visit. In other words, your own browser notices you're visiting google.com. It notices it has a cookie from google.com from another visit. It then decides, on its own, to tell Google.com that it has a cookie from that site and then tells google.com what the cookie contains.
The cookies on your machine can be viewed easily by you. You said you use IE. So, if you're using Windows Vista or later, by default cookies are stored by IE in C:\users\[your user name]\AppData\Roaming\Microsoft\Windows\Cookies. If you're using Windows XP, they're stored in C:\Documents and Settings\[your user name]\Cookies. Each cookie is stored as a text file by IE. Other browsers offer ways for you to view their cookies easily, as well. So, anyone who has control of your computer can see the cookies. So, yeah, if you had a virus that had control of your computer, then they can see the cookie, too.
In JavaScript, there's an object called document.cookie. So, you can set it. Here's a vast simplification of the code you need to write:
document.cookie = [whatever you decide to type here];
As I said, that's a simplification, because you need to include an expiration date. Here's a more detailed discussion: [1].
Likewise, you can retrieve whatever is in document.cookie. But notice that it's specific to the current document. In other words, there is no such command in JavaScript for retrieving any cookies other than those for the document.
If you want, you can set the cookie by telling the server to send it in the header using a language like PHP: [2]. Here's how that code would actually cause the server to behave: HTTP_cookie#Implementation.
So, in short: No. A web site on it's own cannot view cookies from other domains.Best Dog Ever (talk) 09:44, 1 January 2013 (UTC)[reply]
But this is sensitive to what constitutes a "domain". If the site x.y.z is allowed to set cookies for .y.z but not .z, then any UK business registered under co.uk can set cookies on .co.uk which will be visible to any other UK business site. Firefox had that problem until 2007. IE prevented it by an ad hoc rule, but the rule didn't cover .ltd.uk, for example. Modern browsers rely on hand-maintained lists of effectively top-level domains. -- BenRG (talk) 17:25, 1 January 2013 (UTC)[reply]

How to Count the number of References in TOTAL

[edit]

Hi I belong to the Silent Hill Wikia. I'm looking for a template (or any type of code) that can help with counting the total number of references on the wiki. What I mean by this is the sum of all the references that we have on each article combined into a nice little number that we could possibly display on the front page (or least to keep track of my own articles). I'm sure if there are simple tools to count edit patterns of normal Wikipedia users then I'm sure there must be something on this for articles. So instead of counting article total references individually - which is a major pain - we want to have a good idea of how many references our wikia contains overall. This would be good for quality control. So could anyone please help? 92.22.68.237 (talk) —Preceding undated comment added 23:44, 1 January 2013 (UTC)[reply]