Bookmarklets update

Aside

Last June I explored “bookmarklets,” which I’ve found to be an engaging way to explore JavaScript, primarily by leveraging the power of pet peeves—enticing novice learners to change something they don’t like about a web page to be more the way they’d like it to be. As an example I offered a simple script that toggles the visibility of the ads on a Facebook home page.

javascript:(function()
{
  var 
  rCol=document.getElementById('rightCol'),
  isHidden=rCol.style.visibility==='hidden'?true:false;
if(isHidden)
  {
    rCol.style.visibility='visible'
  }
else
  {
    rCol.style.visibility='hidden'
  }
})();
To actually use this as a bookmarklet, first remove all the line breaks and optimize spaces.

Such a snippet can lead to a discussion of the differences between CSS display and visibility or more advanced ideas like native functions and how and when to import external libraries. My bookmarklet soon evolved into the next snippet, which uses an updated id and display:none;

javascript:(function(){var%20adsDiv=document.getElementById('pagelet_side_ads'),isHidden=adsDiv.style.display==='none';if(isHidden){adsDiv.style.display='inline-block';}else{adsDiv.style.display='none';}})();

This worked fine on the Home page, but not elsewhere. Looking into it with Firebug you quickly see the id is different—on a Messages page, for example, it’s pagelet_ego_pane. You might try simply adding a conditional, if it’s not 'pagelet_side_ads' try ‘pagelet_ego_pane’. But this will fail in JavaScript when the document.getElementById method can’t find the id it’s looking for. While there are elegant advanced ways to do this, and we don’t know how many different ids there might be, I followed the learner’s first suggestion and let it turn into an introduction of try/catch blocks and error handling. These work as follows:

try
  { /*something. If it fails...*/ }
catch(errorObjectName)
  {/*report the error and/or try something else*/}

The errorObjectName is usually error and you can retrieve error.message from it, amongst other things.

If at first you don’t succeed, try/catch again

Here’s the expanded code that tries to find an element with id="pagelet_side_ads" and if that returns and error, it catches that and “tries” again with id="pagelet_ego_pane". If that fails it attempts to log that information to the console. Notice I didn’t say “tries” as there’s no additional try/catch block and I want to avoid using the same word with two meanings. What do you think would happen if the browser has no console object containing a log() method? Below the expanded version is a single line version of the same code (except generic console.log() has been refined to console.error() see this link) to use, as expanded code doesn’t work in this context.

javascript:
(function() 
{
  try
    {
      var adsDiv=document.getElementById('pagelet_side_ads'),
          isHidden=adsDiv.style.display==='none';
      if (isHidden) 
      {
        adsDiv.style.display='inline-block';
      }
      else
      {
        adsDiv.style.display='none';
      }
     }
  catch(e) 
  {
    try 
    {
      var adsDiv=document.getElementById('pagelet_ego_pane'),
          isHidden=adsDiv.style.display==='none';
      if (isHidden) 
      {
        adsDiv.style.display='inline-block';
      }
      else 
      {
        adsDiv.style.display='none';
      }
    }
    catch(e)
    {
      console.log('Failed. Message: ',e.message)
    }
   }
})();

Single line version for general use:

javascript:(function(){try{var adsDiv=document.getElementById('pagelet_side_ads'),isHidden=adsDiv.style.display==='none';if(isHidden){adsDiv.style.display='inline-block';}else{adsDiv.style.display='none';}}catch(e){ try{var adsDiv=document.getElementById('pagelet_ego_pane'),isHidden=adsDiv.style.display==='none';if(isHidden){adsDiv.style.display='inline-block';}else{adsDiv.style.display='none';}}catch(e){console.warn('toggleFBAds failed. Message:',e.message,'. This can mean the id was not found.')}}})();

Drag it to your Bookmarks toolbar: Toggle FB ads

You wouldn’t want to nest try/catch blocks in catch statements endlessly, so you might extend this into lessons on arrays, loops, recursion… that depends on you and your learners’ situation.

§

Further reading

console on the Mozilla Developer Network

try…catch on the Mozilla Developer Network


Video explorations on their way

Aside

We will soon return to our regularly scheduled programming:
…Some software and hardware reviews and how-tos (coming soon: Music lessons with iPhone and AmpKit!)
…I’m using CompendiumNG and/or designVUE to make storyboards for my own brand of guitar lessons
…and I’m also working on ways to make html5 video more interactive, making videos to make more interactive, and making videos of making videos to make more interactive.

The teachable moment, is a threshold to a concept.

Jul 30

White Privilege—how I “get it”

composite, high school year book and two pictures from American Community School of Addis AbabaIt was the 1960s. My father was teaching physics at Lehigh University, Bethlehem, Pennsylvania, USA. When presented with an opportunity to make a career decision, my Dr. Spock-influenced father and mother, a teacher of special ed, called a family meeting where my younger sister and I agreed we’d like to go on “a family adventure.” Embracing that fun-sounding idea ultimately led to us packing up, selling the house and cars, and moving to Addis Ababa, Ethiopia, for 4 years. It ultimately led to an experience that has shaped my outlooks the remainder of my life.

Continue reading

Jul 25

Conceptualizing the idea of race as a discourse

Abstract: In this paper I look at the literal and extended meanings of discourse, and at how it can be at once a tool or model that describes, defines, and delineates narrative, and the narrative itself. I look at how that process has presented historically when the topic is race, where a predominantly pathologizing discourse has led us, and what influences are at play in choosing our direction forward. Underlying is the story of an academic coming of age, Cultural Anthropology’s. Having freed us from colonial bionarratives only to abandon us, celebrating our newfound ethnicities, submersed in a whitewash of suppressed but self-perpetuating race-isms, many within the discipline urge greater responsibility for the ways their science is used. I conclude it requires persistent activism in concert with a clear concept of race as a discourse to achieve a post-race society.

Of all the definitions of discourse available on the Internet (e.g., at Google.ca; type definition:discourse) the one I find most helpful is on a list of rhetorical terms one can download in Word format here

Dis • course
spoken or written language, including literary works; the four traditionally classified modes of discourse are description, exposition, narration, and persuasion.

