Attacks on the Press in 2023

Countries imprisoning journalists in 2023

impCountryTable

Countries with deaths in 2023

killingsCountryTable

Attacks on the Press in 2023

Yo
prisonersTable
deathsTable

Attacks on journalists’ lives and liberty remained at near record-levels in 2023, with the Committee to Protect Journalists documenting 99 journalists killed worldwide, the highest total since 2015. CPJ also documented 320 journalists imprisoned for their work as of the December 1 date of its annual prison census — near the global all-time high of more than 360 a year earlier.

Israel made a rapid ascent on the 2023 list, becoming the source for over 75% of journalist killings, and rising to the sixth-worst jailer of journalists after the start of the Israel-Gaza war on October 7.

Interactive map by Geoff McGhee for CPJ

Scroll to continue

Attacks on journalists’ lives and liberty remained at near record-levels in 2023, with the Committee to Protect Journalists documenting 99 journalists killed worldwide, the highest total since 2015. CPJ also documented 320 journalists imprisoned for their work as of the December 1 date of its annual prison census — near the global all-time high of more than 360 a year earlier.

Israel made a rapid ascent on the 2023 list, becoming the source for over 75% of journalist killings, and rising to the sixth-worst jailer of journalists after the start of the Israel-Gaza war on October 7.

Interactive map by Geoff McGhee for CPJ

Scroll to continue

 
 

Journalists killed in 2023

At least 78 journalists and media workers were killed in direct connection with their work, and CPJ is investigating the motives for the killings of eight others to determine whether they were work-related. Of the global total of 99 killings, 77 occurred in Israel and the Occupied Palestinian Territory and Lebanon – the Israel-Gaza war zone – and 72 of those killings were Palestinian journalists and media workers.

Outside the deaths in the Israel-Gaza war, killings dropped markedly compared to 2022, from 69 to 22 deaths. But this declining number is not an indication that journalism has become safer in other parts of the world. Indeed, CPJ’s annual prison census found that 2023 jailings of journalists – another key indicator of conditions for journalists and press freedom – remain close to record highs established in 2022. Read about our methodology

 

The Israel-Gaza war

More than three-quarters of 2023’s deaths took place during the Israel-Gaza war–in a span of only three months. This toll is unprecedented in its intensity, according to CPJ data.

 

The Israel-Gaza war

More than three-quarters of 2023’s deaths took place during the Israel-Gaza war–in a span of only three months. This toll is unprecedented in its intensity, according to CPJ data.

 

Deaths by country

Click on country names in the list to learn about journalists who were killed there in 2023.

 

Scroll to continue.

 

  •••  

 

Journalists imprisoned in 2023

The year’s top five jailers of journalists are China, Myanmar, Belarus, Russia, and Vietnam, respectively. More than 65% of imprisoned journalists in the census face anti-state charges, such as false news and terrorism, in retaliation for their work. Many in the census are jailed without being told of charges against them, and often face cruel and dangerous prison conditions.

This map shows the countries imprisoning journalists in 2023.

Read about our methodology
 

Journalists imprisoned in 2023

The year’s top five jailers of journalists are China, Myanmar, Belarus, Russia, and Vietnam, respectively. More than 65% of imprisoned journalists in the census face anti-state charges, such as false news and terrorism, in retaliation for their work. Many in the census are jailed without being told of charges against them, and often face cruel and dangerous prison conditions.

This map shows the countries imprisoning journalists in 2023.

Read about our methodology
 

Imprisonments by country

Click on countries in the list at left to see journalists imprisoned in 2023.

 

Scroll to continue.

 

Imprisonments by country

Click on countries in the list below to see journalists imprisoned in 2023.

 

Scroll to continue.

 
 
 

China – #1 in 2023

China has been a top jailer of journalists for many years. Its tight censorship of the media and high rates of imprisoning those who speak out make it especially difficult to assess the exact number of journalists in its prisons. Inmates are sent to political re-education camps or simply kept in prison after sentences end. China’s intolerance for independent reporting, along with similar repression in neighboring countries, has made Asia the region with the highest number of jailed journalists–115 of the global total of 320.

 

Myanmar – #2 in 2023

Myanmar catapulted into CPJ’s census rankings as the world’s second-worst jailer of journalists in 2021, when a February military coup ousted the country’s elected government and cracked down on coverage of the new regime. The number of jailed journalists has been on the rise since then, from 30 in 2021, to 42 in 2022, and now, to 43, as the regime continues to arrest journalists, shutter news outlets and force members of the media into exile.

 

Belarus – #3 in 2023

Belarus held 28 journalists in custody on December 1 – up from 26 last year, and 19 in 2021. The majority face anti-state charges, with almost half serving sentences of five years or more. Belarus uses “extremism” laws as a weapon to jail journalists, with five of seven new Belarus prisoners in the census accused of some form of extremism. Arrests in recent years have taken place against the backdrop of President Aleksandr Lukashenko’s ongoing vindictiveness against those covering the aftermath of his disputed 2020 election.

 

Russia – #4 in 2023

As it has intensified efforts to stifle free reporting, Russia has moved into the top five worst jailers of journalists in 2023. With the country’s independent media gutted following its full scale February 2022 invasion of Ukraine, Moscow is continuing efforts to criminalize journalism beyond its borders by issuing arrest warrants and prison sentences for prominent journalists working in exile. Russia also holds a disproportionate number of foreign reporters in its jails. Twelve of the census’ global total of 17 non-local imprisoned journalists are held by Russia.

 

Vietnam — #5 in 2023

Vietnam continues to impose harsh sentences, and harsh prison conditions, on journalists, many of whom are convicted for what the government claims are anti-state crimes. CPJ research found journalists in Vietnamese prisons have been denied necessities such as food, electricity and medical care.

–>

  •••  

Explore the data

Read more about the journalists who were killed in 2023, and explore CPJ’s data on journalists who were jailed because of their work.

Click to interact with the map

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Methodology

Imprisonments

CPJ’s annual prison census accounts only for journalists in government custody and does not include those who have disappeared or are held captive by non-state actors. These cases are classified as “missing” or “abducted.”

CPJ’s list is a snapshot of those incarcerated at 12:01 a.m. on December 1, 2023. It does not include the many journalists imprisoned and released throughout the year. CPJ includes only those journalists who it has confirmed have been imprisoned in relation to their work. Journalists remain on CPJ’s list until the organization determines with reasonable certainty that they have been released or have died in custody.


