What is preventing the installation of this Chrome extension?

I am struggling to install a few short and simple extensions on Chrome. The error message I receive about the 'manifest version' indicates that the issue might be due to outdated information. Since I lack experience in Chrome extensions and JavaScript, I am unable to fix them myself. These extensions were created for me by a friend some time ago.

Can someone provide guidance on how to correct these files?

Error:

The 'manifest_version' key must be present and set to 2 (without quotes). See developer.chrome.com/extensions/manifestVersion.html for details.

Extension files:

manifest.json for extension 1:

{
"content_scripts": [ {
  "exclude_globs": [  ],
  "include_globs": [ "*slavehack*index2.php\\?page=internet&openFolder=&var3=files&aktie=*&*=*" ],
  "js": [ "script.js" ],
  "matches": [ "http://*/*", "https://*/*" ]
} ],
"converted_from_user_script": true,
"description": "",
"key": "XKBlE2kyhcJNHGYLuLylZhjFVQV7puTEQbsFuGRcKoY=",
"name": "Slavehack Process Log Protector",
"version": "1.0"
}

script.js for extension 1:

// ==UserScript==
// @name           Slavehack Process Log Protector
// @include        *slavehack*index2.php?page=internet&openFolder=&var3=files&aktie=*&*=*
// @version                1.0
// ==/UserScript==
var allA = document.getElementsByTagName('a');
for (var i = 0; i < allA.length; i++) {
    if ( allA[i].innerHTML.match('Access logfile') ) {
        window.location.href = allA[i].href;
    }
}

manifest.json for extension 2:

{
  "content_scripts": [ {
  "exclude_globs": [  ],
  "include_globs": [ "*slavehack*index2.php\\?page=internet&var3=&aktie=FP&var2=*&transfer=*&tonumber=*&toip=*" ],
  "js": [ "script.js" ],
  "matches": [ "http://*/*", "https://*/*" ]
   } ],
   "converted_from_user_script": true,
   "description": "",
   "key": "WxQnzwPDzxXFW/TSZw6dNJJJSyVIXlub/QQGMlVtjbc=",
   "name": "Bank IP Log Crack Remover",
   "version": "1.0"
}

script.js for extension 2:

// ==UserScript==
// @name           Bank IP Log Crack Remover
// @include        *slavehack*index2.php?page=internet&var3=&aktie=FP&var2=*&transfer=*&tonumber=*&toip=*
// @version                1.0
// ==/UserScript==
var bankip = window.location.href.split('=')[window.location.href.split('=').length - 1]
window.location.href = 'http://www.slavehack.com/index2.php?page=internet&var2='+bankip.replace('#','')+'&var3=crack&var4=';

Any assistance would be greatly appreciated. Thank you!

Answer №1

The error message is pretty straightforward:

You need to have the 'manifest_version' key included and set to 2 (without quotation marks). Take a look at the details on developer.chrome.com/extensions/manifestVersion.html.

The documentation referenced gives a clear example right at the beginning of the page:

{
  ...,
  "manifest_version": 2,
  ...
}

The ellipsis indicate that some parts of the manifest file were left out for simplicity. You must open your manifest.json file, and add "manifest_version": 2 somewhere in the content.

For instance, you can insert a line before the "version" key and place the "manifest_version": 2 declaration there.

   ...
   <b>"manifest_version": 2,</b>
   "version": "1.0"
}

Make sure to include a comma at the end of the line. In the JSON data format, each name/value pair should be separated by a comma.

Answer №2

Make sure to include the following code in your 'manifest.json':

'manifest_version': 2

For instance:

{
    "name": "Choose a name for your extension",
    "version": "1.0",
    "description": "Provide a description of your project",
    "manifest_version": 2,
    "browser_action":{
       "default_icon": "icon777.png",
       "popup": "body.html"
    }
 }

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

Having trouble sending an array's JSON data to a web service using Angular

I am working with a table where each cell in the rows contains form fields. The table also has two buttons: one button adds a new row to the table, and the other sends all the rows. Below is the code snippet for adding new blank rows: $scope.attributes = ...

Launch a fresh fancybox once the previous one has exited

I am currently facing an issue with my password change process through a fancybox window. Whenever a user enters the wrong password, a "Wrong Password" iframe opens up. However, the challenge arises when I try to reopen the "Password Change" iframe after c ...

Struggling with dragging Vue.js modals?

I am currently utilizing the vue-js-modal library, and I'm encountering an issue with it. Whenever I set my modal to be draggable by using :draggable="true", I can drag it around but then I am unable to input any text in the form fields. It seems to c ...