WikiPedia has a reasonably comprehensive discussion of conceptualize [redirects to http://en.wikipedia.org/wiki/Concept] and what concept has meant to philosophers Plato, Locke, Kant and to contemporary cognitive theorists such as Fauconnier and Turner. According to this account concepts are mental representations or they are abstract objects… or both. According to Deleuze and Guattari’s What Is Philosophy?, philosophy is the “discipline that involves creating concepts” (1994, p. 5). My task as I see it then is to describe the “Idea of Race,” expose its origins and effects, listen to and translate its narration, determine the direction and depth of its persuasion, and bring all that together, using imagery and metaphor, to create an idea of who, what, where, when, how, and why race has described, exposed, narrated to and persuaded us all. Such a discourse will inform where we are, how we got here — and where we can go from here.

Where we are

Faye Harrison (1998, p. 609) locates us in an age of globalisation characterised by a technologically enhanced compression of time and space, and the concentration of wealth in the hands of a mighty few. We have for several generations spoken incessantly and obsessively of sex (Foucault, 1990) and yet within the most recent decades anthropologists have depreciated race, even undertaken a concerted effort to deprecate, disguise, and deny it (Harrison, 1998; Smedley, 1998; Wolf, 1994); racism, however, is not so easily subdued (Goldberg, 1993; Harrison, 1998; Smedley, 1998). It is surreptitious and persistent, with an “ability to reinvent itself in new postcolonial and postmodern forms” (Harrison, 1998, p. 609). As we shall see again in the next section, anthropology owes much of its existence and early growth to the endeavour to establish race as scientific fact (Banton, 2000; Goldberg 1993), and later attempted to undo some of the social and cultural damage enabled by the racializations this premise empowered. Even as society declared itself enlightened and professed to rid itself of racist dogma, race-based discrimination — power allocation with a multitude of restrictions on access and privilege, predicated on categories or hierarchies of physical and biological characteristics, for example skin colour, lips, hair, sexual organs (Gilman,1985) or origin and ethnocultural proximity — endured. The record of anthropology itself bears witness to this complex play between overt and covert racializations, as Fluehr-Lobban (2000) attests in but one example: the case of Anténor Firmin, a Haitian-born scholar educated in colonial Haiti, published in France, a presage of Boas — who remains widely unknown and under-celebrated to this day, due at least in part to his skin colour and ethnic origins; “[Firmin] awaits his reclamation as an early anthropologist” (451).

These colonialist juxtapositions of power and influence are not things of the past. Morbey and Granger (2002, p. 2; also Marchart, 1998) call to light “Two particular ideological viewpoints, among others, are dominant players in colonizing roles: the “American New Frontier” notion, deployed in narratives of cyberspace and standing in the tradition of one of the American founding myths of conquering new geographic spaces, and Japanese ”techno-colonialism”, a technical inter-discourse consisting mainly of “oriental” consumer technologies and objects.”

Many in the social sciences and liberal arts feel a social responsibility and an obligation to address all this (Harrison, 1998, p. 612). Thus we have come to “a moment when anthropologists’ interest in race and racism has been revitalized” (2005, p. 1). It is also a moment when we are poised either to repeat or reject in the cyberworld the mistakes and transgressions of global coloniaism.

How did we get here?

Human beings have not always paid much attention to physical and biological differences, nor based so many social privileges and restrictions on them (Smedley, 1998; Banton, 2000). Deployments of affiliations (Foucault, 1990, p. 106) and relationships to power have always been present, but the ancients tended to rely on kinship and lineage, language and geographical proximity (Wolf, 1994, p. 2) to establish and reinforce these. The practice of expanding territories and subjugating existing occupants necessitated justifying the atrocities of war and later the needs of industry, and explaining the right of one group to dominate another. The Greeks and Romans facilitated this by dividing the peoples of the world into civilized, barbarian and monstrous; Christianity transmuted this inherited trichotomy into faithful, redeemable, and unredeemable (1994, p. 3). Up to this point though, many avenues existed for persons to change stations, including intermarriage and advancement by demonstration of merit. Two discourses emerged to compete for the role of lodestone to the moral compass of the dominant groups (Sanjek, 1994): a) humans share common ancestry and are therefore of equal worth and potential, so may claim equal rights and access to privilege or b) the human species was split into subspecies (“races”) by irreversible physical and biological facts that led ultimately, both by evocations of divine authority and by (pseudo-) scientific reasoning, to the conclusion that one was superior and given the often “divine” role of dominance over the rest (Smedley, 1998; Banton, 2000).

Skin colour was not the first consideration. Harrison (1998, p. 617) highlights Orser and Smedley as just two scholars who have pointed out how “racial Othering” of the Irish by the English narrated those two people’s relationship during the centuries that corresponded roughly with the Age of Discovery (a.k.a. Exploration… or Conquest) and the rise of Imperialism (modern day Colonialism). Lengel (1996) points out that the dichotomous debate I alluded to above, which Banton (2000, p. 53) denotes as polygenist vs. monogenist, was in full swing in mid-19th century Ireland, and quite overt. The monogenist Liberals dominated policy and popular press up to the Great Famine; polygenist essentialists abetted by Robert Knox (1850) and medical science (which as Foucault (1990) has shown was wholly enthralled with pathologism) dominated post-famine. Yet in the closing sentences of his essay Lengel also states, quite emphatically, that it made no difference which narrative one preferred: the English persuaded themselves that the Irish were incorrigibly savage.

It is worth emphasizing in any case that Liberals and racialists agreed on the basic qualities of Saxon and Celt; but while Liberals explained this difference in a gendered discourse of moral inequality, racialists insisted that the ineradicable boundaries of biology would forever separate the two peoples. In both instances, Britain would forever be the master and Ireland the subject. Lengel (1996)

The English reduced humanity to a binary of civilized vs. savage (Harrison, 1998, p. 621), which they exported to the New World where a concurrent narrative of difference in physical features in general, and skin colour in particular, easily transformed into white vs. black (Smedley, 1998). The pathology of Knox and the racialists[1] asserted the superiority of the Anglo-Saxon (not simply “white”) race. Indeed, even the Irish could find partial redemption when they emigrated to a place where there were ample black Africans who appeared even less human than they. Even so, Irish-American “whiteness” was not obtained without a long fight. In 1851 the English satirical magazine Punch referred to the Irish as “A creature manifestly between the Gorilla and the Negro.” (Orser, 1998, p. 665). The election of an Irish Catholic president a full century later was considered nearly as remarkable as that of an African American in 2008[2].

Thus “…racism preceded ‘races’: the ‘master race’ was created to make logical and natural its domination over the rest” (Delacourt, 2005). Race was developed as “…a way to rationalize the conquest and brutal treatment of Native American populations and especially the retention and perpetuation of slavery for imported Africans” (Smedley, 1998, p. 694). It was designed and tailored, using a warehouse of interchangeable and complimentary fabrics and patterns, to dress the white Anglo-Saxon Protestant ethnocultural group for success — and privilege and dominance.

Where do we go from here?

I’ve described a concept of race that is malleable. Race can mean different things to different cultures, or in different regions, or in the same cultures and regions at different points in time. The idea of race is contextual. It exposes power relationships, and is utilized to establish and control them. It often explains how people of different groups interact and “get along.” Yet there is a second aspect of the narrative I have thus far neglected to point out in detail, the aspect Audrey Smedley refers to as “the problem of how individuals and groups perceive who they are—the problem of ‘identity'” (1998, p. 691). The 20th century has witnessed increased emphasis on the concept of ethnicity, which, although it draws from the long tradition of regional, linguistic and kinship based systems that are described and exposed by the concepts of culture and acculturation, expands the narrative to reveal the ways in which groups identify and construct identity for themselves. This seems to present new ways for scholars to discuss the important aspects of societies and their internal and external relationships, ways that may avoid the racialized terminology that now seems so ugly and power/privilege-driven in an age of globalisation. Jumping to such a conclusion ignores the fact that the power relationships still exist, and are no doubt amplified by the same factors that compress time and space and increase the capacity for cross-cultural multiethnic interaction. The higher emphasis on kinship, for example, when coupled with the celebration of common origin inherent in identity construction often leads to nationalistic sentiments presenting consequences far beyond the original self-venerating motives (Wolf, 1994, pp. 5-7).

There is general agreement in the literature that the politics of power has regularly appropriated, and often usurped the science of anthropology in order to construct artificial categories it then turns to explaining and justifying its own actions and intentions. The basic human curiosity and inherent interdisciplinary connectedness that so often fosters a scholarly interest in anthropology[3] comes with a conscience, as evidenced by anthropologists’ well-documented efforts to fight back against the most nefarious ways in which their work is misused. But power is omnipresent and oblivious to truth, thus many writers are recognizing the need for their discipline to take and active stance and a purposeful role in shaping the globalized multiethnic, multicultural society of the near future.

Conclusion

A conceptualization of “race” as a discourse must somehow convey the absence of any real scientific basis or meaning of the word itself, while exposing and undressing the elaborate stitching, the warp, woof and weft of the effects of racializations—the insidious racism—that persist in the minds, institutions, and actions of folk everywhere. From Firmin and Boas to Smedley, Wolf, Sanjek, Goldberg, and Banton we hear an underlying plea to the obligation of the discipline to go beyond conceptualization of a discourse towards an efficacious and effectual effort to influence the unfolding of future interactions. A post-race discourse must narrate the construction of self-affirming identities and yet persuade the affirmed of the benignancy of others’ self-affirmations, the benevolence of affirmation of the Other.

Conceptualizing & illustrating race as discourse

§

Reference

Banton, M. (2000) The Idiom of Race: A critique of presentism. In Back and Solomos (Eds.) Theories of Race and Racism: A Reader. London: Routledge.

Delacourt, J. (2005) Weaving Identities: Refugees, Immigrants, and Local People in a European World of Differences. In Harrison (2005) 191-208.

