Questions tagged [kohana-3]

Kohana 3 is a HMVC (Hierarchical Model-View-Controller) PHP framework that places security, scalability and rapid development at its forefront.

Kohana is an HMVC (Hierarchical Model-View-Controller) PHP5 framework that provides a set of components for building web applications.

Kohana 3 is the first version of Kohana that supports HMVC.


Useful links


Related tags

846 questions
6
votes
3 answers

Kohana 3 ORM - grouping where conditions with parentheses

I'm trying to run a query through the ORM like this: SELECT * from table where (fname like 'string%' or lname like 'string%') AND (fname like 'string2%' or lname like 'string2%'); Here's what i have so far: $results =…
Dexter
  • 5,666
  • 6
  • 33
  • 45
6
votes
1 answer

Kohana sample CRUD application

I'm completely new to this framework and I'm trying to find some sample CRUD application to get started with Kohana 3. There is a tutorial and information in the unofficial Kohana 3 Wiki (http://kerkness.ca/wiki/doku.php), but even there, there are…
titel
  • 3,454
  • 9
  • 45
  • 54
5
votes
1 answer

How to show username in the url route in Kohana PHP Framework?

I am working on Kohana PHP framework. I want to show a 'username' instead of controller name in my URL. For example, username = james then how to show http://localhost:3000/james instead of http://localhost:3000/scrapbook/index => ...…
user990479
  • 115
  • 2
  • 8
5
votes
1 answer

Kohana 3 ORM compares 2 columns in where clause

I need to generate query like that : SELECT * FROM `table1` WHERE `date1` < `date2` I can't find how to compare 2 columns in kohana ORM. Here date2 is considered as text. $foo = ORM::factory('model1')->where('date1','<','date2'); How can I write…
Thierry R.
  • 138
  • 1
  • 1
  • 6
5
votes
2 answers

Creating Helper in Kohana 3.1

I am following documentation http://docs.kohanaphp.com/general/helpers . But these steps are not working in kohana 3.1 . I can't find any documentation about helper in kohana 3.1 . how I can create my own helper class in kohana ?
Vivek Goel
  • 22,942
  • 29
  • 114
  • 186
5
votes
3 answers

How do I build a UNION query with ORDER BY and GROUP BY in Kohana's query builder?

I'm trying to build a UNION query using Kohana's query builder. Everything works fine until I add a GROUP BY or ORDER BY clause. Here is the code I'm using (simplified): $query1 = DB::select('p.name') ->from(array('person', 'p')) …
Darryl Hein
  • 142,451
  • 95
  • 218
  • 261
5
votes
2 answers

3.1 Auth working example of login/logout controller methods?

Does anyone happen to have a working example of Auth in 3.1? I've been trying to get this to work, but have not had any luck. New to Kohana, first attempt is 3.1. Found Bonafide, but don't need it since I'm starting w/ 3.1. Been using examples from…
steveint
  • 71
  • 1
  • 3
5
votes
1 answer

Kohana 3 Command line output buffering?

I am using Kohana 3 and I have a controller that extends Kohana_Controller. I call it from the command line using: php /path/to//index.php --uri="url/path" It works just fine, but this particular script takes a long time and during the execution I…
Craig Nakamoto
  • 2,075
  • 2
  • 18
  • 19
5
votes
3 answers

How to setup a custom 404 page for a Kohana v3 app

How can this be done? I'm trying to do this for about half an hour and it's getting pretty annoying. You would this this should be an basic and easy thing to setup for a framework like this. I hope maybe there's an easy way i missed, because i'm…
daniels
  • 18,416
  • 31
  • 103
  • 173
5
votes
1 answer

htaccess to escape percent (%) from URL

Having percent sign inside URL, returns bad request (error 400) to the browser. I have a filename that have percent (%) sign, resides at server. Original File name: 204153_20090605_Aluminiumacetotartraat_DCB_oordruppels_1,2%.pdf URL in browser…
Asif Mulla
  • 1,652
  • 2
  • 22
  • 32
5
votes
2 answers

Kohana 3 auth module, getting users with 'staff' or 'manager' role

I'm learning the framework, and now building an application using it. I need to get all users that have 'user' or 'staff' role, but I couldn't find about it on the documentation. Help anyone? (I think it's more an ORM problem the the auth module)
leonardys
  • 504
  • 4
  • 10
5
votes
2 answers

What is the correct way to get values from the query string in Kohana 3

Just curious as to what is the 'Kohana' way of getting variables from the query string? The best that I could come up with is parsing the $_GET var with the Arr class. Anybody have a better way to do this? // foo?a=1&b=2 function…
Gerry Shaw
  • 9,178
  • 5
  • 41
  • 45
5
votes
1 answer

Kohana V3 Auth module user_token functionality

Could anybody brief about user_token functionality in Auth module? What is a use and how this incorporates in Auth module?
Asif
  • 833
  • 2
  • 14
  • 23
5
votes
4 answers

Kohana ErrorException [ Fatal Error ]: Call to undefined method Request::redirect()

I'm using Kohana 3.3.0 and i have a controller which is supposed to save blog articles to a database then redirect to the homepage, my code is as follows:- class Controller_Article extends Controller { const INDEX_PAGE =…
boeing
  • 302
  • 7
  • 19
5
votes
1 answer

Kohana 3.2 'advance' ORM joins

This is Database ERD that I use in application. I'm using Kohana 3.2. What I want to achieve is to generate menu for currently logged user. Each user can have many roles, so based on that user should get menu populated with modules (that are in…
dzeno
  • 510
  • 1
  • 5
  • 16
1 2
3
56 57