Hi Dominik
Unfortunately, this was the best thing i could find and what i implemented
in the end
In case of the assertion where i want to verify if someone is the owner of a
resource i did these things:
* I created a ResourceWithOwnerInterface that demands a method getOwnerId()
* Any entity
I've been able to come up with a working solution, using the doctrine events.
Within these events i do an (additional) acl-isAllowed() call which will
trigger the assertion, but this time with the resource that is a doctrine
entity. It works ... but i'm not really happy with it:
1) I have to
i'm creating a zend framework 2 application and i'm sort of trying to
implement what is explained here:
http://ralphschindler.com/2009/08/13/dynamic-assertions-for-zend_acl-in-zf
The demonstration that the code works is really nice, but it doesn't really
apply to how a framework (utilizing mvc)
Hi Michael
Thanks for the response. However, i'm afraid it didnt really help.
Everything works fine, except the assertion-part. My Problem is this:
1. De resource (the blog-post) is loaded in the controller. This works fine.
2. The acl-check is done _before_ the controller loads the blog-post.
Hi Richard
Sounds interesting and where it concerns database _changes_ i think it's
also possible. I already have an abstract controller class with a method
writeDbChanges() that takes a Zend-Form as argument. This form as a
doctrine entity bound to it, so i see a lot of possibilities there.
The
BillKarwin wrote:
In general, you can do this only if your form and your database table
are trivial. For example, no multi-value form fields, no multi-value
data elements, and form fields have a one-to-one mapping to database
columns with the same data types and same names, etc.
I recently started to use Zend_Form in a backend/admin part of an application
where data in the database can be managed. I realized i was duplicating lots
of code where it came to validating processing the form and modifying the
database accordingly. I tried to centralize as much code as
Jader Augusto wrote:
I had to create the 'guestbook' controller; i used the zf tool to create
it and then edited accordingly to the guide, but when i lanched the
page here's what i get:
---
Fatal error: Class 'Application_Model_Guestbook' not found in
I can't help you with converting HTML, but i can help you with the alignment
problem:
http://devshed.excudo.net/scripts/php/source/excudo+pdf+textblock
--
View this message in context:
http://n4.nabble.com/Zend-Pdf-add-special-markup-tp1018366p1099957.html
Sent from the Zend Framework mailing
Manuel Kiessling wrote:
[...] I expect to have presentable code by the
end of next week.
As mentioned before, the interesting question then will be: is this
really a tool, or is it generic enough to have it implemented as
part of a framework like ZF. Either way, we are really
You can use the clearIdentity() method in Zend_Auth to get rid of the data
associated with the authorization that is in the persistent storage.
If you're also looking for a pre-build way to modify the session time of
this identity: that doesn't exist (as far as i know). But it would only
require
What you're looking for doesn't exist (yet) in ZF PDF
I wrote a class some time ago though, that will at least solve part of your
problems (that of multiple lines)
The multiple page problem you will still need to solve yourself though, but
these two variables (in my code) will help you get
This is not yet supported by ZF:
http://framework.zend.com/issues/browse/ZF-314
So you will either have to find a php class that has this support so you can
have a look how they do it, or create this support by looking at the PDF
specifications
funkyfly wrote:
Hi,im starting to use
Ehask71 wrote:
With the new way I wrote my Acl.php plugin I am now forced to create all
the Acl rules for the members now. A side effect yes but one I can deal
with. Im sure as I play with it more I will find a better way :)
You should consider trying to solve this with 1
rcastley wrote:
My ACL implementation already uses a database for storing roles,
resources etc. but on each action these calls are made to the database
and I am wondering how to slim this down.
You can slim it down by cashing the values from the database; for example,
using memcache
An other alternative would be to store only the database-values in the cache
function loadResources()
{
// try cache
// if not available or ttl expired - load from database and store in
cache
}
function loadRoles()
{
[...etc]
Saves you space in the cache, deserialization
Bob O wrote:
I am stumped, if anyone can point me in a good direction where i can find
solid docs on using Zend validation and filters from an ini file that
would be super..Im not a Zend Guru, so sometimes deciphering what is being
presented is frustrating.
Hi Bob O
I doubt there are
I think you meet most if not all of your requirements if you would put
everything in an INI file and load them using
http://framework.zend.com/manual/en/zend.config.adapters.ini.html
For caching you could use memcache for example
-
http://devshed.excudo.net http://devshed.excudo.net
--
Ralph Schindler-2 wrote:
Right, as I mentioned, I might rethink the design of the two database
system
for your application. It might prove easier to put a column inside of
your
tables that would mark a row as 'admin' or not.
I agree 100%.
Duplicating (part of) your database structure
I think i would use a date-filter first, that converts the date into a
specific format and then try to validate that specific format. If the filter
is not able to recognize the format, then it won't validate.
Dealing with different kinds of formats is more a responsibility of a filter
than a
Cristian Bichis-3 wrote:
Hello,
I have one question while working with a Zend_Config_Ini.
I need to assign values like that:
elements.ENCODING.options.multiOptions.UTF-8 = UTF-8
is this correct ?
I think it is. As far as i know the illegal characters are: { } | ~ ! [ (
) , none
Anees wrote:
[...]
But i need to store the file into a location in server
how i can do this?
with 'the file' you mean the attachment?
What is your problem exactly? Don't you know the php-command for opening and
writing to a file? Are you concerned about security? etc.
-
dele454 wrote:
Thanks for the tips. But i CAN'T apply any of them now. The design has
been approved and i need to i implement things as they are. 'Over
engineered' - I dont care. As long my code works as expected. I simply
want to pass my PHP array into my javascript function. - very
This very simple script:
require_once 'Zend/Pdf.php';
$pdf = new Zend_Pdf();
$page1 = new Zend_Pdf_Page(Zend_Pdf_Page::SIZE_A4);
Results in the following error:
Fatal error: Uncaught exception 'Zend_Pdf_Exception' with message 'Cloning
Zend_Pdf_Page object using 'clone' keyword is not
Have a look at the paragraph 35.5.4: Text Drawing
http://framework.zend.com/manual/en/zend.pdf.drawing.html
It takes an optional argument for the character encoding which defaults to
the current locale. I think that is what is causing your problem
Jani Hartikainen wrote:
Hey all
I've
http://www.nabble.com/Converting-html2pdf-with-Zend_PDF--td7401506.html
ranfow wrote:
Does anyone has solution on converting html to pdf using Zend_Pdf?:-)
-
http://devshed.excudo.net http://devshed.excudo.net
--
View this message in context:
Hi valugi
Let's review your code first
You're using Zend_Registy in your example, but i'm not sure why. I think
you're confusing it with the Role-Registry? Zend_Registry is a different
thing and not part of Zend_Acl.
Also, you forget to instantiate proper roles and resources (through
I think your articles should implement the Resource_Interface and your users
should implement the Role_Interface. The article/resource will have
knowlnedge about who its creator is and since both objects are passed to the
assertion you could then simple do something like:
if ($article-ownerId ==
valugi wrote:
Your example is identical with mine only that you construct the ACL in
place and I get it from a class. But in my case the second return is
true which is very wrong.
Also my object is more complex in terms of resources and roles both with
inheritace levels.
I read
Recently i have been using it to create flyers via a CMS. All data is loaded
from a database and relevant pictures are looked up on the HardDisk.
In the past i've used fpdf (or extended versions of it) a lot for:
- creating invoices
- creating profile-pages
(both based on database-data);
Two
Bryce Lohr-2 wrote:
Hi Martijn,
[...]
Just FYI, the non-ZF package DomPDF
(http://www.digitaljunkies.ca/dompdf/) can convert HTML to PDF. It has
some limitations, but is still useful for many common situations.
Yea, i know, but as you said: it's not ZF :-)
What i meant was that it
Martijn Korse wrote:
I have a problem of which i'm trying to determine whether this is because
i don't understand the ACL mechanism or because it is a bug.
I decided to treat it like a bug and trace what is happening and then found
it's not a bug at all, but in the end me misunderstanding
Martijn Korse wrote:
As soon as i've created a (working) example of my class on my private
website, i'll use that to file a suggestion too.
Here's my code, for those who are interested:
http://devshed.excudo.net/scripts/php/source/excudo+pdf+textblock
-
http://devshed.excudo.net
I have a problem of which i'm trying to determine whether this is because i
don't understand the ACL mechanism or because it is a bug.
When i set an allow rule for a a certain role and then a deny rule for a
child-role and then ask whether the child is allowed to do that, it returns
False,
For those who interested, i issued this as a bug:
http://framework.zend.com/issues/browse/ZF-3701
As soon as i've created a (working) example of my class on my private
website, i'll use that to file a suggestion too.
--
View this message in context:
I've used fpdf a few times (some time ago) and last week took a look at
Zend_Pdf
Let met start by saying i'm really happy with it, as it's so much clearer!
However, i got disappointed quite quickly when it appeared that Zend_Pdf
doesn't do text wrapping of large amounts of text. So, first i did
36 matches
Mail list logo