Fluehr-Lobban, C. (2000) Anténor Firmin: Haitian Pioneer of Anthropology. American Anthropologist 102(3), pp. 449-466.

Foucault, M. (1990) The History of Sexuality Vol. 1: An Introduction New York: Vintage.

Gilman, Sander L. (1985) Black Bodies, White Bodies: Toward an Iconography of Female Sexuality in Late Nineteenth-Century Art, Medicine, and Literature. Critical Inquiry, 12(1) “Race,” Writing, and Difference, 204-242.

Goldberg, David T. (1993) Racial Knowledge. In Racist Culture, Philosophy and the Power of Meaning. Cambridge, MA: Blackwell.

Grant, James (1844) Impressions of Ireland and the Irish. 2 volumes (London: Hugh Cunningham), 2, pp. 186-191.

Harrison, Faye V. (1998) Introduction: Expanding the Discourse on “Race” American Anthropologist 100(3), pp. 609-631.

Harrison, Faye V. (2005) Introduction: Global Perspectives… In Resisting Racism and Xenophobia: Global Perspectives on Race, Gender, and Human Rights. 1-34. Toronto: Altamira Press.

Knox, Robert (1850) The Races of Man. London: Renshaw

Lengel, E. (1996) A “Perverse and Ill-Fated People”: English Perceptions of the Irish, 1845-52 Essays in History [On-line serial], 38. Available: http://esoterictexts07.tripod.com/Irish.BritishPerception1800.htm Retrieved: 2013-07-15.

Marchart, O. (1998). The east, the west and the rest: Central and eastern Europe between techno-orientalism and the new electronic frontier. Convergence: The Journal of Research into New Media Technologies, 4(2), 56-75.

Morbey, Mary Leigh and Granger, Colette A. (2002) Cybercolonialism in the State Hermitage Museum, St. Petersburg, Russia: Does it Matter? Available: http://www.yorku.ca/irlt/reports/2002CybercolonialismSHM.pdf Retrieved: 2008-11-11

Orser, Charles E. (1998) The Challenge of Race to American Historical Archaeology. American Anthropologist 100(3), pp. 661-668.

Sanjek, R. (1994) The Enduring Inequalities of Race.

Smedley, Audrey (1998) “Race” and the Construction of Human Identity American Anthropologist 100(3), pp. 690-702.

Wolf, Eric R. (1994) Perilous Ideas: Race, Culture, People. Current Anthropology 35(1) 1-12.

Jul 25

Conceptualizing and illustrating the idea of race as a discourse

Abstract: In this paper I continue looking at “race” as a discourse, how that discourse describes, defines, and delineates narratives of race and the narratives themselves. I look more closely at how this discourse permeates the iconography of our culture, and how it presents around ideologies and such notions as identity, agency, and normalcy. Any discourse develops a grammar that helps shape and reinforce the narrative. Yet the discourse of race is unparalleled, save perhaps by that of sexuality, in its ability to partition power and privilege.

As Robert J. C. Young states so clearly, “…Foucault’s notion of discourse offered an alternative way of thinking about the operations of ideology, both as a form of consciousness and as a lived material practice. The result is a more robust and comprehensive understanding than previously offered by, for example, Marx’s elevation of mainly economic factors” (1995, p. 159). The basic techniques, Young explains, include analysing literary texts, travel logs, memoirs, academic and other writings produced by a subject group during a period of interest. An important goal is to determine “what could be said and what recognized as truth” among these subjects of culture and history (pp. 159-60).

There’s a certain obviousness to the idea of divining the “operations of ideology” from the idioms of the operators, yet it is of course not without implications and potential pitfalls. With discourse and discursive analyses these can manifest in both philosophical and linguistic terms. Before I attend to these it may prove fruitful to provide some illustrations of how conceptualizations of discourse casts both light and shadow upon such understandings.

Popular iconography

Sander L. Gilman (1985) is ideally illustrative—he analyses illustrations; his iconography, “Black Bodies, White bodies…” exposes the imagery or symbolism of a body of art specific to the late 19th century1. Gilman establishes the fact and power of myth within the “overlapping and intertwined systems of conventions” held by classes or groups (p. 224). He draws linkages between the conventions of aesthetics and those of medicine to relate how the latter’s elevation to the status of science extended the implicit authority of that status, discursively, onto works of art (Goldberg, 1993). Discussing the obsession with pathology, in particular a pathology of sexuality, that drove 19th century medical discourse Gilman demonstrates how the Hottentot female came to represent all black women, and how black women and prostitutes came to represent all sexualized females. This manifests throughout the artwork of the period (Gilman, 1985, pp. 223-8) but is perhaps most eloquently revealed in the Hottentot-esque derrière of Manet’s 1877 Nana and Picasso’s 1905 parody on Manet’s 1863 Olympia, in which a naked black Olympia is offered fruit by two naked men (p. 253).

In a more recent iconography of a particular period of cinema, known as the peplum or “sword and sandal” period, Richard Dyer distils “…characteristics applicable to all muscleman films and even to most constructions of white masculinity” (1997, p. 289, emphasis mine). Dyer develops two constructs within his conceptualization of the cinematic discourse—body image and colonial narrativity—and then applies them to “other images of white men.” The continuity of discourses within a culture is implicit in his comparison of peplum hero Maciste in a particular scene to the painting of Adam by Michelangelo in the Sistine Chapel. Dyer even comments that this particular icon would be all the more recognizable to the Italian movie consumer (p. 292). This same concept of discursive continuity becomes explicit in the long discussion of Mussolini and Fascism. Mussolini understood and utilized well the power of physique, spectacle—and whiteness—that the producers of sword and sandal cinema mirrored and emulated (pp. 294-9). The specificity of ‘race’ as a discourse is exemplified throughout Dyer’s discussion but is perhaps most tellingly revealed in the perpetual casting of whites in lead roles and blacks as primitives “possessed of a slave mentality:” in various plot lines the white lead actor eschews slavery only to see the blacks in supporting roles choose subaltern positions anyway (p. 307). The discourse maintains, and more importantly sustains the idiom that this hierarchy is not man made but results from the natural order.

The “embedding of transforming racialized distinctions into the ordinary processes, categories and outcomes of reasoning, into Reason itself” become “conceptions of what sorts of behavior morality requires… who is capable of moral action and who is subjected to it, who is capable of moral autonomy and who should be directed,” examples of “conceptualizing the logics of racializing discourse and racist expression” (Goldberg, 1993, p. 148). David Goldberg illustrates how such conceptualizations fuel processes that extend themselves subtly or surreptitiously into the formalized knowledges production—or reproduction—that form our academic discourse: one of the pitfalls of discursive analysis I mentioned above (p. 148). Texts of analysis are no less “framed” in the racialized experience than the subjects they attempt to analyze. Another set of texts populates the domain of racist discourse; Goldberg calls these “expressive” (1990, p. 297). The forms of expression, as we have partly seen, include the scientific, economic, bureaucratic and linguistic, among others, a discursive formation that “consists of a totality of ordered relations and correlations…” (p. 297). Goldberg (1990) makes special note of the linguistic nature of the field of racist discourse by devoting a bold titled section to the grammar of racist discourse. By pointing out how racist discourse informs and infects many others, for but two examples the discourses of colonialism and of sexuality (Foucault, 1990; Stoler, 1995; 2002), Goldberg calls attention to a certain uniqueness of this particular discourse: it can not be so easily unified as it “does not consist simply in descriptive representations of others.” There is no “singular trans-historical stylistic or normative pattern” to racist expression. “The grammar of racist discourse assumes coherence and uniqueness only when compared from the vantage point of the discourse as a whole with another discursive field” (1990, p. 300).