Killings

CPJ began compiling detailed records on all journalist deaths in 1992. CPJ staff members independently investigate and verify the circumstances behind each death. CPJ considers a case work-related only when its staff is reasonably certain that a journalist was killed in direct reprisal for his or her work; in combat-related crossfire; or while carrying out a dangerous assignment such as covering a protest that turns violent.

If the motives in a killing are unclear, but it is possible that a journalist died in relation to his or her work, CPJ classifies the case as “unconfirmed” and continues to investigate.

CPJ’s list does not include journalists who died of illness or were killed in car or plane accidents unless the crash was caused by hostile action. Other press organizations using different criteria cite different numbers of deaths.

CPJ’s database of journalists killed in 2022 includes capsule reports on each victim and filters for examining trends in the data. CPJ maintains a database of all journalists killed since 1992 and those who have gone missing or are imprisoned for their work.


A note on the map

The map reflects that CPJ holds Russian authorities responsible for press freedom violations in Ukraine’s Crimea after Russia’s 2014 annexation of the peninsula led to de facto control of its media sphere.

Imprisoned in 2021 ( " + (feature.properties["Change since in imprisonments 2020"]>0 ? "+" + feature.properties["Change since in imprisonments 2020"]: feature.properties["Change since in imprisonments 2020"] ) + ")
Click to zoom in" ) .removeClassName("cpj_popup_dark") .setHTML(""+ countryData[selectedISO]["Country"] + "
" + countryData[selectedISO]["Imprisoned in 2023"] + "
Imprisoned in 2023
Click to zoom in" ) .addTo(map); var popupElem = popup.getElement(); popupElem.style.fontStyle = "normal"; popupElem.style.opacity = 0.8; } // end over 0 } // end not undefined /* //if(feature.properties.Imp_2020 > 0){ if(feature.properties["Imprisoned in 2023"] > 0){ // highlight current country map.setFilter('cpj-country-2023-outline', [ //'in', '==', 'GU_A3', feature.properties.GU_A3 ]); } else { // show none map.setFilter('cpj-country-2023-outline', [ //'in', '==', 'GU_A3', "Geoff" ]); }*/ /* // if they had prinsoners if(feature.properties["Imprisoned in 2023"] != 0){ // Display a popup with the name of the county popup .setLngLat(e.lngLat) // .setHTML(""+ feature.properties["Country"] + "
" + feature.properties["Imprisoned in 2022"] + "
Imprisoned in 2021 ( " + (feature.properties["Change since in imprisonments 2020"]>0 ? "+" + feature.properties["Change since in imprisonments 2020"]: feature.properties["Change since in imprisonments 2020"] ) + ")
Click to zoom in" ) .setHTML(""+ feature.properties["Country"] + "
" + feature.properties["Imprisoned in 2023"] + "
Imprisoned in 2023
Click to zoom in" ) .addTo(map); var popupElem = popup.getElement(); popupElem.style.fontStyle = "normal"; popupElem.style.opacity = 0.8; } */ // Single out the first found feature. var feature = e.features[0]; })/**/ // end mousemove on imprisonments // WORKS BUT NOT ADVISABLE // for countries with both killings and imprisonments. // killings interaction overrides; best way to see killed data is thru dot // hover over KILLED countries /* map.on('mousemove', 'cpj-killed-2023-country-fill', function(e) { //logIt("mousemove for imprisonments layer"); map.getCanvas().style.cursor = 'pointer'; var feature = e.features[0]; //if(feature.properties.Imp_2020 > 0){ if(feature.properties["Killed in 2023"] > 0){ // highlight current country map.setFilter('cpj-country-2023-outline', [ //'in', '==', 'GU_A3', feature.properties.GU_A3 ]); } else { // show none map.setFilter('cpj-country-2023-outline', [ //'in', '==', 'GU_A3', "Geoff" ]); } // if they had prinsoners if(feature.properties["Killed in 2023"] != 0){ // Display a popup with the name of the county popup .setLngLat(e.lngLat) .setHTML(""+ feature.properties["Country"] + "
" + feature.properties["Killed in 2023"] + "
Killed in 2023
Click to zoom in" ) .addTo(map); var popupElem = popup.getElement(); popupElem.style.fontStyle = "normal"; popupElem.style.opacity = 0.8; } // Single out the first found feature. var feature = e.features[0]; })*/ // end mousemove on killed COUNTRIES // mouseout on IMPRISONED // remove popup when leaving a state //map.on('mouseleave', 'cpj-imp-2020-20201210-01-bjk6f2', function() { map.on('mouseleave', 'cpj-imp-2023-country-fill', function() { map.getCanvas().style.cursor = ''; popup.remove(); // activate or deactivate? map.setFilter('cpj-country-2023-outline', ['==', 'iso_3166_1_alpha_3', 'geoff']);// shows none }) // hover over KILLED CENTROIDS for each country map.on('mousemove', ["cpj-killed-2023-centroids"], function(e) { //logIt("moved over centroid"); map.getCanvas().style.cursor = 'pointer'; var feature = e.features[0]; var selectedISO = e.features[0].properties["SU_A3"]; //logIt("moved over centroid with selectedISO at " + selectedISO); map.setFilter('cpj-killed-2023-centroids-highlight', [ //'in', '==', 'SU_A3', selectedISO ]); popup .setLngLat(e.lngLat) //.setHTML(""+ feature.properties["Name"] + "
Killed in 2023: " + feature.properties["Killed in 2023"] + "
Click for details
" ) .addClassName("cpj_popup_dark") .setHTML(""+ countryData[selectedISO]["Country"] + "
" + countryData[selectedISO]["Killed in 2023"] + "
Killed in 2023
Click to zoom in" ) .addTo(map); }); map.on('click', ["cpj-killed-2023-centroids"], function(e) { logIt("clicked on centroid"); map.getCanvas().style.cursor = 'pointer'; var feature = e.features[0]; var selectedISO = e.features[0].properties["SU_A3"]; logIt("clicked on centroid with selectedISO at " + selectedISO); // handled by deathsTableNew //zoomToBoundsKill(aopBounds[selectedISO].bounds); drawDeathsTableNew(e.features[0].properties.GU_A3); showKillings(); }); map.on('mouseleave', ["cpj-killed-2023-centroids"], function(e) { //logIt("moved off of centroid"); map.getCanvas().style.cursor = ''; popup.remove(); map.setFilter('cpj-killed-2023-centroids-highlight', [ //'in', '==', 'SU_A3', 'geoff' ]); }); // hover over KILLED /**/ //map.on('mousemove', 'cpj-killed-2023-dots', function(e) { map.on('mousemove', ["cpj-killed-2023-dots","cpj-killed-2023-labels-simp", "cpj-killed-2023-labels-detail"], function(e) { if(map.getZoom() >= 5){ hideImprisonments(); //logIt("mousemove for killings layer"); map.getCanvas().style.cursor = 'pointer'; var feature = e.features[0]; //map.setFilter('cpj-killed-20201209-highlight', [ map.setFilter('cpj-killed-2023-highlight', [ //'in', '==', 'id_GM', feature.properties.id_GM ]); //map.setFilter('labels-simp--cpj-journalists-killed-2019-labels', [ map.setFilter('cpj-killed-2023-labels-simp', [ //'in', '==', 'id_GM', feature.properties.id_GM ]); // Display a popup with the name of the person killed popup .setLngLat(e.lngLat) //.setHTML(""+ feature.properties["fullName"] + "
Killed in " + feature.properties["GeocodedGMText"] + "
Click for details
" ) .addClassName("cpj_popup_dark") .setHTML(""+ feature.properties["Name"] + "
Killed in " + feature.properties["Location Display"] + "
Click for details
" ) .addTo(map); var popupElem = popup.getElement(); popupElem.style.fontStyle = "normal"; popupElem.style.opacity = 0.8; /// highlight country outline too map.setFilter('cpj-country-2023-outline', [ //'in', '==', 'iso_3166_1_alpha_3', feature.properties.Country_ISO ]); // Single out the first found feature. var feature = e.features[0]; }// end zoom minimum }) // end mousemove on killings // restore imprisonments when mousing off simple killing labels //map.on('mouseleave', 'labels-simp--cpj-journalists-killed-2019-labels', function() { //map.on('mouseleave', 'cpj-killed-2023-labels-simp', function() { map.on('mouseleave', ['cpj-killed-2023-labels-simp', 'cpj-killed-2023-labels-detail', 'cpj-killed-2023-dots'], function() { showImprisonments(); popup.remove(); //map.setFilter('cpj-killed-20201209-7zf4qu', ['!=', 'idNum_GM', '']);// shows all //map.setFilter('labels-simp--cpj-journalists-killed-2019-labels', ['!=', 'idNum_GM', '']);// shows all //map.setFilter('cpj-killed-20201209-highlight', ['==', 'Geoff', '']);// shows none map.setFilter('cpj-killed-2023-dots', ['!=', 'id_GM', '']);// shows all map.setFilter('cpj-killed-2023-labels-simp', ['!=', 'id_GM', '']);// shows all map.setFilter('cpj-killed-2023-labels-detail', ['!=', 'id_GM', '']);// shows all map.setFilter('cpj-killed-2023-highlight', ['==', 'Geoff', '']);// shows none // map.setFilter('cpj-country-2023-outline', [ // //'in', // '!=', // 'iso_3166_1_alpha_3', // "geoff" // ]); }) /**/ // 2023 Taiwan patch // patch for taiwan since it is included in CHN iso code map.on('mousemove', 'taiwan-fill-mask', function(e) { map.getCanvas().style.cursor = ''; popup.remove(); //map.setFilter('cpj-country-2023-outline', ['==', 'iso_3166_1_alpha_3', 'geoff']);// shows none }) // patch for taiwan since it is included in CHN iso code map.on('click', 'taiwan-fill-mask', function(e) { logIt("Taiwan fill mask clicked"); e.originalEvent.stopPropagation(); map.getCanvas().style.cursor = ''; popup.remove(); //map.setFilter('cpj-country-2023-outline', ['==', 'iso_3166_1_alpha_3', 'geoff']);// shows none }) map.on('moveend', function () { var mapZoom = map.getZoom(); switch(true){ case(mapZoom = 2.4 && mapZoom 0; } function triggerAction(chapterNameTemp){ logIt("triggerAction running with chapterNameTemp at " + chapterNameTemp); if(chapterNameTemp == "interact" || chapterNameTemp == "methodology" || chapterNameTemp == "years"){ //enableMap(); } else { disableMap(); } if(chapterNameTemp == "intro"){ jQuery("#aopHeader").css("display","block"); jQuery("#aopHeaderFloating").css("display","none"); toggleListDisplay("imprisonmentsListContainer","hide") jQuery("#killingsListContainer").addClass("none"); toggleListDisplay("killingsListContainer","hide"); //jQuery("#aopHeader").fadeTo(500,1,enableHeader); } else { //jQuery("#aopHeader").css("display","none"); //jQuery("#aopHeader").fadeTo(500,0,disableHeader); jQuery("#aopHeaderFloating").css("display","block"); jQuery("#aopHeaderFloating").removeClass("none"); } switch(chapterNameTemp){ case "intro": case "intro-mobile": hideDetails();// hides prisoner or killed list jQuery("#aopHeader").css("display","block"); //jQuery("#aopHeader").fadeTo(1000,1); jQuery("#aopHeaderFloating").css("display","none"); unblurIt(); bannerText(); //showKillings(); showImprisonments(); highlightNav("introduction"); toggleListDisplay("imprisonmentsListContainer","hide") jQuery("#killingsListContainer").addClass("none"); toggleListDisplay("killingsListContainer","hide"); break; /* case "outlook-imprisonment": // imprisonments II problem hideDetails(); showImprisonments(); hideKillings(); highlightNav("imprisonment"); blurIt(); bannerText("","In the coming weeks, CPJ will add its 2023 analysis of journalist killings to this interactive report of Attacks on the Press."); highlightCountry("geoff"); toggleListDisplay("killingsListContainer","hide"); jQuery("#killingsListContainer").addClass("none"); toggleListDisplay("imprisonmentsListContainer","hide"); //disableMap(); break; */ case "killings-interstitial": // transition hideImprisonments(); showKillings(); animateStop(); hideSlider(); highlightNav("killings"); highlightCountry("geoff"); blurIt(); bannerText("Killings","CPJ found that in 2023, at least 99 journalists and media workers were killed — the highest number since 2015 and a 44% increase from 2022. A record number of journalist killings – 78 – were work-related. The rise was driven by the intensity of killings in the Israel-Gaza war, which claimed the lives of more journalists in three months than have ever been killed in a single country over an entire year."); toggleListDisplay("killingsListContainer","hide"); hideDeathsTable(); jQuery("#imprisonmentsListContainer").addClass("none"); toggleListDisplay("imprisonmentsListContainer","hide"); break; case "killings-intro": // all killings //case "killings-intro-mobile": showKillings(); bannerText(); hideImprisonments(); jQuery("#imprisonmentsListContainer").addClass("none"); highlightNav("killings"); toggleListDisplay("killingsListContainer","hide"); hideDeathsTable(); highlightCountry("geoff"); clearAnimateGaza(); hideGazaSlider(); //animateStart(30); unblurIt(); break; case "killings-iopt": // ukraine deaths drawDeathsTableNew('ISR'); toggleListDisplay("killingsListContainer","hide"); gazaStart(); //animateGaza(); break; case "killings-instructions": // imprisonments call to action logIt("killings-instructions arrived") clearAnimateGaza(); hideGazaSlider(); bannerText(); hideImprisonments(); showKillings(); unblurIt(); highlightNav("killings"); toggleListDisplay("killingsListContainer","show"); hideDeathsTable(); highlightCountry("geoff"); drawKillCountryList(); jQuery("#imprisonmentsListContainer").addClass("none"); break; case "killings-sandbox": // imprisonments sandbox case "killings-sandbox-mobile": // imprisonments logIt("killings-sandbox arrived") clearAnimateGaza(); hideGazaSlider(); bannerText(); hideImprisonments(); showKillings(); unblurIt(); highlightNav("killings"); //toggleListDisplay("imprisonmentsListContainer","show"); highlightCountry("geoff"); toggleListDisplay("killingsListContainer","show"); drawKillCountryList(); jQuery("#imprisonmentsListContainer").addClass("none"); break; /* case "killings-mexico": // mexico deaths drawDeathsTable('MEX'); break; case "killings-haiti": // haiti deaths drawDeathsTable('HTI'); break; */ /*case "outlook-killings": hideImprisonments(); hideSlider(); showKillings(); highlightNav("killings"); bannerText("","

