Love Fuel?
Donate
About
Forums
Discussions
Login
FuelPHP Forums
Ask your question about FuelPHP in the appropriate forum, or help others by answering their questions.
WanWizard
a.k.a. WanWizard
Discussions
4
Comments
8242
Activity
Form with Multiple Submit Buttons
This would have been a lot shorter:
Comment by
WanWizard
June 2013
permalink
Sentry 2.0 or NinjAuth ?
Check the dev-docs: http://fuelphp.com/dev-docs/packages/auth/ormauth/intro.html It also contains the OpAuth documentation, and full examples of an Auth and an OAuth controller.
Comment by
WanWizard
June 2013
permalink
Sentry 2.0 or NinjAuth ?
Neither of them? Use the standard Auth package instead, and use the Ormauth driver set, which now comes with OAuth integration? The OAuth integration is similar to the way Ninjauth works btw...
Comment by
WanWizard
June 2013
permalink
Select one many to many per item
An ORM gives you object oriented access to database data. This implies that the resultset from a query must be compliant with the model's definition. So you can't just run any query and return whatever result is produced as model objects…
Comment by
WanWizard
June 2013
permalink
Theme info file name
Eh, I would guess no. I'll have a look. edit: it is a typo, the dot between theme and info should not be there.
Comment by
WanWizard
June 2013
permalink
Select one many to many per item
That query will not fetch any author information, since you haven't specified it should. However, ORM supports lazy loading, so as soon as you access the relation ( ->author ) on a Post object, the ORM detects it doesn't have them yet, …
Comment by
WanWizard
June 2013
permalink
Firing Raw Sql Queries
DB::query();
Comment by
WanWizard
June 2013
permalink
Crazy memory usage on simple query with profiling.
You should never use ORM for bulk operations. ORM hydrates the result and creates an object for every row in the resultset. And it caches all results, so even after destruction of $result these objects remain in memory. This query means you now ha…
Comment by
WanWizard
June 2013
permalink
Use Twig with Theme class instance
It that works, I don't see why not.
Comment by
WanWizard
June 2013
permalink
Use Twig with Theme class instance
If you use Twig via the Parser package, it works transparently for everything that uses views. I'm not a Twig user, so I can't comment on specific functionality, but I can imagine this might be an issue, since Twig internal logic is used …
Comment by
WanWizard
June 2013
permalink
How to remove Set-Cookie from headers with REST implementation
You can't do that. If you open FF, Chrome, Safari and IE from the same computer (for example when you're testing), you'll have 4 valid session records on the same IP. There is also no relation between Session (which is meant to creat…
Comment by
WanWizard
June 2013
permalink
Image from above root
The entire point of placing the code outside of the docroot is that no browser can access the files anymore. This implies that you can't put any files there that the browser MUST be able to access. So you have to either use a technique like yo…
Comment by
WanWizard
June 2013
permalink
What does it mean in Profiler documentaion?
Hmm... Very good question. I assume it means "the state of the [performance of the] code", but I have to agree it's an odd sentence. I think wat is meant is that because it is a built-in tool, anyone working on the application has i…
Comment by
WanWizard
June 2013
permalink
Many To Many. Find by field in 'through' table
You want to limit what exactly? You don't limit a specific table, you limit the result set of a query. ORM is designed to keep results consistent, so in a query that includes relations, by default it will either include a parent with all it…
Comment by
WanWizard
June 2013
permalink
Fuel 1.6 oil error
A rights issue? Check if fuel/core/classes/error.php exists and is readable. PHP version >= 5.3.3 ?
Comment by
WanWizard
June 2013
permalink
How to remove Set-Cookie from headers with REST implementation
If you don't what that record there, you could do a Session::destroy() if you encounter an "access denied" situation...
Comment by
WanWizard
June 2013
permalink
How to remove Set-Cookie from headers with REST implementation
The session class creates a new session every time you open one, but no existing one can be found. It is not a "dupe" effect, it is creating something that should be there (because you load a session driver, you indicate you need session…
Comment by
WanWizard
June 2013
permalink
Many To Many. Find by field in 'through' table
difference between get() and get_one() is that the first returns an array of results (always, also if there is only one), and the second adds a LIMIT 1, and always returns a single result (or null if none found). If you have multiple criteria, I as…
Comment by
WanWizard
June 2013
permalink
Multiple distributions, different databases, without virtual servers
You can also do it in your app bootstrap. Currently that sets the environment based on the environment variable, and if not present to "development". But you can use any logic there to determine a custom environment. It all depends on wh…
Comment by
WanWizard
June 2013
permalink
Specific Session Never Expire
You can not manually update the session table. Data in it is part of the control structure used internally, when the session is written all columns are updates (as you have noticed). Since this happens in the shutdown event, after you code has been …
Comment by
WanWizard
June 2013
permalink
Modules and Crypt
You're running quite an old release, you may bump into all kinds of issues that have long since been solved.
Comment by
WanWizard
June 2013
permalink
Many To Many. Find by field in 'through' table
You should be able to just use where('tags.id', '=', 1) in your query. It's obvious it gives you only one tag, you select it on primary key, so there can only be one. If you need posts for a tag, you need to run your que…
Comment by
WanWizard
June 2013
permalink
How to remove Set-Cookie from headers with REST implementation
I'll think about a configuration item, don't think that is a problem. As to Input, that might be used quite early in the boot process, same is true for Config. This means overloading is only possible in the app bootstrap. if you want to k…
Comment by
WanWizard
June 2013
permalink
Using composer packages with FuelPHP
You don't need to do that, as of 1.6 FuelPHP already uses Composer, and this is all setup. Just add your package to the existing composer.json file that is in your project root, and off you go...
Comment by
WanWizard
June 2013
permalink
How to remove Set-Cookie from headers with REST implementation
Hmm... Thought I implemented that, but it turns out only in my head... I've fixed it, you can now pass the plain session id as a string.
Comment by
WanWizard
June 2013
permalink
More Comments
Howdy, Stranger!
It looks like you're new here. If you want to get involved, click one of these buttons!
Sign In
Apply for Membership
About
Username
WanWizard
Joined
January 2011
Visits
2,368
Last Active
11:42AM
Roles
Administrator