[fw-general] follow location with Zend_Http?

2008-12-24 Thread Dimitri van Hees

Hello,

Is there a possibility to perform a physical redirect to a page instead 
of getting the response? I want to post data to a remote server but I 
don't want a response, I just want to go to that website! The problem is 
that I don't want to use a form as I want to perform some actions after 
a user clicks the submit button. A quick search on the internet learns 
me that a lot of people just output a form and then quickly send it with 
javascript, but this doesn't look right to me.


I was hoping that Curl's FOLLOW_LOCATION could help me out, but that 
also didn't seem to do the trick.


Is there any way Zend_Http can help me out? Or an other way?

Thanks and a merry Christmas in advance,

Dimitri


Re: [fw-general] Zend_Pdf - Text in Box

2008-09-11 Thread Dimitri van Hees

that's true

Michał Zieliński wrote:

There is no free class which supports everything, afaik. If one gives you
line wrapping than doesn`t support UTF-8.


Dimitri van Hees wrote:
  

this is exactly the reason why i don't use Zend_PDF ;-)

Karol Grecki wrote:


Matthias

There's no ready solution for it, but it can be done.
You can use Style information to calculate line height and how much text
you
can fit on each line
Then you just split it and offset each line 


Karol


Matthias Coy-2 wrote:
  
  

Hi there,

I would like to create a Textbox, in which the text I'm writing is 
automatically wrapped, so that it fits into that box. Is there a 
possibility to do that? As far as I looked through the Manual and Api 
there is no possibilty.


Regards
Matthias Coy




  
  

--

- -

*freshheads* grafisch ontwerp en internet applicaties
Dunantstraat 1c | 5017 KC Tilburg | Nederland
tel. +31 (0)13 5448761 | fax. +31 (0)13 5448762
[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] | www.freshheads.com 
http://www.freshheads.com


Laatste berichten op het Freshheads blog:
Eindelijk, stage @ Freshheads! 
http://blog.freshheads.com/2008/09/eindelijk-stage-freshheads/
?Hé, dit is toch beter dan we dachten? 
http://blog.freshheads.com/2008/09/he-dit-is-toch-beter-dan-we-dachten/
Omroepen kondigen plannen aan tijdens Immovator ZomerCafé 
http://blog.freshheads.com/2008/09/omroepen-kondigen-plannen-aan-tijdens-immovator-zomercafe/






  



--

- -

*freshheads* grafisch ontwerp en internet applicaties
Dunantstraat 1c | 5017 KC Tilburg | Nederland
tel. +31 (0)13 5448761 | fax. +31 (0)13 5448762
[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] | www.freshheads.com 
http://www.freshheads.com


Laatste berichten op het Freshheads blog:
Eindelijk, stage @ Freshheads! 
http://blog.freshheads.com/2008/09/eindelijk-stage-freshheads/
?Hé, dit is toch beter dan we dachten? 
http://blog.freshheads.com/2008/09/he-dit-is-toch-beter-dan-we-dachten/
Omroepen kondigen plannen aan tijdens Immovator ZomerCafé 
http://blog.freshheads.com/2008/09/omroepen-kondigen-plannen-aan-tijdens-immovator-zomercafe/


Re: [fw-general] Inter-page messaging - How do I display information in my layout?

2008-09-10 Thread Dimitri van Hees

i guess you could use flash messages for this.

stav wrote:

After I do a database update action, for example, I can:

$this-view-info_msg = 'Profile updated.';
$this-_forward('index');

and in layout.phtml I can:

?php echo $this-info_msg;  ?

and it shows up, but I wan to use _redirect() instead so they can't refresh
and double-post; but, if I do that my view is destroyed and replaced with a
new one.  Do I have to resort to pushing/popping info messages into the
Registry?
  



--

- -

*freshheads* grafisch ontwerp en internet applicaties
Dunantstraat 1c | 5017 KC Tilburg | Nederland
tel. +31 (0)13 5448761 | fax. +31 (0)13 5448762
[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] | www.freshheads.com 
http://www.freshheads.com


Laatste berichten op het Freshheads blog:
Eindelijk, stage @ Freshheads! 
http://blog.freshheads.com/2008/09/eindelijk-stage-freshheads/
?Hé, dit is toch beter dan we dachten? 
http://blog.freshheads.com/2008/09/he-dit-is-toch-beter-dan-we-dachten/
Omroepen kondigen plannen aan tijdens Immovator ZomerCafé 
http://blog.freshheads.com/2008/09/omroepen-kondigen-plannen-aan-tijdens-immovator-zomercafe/


Re: [fw-general] Zend_Pdf - Text in Box

2008-09-10 Thread Dimitri van Hees

this is exactly the reason why i don't use Zend_PDF ;-)

Karol Grecki wrote:

Matthias

There's no ready solution for it, but it can be done.
You can use Style information to calculate line height and how much text you
can fit on each line
Then you just split it and offset each line 


Karol


Matthias Coy-2 wrote:
  

Hi there,

I would like to create a Textbox, in which the text I'm writing is 
automatically wrapped, so that it fits into that box. Is there a 
possibility to do that? As far as I looked through the Manual and Api 
there is no possibilty.


Regards
Matthias Coy





  



--

- -

*freshheads* grafisch ontwerp en internet applicaties
Dunantstraat 1c | 5017 KC Tilburg | Nederland
tel. +31 (0)13 5448761 | fax. +31 (0)13 5448762
[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] | www.freshheads.com 
http://www.freshheads.com


Laatste berichten op het Freshheads blog:
Eindelijk, stage @ Freshheads! 
http://blog.freshheads.com/2008/09/eindelijk-stage-freshheads/
?Hé, dit is toch beter dan we dachten? 
http://blog.freshheads.com/2008/09/he-dit-is-toch-beter-dan-we-dachten/
Omroepen kondigen plannen aan tijdens Immovator ZomerCafé 
http://blog.freshheads.com/2008/09/omroepen-kondigen-plannen-aan-tijdens-immovator-zomercafe/


[fw-general] recursive data in view?

2008-09-10 Thread Dimitri van Hees

hi,

i've got a category table with recursive subcategories. my question is 
how to output this properly in my view.phtml. i created a function which 
does the job, but what is the best way to output the data to my view? 
should i put the function in my view.phtml? it works for me now, but i'm 
curious what you guys think ;-)


dimitri


[fw-general] Zend_Feed from string

2008-08-15 Thread Dimitri van Hees

Hi list,

I am sorry for bothering you again with this question, but I can't seem 
to find a solution to my problem. I use Zend_Http to fetch a feed so 
that I can handle a timeout in case the providing server is down. For 
another feed I need to login so I use CURL to fetch that feed.


Anyway, my variable $rss is a string containing the contents of the 
feed, like: $feed= '?xml etc. etc.';


I want to use Zend_Feed together with this string, but I can't find how 
to 'convert' this string to a Zend_Feed object. I hoped 
Zend_Feed::importString($feed) would do the trick but it doesn't.


Is there any way to achieve this?

Thanks in advance,

Dimitri


Re: [fw-general] Zend_Feed from string

2008-08-15 Thread Dimitri van Hees
h I'm not sure whether it had something to do with my local 
configuration or with ZF 1.6 RC1, but appearantly after installing RC2 
it indeed works with importString(). great stuff!


thanks for your answer by the way!

Simone Carletti wrote:

Zend_Feed::importString($feed) should be the right solution.
Which error did you receive?

-- Simone

On Fri, Aug 15, 2008 at 3:36 PM, Dimitri van Hees 
[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote:


Hi list,

I am sorry for bothering you again with this question, but I can't
seem to find a solution to my problem. I use Zend_Http to fetch a
feed so that I can handle a timeout in case the providing server
is down. For another feed I need to login so I use CURL to fetch
that feed.

Anyway, my variable $rss is a string containing the contents of
the feed, like: $feed= '?xml etc. etc.';

I want to use Zend_Feed together with this string, but I can't
find how to 'convert' this string to a Zend_Feed object. I hoped
Zend_Feed::importString($feed) would do the trick but it doesn't.

Is there any way to achieve this?

Thanks in advance,

Dimitri





--

- -

*freshheads* grafisch ontwerp en internet applicaties
Dunantstraat 1c | 5017 KC Tilburg | Nederland
tel. +31 (0)13 5448761 | fax. +31 (0)13 5448762
[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] | www.freshheads.com 
http://www.freshheads.com


Laatste berichten op het Freshheads blog:
Meer media aandacht voor Werkspot 
http://blog.freshheads.com/2008/08/meer-media-aandacht-voor-werkspot/
Nieuwe website voor 013 
http://blog.freshheads.com/2008/08/nieuwe-website-voor-013/
Werkspot in de Telegraaf 
http://blog.freshheads.com/2008/08/werkspot-in-de-telegraaf/


Re: [fw-general] zend_feed with curl

2008-08-12 Thread Dimitri van Hees

hi matthew,

thanks for your reply. however, i noticed that Zend_Http does the trick 
with the timeout for me as well. my main problem remains: as 
Zend_Feed:importString appearantly only accepts a PHP string, I don't 
know how to create a feed from a Zend_Http_Response object, a SimpleXML 
object, or a complete string with the source code of the feed. does 
anyone know how to use Zend_Feed together with those response types?


thanks again!

Matthew Weier O'Phinney wrote:

-- Dimitri van Hees [EMAIL PROTECTED] wrote
(on Monday, 11 August 2008, 11:33 PM +0200):
  
is there a possibility to combine zend_feed with curl? the problem i  
encounter is that some of the external feeds i try to fetch are offline  
a lot of the time. for that reason, i'd like to use curl (with an option  
to timeout properly) to retrieve the feed contents. i'd see  
Zend_Feed::importString($curlResult) would do the trick, but it doesn't  
work. perhaps adding a functionality to zend_feed for using it with curl  
is something for the future? does anyone have any other solutions to  
face this problem?



There's a curl adapter for Zend_Http_Client in the incubator currently,
but it isn't completely tested or documented. If you would like to
contribute to that effort, you'd be able to use Zend_Feed with curl by
using the Curl adapter to Zend_Http_Client.

  




[fw-general] zend_feed with curl

2008-08-11 Thread Dimitri van Hees

hello list,

is there a possibility to combine zend_feed with curl? the problem i 
encounter is that some of the external feeds i try to fetch are offline 
a lot of the time. for that reason, i'd like to use curl (with an option 
to timeout properly) to retrieve the feed contents. i'd see 
Zend_Feed::importString($curlResult) would do the trick, but it doesn't 
work. perhaps adding a functionality to zend_feed for using it with curl 
is something for the future? does anyone have any other solutions to 
face this problem?


thanks in advance,

dimitri


[fw-general] confused by dojo isEnabled

2008-08-06 Thread Dimitri van Hees

hi there,

i've been trying out Zend_Dojo today, but to me one thing is still not 
clear. let me explain the situation. i have one layout file 
(default.phtml) in which i have to include the following code:


if ($this-dojo()-isEnabled()):
   $this-dojo()-setLocalPath('/js/dojo/dojo.js')
-addStyleSheetModule('dijit.themes.tundra');
   echo $this-dojo();

my problem is simple: on pages without javascript but with the same 
layout, i get a fatal error because $this-dojo() isn't there. i'm not 
sure whether Zend_Dojo::enableView($view) does this for pages where i 
use dojo, in that case perhaps doing this in my bootstrap file is the 
solution. however, as it is not needed in 95% of my pages, this doesn't 
look right to me.


any suggestions anyone? and is setting $this-dojo()-enable() manually 
right in case i want to use my own javascript instead of zf's generated js?


thanks in advance,

dimitri


[fw-general] re[fw-general] moveDefaultRoutes() points non-existing routes to index?

2008-04-02 Thread Dimitri van Hees

Hello,

In my ZF project, I use some alternate routes. This works fine, however the
default route for this is still active. For example, mysite.com/dj_tiesto is
exactly the same as mysite.com/artists/details/id/10 and
mysite.com/artists/details?id=10.

This means there are different links pointing to one location. As I don't
want to do this, I thought removeDefaultRoutes() would do the trick. Indeed
only mysite.com/dj_tiesto is the only route pointing to the right location,
but the other links (which should be non-existing routes by now since the
default routes are gone) point to my index page??

I want to return a 404 on these links instead of returning the index. Is
this a bug, or does anyone have another idea about how to solve this
problem?

Thanks in advance!
-- 
View this message in context: 
http://www.nabble.com/removeDefaultRoutes%28%29-points-non-existing-routes-to-index--tp16446805p16446805.html
Sent from the Zend Framework mailing list archive at Nabble.com.