RESOLUTION TEXT NEEDED CPJ is still investigating the deaths of __ other journalists worldwide to determine whether journalism was the motive.

The __ killings with confirmed motive compare with __ journalists killed in ___. That year’s total was the lowest in CPJ’s records since 2000.

"); hideDetails(); blurIt(); break; */ //https://stackoverflow.com/questions/6476994/using-or-operator-in-javascript-switch-statement case "imprison-preamble": case "imprison-preamble-mobile" : // overview hideDetails();// hides prisoner or killed list clearAnimateGaza(); hideGazaSlider(); //jQuery("#aopHeader").fadeTo(500,0); //jQuery("#aopHeader").css("display","none"); //jQuery("#aopHeaderFloating").css("display","none"); //showKillings(); //showImprisonments(); hideKillings(); blurIt(); bannerText("

Imprisonments

","The near-record number of journalists jailed around the world was fueled by war, entrenched authoritarianism, and governments determined to silence dissenting voices and stifle press freedom both inside and outside of their borders.

Scroll to continue"); highlightNav("imprisonment"); toggleListDisplay("imprisonmentsListContainer","hide") jQuery("#killingsListContainer").addClass("none"); toggleListDisplay("killingsListContainer","hide"); break; case "imprison-intro": // imprisonments case "imprison-intro-mobile": // imprisonments //hideDetails();// hides prisoner or killed list hideSlider(); clearAnimateGaza(); hideGazaSlider(); bannerText(); showImprisonments(); hideKillings(); unblurIt(); highlightNav("imprisonment"); //highlightCountry("geoff"); highlightCountry(["RUS","CHN","MMR","VNM","BLR"]); drawImpCountryList(); toggleListDisplay("imprisonmentsListContainer","hide") jQuery("#killingsListContainer").addClass("none"); toggleListDisplay("killingsListContainer","hide"); jQuery("#detailTextLeft").fadeOut( 500 ); break; case "imprison-instructions": // imprisonments call to action case "imprison-instructions-mobile": // imprisonments call to action logIt("imprison-instructions arrived") clearAnimateGaza(); hideGazaSlider(); hideSlider(); bannerText(); showImprisonments(); hideKillings(); unblurIt(); highlightNav("imprisonment"); toggleListDisplay("imprisonmentsListContainer","show"); hideDetails();// hides the prisoners list from iran highlightCountry("geoff"); drawImpCountryList(); jQuery("#killingsListContainer").addClass("none"); toggleListDisplay("killingsListContainer","hide"); break; case "imprison-sandbox": // imprisonments sandbox case "imprison-sandbox-mobile": // imprisonments logIt("imprison-sandbox arrived") clearAnimateGaza(); hideGazaSlider(); hideSlider(); bannerText(); showImprisonments(); hideKillings(); unblurIt(); highlightNav("imprisonment"); //toggleListDisplay("imprisonmentsListContainer","show"); highlightCountry("geoff"); drawImpCountryList(); jQuery("#killingsListContainer").addClass("none"); toggleListDisplay("killingsListContainer","hide"); showDetails(); //jQuery("#detailTextLeft").fadeOut( 500 ); break; case "imprisonment-china": // imprisonments china highlightCountry("CHN"); drawPrisonersTable('CHN'); break; case "imprisonment-myanmar": // imprisonments myanmar drawPrisonersTable('MMR'); highlightCountry("MMR"); break; case "imprisonment-belarus": // imprisonments belarus unblurIt(); hideKillings(); hideDetails(); showImprisonments(); highlightNav("imprisonment"); highlightCountry("BLR"); drawPrisonersTable('BLR'); break; case "imprisonment-russia": // imprisonments russia highlightCountry("RUS"); drawPrisonersTable('RUS'); break; case "imprisonment-vietnam": // imprisonments vnm highlightCountry("VNM"); drawPrisonersTable('VNM'); break; case "interact-preview": hideDetails();// hides prisoner or killed list clearAnimateGaza(); hideGazaSlider(); showImprisonments(); hideSlider(); showKillings(); highlightNav("explore"); highlightCountry("geoff"); bannerText(); hideDetails(); hideDeathsTable() blurIt(); jQuery("#imprisonmentsListContainer").removeClass("none"); //////////jQuery("#killingsListContainer").removeClass("none"); toggleListDisplay("killingsListContainer","hide"); toggleListDisplay("imprisonmentsListContainer","hide"); drawImpCountryList(); //drawKillCountryList(); break; case "interact": clearAnimateGaza(); hideGazaSlider(); hideDetails();// hides prisoner or killed list showImprisonments(); showKillings(); highlightNav("explore"); highlightCountry("geoff"); bannerText(); unblurIt(); jQuery("#imprisonmentsListContainer").removeClass("none"); jQuery("#killingsListContainer").removeClass("none"); drawImpCountryList(); drawKillCountryList(); toggleListDisplay("killingsListContainer","hide"); toggleListDisplay("imprisonmentsListContainer","hide"); break; case "years": case "methodology": hideDetails();// hides prisoner or killed list showImprisonments(); //showKillings(); highlightNav(""); highlightCountry("geoff"); bannerText(); blurIt(); break; default: break; } } // end triggerAction function highlightNav(itemName){ // unhighlight all in floater jQuery("#aop-nav-float div a").css("color","white"); jQuery("#aop-nav-float div a").css("font-weight","300"); //jQuery("#aop-nav-float div a").css("letter-spacing","0px"); switch(itemName){ case "introduction": jQuery("#aop-nav-float div:nth-child(2) a").css("font-weight","600"); //jQuery("#aop-nav-float div:nth-child(2) a").css("letter-spacing","0.5px"); break; case "killings": jQuery("#aop-nav-float div:nth-child(3) a").css("color","#fff030"); jQuery("#aop-nav-float div:nth-child(3) a").css("font-weight","600"); jQuery("#aop-nav-float div:nth-child(3) a").css("letter-spacing","0.5px"); unblurIt(); break; case "imprisonment": jQuery("#aop-nav-float div:nth-child(4) a").css("color","#fdd3d3"); jQuery("#aop-nav-float div:nth-child(4) a").css("font-weight","600"); //jQuery("#aop-nav-float div:nth-child(3) a").css("letter-spacing","0.5px"); break; case "explore": //jQuery("#aop-nav-float div:nth-child(6) a").css("color","red"); jQuery("#aop-nav-float div:nth-child(5) a").css("font-weight","600"); //jQuery("#aop-nav-float div:nth-child(6) a").css("letter-spacing","0.5px"); blurIt(); break; default: break; } } -->
" + ""; tableTemp += ""; //tableTemp += ""; // generate title text with country and number killed tableTemp += ""; tableTemp += "

