var_dump()和print_r()输出不同的值(var_dump() and print_r() output different values)
我运行这个代码:
<?php $test = $_SERVER['HTTP_HOST']; var_dump($test); print_r($test); die();
我运行这个代码:
<?php $test = $_SERVER['HTTP_HOST']; print_r($test); var_dump($test); die();
为什么
print_r()
和var_dump()
不能在case 1的$ test的值上达成一致?关于我如何抵达这里的背景。 我正在运行laravel / homestead vm框,并且正在使用Browsersync。 Browsersync创建一个我连接到的代理(
localhost:3000
),它指向laravel / homestead vm(192.168.10.10
)。 代理在请求通过时会更改Host
头的值。I run this code:
<?php $test = $_SERVER['HTTP_HOST']; var_dump($test); print_r($test); die();
I run this code:
<?php $test = $_SERVER['HTTP_HOST']; print_r($test); var_dump($test); die();
Why can't
print_r()
andvar_dump()
agree on the value of $test in case 1?For context on how I arrived here. I am running a laravel/homestead vm box, and I'm using Browsersync. Browsersync creates a proxy (
localhost:3000
) that I connect to, which points to the laravel/homestead vm (192.168.10.10
). The proxy changes the value of theHost
header when the request passes through it.
原文:https://stackoverflow.com/questions/41743221
最满意答案
我不认为你只能显示修改后的文件,但你可以对所有文件进行排序,以便将修改后的文件放在各自文件夹的顶部。
//控制资源管理器中文件和文件夹的排序顺序。 除默认排序外,您还可以将订单设置为“混合”(组合文件和文件夹),“类型”(按文件类型),“修改”(按上次修改日期)或“文件首先”文件夹)。
"explorer.sortOrder": "modified",
但是,这只是在他们的文件夹,所以你仍然需要去每个文件夹,所以它仍然需要一些工作。
当然,你的
source control
按钮只会显示修改过的文件。I don't think you can only show modified files but you can sort all the files so that it puts the modified files at the top of their respective folders.
// Controls sorting order of files and folders in the explorer. In addition to the default sorting, you can set the order to 'mixed' (files and folders sorted combined), 'type' (by file type), 'modified' (by last modified date) or 'filesFirst' (sort files before folders).
"explorer.sortOrder": "modified",
However, that is only within their folders so you still have to go to each folder so it still takes some work.
Of course, your
source control
button will show only modified files.
相关问答
更多-
我不确定这是否会有所帮助,或者您愿意使用新版本,但我的环境和问题完全相同。 我所做的是我卸载了旧的TFS电动工具(在控制面板/程序和功能中以“Microsoft Team Foundation Server”前缀和/或“Microsoft Visual Studio Team Foundation Server”列出)并安装了一个较新的版本是RTM。 您可以在http://www.microsoft.com/en-nz/download/details.aspx?id=35775下载它们,并按照下列顺序安装 ...
-
这不是资源管理器特定的,这是NTFS相关的。 有关一些规则,请参阅http://support.microsoft.com/kb/299648 https://web.archive.org/web/20080219020154/http://support.microsoft.com/kb/299648 。 注意:修改的时间可以通过文件系统选项禁用,所以你不应该依赖它。 任何建议的可靠方法将不胜感激。 This is not explorer specific, this is NTFS-related. ...
-
您可以使用/select参数简单地启动explorer.exe ,详见本知识库文章 : Explorer /select,C:\TestDir\TestApp.exe You can simply start explorer.exe with the /select argument, as detailed in this Knowledge Base article: Explorer /select,C:\TestDir\TestApp.exe
-
将您的应用程序转换为服务并将其设置为自动启动。 另外,还有在线工具可以将任意exe作为服务运行。 自己写一个很简单。 如果您的应用程序需要与桌面交互并创建UI,则需要您的服务才能在相应的桌面上启动该exe。 为此,可以使用WTSEnumerateSessions查找交互式用户会话,WTSQueryUserToken以获取其令牌,然后使用CreateProcessAsUser以该用户的身份在正确的桌面上启动应用程序。 Convert your application to a service and set ...
-
在Eclipse中关闭项目资源管理器中已修改文件的排序(Turn off sorting of modified files in Project Explorer in Eclipse)[2023-05-29]
在项目资源管理器中 ,默认的排序/排序是文件之前的主文件夹和次要字母。 显然,按时间顺序排序来自Project Explorer扩展。 要禁用不需要的Project Explorer扩展,请执行以下操作: 在Project Explorer的视图菜单中选择Filters and Customization ... 在“ 过滤器和自定义”对话框的“ 内容”选项卡中, 取消选中不需要的扩展程序,以便在您的情况下显示“ 同步元素” In the Project Explorer the default sorti ... -
解决方案资源管理器中的“显示所有文件”按钮基于每个项目工作:切换按钮只会影响项目节点下文件的可见性,该节点是当前所选(或最后选择)文件的父节点,这是可以理解的可能会导致用户意外的行为(我个人会重新设计解决方案资源管理器以拥有2个工具栏:一个用于解决方案范围的选项,另一个位于下方,用于每个项目选项。 有些项目没有“包含”或“排除”文件的概念,例如“网站项目”(与“Web应用程序项目”相对),其中文件系统中的所有文件在树视图中都可见 - 或者在Visual C ++项目中,“显示所有文件”按钮切换到“虚拟”项目 ...
-
在Source Control Explorer中,您可以比较文件夹: 从那里,使用日期版本指定要比较的内容: In Source Control Explorer you can compare folders: From there, use the Date version to specify what you want to compare:
-
我不认为你只能显示修改后的文件,但你可以对所有文件进行排序,以便将修改后的文件放在各自文件夹的顶部。 //控制资源管理器中文件和文件夹的排序顺序。 除默认排序外,您还可以将订单设置为“混合”(组合文件和文件夹),“类型”(按文件类型),“修改”(按上次修改日期)或“文件首先”文件夹)。 "explorer.sortOrder": "modified", 但是,这只是在他们的文件夹,所以你仍然需要去每个文件夹,所以它仍然需要一些工作。 当然,你的source control按钮只会显示修改过的文件。 I ...
-
将文件添加到源代码控制与将文件添加到项目不同。 你也应该看到源代码管理上的文件。 为了能够在解决方案资源管理器中查看文件,您需要通过“添加现有项目”选项将文件添加到现有项目中。 Adding files to source control is not the same thing with adding files to a project. You are supposed to see the files on source control also. To be able to see the fi ...
-
SCSS文件未在Visual Studio的解决方案资源管理器中分组(SCSS files not grouped in Solution Explorer in Visual Studio)[2022-01-26]
手动编辑项目文件或使用这个漂亮的Visual Studio扩展: 手动技巧是编辑项目文件并将DependentUpon元数据添加到要嵌套显示的每个文件中:Foo.1.cs 相关文章
更多- nutch与起点R3集成之笔记(四)
- javax.imageio.IIOException: Can't create output stream!的解决方案
- nutch与起点R3集成之笔记(二)
- R简单数据分析
- 在Hadoop集群上运行R程序--安装RHadoop
- nutch与起点R3集成之笔记(一)
- 请问起点R3能否做到完全支持MultiCore?
- Hadoop控制输出文件命名
- nutch与起点R3集成之笔记(三)
- INSERT INTO blog_appitem (user_id,appid,app_secret,is_valid) VALUES (1, 'wxf415741de036114c','48e1e345fd5f11c93af18ff1714c7f78',1)
最新问答
更多- 获取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的基本操作命令。。。