应用程序每次都在加载 [英] App is loading each time

查看:22
本文介绍了应用程序每次都在加载的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有 flex 的网络应用程序.它的 swf 文件附加在 tabview 上.意味着页面上有 5 个标签.在选项卡 5 上附加了一个 swf 文件.

I have web application of flex. It's swf file is attached on a tabview. Means there are 5 tabs on the page. On the tab Five a swf file is attached.

当我单击五个选项卡时,它会加载 flex 应用程序的主 mxml 文件的 init 方法.有什么办法可以让我们每次点击五个标签时停止加载它.

When I click on five tab it load the init method of main mxml file of flex application. Is there any way so we can stop to load it every time when we click on Five tab.

此应用程序在加载应用程序时从服务器获取数据.但我不想每次点击标签时一次又一次地发送请求.

This app get the data from server when load the application. But I don't want to send the request again and again when click on tab everytime.

推荐答案

使用 <a href=""> 显示您的选项卡可能会使它们在每次点击时重新加载.而是尝试使用脚本解决方案来设置每个选项卡的 display 值.遍历所有这些并隐藏除点击的那一个之外的每一个.

Using <a href=""> to display your tabs is probably making them reload with each click. Instead try a script solution to set the display value of each tab. Loop through them all and hide every one except the one clicked on.

这样你只加载一次.

看起来您正在使用 JQuery.一些可能的答案:

looks like you are using JQuery. Some possible answers:

这篇关于应用程序每次都在加载的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