JavaScript Ext is not declared

I've designed a webpage with tabs, and everything was working fine in our development environment. However, when we moved it to the staging environment, we started experiencing errors this morning that I'm not sure how to resolve as my JavaScript knowledge is limited.

Here's the error message:

Ext is not defined
[Break On This Error]
Ext.get(newboxes[x].id+"_href").removeClass("selected");

Below is the script causing the issue:

<script language="javascript">
function showonlyone(thechosenone) {
      var newboxes = document.getElementsByTagName("div");
            for(var x=0; x<newboxes.length; x++) {
                  name = newboxes[x].getAttribute("name");
                  if (name == 'newboxes') {
                        if (newboxes[x].id == thechosenone) {
                        newboxes[x].style.display = 'block';
                        Ext.get(newboxes[x].id+"_href").addClass("selected");
                        } else {
                        newboxes[x].style.display = 'none';
                        Ext.get(newboxes[x].id+"_href").removeClass("selected");
                        }
                    }
            }
}
</script>

And here is the code structure:

<!-- Tabs section starts -->
 <div class="fulltab">  
    <div class="tabheader">
        <ul class="tabs">
            <li><a id="tab01_href" href="javascript:showonlyone('tab01');" class="selected">Applications</a></li>
            <li><a id="tab02_href" href="javascript:showonlyone('tab02');" >Features</a></li>
            <li><a id="tab03_href" href="javascript:showonlyone('tab03');" >Testimonials</a></li>
        </ul>
    </div>
    <div style="clear:both;"></div>
<div id="contentDiv">
      <div class="tab-content-wrap" style="background: url(../images/block3.png) no-repeat;">
        <div name="newboxes" id="tab01" class="tab-content" style="display: block;">
            <br /><br />
             <img class="alignleft" style="float:left; margin:5px 11px;border:1px solid #6B6B6B;" src="../images/tt_ss.jpg" alt="" width="400px" /><br />
                        <u><b>STUFF</b></u>
                        <ul style="margin-left:440px;list-style-type:disc;padding:0;margin-top:0;">
                        <li>STUFF</li>
                        <li>STUFF</li>
                        <li>STUFF</li>
                        </ul>
        </div>

        <div name="newboxes" id="tab02" class="tab-content" style="display: none;">
        <div style="margin-left:10px; width:700px;">
            <br /><br />
            <strong>STUFF</strong><br />
            <ul style="margin-left:10px; margin-top:0px;list-style-type:disc;padding: 0;">
                    <li>STUFF</li>
                    <li>STUFF</li>
            </ul>
        </div>
        </div>
    <div name="newboxes" id="tab03" class="tab-content" style="display: none;">
         <div style="padding-right:25px;padding-top:10px;">
            <ul>
                <p>STUFF</p>
                <p>STUFF</p>
            </ul>
         </div>
        </div>
    </div>
    <div style="clear:both;"></div>
</div>
</div>
    <!-- Tabs End -->

I could really use some assistance with this situation!

Answer №1

To properly integrate Ext JS into your webpage, you will need to include the appropriate version of Ext JS based on your requirements. If you are considering using Ext JS 3, you can easily link the CDN-hosted copy of Ext JS 3.4 by adding this code snippet to the head section:

<script type="text/javascript" src="http://cdn.sencha.io/ext-3.4.0/ext-all.js"></script>

If your page functions correctly after adding this script, you might want to explore an Overview of Ext JS, or consider upgrading to Ext JS 4. It's important to note that Ext JS has specific licensing agreements in place.

Answer №2

Fortunately, we were able to resolve the problem by identifying that the development environment was retrieving a file that was not present in the staging environment. With the assistance of the original developers, we managed to rectify this issue successfully. Grateful for everyone's help!

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

FoxyWeb Requests: Utilizing XMLHttpRequest in Firefox Extensions

While I've come across plenty of examples on how to create xhr requests from Firefox Add-ons, I'm currently exploring the new WebExtensions framework (where require and Components are undefined) and facing an issue with sending a simple XmlHttpRe ...

A guide on how to efficiently update and submit a reactive form with a single click of the submit button in Angular

Currently, I have a view component setup where clicking the edit button directs me to the register component for form updates using patchvalue. The issue that I am facing is that when I update and register the form using the same button, it creates anothe ...

Issue with knockout view - unable to remove item from view after deletion

I'm facing an issue with my code that deletes an exam from a list of exams on a page, but the deleted exam still shows up until the page is manually refreshed. This pattern works correctly on other pages, so I don't understand why it's not w ...