" + killedCountryDataTemp.properties.Country + "

" + killedCountryDataTemp.properties["Killed in 2023"] + " journalist" + (killedCountryDataTemp.properties["Killed in 2023"] > 1 ? "s": "") + " Killed in 2023
" + killedCountryDataTemp.properties["Killed in 2023"] + " journalist" + (killedCountryDataTemp.properties["Killed in 2023"] > 1 ? "s": "") + " killed in 2023
"; //showDetails(); // reveals parent div // 2022 not needed because moved dtr out of detailbox // insert top level stats into table //document.getElementById("detailTextLeft").innerHTML = tableTemp; document.getElementById("killedCountryInfo").innerHTML = tableTemp; // create new element for country table currentCountryIndex = extractKilledCountryDataNew(isoTemp); var previousIndex = currentCountryIndex > 0 ? currentCountryIndex - 1 : countryKilledTableData.length -1; var nextIndex = currentCountryIndex + 1 " + previousCountryName + " | Show all | Next: " + nextCountryName + " > "; document.getElementById("deathsFooter").innerHTML = footerTemp; var countryFilterVal = killedCountryDataTemp.properties.GU_A3; var dataTableTemp = ''; var numJournalist = 0; var numMediaWorker = 0; var totalCounter = 0; // loop through deaths data for(var x = 0; x"; }// end if } // row loop //var sText = deathsData.length == 1 ? "" : numMediaWorker == 0 || numJournalist == 0 ? "" : "s"; var sText = totalCounter
Name  URL  Outlet  Killed  Motive  Country  Country_ISO  
" + deathsData[x].Name + "" + deathsData[x].Outlet + "" + deathsData[x]["dateDisplay"] + "" + deathsData[x].Motive + "" + deathsData[x].Country_ISO + "
" document.getElementById("deathsTable").innerHTML = dataTableTemp; jQuery("#deathsFooter2").html(""); /// show detailTextRight Div document.getElementById("detailTextLeft").classList.add("none"); document.getElementById("detailTextRight").classList.remove("none"); // preparation jQuery('#killedCountryInfo #closeBox'). unbind('click'); /*jQuery("#killedCountryInfo #closeBox").on("click",function(){ hideDetails(); toggleListDisplay("killingsListContainer", "show"); map.flyTo(chapters["killings-sandbox"]); //showImprisonments(); }); */ // country detail close box goes to either country bounds in interactive // or to all country view with instructions in scroll jQuery("#killedCountryInfo #closeBox").on("click",function(){ logIt("closebox clicked from instantiation in drawDeathsTableNew") hideDetails(); // new in 2023 - reset appState.countryISO = ""; jQuery("#detailTextRight").addClass("none"); // 2022 if(appState.viewMode == 'interact'){ //zoomToBoundsKill(aopBounds[personData.properties.Country_ISO].bounds);// no! //map.fitBounds(aopBounds[currentCountryISO].bounds); map.fitBounds(aopBounds[killedCountryDataTemp.properties.GU_A3].bounds); scrollToAnchor("#interact"); showImprisonments(); } else { //map.flyTo(chapters["interact"]); scrollToAnchor("#killings-detail"); map.flyTo(chapters["killings-sandbox"]); toggleListDisplay("killingsListContainer", "show"); //zoomToBoundsKill(aopBounds[personData.properties.Country_ISO].bounds); } }); // hide other tabular displays toggleListDisplay("killingsListContainer", "hide"); toggleListDisplay("imprisonmentsListContainer", "hide"); // hide imprisoned legend jQuery("#imprisonedLegend").addClass("none"); // fyi causes doom loop scroll for country steps if having them if(appState.viewMode == 'interact'){ scrollToAnchor("#interact"); } else { if(appState.countryISO == "ISR"){ // do nothing } else { scrollToAnchor("#killings-sandbox"); } //location.hash = "#killings-sandbox"; // learned this from imprison } } // end drawDeathsTableNew function drawDeathsTableOld(countryData){ var currentCountryISO; ///var currentCountryIndex; var currentCountryIndex = 1; logIt("drawDeathsTable running with countryData at " + JSON.stringify(countryData)); if(typeof(countryData) == "object"){ logIt("drawDeathsTable says " + countryData + " is an object"); // get array positon of country to draw footer links to other countries //currentCountryIndex = extractKilledCountryData(countryData.properties.GU_A3); countryData.properties.Rank = "";//countryKilledData[currentCountryIndex].Rank; // carry on as before, using geodata from mapbox } else if(typeof(countryData) == "string"){ //the string will be an ISO code logIt("drawDeathsTable says " + countryData + " is a string") /// use country iso code to pull data from country table currentCountryISO = countryData; //currentCountryIndex = extractKilledCountryData(currentCountryISO); countryData = new Object(); countryData.properties = new Object(); countryData.properties.GU_A3 = currentCountryISO; countryData.properties.Rank = ""; countryData.properties.Country = countryKilledData[currentCountryIndex].Country; countryData.properties["Killed in 2023"] = countryKilledData[currentCountryIndex]['Killed in 2023']; zoomToBoundsKill(aopBounds[currentCountryISO].bounds); highlightCountry(currentCountryISO); } // end first if //logIt("drawDeathsTable running with countryData at " + JSON.stringify(countryData)); logIt("drawDeathsTable running with countryData at " + countryData.properties["Country"]); //var dataTemp = stateDetailsObj[stateName]; // uses js var var dataTemp = countryData; // remove anchor link var tableTemp = "
X Close
" + ""; tableTemp += ""; //tableTemp += ""; // generate title text with country and number killed tableTemp += ""; tableTemp += "

