laravel-4

Laravel Migration Showing Blank Page, No Debug Screen

社会主义新天地 提交于 2020-01-07 06:47:10
问题 I have a site in Laravel that's working perfectly fine here: http://beta.modernassemb.ly but when I try and move it to: http://modernassemb.ly, it just shows a blank screen (everything is the same) I'm not even sure how to go about debugging this, as the standard debug screen doesn't come up. The error log just shows: [Mon Jun 16 00:36:56 2014] [error] [client 222.239.78.246] File does not exist: /var/www/198.211.105.63 Where the IP 198.211.105.63 is the IP of the site. When I echo statements

Laravel 4 Queue - [InvalidArgumentException] There are no commands defined in the “queue” namespace

99封情书 提交于 2020-01-07 03:39:47
问题 I'm using Laravel 4 + Beanstalk + Supervisor on a CentOS 6 VPS. It was already a pain to install both beanstalk and supervisor on the VPS, but I got through it (I have done this same installation on my local server, a Macbook Pro, and it's working fine there). I want to take advantage of Laravel 4's Queues and Beanstalk to send email asynchronously. I have made a "program" for supervisor that basically runs the command php artisan queue:listen --env=production but the process associated to

How to sort an Eloquent subquery

為{幸葍}努か 提交于 2020-01-07 02:45:29
问题 I have two tables conected: Team and member. The models are connected by a n:m relationship and in my team views I will make a foreach loop to get the members of said team like this: @foreach( $team->teammember as $member ) {{ $member->firstname }} {{ $member->lastname }} @endforeach So far everything is great and working, my issue is, how do I get the members list sorted by lastname? In my controller I'm not getting the members, since the connection is done via the model, I can only sort the

Laravel 4.1 folder Layouts not available in views folder

别说谁变了你拦得住时间么 提交于 2020-01-06 21:12:41
问题 Does Laravel 4.1 comes with a layouts folder inside views or should it be created manually? I made one myself but now my templates aren't working. FYI installed Laravel with composer. I want implement the below code template, consist 2 files: user.blade.php(placed in app/views/layouts/user.blade.php) <!doctype html> <html> @section('lib') <head> <meta charset="utf-8"> <link href="//netdna.bootstrapcdn.com/twitter-bootstrap /2.3.1/css/bootstrap-combined.min.css" rel="stylesheet"> <style> table

Laravel 4.1 folder Layouts not available in views folder

你说的曾经没有我的故事 提交于 2020-01-06 21:12:24
问题 Does Laravel 4.1 comes with a layouts folder inside views or should it be created manually? I made one myself but now my templates aren't working. FYI installed Laravel with composer. I want implement the below code template, consist 2 files: user.blade.php(placed in app/views/layouts/user.blade.php) <!doctype html> <html> @section('lib') <head> <meta charset="utf-8"> <link href="//netdna.bootstrapcdn.com/twitter-bootstrap /2.3.1/css/bootstrap-combined.min.css" rel="stylesheet"> <style> table

MethodNotAllowedHttpException thrown after user logs in and get redirected

不打扰是莪最后的温柔 提交于 2020-01-06 19:49:08
问题 Was testing around and this is the behaviour: I have a page with a form, anyone can use it (no need to be logged in), when submitting you get redirected to the next one for which you need to be logged in as a user. Here is the route: /* | Request Booking (POST) */ Route::post('/booking/request-pay-booking', array( 'as' => 'booking-request-pay-booking-post', 'uses' => 'BookingController@postRequestPayBooking' )); Everything works as long as you are already logged in BEFORE. If you are public

Laravel 4 Response download issue

ぐ巨炮叔叔 提交于 2020-01-06 18:00:53
问题 I am trying to force a download of a zip file that contains a few PDFS. return Response::download($zipperPath, NULL, array('content-type' => 'application/zip')); This will force the download.. however the files are corrupted. If I repair the zip it fixes the issue with the re-built zip. I am not sure if maybe I am missing something in the headers or if this is an issue with Laravel? any help is appreciated, thanks. 回答1: $response = Response::download($file, NULL, $headers); ob_end_clean();

Laravel 4.2 serving mp3 - not windable

不想你离开。 提交于 2020-01-06 15:16:15
问题 I have some problems with serving mp3's with Laravel 4.2 I have some files which should be played by flashplayer. public function get($filename) { $file = new Symfony\Component\HttpFoundation\File\File(storage_path().DbConfig::get('system.upload_dir').'/'.DbConfig::get('system.upload_music').'/'.$filename); $response = Response::make(file_get_contents(storage_path().DbConfig::get('system.upload_dir').'/'.DbConfig::get('system.upload_music').'/'.$filename)); $response->header('Content-Type',

Laravel 4.2 serving mp3 - not windable

ⅰ亾dé卋堺 提交于 2020-01-06 15:15:26
问题 I have some problems with serving mp3's with Laravel 4.2 I have some files which should be played by flashplayer. public function get($filename) { $file = new Symfony\Component\HttpFoundation\File\File(storage_path().DbConfig::get('system.upload_dir').'/'.DbConfig::get('system.upload_music').'/'.$filename); $response = Response::make(file_get_contents(storage_path().DbConfig::get('system.upload_dir').'/'.DbConfig::get('system.upload_music').'/'.$filename)); $response->header('Content-Type',

Routing in Laravel 5 error

 ̄綄美尐妖づ 提交于 2020-01-06 14:09:56
问题 Routing in Laravel5 seems to be a major problem for me. I was hoping to follow this example using the composer mapping https://mattstauffer.co/blog/upgrading-from-laravel-4-to-laravel-5#namespacing-controllers To avoid any issues with models or facades. But when I route to this : Route::get('school/test', 'school\SchoolController@index'); Error ReflectionException in Container.php line 776: Class school\SchoolController does not exist The SchoolController is in the HTTP/controllers/school