Transforming into a serialized division

I am working on creating a custom WISYWIG editor that generates a div with specific inner elements. The goal is to design the div (along with its inner structure), serialize it, store it in a database as a string or JSON format, and later insert it into th ...

Adjust the marginLeft and marginRight values in a JavaScript statement within a Highcharts configuration

Is there a way to adjust the chart marginLeft and marginRight using Highcharts, and then redraw it in JavaScript? I am looking to change the chart margin dynamically at different points in my code. http://jsfiddle.net/ovh9dwqc/ I attempted to do this wit ...

Load the page's content gradually, without needing to wait for all the content to be fully loaded

I am facing an issue with a webpage that displays 10 different items, each of which has a slow loading time. Currently, the entire page waits for all 10 items to fully load before displaying anything. I am interested in finding out if it is feasible to sh ...

What is the process of converting code to JavaScript and React?

There are two methods defined as shown below. const handleClick = React.useMemo(() => !isRunning ? (items: string | string[]) => { if(Array.isArray(items)){ startRun({ items: items }); } else ...

Guide on implementing asyncWithLDProvider from Launch Darkly in your Next.js application

Launch Darkly provides an example (https://github.com/launchdarkly/react-client-sdk/blob/main/examples/async-provider/src/client/index.js) showcasing how to use asyncWithLDProvider in a React project (as shown below). However, I'm struggling to integr ...

The @Input() function is failing to display or fetch the latest value that was passed

I am currently working on an angular project, and I've encountered a situation where I'm attempting to send a value from a parent component to a child component using the @Input() decorator. Despite my efforts, the child component continues to di ...

Encountered an Error: The JSON response body is malformed in a NextJS application using the fetch

Running my NextJS app locally along with a Flask api, I confirmed that the Flask is returning proper json data through Postman. You can see the results from the get request below: { "results": [ [ { "d ...

The Material-ui paper component fails to display on the screen

The material-ui paper component is implemented on my homepage and functioning correctly. However, when navigating to another page and returning to the homepage, the paper component disappears, leaving only text rendered. Can you help me identify the issue? ...

I just obtained the height measurement of a dynamic table - now I must transfer this height value to a different element

Recently, I encountered a situation where I needed to get the height of a dynamic table using code like this: var table = document.getElementById("test"); document.write(table.offsetHeight); However, the challenge arose when I realized that I also needed ...

The Angular filter is failing to display the category value

My issue lies in adding a filter to display categories, as my setCurrentCategory function is not showing any value but instead displaying 'undefined'. The goal is to show the category for each person. I'm using ng-click to pass to my functio ...

Tips for Choosing the Right Objects in Vue.js

I have the following code that combines all objects in a person and stores them in an array called Cash:[] this.cash = person.userinvoice.concat(person.usercashfloat) Inside person.usercashfloat, there is an element called validate which sometimes equals ...

I keep encountering the following issue: "It seems that the file requested at /images/crown.png is not recognized as a valid image, as it was received as text/html; charset=utf-8."

I encountered an issue while utilizing Next.js. Here is the code snippet where the error occurred: import React from "react"; import { Container, Col, Row } from "react-bootstrap"; import Image from "next/image"; export defaul ...

The ::before pseudo element is malfunctioning when used in the makeStyles function

I am currently utilizing the makeStyles function in React, but I seem to be facing an issue where the content within the ::before pseudo-element is not displaying. Strangely enough, when the content is an image it works fine, but text does not render. Jus ...

During the execution of a function, the React list remains empty which leads to the issue of having

Having difficulty preventing duplicate values because the item list is always empty when the function is called, even though I know it contains items. The function in question is AddToCart, being passed down to a child component named inventoryModal. The ...

Selecting the appropriate technology or library for incorporating user-defined text along a designated path within established areas

I am currently developing an admin dashboard with CodeIgniter 2 that allows the admin to upload custom images, particularly ones with blank spaces for text overlay. The goal is to enable regular users to add their desired text in specific areas defined by ...

Issue with Pop Up not redirecting correctly after a successful login in Azure AD

I recently integrated Azure AD with my web application. When clicking on the login window, a pop-up appears with the URL . It prompts for the Azure AD username and password. However, after successfully logging in, a code is returned as a parameter but the ...

Displaying Vue v-for data in console.log

One interesting issue arises when printing a list in HTML and checking the output in HTML versus in console.log. It seems that the output is duplicated in the console. After some investigation, I made the following observations: Not showing the product ...