Tips on concealing all classes except one through touch swiping

If you have a website with a single large article divided into multiple sections categorized as Title, Book1, Book2, & Book3, and you want to implement a swipe functionality where only one section is displayed at a time, you may encounter some issues. ...

Expanding functions consist of numerous components

How can I modify this script to work on multiple elements? For example, if a user clicks on a specific link (see demo) labeled "I'd like to expand the article linked here", only that particular link should expand an element, not all like it currently ...

Persist the checkbox value in the database and update the status of the label accordingly

I need a checkbox for user preference selection that is stored in a MySQL database for constant availability. The label should change to "Enabled" when the checkbox is selected and vice versa. Upon saving (submitting) the page, an alert message should disp ...

Concealing a field when the PHP post is devoid of content

On page1.php, there is a form that, upon submission, redirects to page2.php where the selected information is summarized. The code snippet below on page2.php retrieves this information. I am attempting to dynamically hide certain rows if the PHP post is e ...

Having trouble with a Pandas DataFrame - looking to filter by a JSON key that contains a date

I'm looking to filter this JSON data by date, but I'm struggling to figure out how. I've attempted different methods found online without success. Any help would be greatly appreciated. Below is my code snippet. import urllib.request import ...

Error connecting to the server at localhost on port 27017: Connection attempt unsuccessful

I'm having an issue that I can't seem to resolve, and I suspect it might be related to my connection string. Some of my classmates faced the same problem, but their connection string doesn't work for me. Any ideas on how to tackle this? SER ...

The React.js .map function encountered an error while trying to map the results from Firebase

As a newcomer to the realm of React and Firebase, I find myself struggling with arrays and objects. It seems like the way my data is formatted or typed does not play well with the .map method. Despite scouring Stack Overflow for answers, none of the soluti ...

Retrieving a result from a function call is a fundamental aspect of programming

I have a scenario where I am initiating a call from a controller within AngularJS. This call passes some data to a service in order to receive a response that needs to be conditionally checked. Controller patents.forEach(function(item){ // The "patents" ...

How can I send a JavaScript variable to a PHP function using an Ajax call?

I'm having trouble implementing an AJAX search form in WordPress that retrieves posts based on the search term being present in the post title. Below is the PHP function I've created for this purpose: function get_records_ajax($query) { $arg ...

limit stop choice

I'm working on modifying a script to limit the number of selections that can be made. Specifically, I want it to stop allowing selections once the total selected items reach or exceed 4. http://jsfiddle.net/dw6Hf/51/ $(function() { $(".selectabl ...

Could offering a Promise as a module's export be considered a legitimate approach for asynchronous initialization in a Node.js environment?

I am in the process of developing modules that will load data once and create an interface for accessing that data. I am interested in implementing asynchronous loading of the data, especially since my application already utilizes promises. Is it considere ...

What is the best way to utilize the forEach method in React to manipulate a navigation element containing multiple links?

Here is the code I'm trying to convert: document.addEventListener("scroll", function() { const links = document.querySelectorAll(".nav-link"); for (const l of links) l.classList.toggle('scrolling', window.scrollY &g ...

Numeric Input Box: Show gaps

I have numeric input boxes in my HTML/PHP/JS application where users will be entering numbers with 4 to 7 digits. However, I want the users to see spaces between every third digit for better readability. For instance, User types: 8000 Us ...

What is the best way to distinguish if users are accessing my Facebook app through an iframe or by directly entering the

If my Twitter app url is http://tw.domain.com/ and the app url is http://apps.twitter.com/demoapp/ I need to ensure that users cannot access the application url directly, they must view it within an iframe on Twitter. What method can I use to detect & ...

The syntax comparison between CommonJS and AMD modules in a modular AngularJS application

Apologies if this question has already been addressed, but I couldn't find any relevant information. Currently, I'm in the process of refactoring a large AngularJS application by creating components as AMD modules. The build process (grunt) utili ...

What is the process for "unleashing" the X Axis following the execution of chart.zoom()?

After setting the scroll strategy to setScrollStrategy(AxisScrollStrategies.progressive), I noticed that my chart was scrolling too quickly due to the fast incoming data. To address this, I decided to set a specific initial zoom level for the chart using c ...

What is the best way to utilize URL parameters to dynamically update a component's state within a class component

I am currently working on a React component that is making calls to two different API URLs, and the fetch operations are functioning as expected. However, I would like to utilize the URL handle structure, which looks like localhost://site/coins/[handle], a ...