The linguistic nature of any discourse contains obstacles besides the necessity to identify a coherent grammar and syntax. The very vocabulary itself can be suspect. Precise language can illuminate and clarify, such as when Daniel Yon (1999) speaks of the importance of understanding “difference between and difference within” (p. 625, emphasis mine) or even more pertinently reports that “students contest both the “black” and “community” in notions of ‘The Black Community'” (p. 626). Similarly Morris (2005/07), referring to Thesen (1997), spotlights “the way much discourse analyses neglect individual agency and ignore how identities are shaped by practices of labelling and relabelling. […] Language alone is not sufficient for accounting for human experience, nor are subjects merely an effect of discourse” (Morris, 2005/07, pp. 138-9). Beckett and Hager (2002), citing Barbara J. Thayer-Bacon, have the following observation and resulting advise:

Language affects how we view the world, and how we make sense of the experiences we have. But it is also true that much of what we experience remains unnamed, and cannot be reduced to its articulated meanings. I urge people to be receptive and attentive to the inarticulate too, not just what is named (Thayer-Bacon, cited in Beckett and Hager, 2002, p. 167).

Makonde sculpture

Fig. 2.
Makonde sculpture, Mozambique

photo P. Deramaix “…it recalls the community of the village, clan was supported by the patriarch and overcome by the mother”

To understand how language itself, and all the cultural constructs that accompany language—idiom, metaphor, double entendre, “wax and gold2“—frames every conversation and influences understanding one need only consider the familiar predicament of attempting to tell certain jokes to someone who grew up speaking another language. Certain things don’t translate, and when translated their meanings may change… and when their meanings change neither party may know or recognize the extent or direction of the miscommunication. Perhaps, as Robert Young (1995) challenges us to ponder, all knowledge really is phantasm, and knowledge production necessarily creates the reality it attempts to describe. This is why, he tells us, Spivak chooses to “focus on the kinds of exclusion produced not only by colonialism itself but by current forms of understanding… an interrogation of, as she sees it, the increasing commodification in academia of the category of ‘marginality’ itself” (pp. 162-163, emphasis mine). This sounds much like the conclusion Karl Popper drew, that “Darwinism is not a testable scientific theory but a metaphysical research programme” (1976, p. 151). But he continued, “And yet, the theory is invaluable. I do not see how, without it, our knowledge could have grown as it has done since Darwin” (pp. 171-2). This is precisely what Young means by, “at worst [this controversy produces] a certain lack of historical specificity. At best it has resulted in greater attention to the reality of the subaltern thorough the history and testimony of those colonized (1995, pp. 160-161).

In illustrating the conceptualization of race as discourse it has been impossible not to refer to other discourses, a function of the interweaving and interdependency of all discourse. Yet no discourse commands quite the power as that of ‘race’ to partition power and privilege, and none has inspired such energy to contrive and control ideologies of difference. Race has increasingly become the whispered discourse, while that of sexuality is louder than ever. Yet there is no mistaking the relationship between the two. Stoler (2002), summarizing Foucault (1978/90), states that “racial discourse was a part of the technologies of sex that arose in the eighteenth century to regulate sexual conduct and by which populations could be expanded and controlled” (p. 149). If Foucault missed the significance of an “imperial politics of exclusion… reworked… on colonial ground” (Stoler 2002, p. 151) he nonetheless referred to the “symbolics of blood” to illustrate how one discourse literally shaped and steered another (Foucault, 1978/90, pp. 148-50), all the while fuelled by, and fuelling, a cultural machine—itself a machine of culture. Hegel’s dialectic is one of thesis, antithesis, and synthesis; Marx stands that dialectic on its head. In such a picture it seems to matter little whether “modern racism appears as a consequence of that class body in the making” or race was “constitutive” of the making (Stoler, 2002, p. 152).

 

Images:
Fig. 1 This image, from WikiPedia, of a popular “Sword and Sandal” film poster and its caption demonstrate how well understood the concept of period artwork as discourse revealing ideology and conventions is within our society.
Fig. 2 – Makonde sculpture, Mozambique
“…il évoque la communauté du village, clan soutenu par le patriarche et surmonté de la mère.1” photo P. Deramaix, coll. privée3

 

    Footnotes

  1. Gilman’s understanding in 1985 that “visual conventions [are] the primary means by which we perceive and organize the world around us” (1985, p. 223) was prescient of more recent revelations about the way Web 2.0 technologies, especially visual/video-based technologies, enhance understanding in modern day communications (WOW Project, 2007; Churches, 2009).
  2. I’m referring to Levine, Donald N., (1965) Wax and Gold: Tradition and Innovation in Ethiopian Culture, Chicago: University of Chicago Press, of which I was unable to obtain a copy for this essay. This book moved me deeply when I read it as a teen; I did not then understand that it is a discursive analysis of the highest magnitude, presaging Young and others. From a publisher’s description: “Using the insights and the tools of several disciplines, Professor Donald Levine looks on Amhara culture as history, as an outlook on life, a way of growing up, a social structure, a kind of psychological orientation, and, finally, as a “combination of opposites.” […]The author has found one key to Ethiopian society in its poetry, where the “wax” is the obvious meaning, the “gold” the hidden meaning. He finds reflections of this ambiguity at all levels of Ethiopian culture and holds that an appreciation of it is essential to understanding the problems facing Ethiopians in their movement toward modernization and their unique role among African nations.” [Amazon]
  3. Photographer’s caption: “…it recalls the community of the village, clan was supported by the patriarch and overcome by the mother” http://www.amigos-de-mocambique.org/cine/desob.htm retrieved 2009/11/21

Analyzing race and representation

 § 

References:

Banton, M. (2000) The Idiom of Race: A critique of presentism. In Back and Solomos (Eds.) Theories of Race and Racism: A Reader. London: Routledge.

Beckett, D. and Hager, P. (2002) Life, Work and Learning: Practice in Postmodernity, London: Routledge.

Churches, Andrew (2009) ICT Tools and the Visual Learner http://edorigami.wikispaces.com/ICT+and+the+Visual+Learner, retrieved 2009/11/15.

Dyer, Richard (1997) “The White Man’s Muscles” in Race and the Subject of Masculinities, ed. Harry Stecopoulos and Michael Uebel Durham, NC: Duke University Press, 286-314.

Foucault, M. (1978/1990) The History of Sexuality Vol. 1: An Introduction New York: Vintage.

Gilman, Sander L. (1985) Black Bodies, White Bodies: Toward an Iconography of Female Sexuality in Late Nineteenth-Century Art, Medicine, and Literature. Critical Inquiry, 12(1) “Race,” Writing, and Difference, 204-242.

Goldberg, David T. (1990) “The Social Formation of Racist Discourse” in The Anatomy of Racism, ed. Personal author, compiler, or editor name(s); click on any author to run a new search on that name.Goldberg, David Theo, Minneapolis: University of Minnesota Press.

Goldberg, David T. (1993) Racial Knowledge. In Racist Culture, Philosophy and the Power of Meaning. Cambridge, MA: Blackwell.

Haraway, Donna J. (1991) Simians, Cyborgs, and Women: The Reinvention of Nature. New York: Routledge.

Haraway, Donna J. (1990) Primate Visions: Gender, Race, and Nature in the World of Modern Science. New York: Routledge.

Harrison, Faye V. (1998) Introduction: Expanding the Discourse on “Race” American Anthropologist 100(3), pp. 609-631.

Harrison, Faye V. (2005) Introduction: Global Perspectives… In Resisting Racism and Xenophobia: Global Perspectives on Race, Gender, and Human Rights. 1-34. Toronto: Altamira Press.

Morris, Gayle (2005/07) “Performing Pedagogy and the (Re)construction of Global/Local Selves” in Globalizing Education: Policies, Pedagogies and Politics, Michael W. Apple, Jane Kenway, Michael Singh eds., New York: Peter Lang.

Orser, Charles E. (1998) The Challenge of Race to American Historical Archaeology. American Anthropologist 100(3), pp. 661-668.

Popper, Karl. (1976) Unended Quest: An Intellectual Autobiography Glasgow: Fontana/Collins.

Sanjek, R. (1994) The Enduring Inequalities of Race.

