@miles j,
There is a post by mcurry
http://www.pseudocoder.com/archives/2008/10/06/accessing-user-sessions-from-models-or-anywhere-in-cakephp-revealed/
where is shows how to access the auth component using static method
calls.
I was trying to find a easier way to access session from only the cart
That's exactly what I meant, and I think it was John's point when he
answered my very first question.
So if I use link together with url (and true of course) everything
should work out fine, that's what you mean right? Even for non root
sites, right?
cheers
Lorenzo
euromark wrote:
but are you re-using sql dumps?
Because I'd aim at using either sql dumps and possibly sql table update
statements (which I've done in the past) or cake generated schema files
(which should be the cake way).
cheers
Lorenzo
Miles J wrote:
They require shells (or at least what I
That's nice to hear :)
I had already started taking a look at the shell code and it looked to
me as well that most of the code could be shared to be used also inside
a controller.
It'd be nice to isolate that code so that it can be used in the shell
code and also in the controller code.
exactly
but what is the point of creating all urls full?
usually you only do that with urls that are sent in emails or pointed
out to bookmark on the website...
all other links can stay relative to root...
i didnt understand you right away
i thought you needed to do that only for some urls, not
Hi... I have an issue about multiple send...my view call a function
called simplesendmail:
[code]
function sendSimpleMail($id = null) {
$list = $this-Content-query(SELECT * FROM mails WHERE sub =
'1');
$data = $this-Content-find($id);
/*
Hey,
When I was developing countycriminal.com and identityalert.org we ran
into a very similar issue. What we ended up doing was just naming the
components something different than the model's.
With my latest project theeasyapi.com I did the same thing. This time
though I was more aware of the
i have a file input box to attach user's photo using e($form-file
('User.photo'));
but when i post form, i get following array,
Array
(
[User] = Array
(
[photo] = foo.png
)
)
instead i should get the image details regarding image name, type,
tmp_name, size like
Okay, let me be more specific in hopes of a response.
My database.php file contains the following class statement:
class DATABASE_CONFIG {
var $default = array(
'driver' = 'mysql',
'persistent' = false,
'host' =
Hi there,
Thanks for your messages. It helped me finding how to do what I want
to achieve.
So the solution is to set ?php $_SESSION['Config']['language'] =
'fr_fr'; ? to the view of the part I wanna display in French (yes I
have another view just for this part since it's AJAX generated).
This
Is it possible to automagically update 'modified' field in a
'belongsTo' table when a table is updated.
my example is this: I have two tables with 'modified'
fields...'families' and 'family_members'. models are Family hasMany
FamiyMember, FamilyMember belongsTo Family.
When I edit an existing
i would use a behavior ModifyUpdatable or something
that checks if there are any parent relations and if so triggers the
update of the timestamps
for performance issues you could manually define the parent relations
to be modified
so it can update right away instead of checking on existing
yes, exactly only for some urls: say that a page with urls is thought to
be php included on another external site, then the links in the included
page need to be absolute otherwise they would refer to the including
site and they would be dead links.
cheers
Lorenzo
euromark wrote:
sure
that would be a scenario where you'd use it
how do you include a foreign page via php?
usually this is not permitted from the file system / php
or do you mean like an iframe / widget?
On 25 Jan., 17:23, Lorenzo Bettini bett...@dsi.unifi.it wrote:
yes, exactly only for some urls: say
I have a vendors config, and now i am trying configure a plugin
vendors.
In app_controller, i have sucess with this:
Configure::write('pluginPaths', CAKE_CORE_INCLUDE_PATH . DS.
'vendors' . DS. 'plugins');
But is not cool for behaviors and helpers...
Thanks,
Celso
Check out the new CakePHP
I have some connected models: e.g. (made up example):
Post-Comment-Author-Address
My controller's index action creates an array using a model find
function using the containable behaviour - let's call the output
$postSummary.
I have a form that displays data from across the $postSummary array:
I haven't used debug in a while...
when I put it in a view it outputs debug data as it should to the
page. However when I put a debug(...) in a controller or model no
debug output appears on the page.
I've also tried echo, print, Debugger::trace() and none of these give
any output. The output
What does the error msg say? That UsersController is missing, or
something else?
Are your usernames limited to lowercase letters only and no digits?
And you might want to pass the ID to your action:
Router::connect(
'/hp/:id/',
array('controller' = 'users', 'action' = 'homepage'),
usually it is printed before the html tag starts
in a normal browser environment it would display as ugly code at the
very top
maybe its somehow hidden in your case (some css rule?)
but it should still be in the html output (open the source of the page
to confirm this)
On 26 Jan., 01:53, Rick
After finding many posts on HABTM relationships not supported across
databases, I thought I would share my solution. I added an option to
the HABTM config called 'useDbConfig' for specifying which database
the HABTM table is stored in. For example, I have 'system_districts'
linked to
20 matches
Mail list logo