三级动态列表
我在这个脚本上花了两个小时,最后我看到了几乎完整的代码,但我有一些问题。
这是完整代码(PHP)http://robertr.pastebin.com/S4XcmC1f 我在那里写了评论,这样你就可以很容易地理解那里发生了什么。
这是我得到的源代码(HTML) http://robertr.pastebin.com/EMWQnGvt
正如您在源代码中看到的那样,第 16 行关闭了第 15 个打开的 div,第 48 行和第 47 行之间也发生了同样的情况。
我只是不明白,我怎么能对我的代码说,不要再次打印上个月关闭的 div,因为现在已经是新年了,不应该再去那里了。
请帮我。我累极了。
I worked like two hours on this script, and finally I see almost the complete code, but I have some issues with it.
Here is whole code (PHP) http://robertr.pastebin.com/S4XcmC1f
I wrote comments there, so you could easily understand, whats happening there.
And here is the source, which I got (HTML) http://robertr.pastebin.com/EMWQnGvt
As you can see at source, line 16 closes 15th opened div, and the same happens between line 48 and 47.
I just don't get it, how I could say to my code, to NOT print that last month closing div again, because this is already new year, and it shouldn't go there any more.
Please, help me. I'm exhausted.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
第 77 行应该是 elseif。
更改
为
Line 77 should be an elseif.
change
to