Smedley, Audrey (1998) “Race” and the Construction of Human Identity American Anthropologist 100(3), pp. 690-702.

Stoler, Ann Laura (1995) “Placing Race in the History of Sexuality” in Race and the Education of Desire: Foucault’s History of Sexuality and the Colonial Order of Things, Duke University Press.

Stoler, Ann Laura (2002) “A Colonial reading of Foucault” in Colonial Knowledge and Imperial Power, Berkley CA: University of California Press.

Thesen, Lucia (1997) Voices, Discourse, and Transition: In Search of New Categories in EAP, TESOL Quarterly 31(3), 487-511.

Wolf, Eric R. (1994) Perilous Ideas: Race, Culture, People. Current Anthropology 35(1) 1-12.

WOW Project (2007) Web 2.0 and Emerging Learning Technologies/Learning Styles http://en.wikibooks.org/wiki/Web_2.0_and_Emerging_Learning_Technologies, retrieved 2009/11/15.

Yon, Daniel A (1999) ‘Pedagogy and the “problem” of difference: on reading community in The Darker Side of Black’, International Journal of Qualitative Studies in Education, 12 (6), 623-641.

Young, Robert: Colonial Desire: White Power, White Desire (London: Routledge, 1995).

Jul 25

Analyzing race and representation

Abstract: In the final paper in this series I discuss representations of race and consider how perceptions of such representations must be different across gender, age and cultural differences. I discuss research showing how symbolism can be appropriated across these artificial boundaries. I speak of my own evolving sense of White Privilege, with anecdotal examples, and speculate how it benefits me, sometimes to the detriment of others, whether or not I am aware of it or complicit.

Merkato, open air market Addis Ababa, EthiopiaEducators, business people, and many others in potential leadership roles are for the most part quite familiar by now with the assertion that it is important their classrooms, businesses, and organizations are representative of the communities they serve. This can be reflected in many ways, for but a couple of examples, in the pictures they hang or the people they hire. But the apparent simplicity of such a description of problem and solution falls away quickly when one contemplates even the simplest scenario. Let’s say I’m a teacher and I know I have black students in my class, and I wish to display photographs representative of the “black community.” Shall I hang a picture of Barack Obama? …Nelson Mandela? … Michaëlle Jean? …Michelle Obama? …Sean Combs? All are black, but what does each “represent?” And what possible justification could I have for assuming they represent the same things to my students as they do to me, or that they represent anything at all?

. . . identity is formed at that point where the unspeakable stories of subjectivity meet the narratives of history, of a culture . . .

— Stuart Hall (1987, p. 44)

Identity is about belonging, and how we choose where we belong, but also how that is chosen for us. Narratives, our interpretations and retelling of history, shape our views of ourselves and our worlds, so “discourses [can be regarded as] formative, rather than expressive, of identities” (Hall, 1987 referenced in Parker and Song, pp. 583-4).

Vanilla IceWhat is representation?

In the first several pages of Urban Portraits of Identity: on the problem of knowing culture and identity in intercultural studies Daniel Yon exposes the highly complex and deeply nuanced topic of identity and representation from the point of view of a number of adolescents attending public school in a diverse and cosmopolitan city, Toronto (Yon, 2000). Adolescence is widely understood as the stage in human development when we begin to decide what we will do with our lives, and consequently not just what, but who we will be when we grow up, so this is a very good place to begin an analysis. Reading Yon, it soon becomes apparent that, far from being a “simplistic reading of bodies,” (p. 143) the students being interviewed construct identities not only from the corporeal universe within which they dwell, but also from the vast cache of stories and imagery they encounter there. Representations of identity are “more spontaneous” (Parker & Song, 2009, p. 584). Our attempts to contain real students in neat “visible minority” boxes fail because their own view is much “thicker” (see Geertz, 1973). Regardless of any obvious or predictable connection their constructions often “defied neat reduction” to nationality, race or ethnicity (Yon, 2000, pp. 143-5).

This orientation towards community assumes relationships between “personal identity” and “cultural identity” as unproblematic. Either the relationship is imagined as being smooth, or where there is disjuncture then either identity or the culture is constituted as a “crisis.” Education is perceived as the means through which the crisis may be resolved. This is the same discourse that incites desires for curriculum that “reflects” the identities of the learners. In school-based efforts such assumptions about culture, identity, and community are therefore crystallized in a discourse of “inclusive education.” It structures, for example, the call for “African-centered curriculum” as an alternative to “Euro-centered curriculum” while generally offering little or no critique of the structures of knowledge or the meaning of culture that produce these “centerings” in the first place. In these various ways cultural relativism, and the discourse of community as inheritance that it produces, has come to privilege differences “between” while suppressing engagement with difference “within” communities.

Daniel Yon (1999, p. 624)

It’s worth a pause here to consider that none of those three terms is itself neatly reducible; nationality often connotes citizenship, yet ethnicity may allude to that, but contains an element of DNA and a suggestion of tradition and ritual — race has a pseudo-scientific legacy in the realms of anthropology and biology but nonetheless has been applied as a synonym for either or both of the other terms… culture underpins them all (Smedley, 1999). These collisions, this flux between self-identifying and identifying self, is the starting point of my analysis.

The subject is a web of tensions and release, and just as “discourse structures the possibilities for thinking and acting” thinking and acting shapes the discourse. Thus, culture is deemed to be elusive, “…emergent, both product and process” (Yon, 1999, p. 626). Representation, then, can be seen not only as a marker of “social hermeneutics” used by those attempting to read a particular culture from the outside, but also as a tool by those within (or in proximity to) a culture to define and partition the boundaries of the culture, to decode the relationships of themselves and others to the culture (e.g., membership), and similarly to encode or declare their own relationship to a culture (Hall, 1997; 2007). We must, to quote Hall (1997), quoting Richard Hoggart (1958) “…try to see beyond the habits to what the habits stand for, to see through the statements to what the statements really mean…” (Hall, 1997, p. 43).

This is a challenging undertaking, as representations and their symbolisms can be insidious and pervasive—and contradictory, subject to interpretation. It is accepted that observers bring their own baggage to observations. In researching identity this may mean biases and preconceptions, or pre-established categories constructed around them, resulting in research and reflection that becomes an attempt to justify the choice of those particular categories. Lucia Thesen observes that “…identity can be seen as the dynamic interaction between the fixed identity categories that are applied to social groupings (such as race, gender, ethnicity, language, and other, more subtle representations that are activated in certain discourse settings) and the way individuals think of themselves as they move through the different discourses in which these categories are salient.” (Thesen ,1997, p. 488) Thesen draws a useful distinction between discourse (systemic, societal, institutional) and voice (individual). She too acknowledges the tension and flux I alluded to above, as “…linguistic representations of the fundamental tensions between structure and agency in social life.” (1997, p. 494) She cautions, “…discourse theory downplays agency in the sense that new identity categories and combinations of categories, generated by research subjects themselves, fail to emerge in educational understandings.” She advocates for “…research that brings the locus of interpretation closer to students to find out in which discourses they perceive themselves to be operating.” (1997, p. 507) Both Yon, in what he termed an identity “snapshot,” (1999, p. 626, 2000, p. 144) and Thesen in her “exploration of identity in movement, over a period of time” (1997, p. 506) encounter agency and uncover students’ ability to negotiate multiple discourses, even to self-identify using multiple representations, as in the initially surprising case of a Serbian student who self-identified as “Spanish.” My category (“Serbian”) refers to an ethnicity or a geographical origin, but the student perceived, negotiated, and appropriated for herself certain specific representations around music and apparel she perceived as “Spanish” (Yon, 2000, p. 147). My category prepositions the student, furthermore I could undoubtedly deduce it from paperwork and never need to meet with her to do so. Were one to ignore the young woman’s perceptions and the process by which she achieved this appropriation—her agency in the construction—one would not only dismiss the person, but miss the point of undertaking the analysis.

hoodieWhat about race?