" + countryData.properties.Country + "

" + countryData.properties["Killed in 2023"] + " journalist" + (countryData.properties["Killed in 2023"] > 1 ? "s": "") + " Killed in 2023
" + countryData.properties["Killed in 2023"] + " journalist" + (countryData.properties["Killed in 2023"] > 1 ? "s": "") + " killed in 2023
"; //showDetails(); // reveals parent div // 2022 not needed because moved dtr out of detailbox // insert top level stats into table //document.getElementById("detailTextLeft").innerHTML = tableTemp; document.getElementById("killedCountryInfo").innerHTML = tableTemp; // create new element for country table var previousIndex = currentCountryIndex > 0 ? currentCountryIndex - 1 : countryKilledData.length -1; var nextIndex = currentCountryIndex + 1 " + previousCountryName + " | Show all | Next: " + nextCountryName + " > "; document.getElementById("deathsFooter").innerHTML = footerTemp; var countryFilterVal = countryData.properties.GU_A3; var dataTableTemp = ''; var numJournalist = 0; var numMediaWorker = 0; var totalCounter = 0; // loop through deaths data for(var x = 0; x"; }// end if } // row loop //var sText = deathsData.length == 1 ? "" : numMediaWorker == 0 || numJournalist == 0 ? "" : "s"; var sText = totalCounter
Name  URL  Outlet  Killed  Motive  Country  Country_ISO  
" + deathsData[x].Name + "" + deathsData[x].Outlet + "" + deathsData[x]["dateDisplay"] + "" + deathsData[x].Motive + "" + deathsData[x].Country_ISO + "
" document.getElementById("deathsTable").innerHTML = dataTableTemp; jQuery("#deathsFooter2").html(""); // scroll back to top of table document.getElementById("deathsTableContainer").scrollTop = 0; jQuery(".listScroll").scrollTop(0); // disable scroll zooming temporarily //if(map.scrollZoom._enabled == true){ //map.scrollZoom.disable(); //jQuery("#" + tgt).html("Enable scroll-to-zoom"); //} /// show detailTextRight Div document.getElementById("detailTextLeft").classList.add("none"); document.getElementById("detailTextRight").classList.remove("none"); // preparation jQuery('#killedCountryInfo #closeBox'). unbind('click'); /*jQuery("#killedCountryInfo #closeBox").on("click",function(){ hideDetails(); toggleListDisplay("killingsListContainer", "show"); map.flyTo(chapters["killings-sandbox"]); //showImprisonments(); }); */ // country detail close box goes to either country bounds in interactive // or to all country view with instructions in scroll jQuery("#killedCountryInfo #closeBox").on("click",function(){ logIt("closebox clicked from instantiation in drawDeathsTableOld") hideDetails(); jQuery("#detailTextRight").addClass("none"); // 2022 if(appState.viewMode == 'interact'){ //zoomToBoundsKill(aopBounds[personData.properties.Country_ISO].bounds);// no! //map.fitBounds(aopBounds[currentCountryISO].bounds); map.fitBounds(aopBounds[countryData.properties.GU_A3].bounds); scrollToAnchor("#interact"); showImprisonments(); } else { //map.flyTo(chapters["interact"]); scrollToAnchor("#killings-detail"); map.flyTo(chapters["killings-sandbox"]); toggleListDisplay("killingsListContainer", "show"); //zoomToBoundsKill(aopBounds[personData.properties.Country_ISO].bounds); } }); // hide other tabular displays toggleListDisplay("killingsListContainer", "hide"); toggleListDisplay("imprisonmentsListContainer", "hide"); // hide imprisoned legend jQuery("#imprisonedLegend").addClass("none"); // fyi causes doom loop scroll for country steps if having them if(appState.viewMode == 'interact'){ scrollToAnchor("#interact"); } else { //scrollToAnchor("#killings-sandbox"); } // may be redundant but trying to fix bug in list click not knowing what state //currentState = stateName; } // drawDeathsTableOld function hidePrisonersTable(){ hideDetails(); highlightCountry("Geoff"); } function drawPrisonersTable(countryImpDataTemp){ logIt("drawPrisonersTable running with countryImpDataTemp at " + countryImpDataTemp) var currentCountryISO; var currentCountryIndex; var currentCountryRank; if(typeof(countryImpDataTemp) == "object"){ // this used to assume that object was JSON feature data w geometry from vector map // but in 2023 it's only the tabular data taken from the json dictionary data object logIt("drawPrisonersTable says " + countryImpDataTemp + " is an object") // get array positon of country to draw footer links to other countries //currentCountryIndex = extractImpCountryData(countryData.properties.GU_A3); //currentCountryRank = countryImpData[currentCountryIndex].Rank; currentCountryISO = countryImpDataTemp.ISO; //currentCountryIndex = extractImpCountryData(countryData.properties.GU_A3); //currentCountryRank = countryImpData[currentCountryIndex].Rank; currentCountryRank = countryImpDataTemp.Rank; // carry on as before, using geodata from mapbox // if it is just the ISO, like from clicking a table row... fill in the data } else if(typeof(countryImpDataTemp) == "string"){ logIt("drawPrisonersTable says " + countryImpDataTemp + " is a string") /// use country iso code to pull data from country table currentCountryISO = countryImpDataTemp; //currentCountryIndex = parseInt(countryImpJson[currentCountryISO].RankAbs); //currentCountryIndex = parseInt(countryData[currentCountryISO].RankAbs); currentCountryIndex = extractImpCountryDataNew(currentCountryISO); /* currentCountryISO = countryData; currentCountryIndex = extractImpCountryData(currentCountryISO); countryData = new Object(); countryData.properties = new Object(); countryData.properties.GU_A3 = currentCountryISO; countryData.properties.Rank = countryImpData[currentCountryIndex].Rank; currentCountryRank = countryData.properties.Rank; countryData.properties.Country = countryImpData[currentCountryIndex].Country; countryData.properties["Imprisoned in 2023"] = countryImpData[currentCountryIndex]['Imprisoned in 2023']; */ // outline current country only map.setFilter('cpj-country-2023-outline', [ //'in', '==', //'GU_A3', 'iso_3166_1_alpha_3', currentCountryISO ]); zoomToBoundsImp(aopBounds[currentCountryISO].bounds); highlightCountry(currentCountryISO); } //logIt("drawPrisonersTable running with countryData at " + JSON.stringify(countryData)); //logIt("drawPrisonersTable running with countryData at " + countryData.properties["Country"]); var dataTemp = countryImpDataTemp; var tableTemp = "
X Close
" + ""; //tableTemp += ""; tableTemp += ""; //tableTemp += ""; tableTemp += ""; tableTemp += "

