NotFoundHttpException in RouteCollection.php line 161: laravel 5.3

In laravel i am trying to link to a particular page but it is showing NotFoundHttpException in RouteCollection.php line 161: Here is my code please help me figure out the mistake in my view : {{ link_to_route('deleteFile', 'Delete', [$file->resid]) }} in routes : Route::get('/deleteFile/{$id}', ['as'=>'deleteFile','uses'=>'FilesController@deleteFile']); and in controller :

RouteCollection.php中的NotFoundHttpException行161:laravel 5.3

在拉拉维尔,我试图链接到一个特定的页面,但它正在显示 RouteCollection.php中的NotFoundHttpException行161: 这是我的代码,请帮我弄清楚这个错误 在我看来 : {{ link_to_route('deleteFile', 'Delete', [$file->resid]) }} 在路线上: Route::get('/deleteFile/{$id}', ['as'=>'deleteFile','uses'=>'FilesController@deleteFile']); 并在控制器中: class FilesController extends Controller{ pub

How to register user on ejabbered using php code

I found a code from stack over flow to execute the register command in ejabberd xmpp chat server using php. (Create ejabberd user from PHP) But when i execute the file i got error: "sudo: unknown user: ejabberd" "sudo: unable to initialize policy plugin" I am runing this code on my ubuntu(14.04 LTS 64-bit) machine The php code i am using as follows: <?php $usern

如何使用php代码在ejabbered上注册用户

我发现了一个来自堆栈溢出的代码,用php执行ejabberd xmpp聊天服务器中的register命令。 (从PHP创建ejabberd用户) 但是当我执行文件时出现错误: “sudo:未知用户:ejabberd”“sudo:无法初始化策略插件” 我在我的ubuntu(14.04 LTS 64位)机器上运行这段代码我使用的php代码如下: <?php $username = 'tester'; $password = 'testerspassword'; $node = 'myserver.com'; exec('sudo -u ejabberd /us

How to secure a password from being readable at the client?

I need to pass username and password which is at the server to my web chat clients javascript function. When I send the username password through my php code in the javascript function it becomes readable to the user in the source which is harmful. Please share your solutions. I get the user name password from the server A on the client and then submit those credentials to a javascript funct

如何确保密码不被客户端读取?

我需要将服务器上的用户名和密码传递给我的网页聊天客户端javascript函数。 当我在javascript函数中通过我的php代码发送用户名密码时,它对于有害的源代码中的用户是可读的。 请分享您的解决方案。 我从客户端的服务器A获取用户名密码,然后将这些凭证提交给一个javascript函数,然后再连接到另一个服务器B.它就像Facebook和Gmail聊天工作,但他们做什么来将他们的用户凭据传递给他们的JavaScript客户端连接到聊天服务器没

Ideas on IM/chat system for social network website

I'm creating a social network website, and I need a IM/chat solution for it. The conversations are only one-on-one, with the users being able to chat only with their friends (ie Facebook chat - no channels, no rooms ...). The website is made in CodeIgniter(PHP) with MySQL database. Probably will be put on VPS (Linux), so I might have control on the environment. Also, it is expected to h

社交网站上IM /聊天系统的想法

我正在创建一个社交网站,我需要一个IM /聊天解决方案。 对话只是一对一的,用户只能与他们的朋友聊天(即Facebook聊天 - 没有频道,没有房间...)。 该网站使用MySQL数据库在CodeIgniter(PHP)中制作。 可能会被放在VPS(Linux)上,所以我可能会控制环境。 此外,预计将有超过10万名用户。 所以,我需要一些关于如何进行聊天的想法。 到目前为止我的想法: 每隔X秒进行一次Ajax轮询(对于网站来说这不是一个好的

Need to develop a PHP

I was trying to develop a web based chat system using PHP. I created one with the combination of jQuery and PHP but this setup is using lot of network bandwidth as it is continuously sending / receiving data to check whether a new message has been received or not (currently every 1 second). So I need to develop a system that will automatically display the message once a message is received from

需要开发一个PHP

我正在尝试使用PHP开发基于Web的聊天系统。 我用jQuery和PHP的组合创建了一个,但是这个设置使用了很多网络带宽,因为它不断发送/接收数据来检查是否收到了新消息(当前每1秒)。 所以我需要开发一个系统,一旦收到来自另一端的消息,就会自动显示消息,而不需要向服务器发送请求以查看是否收到新消息。 我在很多地方读到,这可以使用Jabber完成。 我对这个jabber技术非常陌生,所以任何帮助使用PHP创建基于Jabber的新聊天

Goal: to create a decent Online IM Chat

Online chat is deceptively difficult due to the stateless nature of http and the web in general, causing such hurdles as session timeouts, users opening multiple windows and different accounts being signed in on one browser window. There is also the problem of users closing the browser window and logging out and such things, which make dealing with undelivered messages quite tricky. Are there

目标:创建一个体面的在线即时通讯聊天

由于http和网络的无状态特性,在线聊天看起来很困难,导致会话超时等障碍,用户打开多个窗口并在一个浏览器窗口中登录不同帐户。 还有用户关闭浏览器窗口并注销等问题,这使得处理未传送的消息非常棘手。 有没有什么好的文章能够描述别人如何优雅地解决这些问题? 请随时写下您自己的想法,以便如何通过最大的健壮性实现像Facebook或Gmail这样的即时通讯。 是否有任何体面的代码库/写入与本地托管的Jabber服务器集成来实

How to secure MySQL from SQL Injection?

Possible Duplicate: Best way to prevent SQL Injection in PHP This is my SQL Query and I want to make it SQL injection free $q1="insert into ecat_user(login_id,password,fullname,gender,disp_name,dob,"; $q1.="street_addr,city,country,zip,email,aol,msn,icq,yahoo,homepg_link,homepg_caption,description,"; $q1.="legal_guardian,phoneno,promotioncode,user_type,height,weight,chest,waist,inseam,eye

如何从SQL注入保护MySQL?

可能重复: 防止PHP中的SQL注入的最佳方法 这是我的SQL查询,我想让它免费的SQL注入 $q1="insert into ecat_user(login_id,password,fullname,gender,disp_name,dob,"; $q1.="street_addr,city,country,zip,email,aol,msn,icq,yahoo,homepg_link,homepg_caption,description,"; $q1.="legal_guardian,phoneno,promotioncode,user_type,height,weight,chest,waist,inseam,eyecolor,haircolor,"; $q1.="shoesize,biceps,co

pdo and hash to prevent sql injection

Possible Duplicate: Best way to prevent SQL Injection in PHP I'm trying to insert user's inputs into a database. Is this pdo and hash secure enough: $dbh = new PDO("mysql:host=hostName; dbname=dbName", "user", "pass"); if(isset($_POST['Submit'])) { $user = $_POST['user']; $pass = $_POST['pass']; $salt = substr(str_replace('+', '.', base64_encode(sha1(microtime(true), true))), 0, 22

pdo和哈希来防止sql注入

可能重复: 防止PHP中的SQL注入的最佳方法 我试图将用户的输入插入到数据库中。 这个pdo和hash是否足够安全: $dbh = new PDO("mysql:host=hostName; dbname=dbName", "user", "pass"); if(isset($_POST['Submit'])) { $user = $_POST['user']; $pass = $_POST['pass']; $salt = substr(str_replace('+', '.', base64_encode(sha1(microtime(true), true))), 0, 22); $hash = crypt($pass, '$2a$12$' . $salt); $mail = $_

Preventing SQL Injection in dynamic SQL

I asked this question earlier Preventing SQL Injection in dynamical SQL, but was not clear which resulted in the question being closed, and was later told in the comments that I should ask the question again. A requirement of my PHP/MySQL application is to allow all users to create their own multiple "views" of the data. These views are not traditional SQL views, but performed by the

在动态SQL中防止SQL注入

之前我在动态SQL中提出了防止SQL注入的问题,但不清楚导致问题被关闭的原因,后来在评论中告诉我应该再次提出这个问题。 我的PHP / MySQL应用程序的一个要求是允许所有用户创建自己的多个数据“视图”。 这些视图不是传统的SQL视图,而是由应用程序执行。 例如,用户可以创建一个视图并提供以下标准: 视图的名称。 每页所需的记录。 使用下拉菜单显示哪些列。 结果的任何过滤器。 第一个下拉菜单用于选择列,第二个

Logic

Im building a commission/referral app in codeigniter but unsure how to code a particular feature. In my database, i have a table called users with a structure like this (simplified version) user_id user_name user_referredby 1 Billy Bob null 2 Janes Smith 1 3 Test Person 2 4 Another Person 3 5 Peter Green 4 6

逻辑

我在codeigniter中构建了佣金/推荐应用程序,但不确定如何编写特定功能。 在我的数据库中,我有一个叫做用户的表,就像这样(简化版) user_id user_name user_referredby 1 Billy Bob null 2 Janes Smith 1 3 Test Person 2 4 Another Person 3 5 Peter Green 4 6 Jess White 5 7 Sally Smith 6 8