I said earlier that race underpins representations of nationality and ethnicity, and that is for a variety of reasons both objective and subjective. Having grown up and attended school during the 60s, and for the most part in the United States, I spent most of my life believing there are three distinct races differentiated by distinct physical characteristics including skull shape, facial features, and skin colour. I was raised to believe such things made no difference as to how people of different races should be treated, and I was astute enough to recognize this wasn’t always the reality. I travelled, and at some point during the 70s I began understanding and using the word “ethnicity” to describe a more general concept I understood to mean not just race, but to encompass culture, language, and other things I had probably associated with “nationality” prior to acquiring the new vocabulary. Not until perhaps two years before taking this course did I even hear the hypothesis that race was an entirely a cultural construct, with no scientific basis, and I was sceptical. How could this be? What about pigment? What about eyelids? What about hair?

Upon reflection I soon came to accept that race is a construct, that these are variations on a theme—but that they represent many other things in many other contexts. It had been, as Goldberg exposed it, “comfortable” to think of race, and in racialized terms (Goldberg, 1993, p. 150). My travels resulted in an extended stay (1970-1974) in a “Third World” country (Ethiopia) and there’s no question in my memory that I understood it to be “primitive.” I learned it was more “advanced” than many other “primitive” countries—the proof was offered in such facts as having the only airline in Africa in the 1970s that could boast of all Ethiopian pilots and maintenance crew, from shop foreman to the most junior mechanic. I don’t recall ever hearing explicit reasons given for this bit of trivia, but I know that I inferred from somewhere that it was due to three things. First, Ethiopia was a “Christian country since the 4th century AD.” Second, Ethiopia is “one of only two countries in Africa that were never colonized by a European power” (see e.g., ImperialEthiopia.org or Henze, 2000, rev.). And third, Ethiopia was an ally of the United States. While it’s also very true that I heard of Emperor Haile Selassie’s stirring 1936 speech to the League of Nations, and I knew that, many years before my arrival, he had insisted English become the language used in all school and schooling beyond grade 7. I now recognize that I probably never fully credited the emperor or the Ethiopian people for any of these creative ideas or accomplishments; my knowledge was racialized, the Primitive internalized, and the Otherness of Africa was a given (Goldberg, 1993, pp. 150-7).

In the post-colonial Africa of the early 1970s, even in a country occupied (by Italy, 1936–1941) but never colonized, I experienced and benefited from White privilege. A 15-year-old boy might carry the only white face in the Merkato, but in 1974 he could walk anywhere without fear, and command attention, authority, and respect—though he might not ponder its especially British Colonial legacy. Many years later I considered what representations I likely manifested meeting narratives of colonial history—unconsciously, unwittingly, and unintentionally, through the same accidents of birth—and I understood that my “burden of representation” (Alexander, 2009, p. 465), while undeniably present, was relatively light.

White privilege

I’m now aware I have benefited from, and I continue to benefit from, white privilege—every waking hour of every day of my life. I have from the moment of my birth, and very well may until death. At 21 in California I stood patiently in line at the unemployment insurance office, spoke to the educated white workers in educated white English, quickly decoded the system, mastered the rules and collected full benefits weekly for the maximum number of weeks I was eligible. I can say with a clear conscience, however, that by 21 I didn’t believe for one second the African and Hispanic Americans in line (who usually weren’t “eligible,” and certainly weren’t as eloquent or composed) were to blame for their frustration—I remember thinking I’d be just as desperate were I held in that cycle of perpetual unemployability, just as rude and angry if I were being treated as I saw they were. When my benefits ran out I dressed just as appropriately and spoke just as eloquently at my next job interview, and quickly rejoined the world of the employed. As a white male I’ve enjoyed that level of freedom all my life, and exploited it often, sometimes without even knowing, other times with blatant arrogance.

A more recent example is when the Canadian born woman, whom I identified by my limited knowledge of accents as being of “Jamaican” heritage, accepted my expired health card and told the very next person, who spoke with a Caribbean accent similar to her own, she needed to see proof of his citizenship, which he then produced. How many times in that man’s life has he been asked to take just one more step to get to the finish line than I’ve been? Good thing she didn’t ask me, I’m an immigrant from the USA—and I didn’t have proof of my permanent residency! As a white male with no perceptible accent I’m identified as Canadian—included, eligible, okay. And while there may be little difference between a Canadian and an American in one context, there may be other times and places that a differentiation might be desired. That’s systemic, it’s about racializations and subliminal attitudes we all carry—yet none of us is “a racist.”

Implications for the 21st century classroom

The 21st century classroom is distinct because it’s often situated, at least in part, in cyberspace, and so is defined and restricted by a different set of boundaries (Parker & Song, 2009). The asynchronous nature of this classroom enables the emergence of “post-colonial subjectivities” providing multiple points of reference enhanced by global communications. “These emergent cultural formations cut across any simplistic binary between ‘pure’ old ethnicities, and multi-dimensional, progressive ‘new ethnicities’” (p. 600). Educators can benefit by becoming aware and respectful of these sensitivities. Framing the design of learning situations as opportunities to draw forth and empower multiple representations may be a powerful approach to engagement and community building that reaches far beyond more traditional perceptions of what classrooms are about (Parker & Song, 2009; WOW Project, 2007; Yon, 1999, 2000).

I believe an important first step is to acknowledge that the pathologizing concept of “race,” while lacking evidence to support its claims on our biology, is still part of our psychology, and is reflected in our attitudes, behaviors, and in our political systems and our policies. We must work as individuals to address the first two. We must work as societies to fix the last. It is—deeply and fundamentally—an education issue.

§

Reference

Alexander, Claire, (2009) “Stuart Hall and ‘Race’”, Cultural Studies, 23: 4, 457 — 482.

Banton, M. (2000) The Idiom of Race: A critique of presentism. In Back and Solomos (Eds.) Theories of Race and Racism: A Reader. London: Routledge.

Beckett, D. and Hager, P. (2002) Life, Work and Learning: Practice in Postmodernity, London: Routledge.

Bourdieu, Pierre and Loïc Wacquant (1999) ‘On the Cunning of Imperialist Reason’, Theory, Culture & Society 16: 41–58.

Foucault, M. (1978/1990) The History of Sexuality Vol. 1: An Introduction New York: Vintage.

Geertz, Clifford (1973) Thick Description: Toward an Interpretive Theory of Culture, pp. 3-30, in The Interpretation of Cultures: Selected Essays, NY: Basic Books, 470 pages.

Gilman, Sander L. (1985) Black Bodies, White Bodies: Toward an Iconography of Female Sexuality in Late Nineteenth-Century Art, Medicine, and Literature. Critical Inquiry, 12(1) “Race,” Writing, and Difference, 204-242.

Goldberg, David T. (1990) “The Social Formation of Racist Discourse” in The Anatomy of Racism, ed. Personal author, compiler, or editor name(s); click on any author to run a new search on that name.Goldberg, David Theo, Minneapolis: University of Minnesota Press.

Goldberg, David T. (1993) Racial Knowledge. In Racist Culture, Philosophy and the Power of Meaning. Cambridge, MA: Blackwell.

Hall, Stuart (1987), ‘Minimal Selves’, in Identity: The Real Me, ICA, London, p. 44.

Hall, Stuart (1988) ‘New ethnicities’, in Black Film/British Cinema, London, ICA.

Hall, Stuart (1997) ‘ “The Centrality of Culture”: Notes on the Revolutions of Our Time’, in K. Thompson (ed.) Media and Cultural Regulation, vol. 6 of the Culture, Media and Identities Course Books. London: SAGE and The Open University.

Hall, Stuart (2007), Richard Hoggart, The Uses of Literacy and the cultural turn, International journal of Cultural studies, 10(1):39-49.

Harrison, Faye V. (1998) Introduction: Expanding the Discourse on “Race” American Anthropologist 100(3):609-631.

Harrison, Faye V. (2005) Introduction: Global Perspectives… In Resisting Racism and Xenophobia: Global Perspectives on Race, Gender, and Human Rights. 1-34. Toronto: Altamira Press.