" + countryData.properties.Country + "

#" + currentCountryRank + " in 2023

" + countryData[currentCountryISO].Country + "

#" + countryData[currentCountryISO].Rank + " in 2023
" + countryData.properties["Imprisoned in 2023"] + " journalist" + (countryData.properties["Imprisoned in 2023"] > 1 ? "s": "") + " imprisoned in 2023
" + countryData[currentCountryISO]["Imprisoned in 2023"] + " journalist" + (countryData[currentCountryISO]["Imprisoned in 2023"] > 1 ? "s": "") + " imprisoned in 2023
"; showDetails(); // reveals parent div document.getElementById("prisonCountryInfo").innerHTML = tableTemp; // create new element for country table var previousIndex = currentCountryIndex > 0 ? currentCountryIndex - 1 : countryImpTableData.length -1; var nextIndex = currentCountryIndex + 1 " + previousCountryName + " | Show all | Next: " + nextCountryName + " > "; // 2022 remove links for more flexibility var footerTemp = "

" + previousCountryName + " | Show all | Next: " + nextCountryName + " >

"; document.getElementById("prisonersFooter").innerHTML = footerTemp; // have previous next buttons move away from country body text jQuery("#prevImpCountry, #nextImpCountry").on("click",function(){ if(appState.viewMode == 'interact'){ scrollToAnchor("#interact"); } else { //jumpToAnchor("#imprison-sandbox"); location.hash = "#imprison-sandbox"; } }); // have show all button move away country body text and zoom out jQuery("#impShowAll").on("click",function(){ if(appState.viewMode == 'interact'){ scrollToAnchor("#interact"); } else { //jumpToAnchor("#imprison-sandbox"); location.hash = "#imprison-sandbox"; map.fitBounds(imprisonmentBounds); } }); // insert prisoners table below stats table //prisonersTable //prisonersTable.params.filterArgs = [["EGY"]]; //prisonersTable.params.filterArgs[0][0] = countryData.properties.GU_A3; prisonersTable.params.filterArgs[0][0] = countryData[currentCountryISO].ISO; // scroll back to top of table document.getElementById("prisListContainer").scrollTop = 0; //initDataTables(); // would be more efficient to call redrawDataTAble but that's scoped out drawDataTable("prisonersTable", true); // disable scroll zooming temporarily if(map.scrollZoom._enabled == true){ //map.scrollZoom.disable(); //jQuery("#" + tgt).html("Enable scroll-to-zoom"); } /// show detailTextLeft Div document.getElementById("detailTextLeft").classList.remove("none"); document.getElementById("detailTextRight").classList.add("none"); // show imprisonments details jQuery("#detailTextLeft").fadeIn( 500 ); jQuery("#detailTextLeft").removeClass("faded"); // hide killings details jQuery("#detailTextRight").fadeOut( 500 ); // preparation jQuery('#prisonCountryInfo #closeBox'). unbind('click'); // country imprisonment detail close box goes to either country bounds in interactive // or to all country view with instructions in scroll jQuery("#prisonCountryInfo #closeBox").on("click",function(){ hideDetails(); if(appState.viewMode == 'interact'){ //zoomToBoundsKill(aopBounds[personData.properties.Country_ISO].bounds);// no! //map.fitBounds(aopBounds[currentCountryISO].bounds); // wider is better for imprisonment map.fitBounds(imprisonmentBounds) scrollToAnchor("#interact"); toggleListDisplay("imprisonmentsListContainer", "hide"); showKillings(); } else { impGoToInstructions(); toggleListDisplay("imprisonmentsListContainer", "show"); /*if(window.innerWidth RankCountryImprisoned in 2023"; document.getElementById("impListContainer").scrollTop = 0; //for(var x = 0; x " + countryImpData[x].Rank + "." + countryImpData[x].Country + "" + countryImpData[x]["Imprisoned in 2023"] + ""; tableContent += "" + countryImpTableData[x].Rank + "." + countryImpTableData[x].Country + "" + countryImpTableData[x]["Imprisoned in 2023"] + ""; } // end loop jQuery("#imprisonmentsListContainer").removeClass("none"); jQuery("#impCountryTable").html("" + tableContent+ "
"); document.getElementById("imprisonmentsListContainer").scrollTop = 0; } // purpose of this is to distinguish between mobile and desktop sandboxes so peple can see data without instructions blocking function impGoToSandbox(){ if( appState.viewMode == 'interact'){ scrollToAnchor("#interact"); // no window size screening } else { if(window.innerWidth Country" + "Related to work"+ "Killed" + "Total"; tableContent += ""; //for(var x = 0; x "; tableContent += ""; /*tableContent += countryKilledData[x].Country + "" + countryKilledData[x]["Confirmed"] + "" + countryKilledData[x]["Unconfirmed"] + "" + countryKilledData[x]["Killed in 2023"] + "";*/ tableContent += countryKilledTableData[x].Country + "" + countryKilledTableData[x]["Confirmed"] + "" + countryKilledTableData[x]["Unconfirmed"] + "" + countryKilledTableData[x]["Killed in 2023"] + ""; } // end loop jQuery("#killingsListContainer").removeClass("none"); jQuery("#killingsCountryTable").html("" + tableContent + "
"); document.getElementById("killListContainer").scrollTop = 0; } //https://stackoverflow.com/questions/8579643/how-to-scroll-up-or-down-the-page-to-an-anchor-using-jquery function scrollToAnchor(anchor_id){ logIt("scrollToAnchor running with anchor_id at " + anchor_id); var scrollOffset = jQuery(anchor_id).offset().top; //$('html,body').animate({scrollTop: tag.offset().top},'slow'); jQuery('html,body').animate({scrollTop: scrollOffset},'slow'); } function jumpToAnchor(anchor_id){ logIt("jumpToAnchor running with anchor_id at " + anchor_id); location.hash = anchor_id; } // new 12/15/2021 function displayPersonFromID(personID){ // was resolving 2023-0018 as 2005! // need to convert the id into a string //personID = personID.toString(); // nope, too late logIt("displayPersonFromID running with personID at " + personID); ///var killedFeatures = map.queryRenderedFeatures({ layers: ['cpj-killed-2022-dots'] }); // had to change 2023 dots to be rendered at 0-22, not 5-22 so query would work zoomed out // used opacity instead to swap between centroid circles and actual dots var killedFeaturesTemp = map.queryRenderedFeatures({ layers: ['cpj-killed-2023-dots'] }); logIt("displayPersonFromID says features (" + killedFeaturesTemp.length + ")"); logIt("displayPersonFromID says features is " + JSON.stringify(killedFeaturesTemp)); var personFeature; var personFound = false; for(var x = 0; x "; //var commaTemp = personData.properties.jobs == "" || personData.properties.Outlet == "" ? "" : ", "; var commaTemp = personData.properties.Outlet == "" ? "" : ", "; var jobsTemp = personData.properties.jobs == "" || typeof(personData.properties.jobs) == "undefined" ? personData.properties.type : personData.properties.jobs; //var headerCalc = 'header'; var headerCalc = "
X Close
" + "
" + imgTemp + "

