首页 \ 问答 \ 在JavaScript中循环“历史”?(Loop over “history” in javascript?)

在JavaScript中循环“历史”?(Loop over “history” in javascript?)

有没有办法在javascript中查找“历史”对象以查找历史记录中的特定页面?


Is there a way to loop over the "history" object in javascript to find a specific page in the history?


原文:https://stackoverflow.com/questions/1946963
更新时间:2022-08-18 19:08

最满意答案

这里是关于这个主题的伟大文章:

http://softsurfer.com/Archive/algorithm_0107/algorithm_0107.htm

我认为这里不需要博士学位:)


Here is the great article on the subject:

http://softsurfer.com/Archive/algorithm_0107/algorithm_0107.htm

I think that PhD is not required here :)

相关问答

更多
  • 这里是关于这个主题的伟大文章: http://softsurfer.com/Archive/algorithm_0107/algorithm_0107.htm 我认为这里不需要博士学位:) Here is the great article on the subject: http://softsurfer.com/Archive/algorithm_0107/algorithm_0107.htm I think that PhD is not required here :)
  • 我认为实现你想要的最简单的方法是创建一个非常轻量级的保留模式绘图系统 。 跟踪所有用户在Stroke标记的位置,并在PictureBox的Paint事件的这些位置绘制圆点/圆/线/橡胶夹/任何位置。 在mousedown +移动事件上,调用PictureBox的Invalidate()函数。 原始图片必须涂在底下或“OnPaintBackground”类(IMO更优雅)。 本教程应该让你开始: http://www.bobpowell.net/backtrack.htm I think the easies ...
  • 方法.convert()需要关于显示/窗口颜色深度的信息(8位,16位,24位或32位) 所以首先你必须使用set_display()创建这个显示/窗口 编辑:完整的代码 - 它执行set_mode()然后执行background = pygame.image.load(...).convert() set_mode() background = pygame.image.load(...).convert() ,甚至self.image = pygame.image.load(...).convert() ...
  • 经过多次搜索,我发现了 g = Graphics.FromImage(Signature); g.Clear(Color.White); 在图形绘图中添加白色背景修复了问题 After more searching i found that g = Graphics.FromImage(Signature); g.Clear(Color.White); Adding a White Background to the Graphics Drawing Fixed The Problem
  • 你的self.backButton永远不会被定义。 将您的init函数更改为以下内容(我假设您的所有CCSprite定义实际上都是属性: -(id) init { if( (self=[super init]) ) { self.touchEnabled = YES; self.accelerometerEnabled = YES; CGSize winSize = [[CCDirector sharedDirector] winSize]; ...
  • 声明x.labelFormatter = nil; 消除了自动轴标签。 如果您提供标签格式化程序和标签文本样式,则轴将根据标签策略自动创建刻度和标签。 The statement x.labelFormatter = nil; eliminates the automatic axis labels. If you supply a label formatter and label text style, the axis will create ticks and labels automaticall ...
  • 您目前在每个轮廓周围绘制边框,并且findContour将在每个连接的白色或黑色组件周围找到轮廓,其中图片中有很多部分。 所以我要做的第一件事是在阈值图像上对所有噪音进行一些形态学操作:做一些打开和关闭 ,这两者都是扩张和侵蚀的组合。 在你的情况下,像cvDilate(2次); cvErode(4次); cvDilate(2次) 这应该将所有的白色斑点合并为一个光滑的斑点,但中间的黑洞将保留。 您可以按大小找到合适的一个,但使用CV_RETR_EXTERNAL而不是CV_RETR_TREE调用findCon ...
  • 请参阅此处的答案以访问像素。 然后,我将迭代数据,将值设置为0xFF ..或0x00 ..取决于阈值。 -S! See this answer here for accessing the pixels. Then, I would iterate over the data, setting the values to 0xFF.. or 0x00.. depending on a threshold. -S!
  • 子弹正在被吸引。 但是由于你编写代码的方式,你永远不会看到它! 首先绘制所有子弹,然后立即用白色填充屏幕。 这种情况发生得如此之快,以至于您无法看到它们。 试试这个,你会明白我的意思: for m in missiles: if m.y < (screen.get_rect()).height and m.y > 0: m.draw(screen) m.y += 1 else: missiles.pop(0) # screen.fill((2 ...
  • //put this line at the top of your cpp file #define CC_VERIFY_TYPE(__OBJECT__,__CLASS_TYPE__) assert(dynamic_cast<__CLASS_TYPE__>(__OBJECT__)) //these lines in your code CCObject* child; CCARRAY_FOREACH(m_pChildren, child) { CC ...

相关文章

更多

最新问答

更多
  • 获取MVC 4使用的DisplayMode后缀(Get the DisplayMode Suffix being used by MVC 4)
  • 如何通过引用返回对象?(How is returning an object by reference possible?)
  • 矩阵如何存储在内存中?(How are matrices stored in memory?)
  • 每个请求的Java新会话?(Java New Session For Each Request?)
  • css:浮动div中重叠的标题h1(css: overlapping headlines h1 in floated divs)
  • 无论图像如何,Caffe预测同一类(Caffe predicts same class regardless of image)
  • xcode语法颜色编码解释?(xcode syntax color coding explained?)
  • 在Access 2010 Runtime中使用Office 2000校对工具(Use Office 2000 proofing tools in Access 2010 Runtime)
  • 从单独的Web主机将图像传输到服务器上(Getting images onto server from separate web host)
  • 从旧版本复制文件并保留它们(旧/新版本)(Copy a file from old revision and keep both of them (old / new revision))
  • 西安哪有PLC可控制编程的培训
  • 在Entity Framework中选择基类(Select base class in Entity Framework)
  • 在Android中出现错误“数据集和渲染器应该不为null,并且应该具有相同数量的系列”(Error “Dataset and renderer should be not null and should have the same number of series” in Android)
  • 电脑二级VF有什么用
  • Datamapper Ruby如何添加Hook方法(Datamapper Ruby How to add Hook Method)
  • 金华英语角.
  • 手机软件如何制作
  • 用于Android webview中图像保存的上下文菜单(Context Menu for Image Saving in an Android webview)
  • 注意:未定义的偏移量:PHP(Notice: Undefined offset: PHP)
  • 如何读R中的大数据集[复制](How to read large dataset in R [duplicate])
  • Unity 5 Heighmap与地形宽度/地形长度的分辨率关系?(Unity 5 Heighmap Resolution relationship to terrain width / terrain length?)
  • 如何通知PipedOutputStream线程写入最后一个字节的PipedInputStream线程?(How to notify PipedInputStream thread that PipedOutputStream thread has written last byte?)
  • python的访问器方法有哪些
  • DeviceNetworkInformation:哪个是哪个?(DeviceNetworkInformation: Which is which?)
  • 在Ruby中对组合进行排序(Sorting a combination in Ruby)
  • 网站开发的流程?
  • 使用Zend Framework 2中的JOIN sql检索数据(Retrieve data using JOIN sql in Zend Framework 2)
  • 条带格式类型格式模式编号无法正常工作(Stripes format type format pattern number not working properly)
  • 透明度错误IE11(Transparency bug IE11)
  • linux的基本操作命令。。。