Henze, Paul B. (2000), Layers of Time – A History of Ethiopia, Christopher Hurst & Co. London, pp 372.

Hoggart, Richard (1958) The Uses of Literacy. Harmondsworth: Penguin Books.

Parker , David and Song, Miri (2009), New Ethnicities and the Internet: Belonging and the negotiation of difference in multicultural Britain, Cultural Studies Vol. 23, No. 4 July 2009, pp. 583—604

Roediger, David R. (2001) ‘Critical Studies of Whiteness, USA: Origins and Arguments’, Theoria (South Africa) 98: 72–98.

Roediger, David R. (2006) A reply to Eric Kaufmann, Ethnicities, 6 (2): 254-262.

Sanjek, R. (1994) The Enduring Inequalities of Race.

Smedley, Audrey (1998) “Race” and the Construction of Human Identity American Anthropologist 100(3):690-702.

Stoler, Ann Laura (1995) “Placing Race in the History of Sexuality” in Race and the Education of Desire: Foucault’s History of Sexuality and the Colonial Order of Things, Duke University Press.

Stoler, Ann Laura (2002) “A Colonial reading of Foucault” in Colonial Knowledge and Imperial Power, Berkley CA: University of California Press.

Thesen, Lucia (1997) Voices, Discourse, and Transition: In Search of New Categories in EAP, TESOL Quarterly 31(3), 487-511.

Wolf, Eric R. (1994) Perilous Ideas: Race, Culture, People. Current Anthropology 35(1) 1-12.

WOW Project (2007) Web 2.0 and Emerging Learning Technologies/Learning Styles http://en.wikibooks.org/wiki/Web_2.0_and_Emerging_Learning_Technologies, retrieved 2009/11/15

Yon, Daniel A (1999) ‘Pedagogy and the “problem” of difference: on reading community in The Darker Side of Black’, International Journal of Qualitative Studies in Education, 12 (6), 623-641

Yon, Daniel A.(2000) ‘Urban Portraits of Identity: On the problem of knowing culture and identity in intercultural studies’, Journal of Intercultural Studies, 21: 2, 143 — 157

Young, Robert: Colonial Desire: White Power, White Desire (London: Routledge, 1995)

Jun 18

Bookmarklets for fun and practice

Bookmarklets are JavaScript links that can be stored in your browser’s Bookmarks or Favorites folder, or attached to a bookmarks toolbar, and then used to do something relative to that page. I think bookmarklets have a lot of value for teaching and self-teaching JavaScript.

What can I learn playing with bookmarklets?

You need to create and use a fundamental unit of HTML: a link (also known as “anchor”; <a href="somewhere">Link</a> ). You can start with the most basic javascript:alert('Hello world');. You can learn how to use a closure javascript:(function(){ alert('Hello world'); })();. You’ll be forced from the start to pay close attention to syntax. If you haven’t yet, you’ll quickly figure out how to use Firebug (and/or any modern browser’s “F12 Developer Tools”) to inspect DOM elements to get their id and other properties. Ultimately you’re limited only by your skill, which will improve quickly, and imagination. What would you change about the blog page you’re reading now, if you could?

Where to start?

I started with a pet peeve about a page I visit regularly. My first bookmarklet ever hides the right column in Facebook, so I don’t have to see the ads. Take that, Mark! If you click the link below while on this page nothing will happen. But if you drag the link to your Bookmarks Toolbar (in Firefox, “Bookmarks Bar” in Chrome, etc…) do that while viewing your Facebook page (or any page that coincidentally has a right column div with id="pagelet_side_ads") you will toggle its visibility.

Bookmarklet1: Toggle FB ads Drag the link to your bookmarks bar to try it.

To embed a bookmarklet so it can be dragged to the toolbar you just place a link on your Web page:

<strong>Bookmarklet: <a href="javascript:(function(){var adsDiv=document.getElementById('pagelet_side_ads'),isHidden=adsDiv.style.display==='none';if(isHidden){adsDiv.style.display='inline-block';}else{adsDiv.style.display='none';}})();">Toggle FB ads</a></strong> 

The imagination runs wild

Still milking my own pet peeves, I wanted to collect lyrics of several songs I needed to learn for the weekend warrior band I play in. A recurring pattern is, we find a song by an artist that is a good fit for our sound, and due to that we later add 3 or 4 more by the same artist. Besides, I just like having lyrics handy… why not just get all the lyrics for that artist at once? But that would mean a lot of clicks and copy/paste! With some intermediate JavaScript you can collect all the links and titles, visit each page in a queue, get just the lyrics you want, and display them in one place in a fraction of the time. To engage students and make meaning of any learning situation requires context and relevance. Do you know any young people who like music, and might be engaged by collecting lyrics of their favourite artists?

I may explain this code in another post, but for now it’s about bookmarklets and an example of what one might do with one. If you don’t understand this paragraph you’ll need to do some vocabulary homework. This script only works at www.lyrics.com. That page has a version of jQuery installed so I used it. To write the script I used Firebug to identify IDs and classes of elements on the page that I use as “selectors” to have access. I fiddled in the console until I had a working script. Meticulous syntax is important… your script goes on one line, so semi-colons are in, comments are out.

Bookmarklet: Get Lyrics This works on Artist pages at www.lyrics.com

This script is quite a bit more involved than the first. I did succeed in making it work in the link code like the first one, but there’s an easier way. In order to make more complicated scripts work you should use the bookmarklet to load your script from a file on your server. I created rcf-get_lyrics.js and placed it on this server. You can copy/paste the script below and just change the path to point to your own file.

javascript:(function(){var url="http://www.rcfouchaux.ca/rcf-get_lyrics.js",n=document.createElement("script");n.setAttribute("language","JavaScript");n.setAttribute("src",url+"?rand="+new Date().getTime());document.body.appendChild(n)})();

I’ll discuss the code in more detail in a future post, but quickly, you create a script element and set the source to the file, then append this new element. There’s a unique identifier, which I’m not using for anything right now, created from the time and appended to the url.

Few limits

The most impressive bookmarklet I’ve ever seen, one that immediately became essential to all my JavaScript learning and development, is Alan Jardine’s Visual Event. Visual Event is an open source JavaScript bookmarklet which provides debugging information about events that have been attached to the DOM (Document Object Model; it means the entire web application represented by the “web page” loaded in the browser’s window).

Alan’s script demonstrates how to load a complex script off a server using only a small manageable amount of code in the bookmarklet itself. As you see, I borrowed it but removed his protocol check for simplicity. I think the aforementioned date/time “query string” he adds prevents the browser from caching the script indefinitely, but I didn’t research that—it’s a guess.

Another impressive project that’s available as a bookmarklet is pjscrape. If I wanted to turn my lyrics scraper into a real utility I’d probably start with pjscrape.

Update 2: I’ve placed both the bookmarklets on their own page. I expect I’ll add to the list.

Update 3: I’ve added a variation on the Facebook ad hider, using display:none and targeting only the ads—compare the two and try to figure out what’s different. I’ll add all future updates on the bookmarklets page.

§

  1. This was updated since original publication and now uses id="pagelet_side_ads" and display:none;
May 28

Make Captivate HTML5 Work in Firefox

screen shot of error dialogWith the slow but steady demise of Flash, SWF-based elearning software makers, like Adobe, have been “cramming” (a word from disruptive innovation) HTML5 into their products, like Captivate (I’m using v6.1), to keep up. Because the HTML5 spec itself is still growing in inconsistent and at times uncertain directions there are bound to be holes and gaps in the implementations. For Captivate 6.1 the first one I encountered was the “This browser does not support some of the content…” error I got when I attempted to view my HTML5 output in my browser of choice—Firefox. It was version 20, and I know Firefox has supported HTML5 audio and video tags since version 3.5 so it had to be something silly. In the proprietary software world that may mean license issues, and so it does with Firefox (Free, Open, Libre software) and the MP3 (not so much). Captivate exports only MP3s, Firefox (and Opera) play only OGGs. So until Adobe offers a checkbox on the Publishing page you can do the following, or hope your visitors use only IE, Safari or Chrome—as the majority probably do… but we’re big on inclusion around here so let’s not leave anyone out!

