casting request parameters

119 views
Skip to first unread message

Alex

unread,
Mar 19, 2013, 12:31:02 AM3/19/13
to pha...@googlegroups.com
I found that I'm getting part of the string from request if I'm casting to a string

$request = $di->getShared("request");
$string = $request->get('string', 'string'); // string truncated to 319 chars

$string = $request->get('string'); // full string

 According to the manual strings can be up to 2GB(http://www.php.net/manual/en/language.types.string.php)

It looks like bug in the Phalcon\Http\Request::get()

Please advice.

Andres Gutierrez

unread,
Mar 20, 2013, 2:09:49 PM3/20/13
to pha...@googlegroups.com
Internally it's using the filter extension:

var_dump(filter_var("large string", FILTER_SANITIZE_STRING));

Is this having the problem too?

2013/3/18 Alex <carme...@gmail.com>

--
You received this message because you are subscribed to the Google Groups "Phalcon PHP Framework" group.
To unsubscribe from this group and stop receiving emails from it, send an email to phalcon+u...@googlegroups.com.
To post to this group, send email to pha...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msg/phalcon/-/0qmu7yDUX5sJ.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Alex

unread,
Mar 21, 2013, 12:30:00 AM3/21/13
to pha...@googlegroups.com, andres.g...@phalconphp.com
FILTER_SANITIZE_STRING filter strips tags and I have >< characters in my long string. I guess I need to use different filter for my string.
Reply all
Reply to author
Forward
0 new messages