Home Web Front-end JS Tutorial Code based on jquery to modify the current TAB display title_jquery

Code based on jquery to modify the current TAB display title_jquery

May 16, 2016 pm 06:14 PM
tab title

A friend proposed the following application scenario:
After clicking a link in the current tab, new content is displayed in the current tab, but the title content is still the title of the previous page and needs to be changed to a new title. Solution For example:
First add the following code to outlook.js:

Copy the code The code is as follows:

function changeCurrentTabTitle(oldtitle,newtitle,url){
var currTab = $('#tabs').tabs('getTab',oldtitle);
// or var currTab = $('#tabs ').tabs('getSelected'); //This can also be done
$('#tabs').tabs('update',{tab:currTab,options:{title:newtitle,content:createFrame(url) }});
}


This method receives two parameters: oldtitle is obviously the title of the current page, and newtitle is the title to be displayed on the new page
When clicked This method is called when the link jumps. Code such as:
Script Home
This solves the problem at the beginning .
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Article

R.E.P.O. Energy Crystals Explained and What They Do (Yellow Crystal)
2 weeks ago By 尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. Best Graphic Settings
2 weeks ago By 尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. How to Fix Audio if You Can't Hear Anyone
2 weeks ago By 尊渡假赌尊渡假赌尊渡假赌

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

Solve the problem that CentOS7's Tab key cannot complete commands Solve the problem that CentOS7's Tab key cannot complete commands Jan 17, 2024 pm 01:30 PM

Today I was doing an experiment on centOS and found that the customary tab key completion method used under Ubuntu could not be used. So I was very curious. After searching for information and testing it myself, I recorded the possible solutions as follows: 1) First, you need to Run the following command in the terminal: #yuminstallbash-completion//You can also use wildcard installation: yuminstallbash-c* or you can install some initialization package groups yum-ygroupinstallBaseCompatibilitylibrariesDebuggingToolsDial-upNetworkingsupppo

How to implement tab components and multi-tab pages in Vue? How to implement tab components and multi-tab pages in Vue? Jun 25, 2023 am 09:33 AM

With the continuous updating of front-end technology, Vue, as a popular front-end framework, has become the first choice of many developers. In actual projects, it is often necessary to use tab components and multi-tab pages to switch and manage different functional modules. In this article, we will introduce how to use Vue to implement a simple tab component and multi-tab page. 1. Implement a simple tab component. Create a Tab.vue component. Create a Tab.vue component in the project to display it.

How to solve the problem that the title of PPT file cannot be deleted How to solve the problem that the title of PPT file cannot be deleted Mar 26, 2024 pm 03:21 PM

1. Delete text When you click the text with the left mouse button, many neatly arranged white squares will appear around the text, which means that the [text/shape/graphic] has been selected. Once selected, the text can be easily deleted by simply pressing the [Delete] key on the keyboard. 2. The text or shape cannot be selected. After left-clicking [Text/Shape/Graph], the [Selected State] in step 1 does not appear. There are many reasons for this kind of problem. Take the master as an example, click the menu [View] on the screen, and find [Slide Master] in [Master View]. 3. In the master view, click on the left navigation page. After finding the [text/shape/graphic] that needs to be deleted, still click the left mouse button. After selecting, press [Delete] on the keyboard to delete.

What are the three ways to implement tab in Vue? What are the three ways to implement tab in Vue? Jan 29, 2023 pm 02:49 PM

There are three ways to implement tabs in Vue: 1. Control tab content switching through "v-show"; 2. Implement tab switching through the is feature and "keep-alive" cache in Vue; 3. Implement route switching through "router-link" .

CSS methods and techniques to achieve title text animation effects CSS methods and techniques to achieve title text animation effects Oct 20, 2023 am 09:00 AM

CSS methods and techniques to achieve title text animation effects require specific code examples. In web design and development, animation effects can improve user experience and increase the appeal and vitality of the page. Title text animation effect is a common design technique, which can make the title of the page more vivid and interesting. This article will introduce some CSS methods and techniques to achieve title text animation effects, and provide specific code examples. Gradient animation effect The gradient animation effect can change the color of title text from one color to another, creating a smooth transition effect.

Why can't alt+tab switch interfaces? Why can't alt+tab switch interfaces? Mar 09, 2023 pm 02:11 PM

The reason why alt+tab cannot switch the interface is that this command is disabled. The solution: 1. Turn on the computer, click the start menu, and select the run command; 2. Enter "regedit" in the blank bar to the right of the start, and click OK; 3. Enter the Registry Manager and find the "AltTabSettings" option; 4. Double-click "AltTabSettings", modify the value data in the opened option to "00000001", and click "Confirm".

How to include a title in a fieldset in HTML? How to include a title in a fieldset in HTML? Aug 23, 2023 pm 05:01 PM

Use the <legend> tag to include a title. The HTML<legend> tag is used to define a title for the <fieldset> tag. It supports the following attributes − Attribute value description Aligntopbottomleftright Deprecated − Specifies content alignment. Example You can try running the following code to implement the <legend> tag in HTML −<!DOCTYPEhtml&g

Empire CMS title modification dilemma? Try these coping strategies! Empire CMS title modification dilemma? Try these coping strategies! Mar 12, 2024 pm 05:27 PM

Empire CMS title modification dilemma? Try these coping strategies! In the process of building a website using Empire CMS (EmpireCMS), it is inevitable that you will encounter the need to modify the article title. However, some users may encounter some difficulties, such as not knowing how to modify the title, or the title displaying abnormally after modification, etc. Today we will share some strategies to deal with these problems and provide specific code examples, hoping to help everyone solve the title modification dilemma. 1. Modify the title of a single article If you want to modify the title of a certain article

See all articles