I quickly ascertained it’s the MP3-only audio export preventing Firefox from doing Captivate sound. As you probably know, some browsers do MP3, others do OGG. You may even remember why. Fortunately that’s the only reason Firefox won’t play Captivate HTML5. All you have to do are

  1. create OGG versions of each MP3 and
  2. edit two JavaScript files to
    1. detect Firefox
    2. provide the appropriate file extension and
    3. suppress the error message.

Simple enough you say, but I figured I may as well google it and see what others have done. I did, and found all the hints I needed in hermit9911’s answer to this post (scroll down a few). hermit just needs OGG. I want both to work depending on browser, so I had to improvise on hermit9911’s theme. Here are the steps I ended up following.

1. Create OGG versions of each MP3

There are many programs that convert audio formats. I used Audacity’s “Chains” feature (macros). Since I’ve met many more people who know of Audacity than know of its Chains feature, I’ve done a separate screencast of that process:

Made using Camstudio (screen video), iPhone (narration),
Audacity (mix/process audio) & Sony Vegas (mix/render video)
Can you suggest a good open source video editor? Please use the comments with my thanks!

2. Edit two JavaScript files

detect Firefox

Project.js is found in the root export folder. It’s “minified,” which means line breaks and extra spaces are removed and it’s pretty hard to read, but we can add our tiny bit of code right at the beginning. I don’t see any need for feature detection in this case, so I settled for user agent:

var is_firefox = navigator.userAgent.toLowerCase().indexOf('firefox') > -1; 
// converts the string to lowercase then creates Boolean, 
// true if it finds 'firefox' anywhere in the name. Otherwise : false 

provide the appropriate file extension

Once you have a question that can be answered yes or no the best syntax is usually as follows:

myExtension = is_firefox ? '.ogg' : 'mp3'; <br>// Yes? Send '.ogg' No : send '.mp3

Then just search & replace existing .mp3' with '+myExtension Everything between ”s is literal, myExtension is variable depending on the answer to is_firefox?yes:no;

UPDATED: If you have Administrator rights and access to the Adobe Captivate install folder you can add these changes to the template Captivate creates the file from. Otherwise both files are overwritten every time you publish, and you have to repeat all these steps. If you can access and edit
[InstallFolder]\HTML\assets\js\CPHTML5Warnings.js
use that file instead (path to install folder will differ depending on operating system and installation) otherwise follow the instructions as written:
Next, open [PublishFolder]/assets/CPHTML5Warnings.js and make the two additions suggested by hermit9911. (I looked up the earliest version of Firefox that supported the audio tag and replaced hermit9911’s xx with 3.5).

this.BrowserEnum.FIREFOX_MIN_SUPPORTED_VERSION = 3.5; // sets minimum version, used in code below

suppress the error message

Finally at the very bottom of the file you will find a series of IF and IF ELSE statements… add the following after the closing semicolon of the last one:

else if((this.browser == this.BrowserEnum.FIREFOX) <br>  &amp;&amp;<br> (this.browserVersion &gt;= this.BrowserEnum.FIREFOX_MIN_SUPPORTED_VERSION )) <br> lSupported = true;

Browse to index.html in Firefox, press Play and watch your movie. With a bit of practice this will add all of about 5-10 minutes to your publishing routine. Alas, you’ll have to redo Project.js—and convert all your audio files— every time you publish.

As an extension activity, make this work for Opera (yes, you can use find/replace but watch case-sensitivity. Do each separately… firefox/opera and FIREFOX/OPERA). Use flow control instead? (Hint: yes) Look back at the code above and explain why you need to do that. Would you change the variable name? To what?

My entire solution instructions and code snippets
(including my answers to the extension questions)

/* ADD TO TOP OF Project.js */
var wantsOggsOverEasy = ((navigator.userAgent.toLowerCase().indexOf('firefox') > -1) || (navigator.userAgent.toLowerCase().indexOf('opera') > -1)), myEXT=wantsOggsOverEasy?'.ogg':'.mp3'; 
/* nb comma/semi-colon usage - I declared 2 local vars in 1 dec */

/* This is the text to search for
   .mp3' and change it to '+myEXT
  EXAMPLE
  FROM: src:'ar/Mouse.mp3',du:182
       TO: src:'ar/Mouse'+myEXT,du:182

IF you have Admin privileges find the Captivate install folder and edit the warnings file found in
[InstallFolder]\HTML\assets\js\CPHTML5Warnings.js. Otherwise you can save these changes in a safe place and you'll need to replace [PublishFolder]/ar/CPHTML5Warnings.js in the published location every time you publish. (Project.js is generated programmatically by the publishing engine, so to the best of my knowledge it must be fixed after each publish, also protect your OGG files.)  */

/* In CPHTML5Warnings.js 
(somewhere between lines 19 and 20) non-destructively ADD:  */

        this.BrowserEnum.FIREFOX_MIN_SUPPORTED_VERSION = 3.5;
        this.BrowserEnum.OPERA_MIN_SUPPORTED_VERSION = 10;

(approximately line 112) AFTER final 
          lSupported = true; AND BEFORE

          return lSupported; non-destructively ADD 

		else if((this.browser == this.BrowserEnum.FIREFOX) && (this.browserVersion >= this.BrowserEnum.FIREFOX_MIN_SUPPORTED_VERSION))

            lSupported = true;	
		else if((this.browser == this.BrowserEnum.OPERA) && (this.browserVersion >= this.BrowserEnum.OPERA_MIN_SUPPORTED_VERSION))
            lSupported = true;

§

N.B. Post was edited for clarity since first publishing.

May 20

Visual Understanding Environment (VUE) as a presentation tool

VUE, and its design-centric extension, designVUE, are concept-mapping tools with rather extraordinary superpowers. In fact if you think they look like simple tools for making mind-maps I’m here to nudge you to take a closer look. Mind map being created in VUE.

Metadata

Does quickly and invisibly making your content “more accessible, interoperable and valuable” sound good? Have you heard of “…Web 3.0, the Semantic Web or the Giant Global Graph…?” These two well-connected apps support OpenCalais and other meta-data helpers.

While the VUE site is essential for resources and documentation, I recommend installing and using designVUE. Even if you don’t use IBIS argumentation, what they refer to as “bi-directional hyperlinking between files,” known elsewhere in designVUE as “wormholes” (and in Compendium as “transclusion,”) or the ability to place one map within another, is a powerful ability that separates tools like VUE and Compendium from the plethora of mind mapping tools available.

Presentation tool

That’s what I’m learning first—the built-in presentation tool. There’s not much more I can add about it at this point than what’s in this rather comprehensive overview/tutorial (more overview than tutorial, maybe?), so with no further ado…

Next

I seem to be able to screen record these presentations with another open source program, so if that pans out I’ll share it then. I think it’ll definitely take some practice thinking about presenting in a different way, but there’s a great deal of evidence that idea maps, visually connecting the dots, and the activities such as argument mapping that are associated with them a) may have a natural fit with social networks and social learning, and b) organize data in ways consistent with the human brain (see for example Conole & Fill, 2005 and its extensive reference list).

§

More

The Visual Understanding Environment (VUE) is an Open Source project based at Tufts University

designVUE is a branch of VUE. It is an open source project based in the Design Engineering Group of the Mechanical Engineering Department at Imperial College London.

Conole, G. and Fill, K. (2005). A learning design toolkit to create pedagogically effective learning activities Journal of Interactive Media in Education 2005(08). [PDF: jime.open.ac.uk/2005/08]. Gráinne Conole and Karen Fill, University of Southampton. Page 1 Published 26 September 2005 ISSN: 1365-893X

Calais Marmoset is a simple yet powerful tool that makes it easy for you to generate and embed metadata in your content in preparation for Yahoo! Search’s new open developer platform, SearchMonkey, as well as other metacrawlers and semantic applications.