" + personData.properties.Name + "

" + //personData.properties.jobs + commaTemp + jobsTemp + commaTemp + "" + personData.properties.Outlet + "
"+ "Killed " + personData.properties.dateDisplay + " in " + personData.properties["Location Display"] + "

"; var footerTemp = "

killings in " + personData.properties.Country + "

"; //var textCalc = personData.properties.body_text; var textCalc = personData.properties.profile; var bodyCalc = "
" + textCalc + "
"; jQuery("#detailBox").css("z-index",3); jQuery("#detailTextRight").removeClass("none"); jQuery("#killedCountryInfo").html(headerCalc); jQuery("#deathsFooter").html(footerTemp); jQuery("#deathsTable").html(bodyCalc); jQuery("#deathsFooter2").html("

View profile page »

"); // 2023 trap for gaza location if(personData.properties.Country_ISO == "ISR"){ map.setFilter('cpj-killed-gaza-locs-240207-bars', [ '==', 'Name', personData.properties["Loc-Rough"] ]); map.setFilter('cpj-killed-gaza-locs-240207-labels', [ '==', 'Name', personData.properties["Loc-Rough"] ]); } else { map.setFilter('cpj-killed-gaza-locs-240207-bars', [ '!=', 'Name', "geoff" ]); } // end if gaza // preparation jQuery('#detailTextRight #closeBox'). unbind('click'); // person view close box goes to parent country //jQuery("#detailBox #closeBox").on("click",function(){ jQuery("#detailTextRight #closeBox").on("click",function(){ // 2022 logIt("closebox clicked from instantiation in displayPerson") hideDetails(); if(appState.viewMode == 'interact'){ map.fitBounds(aopBounds[personData.properties.Country_ISO].bounds); showImprisonments(); // only in interactive mode scrollToAnchor("#interact"); } else { // need to make story scroll to anchor link killings-detail scrollToAnchor("#killings-detail"); drawDeathsTableNew(personData.properties.Country_ISO); hideImprisonments(); // only in scroll mode if(personData.properties.Country_ISO == "ISR"){ var paddingTemp; if(window.innerWidth 0){ countryString +=","; } countryString += "'" + countries[i] + "'"; } countryString += ""; //var myCountryFilter = ['match', ['get', 'GU_A3'],countries, true, false]; // works but with string literal only var myCountryFilter = ['match', ['get', 'iso_3166_1_alpha_3'],countries, true, false]; // works but with string literal only if(countries != "" && countries != undefined){ map.setFilter('cpj-country-2023-outline',myCountryFilter) } else { // highlight none //map.setFilter('cpj-country-2023-outline',['!=', 'GU_A3', "Geoff"]) map.setFilter('cpj-country-2023-outline',['!=', 'iso_3166_1_alpha_3', "Geoff"]) } }